Package org.drools.grid.NodeTests

Examples of org.drools.grid.NodeTests.MyObject


    
     @Ignore // FIX
     public void getFactHandleTest() {
        StatefulKnowledgeSession ksession = createSession();
       
        ksession.setGlobal("myGlobalObj", new MyObject("myglobalObj"));
        MyObject obj1 = new MyObject("obj1");
        FactHandle handle = ksession.insert(obj1);
         System.out.println("Handle Identity HashCode -> "+handle.toExternalForm());
        Assert.assertNotNull(handle);
        Assert.assertEquals(true, ((DefaultFactHandle)handle).isDisconnected());
        // The session assertMap doesn't find the factHandle for this object
View Full Code Here


    
     @Test
     public void getFactHandlesTest() {
        StatefulKnowledgeSession ksession = createSession();
       
        ksession.setGlobal("myGlobalObj", new MyObject("myglobalObj"));
        MyObject obj1 = new MyObject("obj1");
        FactHandle handle = ksession.insert(obj1);
        Assert.assertNotNull(handle);
        Assert.assertEquals(true, ((DefaultFactHandle)handle).isDisconnected());
         System.out.println("Handle Identity HashCode -> "+handle.toExternalForm());
        
View Full Code Here

    
      @Test
     public void getObjectTest() {
        StatefulKnowledgeSession ksession = createSession();
       
        ksession.setGlobal("myGlobalObj", new MyObject("myglobalObj"));
        MyObject obj1 = new MyObject("obj1");
        FactHandle handle = ksession.insert(obj1);
        Assert.assertNotNull(handle);
        Assert.assertEquals(true, ((DefaultFactHandle)handle).isDisconnected());
       
        Object result = ksession.getObject(handle);
View Full Code Here

     
      @Test
     public void queryTest() {
        StatefulKnowledgeSession ksession = createSession();
       
        ksession.setGlobal("myGlobalObj", new MyObject("myglobalObj"));
        MyObject obj1 = new MyObject("obj1");
        FactHandle handle = ksession.insert(obj1);
        Assert.assertNotNull(handle);
        Assert.assertEquals(true, ((DefaultFactHandle)handle).isDisconnected());
       
        Object result = ksession.getObject(handle);
View Full Code Here

TOP

Related Classes of org.drools.grid.NodeTests.MyObject

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.