Class CompositeActivity
java.lang.Object
org.cristalise.kernel.graph.model.Vertex
org.cristalise.kernel.graph.model.GraphableVertex
org.cristalise.kernel.lifecycle.instance.WfVertex
org.cristalise.kernel.lifecycle.instance.Activity
org.cristalise.kernel.lifecycle.instance.CompositeActivity
- Direct Known Subclasses:
PredefinedStepContainer,Workflow
-
Nested Class Summary
Nested classes/interfaces inherited from class org.cristalise.kernel.lifecycle.instance.WfVertex
WfVertex.Types -
Field Summary
Fields inherited from class org.cristalise.kernel.lifecycle.instance.Activity
active, mErrors, PREDEF_STEPS_ELEMENT, state, XPATH_TOKENFields inherited from class org.cristalise.kernel.graph.model.GraphableVertex
mIsComposite -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidabort(AgentPath agentPath, ItemPath itemPath, TransactionKey transactionKey) addNext(int originID, int terminusID) calculateAllJobs(AgentPath agent, ItemPath itemPath, boolean recurse) calculateJobs(AgentPath agent, ItemPath itemPath, boolean recurse) Calculates the lists of jobs for the activity and its children (cf org.cristalise.kernel.entity.Job)getPossibleActs(WfVertex fromVertex, int direction) getType()Returns the type.booleanbooleanvoidinitChild(WfVertex vertex, boolean first, GraphPoint point) Initialise Vertex and attach to the current activityprotected booleanChecks if the CompositeActivity can be finished by checking if there is no further Activities to be executed at its current state.protected booleanisFinishable(WfVertex lastVertex) Checks if the CompositeActivity can be finished by checking if there is no further Activities to be executed at its current state.protected booleannewAtomChild(String id, boolean first, GraphPoint point) newChild(String Name, String Type, GraphPoint point) newChild(String vertexTypeId, GraphPoint point) newChild(WfVertex.Types type, String name, boolean first, GraphPoint point) newCompChild(String id, boolean first, GraphPoint point) newExistingChild(Activity child, String Name, GraphPoint point) newJoinChild(String name, String type, boolean first, GraphPoint point) newSplitChild(String name, String Type, boolean first, GraphPoint point) voidreinit(int idLoop) reinitialises the Activity and propagate (for Loop)request(AgentPath agent, ItemPath itemPath, int transitionID, String requestData, String attachmentType, byte[] attachment, TransactionKey transactionKey) voidrun(TransactionKey transactionKey) called by precedent Activity runNext() for setting the activity able to be executedvoidrunNext(TransactionKey transactionKey) sets the next activity available if possiblevoidsetChildrenGraphModel(GraphModel childrenGraph) Sets the childrenGraph.voidsetFirstVertex(int vertexID) booleanverify()launch the verification of the subprocess()Methods inherited from class org.cristalise.kernel.lifecycle.instance.Activity
addNext, getActive, getCurrentAgentName, getCurrentAgentRole, getDescription, getErrors, getErrorTransitionId, getNext, getState, getStateDate, getStateMachine, getStateMachine, getStateName, getTypeName, isFinished, loop, request, runActivityLogic, runFirst, setActive, setActiveDate, setStartDate, setState, setStateDate, setType, toStringMethods inherited from class org.cristalise.kernel.lifecycle.instance.WfVertex
evaluateProperty, evaluatePropertyValue, evaluateScript, findLastVertex, findPair, getActContext, getWfMethods inherited from class org.cristalise.kernel.graph.model.GraphableVertex
addChild, deriveVersionNumber, getBuiltInProperty, getBuiltInProperty, getCentrePoint, getChildren, getChildrenEdges, getChildrenGraphModel, getCreationContext, getInEdgeIds, getInEdges, getInGraphables, getIsComposite, getIsLayoutable, getKeyValuePairs, getLayoutableChildren, getOtherPairingID, getOutEdgeIds, getOutEdges, getOutGraphables, getOutlinePoints, getPairingId, getParent, getPath, getProperties, isMyPair, search, setBuiltInProperty, setIsComposite, setIsLayoutable, setKeyValuePairs, setParent, setProperties, updatePropertiesFromCollection, updatePropertiesFromCollectionMethods inherited from class org.cristalise.kernel.graph.model.Vertex
addInEdgeId, addOutEdgeId, clearTag, containsPoint, hasTag, isJoin, isLoop, moveAbsolute, removeInEdgeId, removeOutEdgeId, setInEdgeIds, setOutEdgeIds, setOutlinePoints, setTag
-
Constructor Details
-
CompositeActivity
public CompositeActivity()
-
-
Method Details
-
setChildrenGraphModel
Description copied from class:GraphableVertexSets the childrenGraph.- Overrides:
setChildrenGraphModelin classGraphableVertex- Parameters:
childrenGraph- The childrenGraph to set- Throws:
InvalidDataException- - if the graph model wasn't valid in this context
-
verify
public boolean verify()launch the verification of the subprocess() -
initChild
Initialise Vertex and attach to the current activity- Parameters:
vertex- the vertex to be initialisedfirst- if true, the Waiting state will be one of the first launched by the parent activitypoint- the location of the vertex in the graph
-
setFirstVertex
public void setFirstVertex(int vertexID) -
newExistingChild
-
newChild
-
newChild
-
newChild
-
newCompChild
-
newAtomChild
-
newSplitChild
-
newJoinChild
-
run
Description copied from class:Activitycalled by precedent Activity runNext() for setting the activity able to be executed- Overrides:
runin classActivity- Throws:
InvalidDataException
-
isStartable
- Returns:
- Throws:
InvalidDataException
-
isFinishable
Checks if the CompositeActivity can be finished by checking if there is no further Activities to be executed at its current state.- Returns:
- whether the CompositeActivity can be finished or not
- Throws:
InvalidDataException- current data of CompositeActivity was inconsistent
-
isFinishable
Checks if the CompositeActivity can be finished by checking if there is no further Activities to be executed at its current state.- Parameters:
lastVertex- of the current CompositeActivity is used as a starting point for the checking- Returns:
- whether the CompositeActivity can be finished or not
- Throws:
InvalidDataException- current data of CompositeActivity was inconsistent
-
runNext
Description copied from class:Activitysets the next activity available if possible- Overrides:
runNextin classActivity- Throws:
InvalidDataException
-
calculateJobs
public ArrayList<Job> calculateJobs(AgentPath agent, ItemPath itemPath, boolean recurse) throws ObjectNotFoundException, InvalidDataException Description copied from class:ActivityCalculates the lists of jobs for the activity and its children (cf org.cristalise.kernel.entity.Job)- Overrides:
calculateJobsin classActivity- Throws:
ObjectNotFoundExceptionInvalidDataException
-
calculateAllJobs
public ArrayList<Job> calculateAllJobs(AgentPath agent, ItemPath itemPath, boolean recurse) throws ObjectNotFoundException, InvalidDataException - Overrides:
calculateAllJobsin classActivity- Throws:
ObjectNotFoundExceptionInvalidDataException
-
addNext
-
addNext
-
hasGoodNumberOfActivity
public boolean hasGoodNumberOfActivity() -
getType
Description copied from class:ActivityReturns the type. -
reinit
Description copied from class:Activityreinitialises the Activity and propagate (for Loop)- Overrides:
reinitin classActivity- Throws:
InvalidDataException
-
abort
public void abort(AgentPath agentPath, ItemPath itemPath, TransactionKey transactionKey) throws AccessRightsException, InvalidTransitionException, InvalidDataException, ObjectNotFoundException, PersistencyException, ObjectAlreadyExistsException, ObjectCannotBeUpdated, CannotManageException, InvalidCollectionModification -
hasActive
public boolean hasActive() -
request
public String request(AgentPath agent, ItemPath itemPath, int transitionID, String requestData, String attachmentType, byte[] attachment, TransactionKey transactionKey) throws AccessRightsException, InvalidTransitionException, InvalidDataException, ObjectNotFoundException, PersistencyException, ObjectAlreadyExistsException, ObjectCannotBeUpdated, CannotManageException, InvalidCollectionModification -
getPossibleActs
public List<Activity> getPossibleActs(WfVertex fromVertex, int direction) throws InvalidDataException - Throws:
InvalidDataException
-