Package org.imixs.melman
Class WorkflowClient
java.lang.Object
org.imixs.melman.AbstractClient
org.imixs.melman.DocumentClient
org.imixs.melman.WorkflowClient
This ServiceClient is a WebService REST Client which encapsulate the
communication with a REST web serice based on the Imixs Workflow REST API.
The Implementation is based on the JAXB API 2.0.
- Author:
- Ralph Soika
-
Field Summary
Fields inherited from class org.imixs.melman.DocumentClient
DEFAULT_PAGE_SIZE, DEFAULT_TYPE, ITEM_ERROR_CODE, ITEM_ERROR_MESSAGE, items, pageIndex, pageSize, sortBy, sortReverse, typeFields inherited from class org.imixs.melman.AbstractClient
baseURI, requestFilterList, sslContext -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddeleteWorkitem(String uniqueid) Deletes a single workItem instance by UniqueID.List<org.imixs.workflow.ItemCollection>getTaskListByCreator(String userid) Returns the current task list by creatorList<org.imixs.workflow.ItemCollection>getTaskListByOwner(String userid) Returns the current task list by ownerList<org.imixs.workflow.ItemCollection>getWorkflowEventsByWorkitem(org.imixs.workflow.ItemCollection workitem) Returns the current task list by ownerorg.imixs.workflow.ItemCollectiongetWorkitem(String uniqueid) Returns a single workItem instance by UniqueID.org.imixs.workflow.ItemCollectionprocessWorkitem(org.imixs.workflow.ItemCollection workitem) Process a single workitem instance.Methods inherited from class org.imixs.melman.DocumentClient
countDocuments, createAdminPJob, deleteDocument, getDocument, getItems, getPageIndex, getPageSize, getSortBy, getType, isSortReverse, postXMLDataCollection, postXMLDocument, queryDocuments, saveDocument, searchDocuments, setItems, setPageIndex, setPageSize, setSortBy, setSortOrder, setSortReverse, setTypeMethods inherited from class org.imixs.melman.AbstractClient
getBaseURI, getCustomResource, getCustomResourceXML, getRequestFilterList, getSslContext, getWebTarget, logout, newClient, registerClientRequestFilter, setBaseURI, setSslContext
-
Constructor Details
-
WorkflowClient
Initialize the client by a BASE_URL.- Parameters:
base_uri-
-
-
Method Details
-
processWorkitem
public org.imixs.workflow.ItemCollection processWorkitem(org.imixs.workflow.ItemCollection workitem) throws RestAPIException Process a single workitem instance. If the workitem is not yet managed by the workflow manger a new instance will be created.- Parameters:
workitem- - a ItemCollection representing the workitem.- Returns:
- updated workitem instance
- Throws:
RestAPIException
-
getWorkitem
Returns a single workItem instance by UniqueID.The method calls the workflow rest interface instead of the document rest interface to ensure the corresponding backend method is accessed.
- Parameters:
uniqueid-items-- Returns:
- workitem
- Throws:
RestAPIException
-
deleteWorkitem
Deletes a single workItem instance by UniqueID.- Parameters:
userid-items-- Throws:
RestAPIException
-
getTaskListByCreator
public List<org.imixs.workflow.ItemCollection> getTaskListByCreator(String userid) throws RestAPIException Returns the current task list by creator- Parameters:
userid-- Throws:
RestAPIException
-
getTaskListByOwner
public List<org.imixs.workflow.ItemCollection> getTaskListByOwner(String userid) throws RestAPIException Returns the current task list by owner- Parameters:
userid-items-- Returns:
- task list for given user
- Throws:
RestAPIException
-
getWorkflowEventsByWorkitem
public List<org.imixs.workflow.ItemCollection> getWorkflowEventsByWorkitem(org.imixs.workflow.ItemCollection workitem) throws RestAPIException Returns the current task list by owner- Parameters:
userid-items-- Returns:
- task list for given user
- Throws:
RestAPIException
-