Knowledge API Legacy5 Adapter 6.0.0.CR4-Pre1

org.drools.impl.adapters
Class WorkItemAdapter

java.lang.Object
  extended by org.drools.impl.adapters.WorkItemAdapter
All Implemented Interfaces:
WorkItem

public class WorkItemAdapter
extends Object
implements WorkItem


Field Summary
 org.kie.api.runtime.process.WorkItem delegate
           
 
Fields inherited from interface org.drools.runtime.process.WorkItem
ABORTED, ACTIVE, COMPLETED, PENDING
 
Constructor Summary
WorkItemAdapter(org.kie.api.runtime.process.WorkItem delegate)
           
 
Method Summary
 long getId()
          The unique id of this work item
 String getName()
          The name of the work item.
 Object getParameter(String name)
          Returns the value of the parameter with the given name.
 Map<String,Object> getParameters()
          Returns the map of parameters of this work item.
 long getProcessInstanceId()
          The id of the process instance that requested the execution of this work item
 Object getResult(String name)
          Returns the value of the result parameter with the given name.
 Map<String,Object> getResults()
          Returns the map of result parameters of this work item.
 int getState()
          The state of the work item.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

delegate

public org.kie.api.runtime.process.WorkItem delegate
Constructor Detail

WorkItemAdapter

public WorkItemAdapter(org.kie.api.runtime.process.WorkItem delegate)
Method Detail

getId

public long getId()
Description copied from interface: WorkItem
The unique id of this work item

Specified by:
getId in interface WorkItem
Returns:
the id of this work item

getName

public String getName()
Description copied from interface: WorkItem
The name of the work item. This represents the type of work that should be executed.

Specified by:
getName in interface WorkItem
Returns:
the name of the work item

getState

public int getState()
Description copied from interface: WorkItem
The state of the work item.

Specified by:
getState in interface WorkItem
Returns:
the state of the work item

getParameter

public Object getParameter(String name)
Description copied from interface: WorkItem
Returns the value of the parameter with the given name. Parameters can be used to pass information necessary for the execution of this work item. Returns null if the parameter cannot be found.

Specified by:
getParameter in interface WorkItem
Parameters:
name - the name of the parameter
Returns:
the value of the parameter

getParameters

public Map<String,Object> getParameters()
Description copied from interface: WorkItem
Returns the map of parameters of this work item. Parameters can be used to pass information necessary for the execution of this work item.

Specified by:
getParameters in interface WorkItem
Returns:
the map of parameters of this work item

getResult

public Object getResult(String name)
Description copied from interface: WorkItem
Returns the value of the result parameter with the given name. Result parameters can be used to pass information related the result of the execution of this work item. Returns null if the result cannot be found.

Specified by:
getResult in interface WorkItem
Parameters:
name - the name of the result parameter
Returns:
the value of the result parameter

getResults

public Map<String,Object> getResults()
Description copied from interface: WorkItem
Returns the map of result parameters of this work item. Result parameters can be used to pass information related the result of the execution of this work item.

Specified by:
getResults in interface WorkItem
Returns:
the map of results of this work item

getProcessInstanceId

public long getProcessInstanceId()
Description copied from interface: WorkItem
The id of the process instance that requested the execution of this work item

Specified by:
getProcessInstanceId in interface WorkItem
Returns:
the id of the related process instance

Knowledge API Legacy5 Adapter 6.0.0.CR4-Pre1

Copyright © 2001-2013 JBoss by Red Hat. All Rights Reserved.