Class AgentProxy
java.lang.Object
org.cristalise.kernel.entity.proxy.ItemProxy
org.cristalise.kernel.entity.proxy.AgentProxy
It is a wrapper for the connection and communication with Agent It caches
data loaded from the Agent to reduce communication
-
Field Summary
Fields inherited from class org.cristalise.kernel.entity.proxy.ItemProxy
mItem, mItemPath, transactionKey -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAgentProxy(AgentPath agentPath) Creates an AgentProxy without cache and change notificationprotectedAgentProxy(AgentPath agentPath, TransactionKey transKey) -
Method Summary
Modifier and TypeMethodDescriptionStandard execution of jobs.Extended execution of jobs when the client knows that there is a Transition to be used in case of an error.Execution without any parameters using Class of predefined step instead of string literal.Single parameter execution using Class of predefined step instead of string literal.execute(ItemProxy item, Class<?> predefStep, C2KLocalObject obj) Execution without any parameters.Single parameter execution.Multi-parameter execution.execute(ItemProxy item, String predefStep, C2KLocalObject obj) getItemByUUID(String uuid) getPath()Return the ItemPath object of the Item this proxy is linked withRolePath[]getRoles()searchItem(String name) searchItem(Path root, String name) Let scripts resolve itemssearchItems(Path start, Property[] props) searchItems(Path start, PropertyDescriptionList props) Methods inherited from class org.cristalise.kernel.entity.proxy.ItemProxy
checkCollection, checkCollection, checkCollection, checkCollection, checkContent, checkContent, checkContent, checkContent, checkJobForAgent, checkOutcome, checkOutcome, checkOutcome, checkOutcome, checkOutcomeAttachment, checkOutcomeAttachment, checkProperty, checkProperty, checkProperty, checkProperty, checkViewpoint, checkViewpoint, clearCache, executeQuery, getAggregateScript, getAggregateScript, getCollection, getCollection, getCollection, getCollection, getCollection, getCollection, getCollection, getCollection, getContents, getContents, getContents, getContents, getEvent, getEvent, getHistory, getHistory, getItem, getJob, getJob, getJobByName, getJobByTransitionName, getJobByTransitionName, getJobs, getJobs, getJobs, getJobs, getJobs, getMasterSchema, getMasterSchema, getName, getName, getObject, getObject, getObject, getObject, getOutcome, getOutcome, getOutcome, getOutcome, getOutcome, getOutcome, getOutcome, getOutcome, getOutcomeAttachment, getOutcomeAttachment, getOutcomeAttachment, getOutcomeAttachment, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getType, getType, getUpdateSchema, getUuid, getViewpoint, getViewpoint, getViewpoints, getViewpoints, getWorkflow, getWorkflow, marshall, queryData, queryData, requestAction, requestAction, setProperty, toString, unmarshall
-
Constructor Details
-
AgentProxy
Creates an AgentProxy without cache and change notification- Parameters:
agentPath-ior-- Throws:
ObjectNotFoundException
-
AgentProxy
-
-
Method Details
-
execute
Extended execution of jobs when the client knows that there is a Transition to be used in case of an error. All execution parameters are taken from the job where they're probably going to be correct.- Parameters:
job- the Actual Job to be executederrorJob- the Job the be executed in case there was an exception while executing the original Job. The client calling this method knows (configured) which Job is need to be used.- Returns:
- The outcome after processing. May have been altered by the step. Aternatively it contains the xml of marshalles ErrorInfo if the errorJob was exeuted
- Throws:
AccessRightsException- The agent was not allowed to execute this stepInvalidDataException- The parameters supplied were incorrectInvalidTransitionException- The step wasn't availableObjectNotFoundException- Thrown by some steps that try to locate additional objectsPersistencyException- Problem writing or reading the databaseObjectAlreadyExistsException- Thrown by steps that create additional objectScriptErrorException- Thrown by scripting classesInvalidCollectionModification- Thrown by steps that create/modify collectionsCriseVertxException
-
execute
Standard execution of jobs. Note that this method should always be the one used from clients. All execution parameters are taken from the job where they're probably going to be correct.- Parameters:
job- the Actual Job to be executed- Returns:
- The outcome after processing. May have been altered by the step.
- Throws:
CriseVertxException
-
execute
public String execute(ItemProxy item, Class<?> predefStep, C2KLocalObject obj) throws CriseVertxException - Parameters:
item-predefStep-obj-- Returns:
- Throws:
AccessRightsExceptionInvalidDataExceptionInvalidTransitionExceptionObjectNotFoundExceptionPersistencyExceptionObjectAlreadyExistsExceptionInvalidCollectionModificationCriseVertxException
-
execute
public String execute(ItemProxy item, String predefStep, C2KLocalObject obj) throws CriseVertxException - Parameters:
item-predefStep-obj-- Returns:
- Throws:
AccessRightsExceptionInvalidDataExceptionInvalidTransitionExceptionObjectNotFoundExceptionPersistencyExceptionObjectAlreadyExistsExceptionInvalidCollectionModificationCriseVertxException
-
execute
public String execute(ItemProxy item, Class<?> predefStep, String... params) throws CriseVertxException - Parameters:
item-predefStep-params-- Returns:
- Throws:
AccessRightsExceptionInvalidDataExceptionInvalidTransitionExceptionObjectNotFoundExceptionPersistencyExceptionObjectAlreadyExistsExceptionInvalidCollectionModificationCriseVertxException
-
execute
public String execute(ItemProxy item, String predefStep, String... params) throws CriseVertxException Multi-parameter execution. Wraps parameters up in a PredefinedStepOutcome if the schema of the requested step is such.- Parameters:
item- The item on which to execute the steppredefStep- The step name to runparams- An array of parameters to pass to the step. See each step's documentation for its required parameters- Returns:
- The outcome after processing. May have been altered by the step.
- Throws:
AccessRightsException- The agent was not allowed to execute this stepInvalidDataException- The parameters supplied were incorrectInvalidTransitionException- The step wasn't availableObjectNotFoundException- Thrown by some steps that try to locate additional objectsPersistencyException- Problem writing or reading the databaseObjectAlreadyExistsException- Thrown by steps that create additional objectInvalidCollectionModification- Thrown by steps that create/modify collectionsCriseVertxException
-
execute
Execution without any parameters using Class of predefined step instead of string literal. There are steps which can be executed without any parameters- Throws:
CriseVertxException- See Also:
-
execute
Execution without any parameters. There are steps which can be executed without any parameters- Throws:
CriseVertxException- See Also:
-
execute
Single parameter execution using Class of predefined step instead of string literal. Wraps parameters up in a PredefinedStepOutcome if the schema of the requested step is such.- Throws:
CriseVertxException- See Also:
-
execute
Single parameter execution. Wraps parameters up in a PredefinedStepOutcome if the schema of the requested step is such.- Throws:
CriseVertxException- See Also:
-
searchItem
- Throws:
ObjectNotFoundException
-
searchItem
Let scripts resolve items- Throws:
ObjectNotFoundException
-
searchItems
-
searchItems
-
getItem
- Throws:
ObjectNotFoundException
-
getPath
Description copied from class:ItemProxyReturn the ItemPath object of the Item this proxy is linked with -
getItem
- Throws:
ObjectNotFoundException
-
getItemByUUID
public ItemProxy getItemByUUID(String uuid) throws ObjectNotFoundException, InvalidItemPathException -
getRoles
-