|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.eclipse.stardust.engine.api.query.Query
org.eclipse.stardust.engine.api.query.ProcessInstanceQuery
public class ProcessInstanceQuery
Query container for building complex queries for process instances.
Valid filter criteria are:
FilterTerm for building complex criteria.ProcessDefinitionFilter for finding instances of specific process definitions.ProcessInstanceFilter for finding instances of specific process instance hierarchies.ProcessStateFilter for finding process instances currently being in specific states.StartingUserFilter for finding process instances being started by a specific user.DataFilter for finding process instances with same scope process instance containing specific workflow data.SubProcessDataFilter for finding process instances and its subprocess instances containing specific workflow data.HierarchyDataFilter for finding the complete hierarchy of process instances containing specific workflow data.
| Nested Class Summary | |
|---|---|
static class |
ProcessInstanceQuery.Attribute
Process instance attribute supporting filter operations. |
| Field Summary | |
|---|---|
static ProcessInstanceQuery.Attribute |
BENCHMARK_OID
|
static ProcessInstanceQuery.Attribute |
BENCHMARK_VALUE
|
static ProcessInstanceQuery.Attribute |
CURRENT_DOMAIN_OID
Deprecated. This attribute existed in AuditTrail. |
static ProcessInstanceQuery.Attribute |
OID
|
static ProcessInstanceQuery.Attribute |
PRIORITY
|
static org.eclipse.stardust.engine.api.query.CustomOrderCriterion |
PROC_DEF_ID
Orders the resulting process instances by their process definition id. |
static org.eclipse.stardust.engine.api.query.CustomOrderCriterion |
PROC_DEF_NAME
Orders the resulting process instances by their process definition name. |
static ProcessInstanceQuery.Attribute |
PROCESS_DEFINITION_OID
|
static org.eclipse.stardust.engine.api.query.RootProcessDefinitionDescriptor |
ROOT_PROC_DEF_ID
Orders the resulting process instances by their root process definition id. |
static org.eclipse.stardust.engine.api.query.RootProcessDefinitionDescriptor |
ROOT_PROC_DEF_NAME
Orders the resulting process instances by their root process definition name. |
static ProcessInstanceQuery.Attribute |
ROOT_PROCESS_INSTANCE_OID
|
static ProcessInstanceQuery.Attribute |
START_TIME
|
static ProcessInstanceQuery.Attribute |
STARTING_ACTIVITY_INSTANCE_OID
|
static ProcessInstanceQuery.Attribute |
STARTING_DOMAIN_OID
Deprecated. This attribute existed in AuditTrail. |
static ProcessInstanceQuery.Attribute |
STARTING_USER_OID
|
static ProcessInstanceQuery.Attribute |
STATE
|
static ProcessInstanceQuery.Attribute |
TERMINATION_TIME
|
static org.eclipse.stardust.engine.api.query.CustomOrderCriterion |
USER_ACCOUNT
Orders the resulting process instances by their starting user account. |
static org.eclipse.stardust.engine.api.query.CustomOrderCriterion |
USER_FIRST_NAME
Orders the resulting process instances by their starting user first name. |
static org.eclipse.stardust.engine.api.query.CustomOrderCriterion |
USER_LAST_NAME
Orders the resulting process instances by their starting user last name. |
| Constructor Summary | |
|---|---|
ProcessInstanceQuery()
|
|
| Method Summary | |
|---|---|
static ProcessInstanceQuery |
findActive()
Creates a query for finding active process instances. |
static ProcessInstanceQuery |
findAlive()
Creates a query for finding alive process instances. |
static ProcessInstanceQuery |
findAlive(String processID)
Creates a query for finding alive instances of the process definition identified by processID. |
static ProcessInstanceQuery |
findAliveHavingData(String processID,
String dataID,
Serializable dataValue)
Creates a query for finding alive instances of the process definition identified by processID containing workflow data dataID having a value
of dataValue. |
static ProcessInstanceQuery |
findAll()
Creates a query for finding all process instances currently existing. |
static ProcessInstanceQuery |
findCaseByName(String caseName)
Creates a query for finding case instances with the specified name. |
static ProcessInstanceQuery |
findCaseMembers(long caseOid)
Creates a query for finding instances belonging to the case instance with the specified oid. |
static ProcessInstanceQuery |
findCases()
Creates a query for finding case instances. |
static ProcessInstanceQuery |
findCompleted()
Creates a query for finding completed process instances. |
static ProcessInstanceQuery |
findCompleted(String processID)
Creates a query for finding completed instances of the process definition identified by processID. |
static ProcessInstanceQuery |
findForProcess(String processID)
Creates a query for finding instances of the process definition identified by processID. |
static ProcessInstanceQuery |
findForProcess(String processID,
boolean includingSubprocesses)
Creates a query for finding instances of the process definition identified by processID. |
static ProcessInstanceQuery |
findHavingDocument(Document document)
Creates a query for finding process instances which have the given Document as a process attachment, document data or document list data. |
static ProcessInstanceQuery |
findHavingDocument(Document document,
String modelId)
Creates a query for finding process instances which have the given Document as a process attachment, document data or document list data. |
static ProcessInstanceQuery |
findHavingDocument(String documentId)
Creates a query for finding process instances which have the given Document as a process attachment, document data or document list data. |
static ProcessInstanceQuery |
findInState(ProcessInstanceState state)
Creates a query for finding process instances currently being in the specified state. |
static ProcessInstanceQuery |
findInState(ProcessInstanceState[] states)
Creates a query for finding process instances currently being in one of the specified states. |
static ProcessInstanceQuery |
findInState(String processID,
ProcessInstanceState state)
Creates a query for finding instances of the process definition identified by processID currently being in the specified state. |
static ProcessInstanceQuery |
findInState(String processID,
ProcessInstanceState[] states)
Creates a query for finding instances of the process definition identified by processID currently being in one of the specified states. |
static ProcessInstanceQuery |
findInStateHavingData(String processID,
String dataID,
Serializable dataValue,
ProcessInstanceState state)
Creates a query for finding instances of the process definition identified by processID containing workflow data dataID having a value
of dataValue and currently being in the specified state. |
static ProcessInstanceQuery |
findInStateHavingData(String processID,
String dataID,
Serializable dataValue,
ProcessInstanceState[] states)
Creates a query for finding instances of the process definition identified by processID containing workflow data dataID having a value
of dataValue and currently being in one of the specified states. |
static ProcessInstanceQuery |
findInterrupted()
Creates a query for finding pending process instances. |
static ProcessInstanceQuery |
findLinked(long processInstanceOid,
LinkDirection direction,
org.eclipse.stardust.engine.api.runtime.PredefinedProcessInstanceLinkTypes... linkType)
Creates a query for finding process instances the given process instance is linked to via the given link type(s) and direction. |
static ProcessInstanceQuery |
findLinked(long processInstanceOid,
LinkDirection direction,
String... linkType)
Creates a query for finding process instances the given process instance is linked to via the given link type(s) and direction. |
static ProcessInstanceQuery |
findStartedByUser(long userOID)
Creates a query for finding process instances started by the user identified by the given OID. |
String |
toString()
|
| Methods inherited from class org.eclipse.stardust.engine.api.query.Query |
|---|
getFilter, getOrderCriteria, getPolicy, orderBy, orderBy, orderBy, removePolicy, setPolicy, where |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final ProcessInstanceQuery.Attribute OID
public static final ProcessInstanceQuery.Attribute START_TIME
public static final ProcessInstanceQuery.Attribute TERMINATION_TIME
public static final ProcessInstanceQuery.Attribute STATE
public static final ProcessInstanceQuery.Attribute PROCESS_DEFINITION_OID
public static final ProcessInstanceQuery.Attribute ROOT_PROCESS_INSTANCE_OID
public static final ProcessInstanceQuery.Attribute STARTING_USER_OID
public static final ProcessInstanceQuery.Attribute STARTING_ACTIVITY_INSTANCE_OID
public static final ProcessInstanceQuery.Attribute PRIORITY
public static final ProcessInstanceQuery.Attribute BENCHMARK_OID
public static final ProcessInstanceQuery.Attribute BENCHMARK_VALUE
public static final ProcessInstanceQuery.Attribute STARTING_DOMAIN_OID
public static final ProcessInstanceQuery.Attribute CURRENT_DOMAIN_OID
public static final org.eclipse.stardust.engine.api.query.CustomOrderCriterion PROC_DEF_ID
public static final org.eclipse.stardust.engine.api.query.CustomOrderCriterion PROC_DEF_NAME
public static final org.eclipse.stardust.engine.api.query.CustomOrderCriterion USER_ACCOUNT
public static final org.eclipse.stardust.engine.api.query.CustomOrderCriterion USER_FIRST_NAME
public static final org.eclipse.stardust.engine.api.query.CustomOrderCriterion USER_LAST_NAME
public static final org.eclipse.stardust.engine.api.query.RootProcessDefinitionDescriptor ROOT_PROC_DEF_ID
public static final org.eclipse.stardust.engine.api.query.RootProcessDefinitionDescriptor ROOT_PROC_DEF_NAME
| Constructor Detail |
|---|
public ProcessInstanceQuery()
| Method Detail |
|---|
public static ProcessInstanceQuery findAll()
public static ProcessInstanceQuery findForProcess(String processID)
processID. Also retrieves instances of subprocesses.
processID - The ID of the process definition the activity should belong to.
findForProcess(String, boolean),
ProcessDefinitionFilter.ProcessDefinitionFilter(String),
findInState(String, ProcessInstanceState),
findAlive(String)
public static ProcessInstanceQuery findForProcess(String processID,
boolean includingSubprocesses)
processID. Optionally retrieves subprocesses.
processID - The ID of the process definition the activity should belong to.includingSubprocesses - Flag indicating if subprocesses should be retrieved,
too.
findForProcess(String),
ProcessDefinitionFilter.ProcessDefinitionFilter(String, boolean)public static ProcessInstanceQuery findCases()
public static ProcessInstanceQuery findCaseByName(String caseName)
caseName - The name of the case instance to search for.
public static ProcessInstanceQuery findCaseMembers(long caseOid)
caseOid - The oid of the case instance to search members for.
public static ProcessInstanceQuery findInState(ProcessInstanceState state)
state - The state the process instance should be in.
findInState(String, ProcessInstanceState),
findAlive(),
ProcessStateFilterpublic static ProcessInstanceQuery findInState(ProcessInstanceState[] states)
states - The list of states the process instance should be in one of.
findInState(String, ProcessInstanceState[]),
findAlive(),
ProcessStateFilter
public static ProcessInstanceQuery findInState(String processID,
ProcessInstanceState state)
processID currently being in the specified state. Also retrieves instances of subprocesses.
processID - The ID of the process definition the activity should belong to.state - The state the process instance should be in.
findInState(String, ProcessInstanceState[]),
findAlive(String),
ProcessDefinitionFilter,
ProcessStateFilter
public static ProcessInstanceQuery findInState(String processID,
ProcessInstanceState[] states)
processID currently being in one of the specified states. Also retrieves instances of subprocesses.
processID - The ID of the process definition the activity should belong to.states - The list of states the process instance should be in one of.
findInState(String, ProcessInstanceState),
findAlive(String),
ProcessDefinitionFilter,
ProcessStateFilterpublic static ProcessInstanceQuery findAlive()
Alive means not being in states ProcessInstanceState.ABORTED or
ProcessInstanceState.Completed
findAlive(String),
findInState(ProcessInstanceState[]),
ProcessStateFilter,
ProcessStateFilter.ALIVEpublic static ProcessInstanceQuery findActive()
findInterrupted(),
findCompleted(),
findAlive(),
findInState(ProcessInstanceState),
ProcessStateFilter,
ProcessStateFilter.ALIVEpublic static ProcessInstanceQuery findInterrupted()
findActive(),
findCompleted(),
findAlive(),
findInState(ProcessInstanceState),
ProcessStateFilter,
ProcessStateFilter.ALIVEpublic static ProcessInstanceQuery findCompleted()
Completed means being in state ProcessInstanceState.Completed
findCompleted(String),
findAlive(),
findInState(ProcessInstanceState),
ProcessStateFilter,
ProcessStateFilter.COMPLETEDpublic static ProcessInstanceQuery findAlive(String processID)
processID. Also retrieves instances of subprocesses.
Alive means not being in states ProcessInstanceState.ABORTED or
ProcessInstanceState.Completed
processID - The ID of the process definition the activity should belong to.
findInState(String, ProcessInstanceState),
ProcessDefinitionFilter,
ProcessStateFilter,
ProcessStateFilter.ALIVEpublic static ProcessInstanceQuery findCompleted(String processID)
processID. Also retrieves instances of subprocesses.
Completed means being in state ProcessInstanceState.Completed
processID - The ID of the process definition the activity should belong to.
findCompleted(),
findAlive(String),
findInState(String, ProcessInstanceState),
ProcessDefinitionFilter,
ProcessStateFilter,
ProcessStateFilter.COMPLETED
public static ProcessInstanceQuery findInStateHavingData(String processID,
String dataID,
Serializable dataValue,
ProcessInstanceState state)
processID containing workflow data dataID having a value
of dataValue and currently being in the specified state. Also retrieves instances of subprocesses.
processID - The ID of the process definition the activity should belong to.dataID - The ID of the workflow data to match with.dataValue - The value to match the workflow data with.state - The state the process instance should be in.
findInStateHavingData(String, String, Serializable, ProcessInstanceState[]),
findAliveHavingData(java.lang.String, java.lang.String, java.io.Serializable),
findInState(String, ProcessInstanceState),
findAlive(String),
ProcessDefinitionFilter,
DataFilter,
ProcessStateFilter
public static ProcessInstanceQuery findInStateHavingData(String processID,
String dataID,
Serializable dataValue,
ProcessInstanceState[] states)
processID containing workflow data dataID having a value
of dataValue and currently being in one of the specified states.
Also retrieves instances of subprocesses.
processID - The ID of the process definition the activity should belong to.dataID - The ID of the workflow data to match with.dataValue - The value to match the workflow data with.states - The list of states the process instance should be in one of.
findInStateHavingData(String, String, Serializable, ProcessInstanceState),
findAliveHavingData(java.lang.String, java.lang.String, java.io.Serializable),
findInState(ProcessInstanceState[]),
findAlive(String),
ProcessDefinitionFilter,
DataFilter,
ProcessStateFilter
public static ProcessInstanceQuery findAliveHavingData(String processID,
String dataID,
Serializable dataValue)
processID containing workflow data dataID having a value
of dataValue. Also retrieves instances of subprocesses.
Alive means not being in states ProcessInstanceState.ABORTED or
ProcessInstanceState.Completed
processID - The ID of the process definition the activity should belong to.dataID - The ID of the workflow data to match with.dataValue - The value to match the workflow data with.
findInStateHavingData(String, String, Serializable, ProcessInstanceState[]),
findInState(String, ProcessInstanceState[]),
findAlive(String),
ProcessDefinitionFilter,
DataFilter,
ProcessStateFilter,
ProcessStateFilter.ALIVEpublic static ProcessInstanceQuery findStartedByUser(long userOID)
userOID - The OID of the user having started the process instances to find.
StartingUserFilter,
StartingUserFilter.CURRENT_USER
public static ProcessInstanceQuery findLinked(long processInstanceOid,
LinkDirection direction,
String... linkType)
processInstanceOid - The OID of the process instance the query should be executed fordirection - The direction of the links that should be taken into account when determining the linked process instanceslinkType - The link types that should be taken into account when determining the linked process instances
public static ProcessInstanceQuery findLinked(long processInstanceOid,
LinkDirection direction,
org.eclipse.stardust.engine.api.runtime.PredefinedProcessInstanceLinkTypes... linkType)
processInstanceOid - The OID of the process instance the query should be executed fordirection - The direction of the links that should be taken into account when determining the linked process instanceslinkType - The link types that should be taken into account when determining the linked process instances
public static ProcessInstanceQuery findHavingDocument(Document document,
String modelId)
document - The Document to find process instances having a reference to.modelId - The model id (null searches all models).
public static ProcessInstanceQuery findHavingDocument(Document document)
document - The Document to find process instances having a reference to.
public static ProcessInstanceQuery findHavingDocument(String documentId)
documentId - The id of the Document to find process instances having a reference to.
public String toString()
toString in class Query
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||