Package org.flowable.engine.delegate

# Class BpmnError

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.flowable.common.engine.api.FlowableException
org.flowable.engine.delegate.BpmnError

All Implemented Interfaces:
  `Serializable`

public class BpmnError extends FlowableException
Special exception that can be used to throw a BPMN Error from `JavaDelegate`s and expressions. This should only be used for business faults, which shall be handled by a Boundary Error Event or Error Event Sub-Process modeled in the process definition. Technical errors should be represented by other exception types. This class represents an actual instance of a BPMN Error, whereas `Error` represents an Error definition.

Author:
  Tijs Rademakers
See Also:
  - Serialized Form

- ## Field Summary

  ### Fields inherited from class org.flowable.common.engine.api.FlowableException

  `isLogged, reduceLogLevel`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `BpmnError(String errorCode)`
  `BpmnError(String errorCode, String message)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `addAdditionalData(String name, Object value)`
  `VariableContainer`
  `getAdditionalDataContainer()`
  `String`
  `getErrorCode()`
  `void`
  `setAdditionalDataContainer(VariableContainer additionalDataContainer)`
  `protected void`
  `setErrorCode(String errorCode)`

  ### Methods inherited from class org.flowable.common.engine.api.FlowableException

  `isLogged, isReduceLogLevel, setLogged, setReduceLogLevel`

  ### Methods inherited from class java.lang.Throwable

  `addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString`

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

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### BpmnError

    public BpmnError(String errorCode)

  - ### BpmnError

    public BpmnError(String errorCode, String message)

- ## Method Details

  - ### setErrorCode

    protected void setErrorCode(String errorCode)

  - ### getErrorCode

    public String getErrorCode()

  - ### getAdditionalDataContainer

    public VariableContainer getAdditionalDataContainer()

  - ### setAdditionalDataContainer

    public void setAdditionalDataContainer(VariableContainer additionalDataContainer)

  - ### addAdditionalData

    public void addAdditionalData(String name, Object value)