Try OpenEdge Now
skip to main content
BP Server Developer's Guide
Work item management : Working with work item states
 

Working with work item states

BP Server provides a number of APIs for getting the state of a work item.
*public int getState()
Returns the state of work item as an integer value. BP Server defines a specific integer value for each state. This API is not generally meant to be used directly. Instead, it is recommended to use the API getStateDescription (), which returns the state of work item as String.
*public String getStateDescription()
Returns the state of work item as a String value. The possible states of a work item seen by the BP Server client are:
*I_CREATED
*I_ASSIGNED
*I_AVAILABLE
*I_SUSPENDED
*I_COMPLETED
*I_REMOVED
*public boolean isAssigned()
This is a direct API that checks whether a work item is in the Assigned state. Returns a Boolean value that is true if the work item is assigned to the performer, false if the work item is not assigned.
*public boolean isAvailable()
This is a direct API that checks whether a work item is in the Available state. Returns a Boolean value that is true if the work item is Available but not assigned to any performer, false if the work item is not Available.
*public boolean isWorkItemExist (Session session, long wiid)
This is a direct API that checks whether a work item exists. Returns true if a work item exists.