oracle.apps.fnd.wf.engine
Class EngineBaseComponent

java.lang.Object
  |
  +--oracle.apps.fnd.wf.common.Element
        |
        +--oracle.apps.fnd.wf.common.BaseComponent
              |
              +--oracle.apps.fnd.wf.engine.EngineBaseComponent
Direct Known Subclasses:
Fault, RuntimeStore, WorkItem, WorkItemProcessActivity

public class EngineBaseComponent
extends BaseComponent


Field Summary
static java.lang.String ACTIVE
           
static java.lang.String BLOCK
           
static java.lang.String CANCELLED
           
static java.lang.String COMPLETE
           
static java.lang.String ERROR
           
static java.lang.String FORCED_COMPLETE
           
static java.lang.String NOT_INITIALIZED
           
static java.lang.String RCS_ID
           
static boolean RCS_ID_RECORDED
           
static java.lang.String SUSPENDED
           
static java.lang.String WAITING
           
 
Fields inherited from class oracle.apps.fnd.wf.common.Element
ELEMENT_DB_CREATED, ELEMENT_DB_CREATING, ELEMENT_DB_DIRTY, ELEMENT_DB_LOADED, ELEMENT_DB_LOADING, ELEMENT_DB_NOT_INITIALIZED, ELEMENT_DB_SAVED, ELEMENT_DB_SAVING
 
Method Summary
 void addChild(BaseComponent pChild)
          Override the parent method to make sure all the children has the same workItem
 AttributeValue getAttributeValue(java.lang.String pAttributeName)
          This method returns an attribute of the same name in the current attribute value list or null
 java.util.List getAttributeValues()
          Retrieve attribute values from database if needed
 long getEndDate()
           
 java.lang.String getInstancePath()
          This is information method could be used to identify the instance of this component.
 DesignBaseComponent getMetaType()
          DesignStore entity reference of this engine component.
 long getStartDate()
           
 java.lang.String getStatus()
          Return current runtime status of this component.
 WorkItem getWorkItem()
          Each process activity must belong to a workitem.
 boolean isActive()
          Convenient method to test if the component is still to be executed.
 boolean isComplete()
          Convenient method to test if the component has finished execution.
 void save(WorkflowContext pCtx)
          For internal use only.
 void setAttributeValue(java.lang.String pAttributeName, java.lang.Object pValue)
          Set a name attribute value to a base component.
 void setAttributeValues(java.util.Map pValues)
          Set attribute value in bulk
 void setMetaType(DesignBaseComponent pMetaData)
          Sets DesignStore entity reference of this engine component.
 void setStatus(java.lang.String pStatus)
          Change status of this component, should only be used by engines internally.
 
Methods inherited from class oracle.apps.fnd.wf.common.BaseComponent
getChildByTypeAndName, getChildren, getChildrenByName, getChildrenByType, getName, getParent, removeChild, removeChildren
 
Methods inherited from class oracle.apps.fnd.wf.common.Element
create, getDBStatus, getId, load, setStore, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RCS_ID

public static final java.lang.String RCS_ID

RCS_ID_RECORDED

public static final boolean RCS_ID_RECORDED

NOT_INITIALIZED

public static java.lang.String NOT_INITIALIZED

CANCELLED

public static java.lang.String CANCELLED

BLOCK

public static java.lang.String BLOCK

COMPLETE

public static java.lang.String COMPLETE

ACTIVE

public static java.lang.String ACTIVE

SUSPENDED

public static java.lang.String SUSPENDED

ERROR

public static java.lang.String ERROR

WAITING

public static java.lang.String WAITING

FORCED_COMPLETE

public static java.lang.String FORCED_COMPLETE
Method Detail

setAttributeValue

public void setAttributeValue(java.lang.String pAttributeName,
                              java.lang.Object pValue)
                       throws WorkflowException
Set a name attribute value to a base component. If an attribute value with the same name already exists, old value will be overriden, provide new and old are the same type. Otherwise, a new value will be added to this component
Parameters:
pCtx - context the engine runs in
pAttributeName - name of the attribute of this component.
pValue - an attribute object which can be one of the following type BigDecimal Date String
Returns:
attribute object. This value would be null, if the named attribute is not defined for this component
Throws:
WorkflowException - thrown

getStatus

public java.lang.String getStatus()
Return current runtime status of this component. It will refresh from the loader before return the vlaue. This method is only used internally by engines.
Returns:
statusCode : int

setStatus

public void setStatus(java.lang.String pStatus)
Change status of this component, should only be used by engines internally.
Parameters:
pStatus - : int new status for the component. Does not flush to loader. Engine must explicitly call save to persist the status.

isComplete

public boolean isComplete()
Convenient method to test if the component has finished execution.
Returns:
completed : boolean indicates status of the component

isActive

public boolean isActive()
Convenient method to test if the component is still to be executed.
Returns:
active : boolean indicates status of the component

getWorkItem

public WorkItem getWorkItem()
Each process activity must belong to a workitem. Workitem is an instance of a item type, which acts as a container for all runtime instance of this particular itemtype. It also hold an context that sets up the runtime env for all process activities. Workitem is assigned to a process activity when it is created by its process
Returns:
return-value

addChild

public void addChild(BaseComponent pChild)
Override the parent method to make sure all the children has the same workItem
Overrides:
addChild in class BaseComponent
Following copied from class: oracle.apps.fnd.wf.common.BaseComponent
Parameters:
child - : BaseComponent child to be added.

getInstancePath

public java.lang.String getInstancePath()
This is information method could be used to identify the instance of this component.
Returns:
instancePath : String identification of this instance in runtime store.

getMetaType

public DesignBaseComponent getMetaType()
DesignStore entity reference of this engine component.
Returns:
metaName : DesignBaseComponentDesignStore entity reference

setMetaType

public void setMetaType(DesignBaseComponent pMetaData)
Sets DesignStore entity reference of this engine component.
Parameters:
pMetaData - :DesignBaseComponentDesignStore entity reference

getAttributeValues

public java.util.List getAttributeValues()
Retrieve attribute values from database if needed
Returns:
list of AttributeValues

setAttributeValues

public void setAttributeValues(java.util.Map pValues)
                        throws WorkflowException
Set attribute value in bulk
Parameters:
pCtx - Parameter
pValues - Parameter
Throws:
WorkflowException - Exception

getAttributeValue

public AttributeValue getAttributeValue(java.lang.String pAttributeName)
This method returns an attribute of the same name in the current attribute value list or null
Parameters:
pAttributeName - Parameter
Returns:
return-value

save

public void save(WorkflowContext pCtx)
          throws WorkflowException
Description copied from class: Element
For internal use only. Save this object to a persistent medium.
Overrides:
save in class Element
Following copied from class: oracle.apps.fnd.wf.common.Element
Parameters:
pCtx - Parameter
Throws:
WorkflowException - Exception

getStartDate

public long getStartDate()

getEndDate

public long getEndDate()