org.jbpm.api
Interface ProcessInstanceQuery


public interface ProcessInstanceQuery

query for ongoing process instances exclusively. refer to HistoryProcessInstanceQuery for queries that include finished process instances.

Author:
Tom Baeyens

Field Summary
static java.lang.String PROPERTY_KEY
          key property to be used as property in orderAsc(String) and orderDesc(String)
 
Method Summary
 long count()
          execute a count(*) query and returns number of results
 java.util.List<ProcessInstance> list()
          execute the query and obtain the list of ProcessInstances
 ProcessInstanceQuery notSuspended()
          select only process definitions that are not suspended
 ProcessInstanceQuery orderAsc(java.lang.String property)
          order selected process instances ascending for certain properties
 ProcessInstanceQuery orderDesc(java.lang.String property)
          order selected process instances descending for certain properties
 ProcessInstanceQuery page(int firstResult, int maxResults)
          select a specific page in the result set
 ProcessInstanceQuery processDefinitionId(java.lang.String processDefinitionId)
          select only process instances for the given process definition
 ProcessInstanceQuery processInstanceId(java.lang.String processInstanceId)
          select only a specific process instances using the process instance id
 ProcessInstanceQuery processInstanceKey(java.lang.String processInstanceKey)
          select only specific process instances using a business key
 ProcessInstanceQuery suspended()
          select only suspended process definitions
 ProcessInstance uniqueResult()
          execute the query and obtain the unique ProcessInstance
 

Field Detail

PROPERTY_KEY

static final java.lang.String PROPERTY_KEY
key property to be used as property in orderAsc(String) and orderDesc(String)

See Also:
Constant Field Values
Method Detail

processDefinitionId

ProcessInstanceQuery processDefinitionId(java.lang.String processDefinitionId)
select only process instances for the given process definition


processInstanceId

ProcessInstanceQuery processInstanceId(java.lang.String processInstanceId)
select only a specific process instances using the process instance id


processInstanceKey

ProcessInstanceQuery processInstanceKey(java.lang.String processInstanceKey)
select only specific process instances using a business key


suspended

ProcessInstanceQuery suspended()
select only suspended process definitions


notSuspended

ProcessInstanceQuery notSuspended()
select only process definitions that are not suspended


orderAsc

ProcessInstanceQuery orderAsc(java.lang.String property)
order selected process instances ascending for certain properties


orderDesc

ProcessInstanceQuery orderDesc(java.lang.String property)
order selected process instances descending for certain properties


page

ProcessInstanceQuery page(int firstResult,
                          int maxResults)
select a specific page in the result set


list

java.util.List<ProcessInstance> list()
execute the query and obtain the list of ProcessInstances


uniqueResult

ProcessInstance uniqueResult()
execute the query and obtain the unique ProcessInstance


count

long count()
execute a count(*) query and returns number of results



Copyright © 2010 JBoss Community. All Rights Reserved.