Package org.drools.compiler

Examples of org.drools.compiler.FactC


        final AgendaEventListener al = mock( AgendaEventListener.class );
        ksession.addEventListener( al );

        ksession.insert( new FactA( "a" ) );
        ksession.insert( new FactB( "b" ) );
        ksession.insert( new FactC( "c" ) );

        ksession.fireAllRules();
        verify( al,
                times( 8 ) ).afterMatchFired(any(AfterMatchFiredEvent.class));
    }
View Full Code Here


        session = SerializationHelper.getSerialisedStatefulKnowledgeSession( session, kBase, true );

        session.insert( new FactA( 15 ) );
        session.insert( new FactB( 20 ) );
        FactC factC27 = new FactC( 27 );
        session.insert( factC27 );
        FactC factC52 = new FactC( 52 );
        session.insert( factC52 );

        session = SerializationHelper.getSerialisedStatefulKnowledgeSession( session, kBase, true );

        session.fireAllRules();
View Full Code Here

         FactA a = new FactA();
         a.setField1( "a value" );

         ksession.insert( a );
         ksession.insert( new FactB() );
         ksession.insert( new FactC() );

         ksession.fireAllRules();

         assertEquals( "should not have fired",
                       0,
View Full Code Here

         ksession.insert( new FactA() );
         ksession.insert( new FactA() );
         ksession.insert( new FactB() );
         ksession.insert( new FactB() );
         ksession.insert( new FactC() );
         ksession.insert( new FactC() );
         ksession.fireAllRules();

         for ( org.kie.api.runtime.rule.FactHandle fact : ksession.getFactHandles() ) {
             InternalFactHandle internalFact = (InternalFactHandle) fact;
             assertTrue( internalFact.getObject() instanceof FactB );
View Full Code Here

        FactA a = new FactA();
        a.setField1( "a value" );

        ksession.insert( a );
        ksession.insert( new FactB() );
        ksession.insert( new FactC() );

        ksession.fireAllRules();

        assertEquals( "should not have fired",
                      0,
View Full Code Here

        ksession.insert( new FactA() );
        ksession.insert( new FactA() );
        ksession.insert( new FactB() );
        ksession.insert( new FactB() );
        ksession.insert( new FactC() );
        ksession.insert( new FactC() );
        ksession.fireAllRules();

        for ( FactHandle fact : ksession.getFactHandles() ) {
            InternalFactHandle internalFact = (InternalFactHandle) fact;
            assertTrue( internalFact.getObject() instanceof FactB );
View Full Code Here

        FactA a = new FactA();
        a.setField1( "a value" );

        ksession.insert( a );
        ksession.insert( new FactB() );
        ksession.insert( new FactC() );

        ksession.fireAllRules();

        assertEquals( "should not have fired",
                      0,
View Full Code Here

        ksession.insert( new FactA() );
        ksession.insert( new FactA() );
        ksession.insert( new FactB() );
        ksession.insert( new FactB() );
        ksession.insert( new FactC() );
        ksession.insert( new FactC() );
        ksession.fireAllRules();

        for ( org.kie.api.runtime.rule.FactHandle fact : ksession.getFactHandles() ) {
            InternalFactHandle internalFact = (InternalFactHandle) fact;
            assertTrue( internalFact.getObject() instanceof FactB );
View Full Code Here

        session = SerializationHelper.getSerialisedStatefulKnowledgeSession( session, kBase, true );

        session.insert( new FactA( 15 ) );
        session.insert( new FactB( 20 ) );
        FactC factC27 = new FactC( 27 );
        session.insert( factC27 );
        FactC factC52 = new FactC( 52 );
        session.insert( factC52 );

        session = SerializationHelper.getSerialisedStatefulKnowledgeSession( session, kBase, true );

        session.fireAllRules();
View Full Code Here

        FactA a = new FactA();
        a.setField1( "a value" );

        ksession.insert( a );
        ksession.insert( new FactB() );
        ksession.insert( new FactC() );

        ksession.fireAllRules();

        assertEquals( "should not have fired",
                      0,
View Full Code Here

TOP

Related Classes of org.drools.compiler.FactC

Copyright © 2018 www.massapicom. 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.