Package org.camunda.bpm.engine
Class ProcessEngineException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.camunda.bpm.engine.ProcessEngineException
-
- All Implemented Interfaces:
java.io.Serializable
- Direct Known Subclasses:
AuthenticationException,AuthorizationException,BadUserRequestException,BpmnError,BpmnParseException,CaseException,ClassLoadingException,CmmnTransformException,DecisionException,DeploymentResourceNotFoundException,ELException,FormException,IdentityProviderException,MigratingProcessInstanceValidationException,MismatchingMessageCorrelationException,NullValueException,OptimisticLockingException,ParseException,PasswordEncryptionException,ProcessEngineCdiException,PvmException,ScriptEngineException,TaskAlreadyClaimedException,WrongDbException
public class ProcessEngineException extends java.lang.RuntimeExceptionRuntime exception that is the superclass of all exceptions in the process engine.- Author:
- Tom Baeyens
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected intcode
-
Constructor Summary
Constructors Constructor Description ProcessEngineException()ProcessEngineException(java.lang.String message)ProcessEngineException(java.lang.String message, int code)ProcessEngineException(java.lang.String message, java.lang.Throwable cause)ProcessEngineException(java.lang.Throwable cause)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetCode()Accessor of the exception error code.voidsetCode(int code)The exception code can be set via delegation code.
-
-
-
Constructor Detail
-
ProcessEngineException
public ProcessEngineException()
-
ProcessEngineException
public ProcessEngineException(java.lang.String message, java.lang.Throwable cause)
-
ProcessEngineException
public ProcessEngineException(java.lang.String message)
-
ProcessEngineException
public ProcessEngineException(java.lang.String message, int code)
-
ProcessEngineException
public ProcessEngineException(java.lang.Throwable cause)
-
-
Method Detail
-
setCode
public void setCode(int code)
The exception code can be set via delegation code.
Setting an error code on the exception in delegation code always overrides the exception code from a custom
ExceptionCodeProvider.Your business logic can react to the exception code exposed via
getCode()when calling Camunda Java API and is even exposed to the REST API when an error occurs.
-
getCode
public int getCode()
Accessor of the exception error code.
If not changed via
setCode(int), default code isBuiltinExceptionCode.FALLBACKwhich is always overridden by a custom or built-in error code provider.You can implement a custom
ExceptionCodeProviderand register it in theProcessEngineConfigurationImplvia thecustomExceptionCodeProviderproperty.
-
-