| org.enhydra.shark.api.client.wfservice.SharkConnection
All known Subclasses: org.enhydra.shark.SharkConnectionImpl, org.enhydra.shark.ejb.SharkConnectionSSBean,
SharkConnection | public interface SharkConnection (Code) | | Interface used to perform some administrative operations that concern execution engine
objects.
The first method to be called by client application is the first method of this
interface - connect(), and only if user authentication is OK, other methods can be used
(otherwise, every method throws NotConnected exception).
author: Sasa Bojanic author: Vladimir Puskas |
Method Summary | |
void | attachToHandle(WMSessionHandle shandle) | void | connect(WMConnectInfo connectInfo) This is the first method to be called in order to communicate with the engine. | void | disconnect() Disconnects from shark engine. | WfActivity | getActivity(String procId, String actId) Returns WfActivity object that has the given Id, or null if such doesn't exist.
Parameters: procId - activity's process Id. Parameters: actId - activity instance Id. | WfAssignment | getAssignment(String procId, String actId, String username) Returns WfAssignment object for activity with given Id, and resource with the given
username, or null if such doesn't exist. | WfAssignment | getAssignment(String procId, String assId) Returns WfAssignment object for given Id, or null if such doesn't exist. | WfProcess | getProcess(String procId) Returns WfProcess object that has the given Id, or null if such does not exist.
Parameters: procId - process instance Id. | WfProcessMgr | getProcessMgr(String name) Returns WfProcessMgr object that has the given name, or null if such does not exist.
Parameters: name - WfProcessMgr object name. | WfResource | getResource(String username) Returns WfResource object that has the given username, or null if such doesn't
exist.
Parameters: username - username of WfResource instance. | WfResource | getResourceObject() Returns WfResource object belonging to the user that has been connected to shark
through this interface. | WMSessionHandle | getSessionHandle() | WfActivityIterator | get_iterator_activity() | WfAssignmentIterator | get_iterator_assignment() | WfProcessIterator | get_iterator_process() | WfProcessMgrIterator | get_iterator_processmgr() Returns an iterator that can be used to retrieve WfProcessMgr objects that represent
appropriate XPDL process definitions, and are used to create new process instances. | WfResourceIterator | get_iterator_resource() Returns an iterator that can be used to retrieve WfResource objects that represent
appropriate shark users.
WfResourceIterator for retrieving WfResource objects. | WfProcessMgr[] | get_sequence_processmgr(int max_number) Returns an array of WfProcessMgr objects.
Parameters: max_number - The maximum number of WfProcessMgr instances to be returned. | WfResource[] | get_sequence_resource(int max_number) Returns an array of WfResource objects.
Parameters: max_number - The maximum number of WfResource instances to be returned. |
connect | void connect(WMConnectInfo connectInfo) throws Exception(Code) | | This is the first method to be called in order to communicate with the engine. If
the login parameters are correct, user can use other methods of this interface to
communicate with the shark engine, and if not, he can't do anything.
Parameters: connectInfo - structure holding connection request data throws: Exception - If something unexpected happens. |
disconnect | void disconnect() throws Exception(Code) | | Disconnects from shark engine.
throws: Exception - If something unexpected happens. |
getActivity | WfActivity getActivity(String procId, String actId) throws Exception(Code) | | Returns WfActivity object that has the given Id, or null if such doesn't exist.
Parameters: procId - activity's process Id. Parameters: actId - activity instance Id. WfActivity with the given Id, or null if does not exist. throws: Exception - If something unexpected happens. |
getAssignment | WfAssignment getAssignment(String procId, String actId, String username) throws Exception(Code) | | Returns WfAssignment object for activity with given Id, and resource with the given
username, or null if such doesn't exist.
Parameters: procId - the assignment's activity's process instance Id. Parameters: actId - the assignment's activity instance Id. Parameters: username - the assignement's username Specified WfAssignment , or null if does not exist. throws: Exception - If something unexpected happens. |
getAssignment | WfAssignment getAssignment(String procId, String assId) throws Exception(Code) | | Returns WfAssignment object for given Id, or null if such doesn't exist. NOTE: this
method is here only because of standardization (having one method with transaction,
and other without), and is not supposed to be used in normal situations - tool
agents can call the same method but with additional transaction parameter, and user
applications should call the same method but with actId and username parameters
instead of assId parameter.
Parameters: procId - the assignment's activity's process instance Id. Parameters: assId - the assignment Id. Specified WfAssignment , or null if does not exist. throws: Exception - If something unexpected happens. |
getProcess | WfProcess getProcess(String procId) throws Exception(Code) | | Returns WfProcess object that has the given Id, or null if such does not exist.
Parameters: procId - process instance Id. WfProcess with the given name, or null if does not exist. throws: Exception - If something unexpected happens. |
getProcessMgr | WfProcessMgr getProcessMgr(String name) throws Exception(Code) | | Returns WfProcessMgr object that has the given name, or null if such does not exist.
Parameters: name - WfProcessMgr object name. WfProcessMgr with the given name, or null if does not exist. throws: Exception - If something unexpected happens. |
getResource | WfResource getResource(String username) throws Exception(Code) | | Returns WfResource object that has the given username, or null if such doesn't
exist.
Parameters: username - username of WfResource instance. WfResource with the given name, or null if does not exist. throws: Exception - If something unexpected happens. |
getResourceObject | WfResource getResourceObject() throws Exception(Code) | | Returns WfResource object belonging to the user that has been connected to shark
through this interface. This will be the WfResource object that has the same
username attribute as the one used in connect() method. After getting this object,
client application can present user a list of its assignments that can be retrieved
throug this WfResource object.
WfResource object belonging to the user. throws: Exception - If something unexpected happens. |
get_iterator_processmgr | WfProcessMgrIterator get_iterator_processmgr() throws Exception(Code) | | Returns an iterator that can be used to retrieve WfProcessMgr objects that represent
appropriate XPDL process definitions, and are used to create new process instances.
WfProcessMgrIterator for retrieving WfProcessMgr objects. throws: Exception - If something unexpected happens. |
get_iterator_resource | WfResourceIterator get_iterator_resource() throws Exception(Code) | | Returns an iterator that can be used to retrieve WfResource objects that represent
appropriate shark users.
WfResourceIterator for retrieving WfResource objects. that representappropriate shark users. throws: Exception - If something unexpected happens. |
get_sequence_processmgr | WfProcessMgr[] get_sequence_processmgr(int max_number) throws Exception(Code) | | Returns an array of WfProcessMgr objects.
Parameters: max_number - The maximum number of WfProcessMgr instances to be returned. Ifset to 0, all existing instances will be returned (this will be equal tothe number of XPDL process definitions in all packages that are loadedinto engine). Array of specified WfProcessMgr objects. throws: Exception - If something unexpected happens. |
get_sequence_resource | WfResource[] get_sequence_resource(int max_number) throws Exception(Code) | | Returns an array of WfResource objects.
Parameters: max_number - The maximum number of WfResource instances to be returned. If setto 0, all existing instances will be returned. Specified array of WfResource objects. throws: Exception - If something unexpected happens. |
|
|