Interface EventInstanceRepository
- All Known Implementing Classes:
EventInstanceRepositoryImpl
public interface EventInstanceRepository
- Author:
- Pascal GARCIA
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
createEventInstance
(SEventInstance eventInstance) void
createMessageInstance
(SMessageInstance messageInstance) void
createTimerEventTriggerInstance
(STimerEventTriggerInstance sEventTriggerInstance) STimerEventTriggerInstance is used to keep track of currently running timers usingProcessRuntimeAPI.searchTimerEventTriggerInstances(long, SearchOptions)
void
createWaitingEvent
(SWaitingEvent waitingEvent) void
deleteEventTriggerInstance
(STimerEventTriggerInstance eventTriggerInstance) void
deleteMessageInstance
(SMessageInstance messageInstance) void
void
deleteWaitingEvent
(SWaitingEvent waitingEvent) getActivityBoundaryEventInstances
(long activityInstanceId, int fromIndex, int maxResults) getAllWaitingEventsForProcessInstance
(long processInstanceId, int fromIndex, int maxResults) Return waiting events related to the process instance passed as parameter, including the ones at flow node level.getBoundaryWaitingErrorEvent
(long relatedActivityInstanceId, String errorCode) getEventInstances
(long rootContainerId, int fromIndex, int maxResults, String fieldName, OrderByType orderByType) <T extends STimerEventTriggerInstance>
TgetEventTriggerInstance
(Class<T> entityClass, long eventTriggerInstanceId) getMessageEventCouples
(int fromIndex, int maxResults) getMessageInstance
(long messageInstanceId) getMessageInstanceIdOlderThanCreationDate
(long creationDate, QueryOptions queryOptions) long
getNumberOfTimerEventTriggerInstances
(long processInstanceId, QueryOptions queryOptions) Get the number of STimerEventTriggerInstance on the specific process instance & corresponding to the criterialong
getNumberOfWaitingEvents
(Class<? extends SWaitingEvent> entityClass, QueryOptions countOptions) getStartWaitingEventsOfProcessDefinition
(long processDefinitionId) search start waiting events related to a process definition (not its event sub processes)getTimerEventTriggerInstanceOfFlowNode
(long flowNodeInstanceId) getWaitingEventsForFlowNodeId
(long flowNodeInstanceId) getWaitingMessage
(long waitingMessageId) getWaitingSignalEvent
(long id) getWaitingSignalEvents
(String signalName, int fromIndex, int maxResults) int
Resets all Waiting Message Events marked as 'in progress", so that they are eligible to match Message Instances again.int
Resets all Message Instances marked as handled, so that they are eligible to match Waiting Events again.searchTimerEventTriggerInstances
(long processInstanceId, QueryOptions queryOptions) Search the list of STimerEventTriggerInstance on the specific process instance & corresponding to the criteria<T extends SWaitingEvent>
List<T>searchWaitingEvents
(Class<T> entityClass, QueryOptions searchOptions) void
updateEventTriggerInstance
(STimerEventTriggerInstance sTimerEventTriggerInstance, EntityUpdateDescriptor descriptor) Update an event trigger instance.void
updateMessageInstance
(SMessageInstance messageInstance, EntityUpdateDescriptor descriptor) void
updateWaitingMessage
(SWaitingMessageEvent waitingMessageEvent, EntityUpdateDescriptor descriptor)
-
Field Details
-
EVENT_INSTANCE
- See Also:
-
EVENT_TRIGGER_INSTANCE
- See Also:
-
MESSAGE_INSTANCE
- See Also:
-
IN_REQUEST_SIZE
static final int IN_REQUEST_SIZE- See Also:
-
-
Method Details
-
createEventInstance
- Throws:
SEventInstanceCreationException
-
createTimerEventTriggerInstance
void createTimerEventTriggerInstance(STimerEventTriggerInstance sEventTriggerInstance) throws SEventTriggerInstanceCreationException STimerEventTriggerInstance is used to keep track of currently running timers usingProcessRuntimeAPI.searchTimerEventTriggerInstances(long, SearchOptions)
-
createMessageInstance
void createMessageInstance(SMessageInstance messageInstance) throws SMessageInstanceCreationException -
createWaitingEvent
- Throws:
SWaitingEventCreationException
-
getBoundaryWaitingErrorEvent
SWaitingErrorEvent getBoundaryWaitingErrorEvent(long relatedActivityInstanceId, String errorCode) throws SWaitingEventReadException - Throws:
SWaitingEventReadException
-
getEventInstances
List<SEventInstance> getEventInstances(long rootContainerId, int fromIndex, int maxResults, String fieldName, OrderByType orderByType) throws SEventInstanceReadException - Throws:
SEventInstanceReadException
-
getActivityBoundaryEventInstances
List<SBoundaryEventInstance> getActivityBoundaryEventInstances(long activityInstanceId, int fromIndex, int maxResults) throws SEventInstanceReadException - Parameters:
activityInstanceId
-fromIndex
-maxResults
-- Returns:
- List of SBoundaryEventInstance, ordered by identifier ascending
- Throws:
SEventInstanceReadException
- Since:
- 6.2
-
getEventTriggerInstance
<T extends STimerEventTriggerInstance> T getEventTriggerInstance(Class<T> entityClass, long eventTriggerInstanceId) throws SEventTriggerInstanceReadException - Parameters:
entityClass
-eventTriggerInstanceId
-- Returns:
- Throws:
SEventTriggerInstanceReadException
- Since:
- 6.4.0
-
deleteMessageInstance
- Throws:
SMessageModificationException
-
deleteWaitingEvent
-
getWaitingSignalEvents
List<SWaitingSignalEvent> getWaitingSignalEvents(String signalName, int fromIndex, int maxResults) throws SEventTriggerInstanceReadException - Parameters:
signalName
-fromIndex
-maxResults
-- Returns:
- Throws:
SEventTriggerInstanceReadException
- Since:
- 6.3
-
getStartWaitingEventsOfProcessDefinition
List<SWaitingEvent> getStartWaitingEventsOfProcessDefinition(long processDefinitionId) throws SBonitaReadException search start waiting events related to a process definition (not its event sub processes)- Parameters:
processDefinitionId
-- Returns:
- Throws:
SBonitaReadException
- Since:
- 6.3
-
getMessageEventCouples
List<SMessageEventCouple> getMessageEventCouples(int fromIndex, int maxResults) throws SEventTriggerInstanceReadException -
getWaitingMessage
- Throws:
SWaitingEventReadException
-
getMessageInstance
- Throws:
SMessageInstanceReadException
-
deleteMessageInstanceByIds
- Throws:
SMessageModificationException
-
getMessageInstanceIdOlderThanCreationDate
List<Long> getMessageInstanceIdOlderThanCreationDate(long creationDate, QueryOptions queryOptions) throws SEventTriggerInstanceReadException, SMessageInstanceReadException -
updateWaitingMessage
void updateWaitingMessage(SWaitingMessageEvent waitingMessageEvent, EntityUpdateDescriptor descriptor) throws SWaitingEventModificationException -
updateMessageInstance
void updateMessageInstance(SMessageInstance messageInstance, EntityUpdateDescriptor descriptor) throws SMessageModificationException - Throws:
SMessageModificationException
-
searchWaitingEvents
<T extends SWaitingEvent> List<T> searchWaitingEvents(Class<T> entityClass, QueryOptions searchOptions) throws SBonitaReadException - Throws:
SBonitaReadException
-
getNumberOfWaitingEvents
long getNumberOfWaitingEvents(Class<? extends SWaitingEvent> entityClass, QueryOptions countOptions) throws SBonitaReadException - Throws:
SBonitaReadException
-
getTimerEventTriggerInstanceOfFlowNode
Optional<STimerEventTriggerInstance> getTimerEventTriggerInstanceOfFlowNode(long flowNodeInstanceId) throws SBonitaReadException - Parameters:
flowNodeInstanceId
- the flow node instance id- Returns:
- the timer event trigger instance of this flow node if there is one
- Throws:
SBonitaReadException
-
getWaitingSignalEvent
SWaitingSignalEvent getWaitingSignalEvent(long id) throws SEventTriggerInstanceReadException, SEventTriggerInstanceNotFoundException -
deleteEventTriggerInstance
void deleteEventTriggerInstance(STimerEventTriggerInstance eventTriggerInstance) throws SEventTriggerInstanceDeletionException - Parameters:
eventTriggerInstance
-- Throws:
SEventTriggerInstanceDeletionException
- Since:
- 6.1
-
resetProgressMessageInstances
Resets all Message Instances marked as handled, so that they are eligible to match Waiting Events again.- Throws:
SMessageModificationException
- if an error occurs when resetting the 'handled' flag.
-
resetInProgressWaitingEvents
Resets all Waiting Message Events marked as 'in progress", so that they are eligible to match Message Instances again.- Returns:
- the number of waiting events reset.
- Throws:
SWaitingEventModificationException
- if an error occurs when resetting the 'progress' flag.
-
getNumberOfTimerEventTriggerInstances
long getNumberOfTimerEventTriggerInstances(long processInstanceId, QueryOptions queryOptions) throws SBonitaReadException Get the number of STimerEventTriggerInstance on the specific process instance & corresponding to the criteria- Parameters:
processInstanceId
- The identifier of the process instancequeryOptions
- Criteria of the search- Returns:
- The number of STimerEventTriggerInstance on the specific process instance & corresponding to the criteria
- Throws:
SBonitaReadException
- Since:
- 6.4.0
-
searchTimerEventTriggerInstances
List<STimerEventTriggerInstance> searchTimerEventTriggerInstances(long processInstanceId, QueryOptions queryOptions) throws SBonitaReadException Search the list of STimerEventTriggerInstance on the specific process instance & corresponding to the criteria- Parameters:
processInstanceId
- The identifier of the process instancequeryOptions
- Criteria of the search- Returns:
- The list of STimerEventTriggerInstance on the specific process instance & corresponding to the criteria
- Throws:
SBonitaReadException
- Since:
- 6.4.0
-
updateEventTriggerInstance
void updateEventTriggerInstance(STimerEventTriggerInstance sTimerEventTriggerInstance, EntityUpdateDescriptor descriptor) throws SEventTriggerInstanceModificationException Update an event trigger instance.- Parameters:
sTimerEventTriggerInstance
- The event trigger instance to updatedescriptor
- The fields to update- Throws:
SEventTriggerInstanceModificationException
- Since:
- 6.4.0
-
getWaitingEventsForFlowNodeId
List<SWaitingEvent> getWaitingEventsForFlowNodeId(long flowNodeInstanceId) throws SEventTriggerInstanceReadException -
getAllWaitingEventsForProcessInstance
List<SWaitingEvent> getAllWaitingEventsForProcessInstance(long processInstanceId, int fromIndex, int maxResults) throws SEventTriggerInstanceReadException Return waiting events related to the process instance passed as parameter, including the ones at flow node level.
-