com.sap.caf.eu.gp.process.rt.api

Interface IGPRuntimeManager


public interface IGPRuntimeManager


Method Summary
 void addRuntimeDefinedUserToRole(IGPProcessInstance processInstance, String roleName, IUser runtimeUser, IGPUserContext userContext)
          This method adds an user to a process role instance during runtime
 void changeTaskProcessor(String processInstanceID, String activityInstanceID, IGPUserContext actualProcessor, IGPUserContext newProcessor)
          Delegates the given activity in given process from actualProcessor to .
 void completeAction(IGPActionCompletionData actionCompletionData)
           
 IGPActionCompletionData createActionCompletionData(String processInstanceID, String actionInstanceID, IUser user)
          Deprecated.  
 IGPProcessRoleInstanceList createProcesRoleInstanceList()
          Deprecated. This method creates an initial IGPProcessRoleInstanceList needed for starting a process.
 IGPProcessRoleInstanceList createProcessRoleInstanceList()
          This method creates an initial IGPProcessRoleInstanceList needed for starting a process.
 IGPActionInstance getActionInstance(String processId, String actionId, IUser user)
          Deprecated. Returns the action instance information for the given parameters.
 IGPProcessInfo[] getActiveProcessTemplatesByCategory(String categoryId, IUser user)
          Deprecated. Returns information for all active process templates.
 IGPRuntimeAttachmentList getAttachmentList(String processInstanceID, String activityInstanceID, IUser user)
          Returns the list of attachments associated with a given activity in a given process instance.
 IGPBlockInstance getBlockInstance(String processId, String blockId, IUser user)
          Deprecated. Returns the block instance information for the given parameters.
 IGPProcessInstanceInfo[] getCompletedInstances(GPSearchRole searchRole, Date startDate, Date endDate, IGPUserContext userContext)
          Returns information for completed process instances for the specified parameters.
 IGPProcessInstanceInfo[] getCompletedInstances(int searchRole, Date startDate, Date endDate, IUser user)
          Deprecated. Returns information for completed process instances for the specified parameters.
 Iterator getCurrentWorkItems(String processInstanceId, IGPUserContext userContext)
           
 IGPProcessInstanceInfo[] getErroneousInstances(GPSearchRole searchRole, Date startDate, Date endDate, IGPUserContext userContext)
          Returns information for erroneous process instances for the specified parameters.
 IGPProcessInstance getProcessInstance(IGPProcessInstanceInfo processInstanceInfo, IUser user)
          Deprecated. Returns the process instance for a process instance info object (e.g. click on list of processes to jump into one special process)
 IGPProcessInstance getProcessInstance(String processId, IUser user)
          Deprecated. Returns the process instance information for the given parameters.
 IGPProcessInstanceInfo getProcessInstanceInformation(String processInstanceID, IUser user)
          Returns one IGPProcessInstanceInfo object which is identified by the process Id, and it is unique to the process.
 IGPProcessInstanceInfo[] getRunningInstances(GPSearchRole searchRole, Date startDate, Date endDate, IGPUserContext userContext)
          Returns information for running process instances for the specified parameters.
 IGPProcessInstanceInfo[] getRunningInstances(int searchRole, Date startDate, Date endDate, IUser user)
          Deprecated. Returns information for running process instances for the specified parameters.
 IGPWorkItem[] getWorkItems(GPWorkItemStatus status, IGPUserContext userContext)
          Returns the workitems with a given status for a given user.
 IGPWorkItem[] getWorkItems(int status, IUser user)
          Deprecated. Returns information for workitems with a given status for a given user.
 void persistAttachmentList(String processInstanceID, String activityInstanceID, IGPRuntimeAttachmentList attachments, IUser user)
          Saves the given list of attachments for the given activity and process instance and returns it.
 void removeTaskProcessor(String processInstanceID, String activityInstanceID, IGPUserContext currentProcessor)
          Removes a user as processor of a workitem.
 void setCustomProcessTitle(String processInstanceID, String title)
          The custom process title of a running process can be reset.
 IGPProcessInstance startProcess(IGPProcess processTemplate, String userProvidedName, String userProvidedDescription, IUser initiator, IGPProcessRoleInstanceList processRoleInstanceList, IGPStructure startStructure, IUser user)
           
 IGPProcessInstance stopProcess(IGPProcessInstance processInstance, IUser user)
          Deprecated. Stops a running process.
 

Method Detail

createProcesRoleInstanceList

IGPProcessRoleInstanceList createProcesRoleInstanceList()
Deprecated. This method creates an initial IGPProcessRoleInstanceList needed for starting a process.

Returns:

createProcessRoleInstanceList

IGPProcessRoleInstanceList createProcessRoleInstanceList()
This method creates an initial IGPProcessRoleInstanceList needed for starting a process.

Returns:

startProcess

IGPProcessInstance startProcess(IGPProcess processTemplate,
                                String userProvidedName,
                                String userProvidedDescription,
                                IUser initiator,
                                IGPProcessRoleInstanceList processRoleInstanceList,
                                IGPStructure startStructure,
                                IUser user)
                                throws GPEngineException,
                                       GPInvocationException
Parameters:
processTemplate -
userProvidedName -
userProvidedDescription -
initiator -
processRoleInstanceList -
startStructure -
user -
Returns:
Throws:
GPEngineException
GPInvocationException

stopProcess

IGPProcessInstance stopProcess(IGPProcessInstance processInstance,
                               IUser user)
                               throws GPEngineException,
                                      GPInvocationException
Deprecated. Stops a running process.

Parameters:
processInstance - NOT NULL
user - NOT NULL
Returns:
Throws:
GPEngineException
GPInvocationException

addRuntimeDefinedUserToRole

void addRuntimeDefinedUserToRole(IGPProcessInstance processInstance,
                                 String roleName,
                                 IUser runtimeUser,
                                 IGPUserContext userContext)
                                 throws GPEngineException,
                                        GPInvocationException
This method adds an user to a process role instance during runtime

Parameters:
processInstance - NOT NULL
roleName - NOT NULL
runtimeUser - NOT NULL
userContext - NOT NULL
Throws:
GPEngineException
GPInvocationException

setCustomProcessTitle

void setCustomProcessTitle(String processInstanceID,
                           String title)
                           throws GPEngineException,
                                  GPInvocationException
The custom process title of a running process can be reset.

Parameters:
processInstanceID - NOT NULL
title -
Throws:
GPEngineException
GPInvocationException

completeAction

void completeAction(IGPActionCompletionData actionCompletionData)
                    throws GPEngineException,
                           GPInvocationException
Parameters:
actionCompletionData -
Throws:
GPEngineException
GPInvocationException

createActionCompletionData

IGPActionCompletionData createActionCompletionData(String processInstanceID,
                                                   String actionInstanceID,
                                                   IUser user)
                                                   throws GPEngineException,
                                                          GPInvocationException
Deprecated. 

Parameters:
processInstanceID - NOT NULL
actionInstanceID - NOT NULL
user - NOT NULL
Returns:
Throws:
GPEngineException
GPInvocationException

getProcessInstance

IGPProcessInstance getProcessInstance(IGPProcessInstanceInfo processInstanceInfo,
                                      IUser user)
                                      throws GPEngineException,
                                             GPInvocationException
Deprecated. Returns the process instance for a process instance info object (e.g. click on list of processes to jump into one special process)

Parameters:
processInstanceInfo - NOT NULL
user - NOT NULL
Returns:
IGPProcessInstance
Throws:
GPEngineException
GPInvocationException

getActionInstance

IGPActionInstance getActionInstance(String processId,
                                    String actionId,
                                    IUser user)
                                    throws GPEngineException,
                                           GPInvocationException
Deprecated. Returns the action instance information for the given parameters.

Parameters:
processId - String NOT NULL
actionId - String NOT NULL
user - IUser NOT NULL
Returns:
IActionInformation NOT NULL
Throws:
ProcessInformationException
GPEngineException
GPInvocationException

getBlockInstance

IGPBlockInstance getBlockInstance(String processId,
                                  String blockId,
                                  IUser user)
                                  throws GPEngineException,
                                         GPInvocationException
Deprecated. Returns the block instance information for the given parameters.

Parameters:
processId - String NOT NULL
blockId - String NOT NULL
user - IUser NOT NULL
Returns:
IBlockInformation NOT NULL
Throws:
ProcessInformationException
GPEngineException
GPInvocationException

getProcessInstance

IGPProcessInstance getProcessInstance(String processId,
                                      IUser user)
                                      throws GPEngineException,
                                             GPInvocationException
Deprecated. Returns the process instance information for the given parameters.

Parameters:
processId - String NOT NULL
user - IUser NOT NULL
Returns:
IInstanceInformation NOT NULL
Throws:
ProcessInformationException
GPEngineException
GPInvocationException

getActiveProcessTemplatesByCategory

IGPProcessInfo[] getActiveProcessTemplatesByCategory(String categoryId,
                                                     IUser user)
                                                     throws GPEngineException,
                                                            GPInvocationException
Deprecated. Returns information for all active process templates.

Parameters:
categoryId -
user - IUser NOT NULL
Returns:
ITemplateInformation[] NOT NULL
Throws:
ProcessReportingException
GPEngineException
GPInvocationException

getRunningInstances

IGPProcessInstanceInfo[] getRunningInstances(int searchRole,
                                             Date startDate,
                                             Date endDate,
                                             IUser user)
                                             throws GPEngineException,
                                                    GPInvocationException
Deprecated. Returns information for running process instances for the specified parameters.

Parameters:
searchRole - - one of the constants in com.sap.caf.eu.gp.process.api.ISearchRolesInformation
startDate -
endDate -
user - IUser NOT NULL
Returns:
IInstanceInformation[] NOT NULL
Throws:
ProcessReportingException
GPEngineException
GPInvocationException

getRunningInstances

IGPProcessInstanceInfo[] getRunningInstances(GPSearchRole searchRole,
                                             Date startDate,
                                             Date endDate,
                                             IGPUserContext userContext)
                                             throws GPEngineException,
                                                    GPInvocationException
Returns information for running process instances for the specified parameters.

Parameters:
searchRole - - one of the constants of GPSearchRole.SEARCH_ROLE_*
startDate - - NOT NULL or endDate is NOT NULL
endDate - - NOT NULL or startDate is NOT NULL
userContext - IGPUserContext NOT NULL
Returns:
IInstanceInformation[] NOT NULL
Throws:
ProcessReportingException - - You will get a ProcessReportingException, if startDate and endDate is NULL or user is null
GPEngineException
GPInvocationException

getErroneousInstances

IGPProcessInstanceInfo[] getErroneousInstances(GPSearchRole searchRole,
                                               Date startDate,
                                               Date endDate,
                                               IGPUserContext userContext)
                                               throws GPEngineException,
                                                      GPInvocationException
Returns information for erroneous process instances for the specified parameters.

Parameters:
searchRole - - one of the constants of GPSearchRole.SEARCH_ROLE_*
startDate - - NOT NULL or endDate is NOT NULL
endDate - - NOT NULL or startDate is NOT NULL
userContext - IGPUserContext NOT NULL
Returns:
IInstanceInformation[] NOT NULL
Throws:
ProcessReportingException - - You will get a ProcessReportingException, if startDate and endDate is NULL or user is null
GPEngineException
GPInvocationException

getCompletedInstances

IGPProcessInstanceInfo[] getCompletedInstances(int searchRole,
                                               Date startDate,
                                               Date endDate,
                                               IUser user)
                                               throws GPEngineException,
                                                      GPInvocationException
Deprecated. Returns information for completed process instances for the specified parameters.

Parameters:
searchRole - - one of the constants in com.sap.caf.eu.gp.process.api.ISearchRolesInformation
startDate -
endDate -
user - IUser NOT NULL
Returns:
IInstanceInformation[] NOT NULL
Throws:
ProcessReportingException
GPEngineException
GPInvocationException

getCompletedInstances

IGPProcessInstanceInfo[] getCompletedInstances(GPSearchRole searchRole,
                                               Date startDate,
                                               Date endDate,
                                               IGPUserContext userContext)
                                               throws GPEngineException,
                                                      GPInvocationException
Returns information for completed process instances for the specified parameters.

Parameters:
searchRole - - one of the constants of GPSearchRole.SEARCH_ROLE_*
startDate - - NOT NULL or endDate is NOT NULL
endDate - - NOT NULL or startDate is NOT NULL
userContext - IGPUserContext NOT NULL
Returns:
IInstanceInformation[] NOT NULL
Throws:
ProcessReportingException - - You will get a ProcessReportingException, if startDate and endDate is NULL or user is null
GPEngineException
GPInvocationException

getProcessInstanceInformation

IGPProcessInstanceInfo getProcessInstanceInformation(String processInstanceID,
                                                     IUser user)
                                                     throws GPEngineException,
                                                            GPInvocationException
Returns one IGPProcessInstanceInfo object which is identified by the process Id, and it is unique to the process. This way you can retrieve information of a process instance.

Parameters:
processInstanceID - --the Id of the process instance
user - -- the user who wants to retrieve this information
Returns:
Throws:
GPEngineException - -- if something went wrong when communicatong with the database
GPInvocationException - -- if there is some problem with the processInstanceId. (invalid)

getWorkItems

IGPWorkItem[] getWorkItems(int status,
                           IUser user)
                           throws GPEngineException,
                                  GPInvocationException
Deprecated. Returns information for workitems with a given status for a given user.

Parameters:
status -
user - IUser NOT NULL
Returns:
IWorkItemInformation[] NOT NULL
Throws:
ProcessReportingException
GPEngineException
GPInvocationException

getWorkItems

IGPWorkItem[] getWorkItems(GPWorkItemStatus status,
                           IGPUserContext userContext)
                           throws GPEngineException,
                                  GPInvocationException
Returns the workitems with a given status for a given user.

Parameters:
status - NOT NULL - one of the constants in com.sap.caf.eu.gp.process.api.GPWorkItemStatus
userContext - IGPUserContext NOT NULL
Returns:
IWorkItemInformation[] NOT NULL
Throws:
ProcessReportingException
GPEngineException
GPInvocationException

getCurrentWorkItems

Iterator getCurrentWorkItems(String processInstanceId,
                             IGPUserContext userContext)
                             throws GPEngineException,
                                    GPInvocationException
Throws:
GPEngineException
GPInvocationException

getAttachmentList

IGPRuntimeAttachmentList getAttachmentList(String processInstanceID,
                                           String activityInstanceID,
                                           IUser user)
                                           throws GPEngineException,
                                                  GPInvocationException
Returns the list of attachments associated with a given activity in a given process instance.

If the activityInstanceID is null, retrieve the attachments of the process instance only. Otherwise, retrieve the attachment list of the activity instance.

Parameters:
processInstanceID - process instance id
activityInstanceID - activity instance id, can be null
user - user
Returns:
run time attachment list instance
Throws:
GPEngineException - in case of internal error
GPInvocationException - in case of invalid arguments

persistAttachmentList

void persistAttachmentList(String processInstanceID,
                           String activityInstanceID,
                           IGPRuntimeAttachmentList attachments,
                           IUser user)
                           throws GPEngineException,
                                  GPInvocationException
Saves the given list of attachments for the given activity and process instance and returns it.

If the activityInstanceID is null, persist the attachments of the process instance only. Otherwise, persist the attachment list of the activity instance.

Parameters:
processInstanceID - process instance id
activityInstanceID - activity instance id, can be null in case of
attachments - modified run time attachment list
user - user
Throws:
GPEngineException - in case of internal error
GPInvocationException - in case of invalid arguments

changeTaskProcessor

void changeTaskProcessor(String processInstanceID,
                         String activityInstanceID,
                         IGPUserContext actualProcessor,
                         IGPUserContext newProcessor)
                         throws GPEngineException,
                                GPInvocationException
Delegates the given activity in given process from actualProcessor to .

If the actualProcessor is null: - if there are more then one user assigned to the activity, a GPInvocationException is thrown - if there is only one user assigned to the activity, it will be changed

Parameters:
processInstanceID - process instance id
activityInstanceID - activity instance id
actualProcessor - user who is assigned to the activity, can be null
newProcessor - user who will take over the activity
Throws:
GPEngineException - in case of internal error
GPInvocationException - in case of invalid arguments

removeTaskProcessor

void removeTaskProcessor(String processInstanceID,
                         String activityInstanceID,
                         IGPUserContext currentProcessor)
                         throws GPEngineException,
                                GPInvocationException
Removes a user as processor of a workitem.

A user can only be removed as processor if there are also other processors assigned. If the user is the only processor of this workitem an exception will be thrown.

Parameters:
processInstanceID - process instance id
activityInstanceID - activity instance id
currentProcessor - user who is currently assigned to the activity
Throws:
GPEngineException - in case of internal error
GPInvocationException - in case of invalid arguments


Copyright 2009 SAP AG Complete Copyright Notice