Examples of immediateParents()


Examples of org.drools.core.util.HierarchyEncoderImpl.immediateParents()

        x = encoder.upperBorder( encoder.metMembersCode( Arrays.asList( "B" ) ) );
        System.out.println( "LCS " + x );
        assertEquals( 1, x.size() );
        assertTrue( x.contains( "B" ) );

        x = encoder.immediateParents( encoder.metMembersCode( Arrays.asList( "B" ) ) );
        System.out.println( "LCS " + x );
        assertEquals( 2, x.size() );
        assertTrue( x.contains( "A" ) );
        assertTrue( x.contains( "Z" ) );
View Full Code Here

Examples of org.drools.core.util.HierarchyEncoderImpl.immediateParents()

        System.out.println( "LCS " + x );

        assertEquals( 1, x.size() );
        assertTrue( x.contains( "Thing" ) );

        x = encoder.immediateParents( encoder.jointMembersCode( Arrays.asList( "Z", "Q" ) ) );
        System.out.println( "LCS " + x );

        assertEquals( 1, x.size() );
        assertTrue( x.contains( "Thing" ) );
View Full Code Here

Examples of org.drools.core.util.HierarchyEncoderImpl.immediateParents()

        assertEquals( 2, x.size() );
        assertTrue( x.contains( "A" ) );
        assertTrue( x.contains( "Z" ) );

        x = encoder.immediateParents( encoder.jointMembersCode( Arrays.asList( "B", "C" ) ) );
        System.out.println( "LCS " + x );

        assertEquals( 2, x.size() );
        assertTrue( x.contains( "A" ) );
        assertTrue( x.contains( "Z" ) );
View Full Code Here

Examples of org.drools.core.util.HierarchyEncoderImpl.immediateParents()

        System.out.println( "LCS " + x );

        assertEquals( 1, x.size() );
        assertTrue( x.contains( "T" ) );

        x = encoder.immediateParents( encoder.jointMembersCode( Arrays.asList( "T" ) ) );
        System.out.println( "LCS " + x );

        assertEquals( 2, x.size() );
        assertTrue( x.contains( "C" ) );
        assertTrue( x.contains( "Q" ) );
View Full Code Here

Examples of org.drools.factmodel.traits.TraitTypeMap.immediateParents()

                        // Example: given classes A <- B <-C, at OTN A, a proxy c can only pass if no proxy b exists

                        TraitableBean txBean = (TraitableBean) proxy.getObject();
                        TraitTypeMap tMap = (TraitTypeMap) txBean._getTraitMap();
                        Collection<Thing> x = tMap.immediateParents( this.typeMask );
                        Thing k = x.iterator().next();

                        long originalMask = context.getModificationMask();
                        if ( ! k.isTop() ) {
                            ((PropagationContextImpl) context).setModificationMask( -1L );
View Full Code Here

Examples of org.drools.factmodel.traits.TraitTypeMap.immediateParents()

                        // Example: given classes A <- B <-C, at OTN A, a proxy c can only pass if no proxy b exists

                        TraitableBean txBean = (TraitableBean) proxy.getObject();
                        TraitTypeMap tMap = (TraitTypeMap) txBean._getTraitMap();
                        Collection<Key<Thing>> x = tMap.immediateParents( this.typeMask );
                        Key<Thing> k = x.iterator().next();

                        long originalMask = context.getModificationMask();
                        if ( ! k.getValue().isTop() ) {
                            ((PropagationContextImpl) context).setModificationMask( -1L );
View Full Code Here

Examples of org.drools.util.HierarchyEncoder.immediateParents()

        x = encoder.upperBorder( encoder.metMembersCode( Arrays.asList( "B" ) ) );
        System.out.println( "LCS " + x );
        assertEquals( 1, x.size() );
        assertTrue( x.contains( "B" ) );

        x = encoder.immediateParents( encoder.metMembersCode( Arrays.asList( "B" ) ) );
        System.out.println( "LCS " + x );
        assertEquals( 2, x.size() );
        assertTrue( x.contains( "A" ) );
        assertTrue( x.contains( "Z" ) );
View Full Code Here

Examples of org.drools.util.HierarchyEncoder.immediateParents()

        System.out.println( "LCS " + x );

        assertEquals( 1, x.size() );
        assertTrue( x.contains( "Thing" ) );

        x = encoder.immediateParents( encoder.jointMembersCode( Arrays.asList( "Z", "Q" ) ) );
        System.out.println( "LCS " + x );

        assertEquals( 1, x.size() );
        assertTrue( x.contains( "Thing" ) );
View Full Code Here

Examples of org.drools.util.HierarchyEncoder.immediateParents()

        assertEquals( 2, x.size() );
        assertTrue( x.contains( "A" ) );
        assertTrue( x.contains( "Z" ) );

        x = encoder.immediateParents( encoder.jointMembersCode( Arrays.asList( "B", "C" ) ) );
        System.out.println( "LCS " + x );

        assertEquals( 2, x.size() );
        assertTrue( x.contains( "A" ) );
        assertTrue( x.contains( "Z" ) );
View Full Code Here

Examples of org.drools.util.HierarchyEncoder.immediateParents()

        System.out.println( "LCS " + x );

        assertEquals( 1, x.size() );
        assertTrue( x.contains( "T" ) );

        x = encoder.immediateParents( encoder.jointMembersCode( Arrays.asList( "T" ) ) );
        System.out.println( "LCS " + x );

        assertEquals( 2, x.size() );
        assertTrue( x.contains( "C" ) );
        assertTrue( x.contains( "Q" ) );
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.