Package org.drools.grid.io.impl

Examples of org.drools.grid.io.impl.CommandImpl


        this.conversationManager = conversationManager;
    }

    public Address addAddress(String transport) {
        InetSocketAddress[] sockets = (InetSocketAddress[]) ((Address) whitePagesGsd.getAddresses().get( "socket" )).getObject();
        CommandImpl cmd = new CommandImpl( "GridServiceDescription.addAddress",
                                           Arrays.asList( new Object[]{ this.id, transport } ) );
        Address address = (Address) sendMessage( this.conversationManager,
                                                 sockets,
                                                 whitePagesGsd.getId(),
                                                 cmd );
View Full Code Here


        String localId = "query_" + UUID.randomUUID().toString();
        String kresultsId = "kresults_" + this.gsd.getId();
       
       
        CommandImpl cmd = new CommandImpl( "execute",
                                           Arrays.asList( new Object[]{ new SetVariableCommandFromCommand("__TEMP__", localId,
                                                                                new KnowledgeContextResolveFromContextCommand( new QueryRemoteCommand( localId ,
                                                                                                                                                        query, false,
                                                                                                                                                        arguments ),
                                                                                                                                                         null,
View Full Code Here

        return this.id;
    }

    public void removeAddress(String transport) {
        InetSocketAddress[] sockets = (InetSocketAddress[]) ((Address) whitePagesGsd.getAddresses().get( "socket" )).getObject();
        CommandImpl cmd = new CommandImpl( "GridServiceDescription.removeAddress",
                                           Arrays.asList( new Object[]{ id, transport } ) );
        sendMessage( this.conversationManager,
                     sockets,
                     whitePagesGsd.getId(),
                     cmd );
View Full Code Here

    }

    public FactHandle insert(Object object) {

        String kresultsId = "kresults_" + this.gsd.getId();
        CommandImpl cmd = new CommandImpl( "execute",
                                           Arrays.asList( new Object[]{new KnowledgeContextResolveFromContextCommand( new InsertObjectCommand( object,
                                                                                                                                               true ),
                                                                                                                      null,
                                                                                                                      null,
                                                                                                                      this.instanceId,
View Full Code Here

        return this.serviceInterface;
    }

    public void setServiceInterface(Class cls) {
        InetSocketAddress[] sockets = (InetSocketAddress[]) ((Address) whitePagesGsd.getAddresses().get( "socket" )).getObject();
        CommandImpl cmd = new CommandImpl( "GridServiceDescription.setServiceInterface",
                                           Arrays.asList( new Object[]{ id, cls } ) );
        sendMessage( this.conversationManager,
                     sockets,
                     whitePagesGsd.getId(),
                     cmd );
View Full Code Here

        return (FactHandle) result;
    }

    public void retract(FactHandle handle) {
        String kresultsId = "kresults_" + this.gsd.getId();
        CommandImpl cmd = new CommandImpl( "execute",
                                           Arrays.asList( new Object[]{new KnowledgeContextResolveFromContextCommand( CommandFactory.newRetract( handle ),
                                                                                                                      null,
                                                                                                                      null,
                                                                                                                      this.instanceId,
                                                                                                                      kresultsId )} ) );
View Full Code Here

        return hash;
    }

    public Serializable getData() {
        InetSocketAddress[] sockets = (InetSocketAddress[]) ((Address) whitePagesGsd.getAddresses().get( "socket" )).getObject();
        CommandImpl cmd = new CommandImpl( "GridServiceDescription.getData",
                                           null );
        Serializable data = (Serializable) sendMessage( this.conversationManager,
                                                        sockets,
                                                        whitePagesGsd.getId(),
                                                        cmd );
View Full Code Here

        return data;
    }

    public void setData(Serializable data) {
        InetSocketAddress[] sockets = (InetSocketAddress[]) ((Address) whitePagesGsd.getAddresses().get( "socket" )).getObject();
        CommandImpl cmd = new CommandImpl( "GridServiceDescription.setData",
                                           Arrays.asList( new Object[]{ data } ) );
        sendMessage( this.conversationManager,
                     sockets,
                     whitePagesGsd.getId(),
                     cmd );
View Full Code Here

    }

    public void update(FactHandle handle,
                       Object object) {
        String kresultsId = "kresults_" + this.gsd.getId();
        CommandImpl cmd = new CommandImpl( "execute",
                                           Arrays.asList( new Object[]{new KnowledgeContextResolveFromContextCommand( new UpdateCommand( handle,
                                                                                                                                         object ),
                                                                                                                      null,
                                                                                                                      null,
                                                                                                                      this.instanceId,
View Full Code Here

                                      cmd );
    }

    public FactHandle getFactHandle(Object object) {
        String kresultsId = "kresults_" + this.gsd.getId();
        CommandImpl cmd = new CommandImpl( "execute",
                                           Arrays.asList( new Object[]{new KnowledgeContextResolveFromContextCommand( new GetFactHandleCommand( object,
                                                                                                                                                true ),
                                                                                                                      null,
                                                                                                                      null,
                                                                                                                      this.instanceId,
View Full Code Here

TOP

Related Classes of org.drools.grid.io.impl.CommandImpl

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.