Package org.drools.command.runtime

Examples of org.drools.command.runtime.SetGlobalCommand


    public Command newSetGlobal(String identifier, Object object) {
        return new SetGlobalCommand(identifier, object);
    }

    public Command newSetGlobal(String identifier, Object object, boolean out) {
        SetGlobalCommand cmd = new SetGlobalCommand(identifier, object);
        cmd.setOut(out);
        return cmd;
    }
View Full Code Here


        return cmd;
    }

    public Command newSetGlobal(String identifier, Object object,
            String outIdentifier) {
        SetGlobalCommand cmd = new SetGlobalCommand(identifier, object);
        cmd.setOutIdentifier(outIdentifier);
        return cmd;
    }
View Full Code Here

        return commandService.execute( new GetGlobalCommand( identifier ) );
    }

    public void setGlobal(String identifier,
                          Object object) {
        this.commandService.execute( new SetGlobalCommand( identifier,
                                                           object ) );
    }
View Full Code Here

        return commandService.execute( new GetGlobalCommand( identifier ) );
    }

    public void setGlobal(String identifier,
                          Object object) {
        this.commandService.execute( new SetGlobalCommand( identifier,
                                                           object ) );
    }
View Full Code Here

    public Command newGetObjects(ObjectFilter filter, String outIdentifier) {
        return new GetObjectsCommand(filter, outIdentifier);
    }

    public Command newSetGlobal(String identifier, Object object) {
        return new SetGlobalCommand(identifier, object);
    }
View Full Code Here

        }
    }

    public Command newSetGlobal(String identifier, Object object,
            String outIdentifier) {
        SetGlobalCommand cmd = new SetGlobalCommand(identifier, object);
        cmd.setOutIdentifier(outIdentifier);
        return cmd;
    }
View Full Code Here

        return this;
    }

    public StatefulKnowledgeSessionSimFluent setGlobal(String identifier,
                                                            Object object) {
        addCommand(new SetGlobalCommand(identifier, object));
        return this;
    }   
View Full Code Here

        throw new UnsupportedOperationException(
                "FluentBatchExecutionImpl duplicates DefaultStatefulKnowledgeSessionSimFluent");
    }

    public FluentBatchExecution setGlobal(String identifier, Object object) {
        lastAddedCommand = new SetGlobalCommand(identifier, object);
        addCommand(lastAddedCommand);
        return this;
    }
View Full Code Here

/**
* Class for transforming a SetGlobal command.
*/
class SetGlobalTransformer extends CommandTransformer {
  public GenericCommand<?> transform(CommandTranslator ct, Object o, Unmarshaller unmarshaller) {
    SetGlobalCommand sg = (SetGlobalCommand)o;
    Object object = sg.getObject();
    if (object instanceof Element) {
      Element el = (Element)object;
      Object obj = ct.makeObject(el , unmarshaller);
      sg.setObject(obj);
    }
    return sg;
  }
View Full Code Here

        List<GenericCommand< ? >> cmds = new ArrayList<GenericCommand< ? >>();
        cmds.add( new InsertObjectCommand( new Person( "darth",
                                                       21 ),
                                           "p" ) );
        cmds.add( new GetGlobalCommand( "xxx" ) );
        cmds.add( new SetGlobalCommand( "yyy",
                                        new Person( "yoda",
                                                    21 ) ) );
        BatchExecutionCommandImpl batch = new BatchExecutionCommandImpl( cmds );

        Marshaller marshaller = jaxbContext.createMarshaller();
View Full Code Here

TOP

Related Classes of org.drools.command.runtime.SetGlobalCommand

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.