org.activiti.engine.delegate.event

## Enum ActivitiEventType

- java.lang.Object
- - java.lang.Enum<ActivitiEventType>
  - - org.activiti.engine.delegate.event.ActivitiEventType

- All Implemented Interfaces:
    Serializable, Comparable<ActivitiEventType>

      public enum ActivitiEventType
      extends Enum<ActivitiEventType>

  Enumeration containing all possible types of `ActivitiEvent`s.
  Author:
    Frederik Heremans

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `ACTIVITY_CANCELLED` An activity has been cancelled because of boundary event.
    `ACTIVITY_COMPENSATE` An activity is about to be executed as a compensation for another activity.
    `ACTIVITY_COMPLETED` An activity has been completed successfully.
    `ACTIVITY_ERROR_RECEIVED` An activity has received an error event.
    `ACTIVITY_MESSAGE_RECEIVED` An activity has received a message event.
    `ACTIVITY_SIGNALED` An activity has received a signal.
    `ACTIVITY_STARTED` An activity is starting to execute.
    `CUSTOM` An event type to be used by custom events.
    `ENGINE_CLOSED` The process-engine that dispatched this event has been closed and cannot be used anymore.
    `ENGINE_CREATED` The process-engine that dispatched this event has been created and is ready for use.
    `ENTITY_ACTIVATED` Existing entity has been activated.
    `ENTITY_CREATED` New entity is created.
    `ENTITY_DELETED` Existing entity is deleted.
    `ENTITY_INITIALIZED` New entity has been created and all child-entities that are created as a result of the creation of this particular entity are also created and initialized.
    `ENTITY_SUSPENDED` Existing entity has been suspended.
    `ENTITY_UPDATED` Existing entity us updated.
    `HISTORIC_ACTIVITY_INSTANCE_CREATED` A event dispatched when a `HistoricActivityInstance` is created.
    `HISTORIC_ACTIVITY_INSTANCE_ENDED` A event dispatched when a `HistoricActivityInstance` is marked as ended.
    `HISTORIC_PROCESS_INSTANCE_CREATED` A event dispatched when a `HistoricProcessInstance` is created.
    `HISTORIC_PROCESS_INSTANCE_ENDED` A event dispatched when a `HistoricProcessInstance` is marked as ended.
    `JOB_CANCELED` Timer has been cancelled (e.g.
    `JOB_EXECUTION_FAILURE` A job has been executed, but failed.
    `JOB_EXECUTION_SUCCESS` A job has been successfully executed.
    `JOB_RETRIES_DECREMENTED` The retry-count on a job has been decremented.
    `MEMBERSHIP_CREATED` A new membership has been created.
    `MEMBERSHIP_DELETED` A single membership has been deleted.
    `MEMBERSHIPS_DELETED` All memberships in the related group have been deleted.
    `PROCESS_CANCELLED` A process has been cancelled.
    `PROCESS_COMPLETED` A process has been completed.
    `PROCESS_COMPLETED_WITH_ERROR_END_EVENT` A process has been completed with an error end event.
    `PROCESS_STARTED` A process instance has been started.
    `SEQUENCEFLOW_TAKEN` Indicates the engine has taken (ie.
    `TASK_ASSIGNED` A task as been assigned.
    `TASK_COMPLETED` A task has been completed.
    `TASK_CREATED` A task has been created.
    `TIMER_FIRED` Timer has been fired successfully.
    `UNCAUGHT_BPMN_ERROR` When a BPMN Error was thrown, but was not caught within in the process.
    `VARIABLE_CREATED` A new variable has been created.
    `VARIABLE_DELETED` An existing variable has been deleted.
    `VARIABLE_UPDATED` An existing variable has been updated.

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static ActivitiEventType[]` | `EMPTY_ARRAY`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static ActivitiEventType[]` | `getTypesFromString(String string)`
    `static ActivitiEventType` | `valueOf(String name)` Returns the enum constant of this type with the specified name.
    `static ActivitiEventType[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

    - ### Methods inherited from class java.lang.Enum

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### ENTITY_CREATED

          public static final ActivitiEventType ENTITY_CREATED

      New entity is created.

    - #### ENTITY_INITIALIZED

          public static final ActivitiEventType ENTITY_INITIALIZED

      New entity has been created and all child-entities that are created as a result of the creation of this particular entity are also created and initialized.

    - #### ENTITY_UPDATED

          public static final ActivitiEventType ENTITY_UPDATED

      Existing entity us updated.

    - #### ENTITY_DELETED

          public static final ActivitiEventType ENTITY_DELETED

      Existing entity is deleted.

    - #### ENTITY_SUSPENDED

          public static final ActivitiEventType ENTITY_SUSPENDED

      Existing entity has been suspended.

    - #### ENTITY_ACTIVATED

          public static final ActivitiEventType ENTITY_ACTIVATED

      Existing entity has been activated.

    - #### TIMER_FIRED

          public static final ActivitiEventType TIMER_FIRED

      Timer has been fired successfully.

    - #### JOB_CANCELED

          public static final ActivitiEventType JOB_CANCELED

      Timer has been cancelled (e.g. user task on which it was bounded has been completed earlier than expected)

    - #### JOB_EXECUTION_SUCCESS

          public static final ActivitiEventType JOB_EXECUTION_SUCCESS

      A job has been successfully executed.

    - #### JOB_EXECUTION_FAILURE

          public static final ActivitiEventType JOB_EXECUTION_FAILURE

      A job has been executed, but failed. Event should be an instance of a `ActivitiExceptionEvent`.

    - #### JOB_RETRIES_DECREMENTED

          public static final ActivitiEventType JOB_RETRIES_DECREMENTED

      The retry-count on a job has been decremented.

    - #### CUSTOM

          public static final ActivitiEventType CUSTOM

      An event type to be used by custom events. These types of events are never thrown by the engine itself, only be an external API call to dispatch an event.

    - #### ENGINE_CREATED

          public static final ActivitiEventType ENGINE_CREATED

      The process-engine that dispatched this event has been created and is ready for use.

    - #### ENGINE_CLOSED

          public static final ActivitiEventType ENGINE_CLOSED

      The process-engine that dispatched this event has been closed and cannot be used anymore.

    - #### ACTIVITY_STARTED

          public static final ActivitiEventType ACTIVITY_STARTED

      An activity is starting to execute. This event is dispatch right before an activity is executed.

    - #### ACTIVITY_COMPLETED

          public static final ActivitiEventType ACTIVITY_COMPLETED

      An activity has been completed successfully.

    - #### ACTIVITY_CANCELLED

          public static final ActivitiEventType ACTIVITY_CANCELLED

      An activity has been cancelled because of boundary event.

    - #### ACTIVITY_SIGNALED

          public static final ActivitiEventType ACTIVITY_SIGNALED

      An activity has received a signal. Dispatched after the activity has responded to the signal.

    - #### ACTIVITY_COMPENSATE

          public static final ActivitiEventType ACTIVITY_COMPENSATE

      An activity is about to be executed as a compensation for another activity. The event targets the activity that is about to be executed for compensation.

    - #### ACTIVITY_MESSAGE_RECEIVED

          public static final ActivitiEventType ACTIVITY_MESSAGE_RECEIVED

      An activity has received a message event. Dispatched before the actual message has been received by the activity. This event will be either followed by a `#ACTIVITY_SIGNALLED` event or `#ACTIVITY_COMPLETE` for the involved activity, if the message was delivered successfully.

    - #### ACTIVITY_ERROR_RECEIVED

          public static final ActivitiEventType ACTIVITY_ERROR_RECEIVED

      An activity has received an error event. Dispatched before the actual error has been received by the activity. This event will be either followed by a `#ACTIVITY_SIGNALLED` event or `#ACTIVITY_COMPLETE` for the involved activity, if the error was delivered successfully.

    - #### HISTORIC_ACTIVITY_INSTANCE_CREATED

          public static final ActivitiEventType HISTORIC_ACTIVITY_INSTANCE_CREATED

      A event dispatched when a `HistoricActivityInstance` is created. This is a specialized version of the `ENTITY_CREATED` and `ENTITY_INITIALIZED` event, with the same use case as the `ACTIVITY_STARTED`, but containing slightly different data. Note this will be an `ActivitiEntityEvent`, where the entity is the `HistoricActivityInstance`. Note that history (minimum level ACTIVITY) must be enabled to receive this event.

    - #### HISTORIC_ACTIVITY_INSTANCE_ENDED

          public static final ActivitiEventType HISTORIC_ACTIVITY_INSTANCE_ENDED

      A event dispatched when a `HistoricActivityInstance` is marked as ended. his is a specialized version of the `ENTITY_UPDATED` event, with the same use case as the `ACTIVITY_COMPLETED`, but containing slightly different data (e.g. the end time, the duration, etc.). Note that history (minimum level ACTIVITY) must be enabled to receive this event.

    - #### SEQUENCEFLOW_TAKEN

          public static final ActivitiEventType SEQUENCEFLOW_TAKEN

      Indicates the engine has taken (ie. followed) a sequenceflow from a source activity to a target activity.

    - #### UNCAUGHT_BPMN_ERROR

          public static final ActivitiEventType UNCAUGHT_BPMN_ERROR

      When a BPMN Error was thrown, but was not caught within in the process.

    - #### VARIABLE_CREATED

          public static final ActivitiEventType VARIABLE_CREATED

      A new variable has been created.

    - #### VARIABLE_UPDATED

          public static final ActivitiEventType VARIABLE_UPDATED

      An existing variable has been updated.

    - #### VARIABLE_DELETED

          public static final ActivitiEventType VARIABLE_DELETED

      An existing variable has been deleted.

    - #### TASK_CREATED

          public static final ActivitiEventType TASK_CREATED

      A task has been created. This is thrown when task is fully initialized (before TaskListener.EVENTNAME_CREATE).

    - #### TASK_ASSIGNED

          public static final ActivitiEventType TASK_ASSIGNED

      A task as been assigned. This is thrown alongside with an `ENTITY_UPDATED` event.

    - #### TASK_COMPLETED

          public static final ActivitiEventType TASK_COMPLETED

      A task has been completed. Dispatched before the task entity is deleted (`ENTITY_DELETED`). If the task is part of a process, this event is dispatched before the process moves on, as a result of the task completion. In that case, a `ACTIVITY_COMPLETED` will be dispatched after an event of this type for the activity corresponding to the task.

    - #### PROCESS_STARTED

          public static final ActivitiEventType PROCESS_STARTED

      A process instance has been started. Dispatched when starting a process instance previously created. The event PROCESS_STARTED is dispatched after the associated event ENTITY_INITIALIZED.

    - #### PROCESS_COMPLETED

          public static final ActivitiEventType PROCESS_COMPLETED

      A process has been completed. Dispatched after the last activity is ACTIVITY_COMPLETED. Process is completed when it reaches state in which process instance does not have any transition to take.

    - #### PROCESS_COMPLETED_WITH_ERROR_END_EVENT

          public static final ActivitiEventType PROCESS_COMPLETED_WITH_ERROR_END_EVENT

      A process has been completed with an error end event.

    - #### PROCESS_CANCELLED

          public static final ActivitiEventType PROCESS_CANCELLED

      A process has been cancelled. Dispatched when process instance is deleted by
      See Also:
        `org.activiti.engine.impl.RuntimeServiceImpl#deleteProcessInstance(java.lang.String, java.lang.String), before DB delete.`

    - #### HISTORIC_PROCESS_INSTANCE_CREATED

          public static final ActivitiEventType HISTORIC_PROCESS_INSTANCE_CREATED

      A event dispatched when a `HistoricProcessInstance` is created. This is a specialized version of the `ENTITY_CREATED` and `ENTITY_INITIALIZED` event, with the same use case as the `PROCESS_STARTED`, but containing slightly different data (e.g. the start time, the start user id, etc.). Note this will be an `ActivitiEntityEvent`, where the entity is the `HistoricProcessInstance`. Note that history (minimum level ACTIVITY) must be enabled to receive this event.

    - #### HISTORIC_PROCESS_INSTANCE_ENDED

          public static final ActivitiEventType HISTORIC_PROCESS_INSTANCE_ENDED

      A event dispatched when a `HistoricProcessInstance` is marked as ended. his is a specialized version of the `ENTITY_UPDATED` event, with the same use case as the `PROCESS_COMPLETED`, but containing slightly different data (e.g. the end time, the duration, etc.). Note that history (minimum level ACTIVITY) must be enabled to receive this event.

    - #### MEMBERSHIP_CREATED

          public static final ActivitiEventType MEMBERSHIP_CREATED

      A new membership has been created.

    - #### MEMBERSHIP_DELETED

          public static final ActivitiEventType MEMBERSHIP_DELETED

      A single membership has been deleted.

    - #### MEMBERSHIPS_DELETED

          public static final ActivitiEventType MEMBERSHIPS_DELETED

      All memberships in the related group have been deleted. No individual `MEMBERSHIP_DELETED` events will be dispatched due to possible performance reasons. The event is dispatched before the memberships are deleted, so they can still be accessed in the dispatch method of the listener.

  - ### Field Detail

    - #### EMPTY_ARRAY

          public static final ActivitiEventType[] EMPTY_ARRAY

  - ### Method Detail

    - #### values

          public static ActivitiEventType[] values()

      Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

          for (ActivitiEventType c : ActivitiEventType.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static ActivitiEventType valueOf(String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
        `name` - the name of the enum constant to be returned.
      Returns:
        the enum constant with the specified name
      Throws:
        `IllegalArgumentException` - if this enum type has no constant with the specified name
        `NullPointerException` - if the argument is null

    - #### getTypesFromString

          public static ActivitiEventType[] getTypesFromString(String string)

      Parameters:
        `string` - the string containing a comma-separated list of event-type names
      Returns:
        a list of `ActivitiEventType` based on the given list.
      Throws:
        `ActivitiIllegalArgumentException` - when one of the given string is not a valid type name

Copyright © 2016 Alfresco. All rights reserved.