Class ApplicationFailedException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
de.aristaflow.adept2.model.runtimeenvironment.ApplicationFailedException
All Implemented Interfaces:
Serializable

public class ApplicationFailedException extends RuntimeException
Exception indicating the failing of an application / activity for internal reasons. This exception is used to inform the process management system about the failure and its reasons. Therefore the exception has an error code conforming to the ADEPT2-error codes as well as an arbitrary state. The state is component-specific and is not interpreted by the process management system itself. It can be handled by sophisticated failure recovery components plugged in the process management system. Additionally every ApplicationFailedException contains a human readable message explaining the failure and optionally the exception that caused the failure.
Author:
Kevin Goeser, Ulrich Kreher
See Also:
  • Constructor Details

    • ApplicationFailedException

      public ApplicationFailedException(String errorMessage, String state, long errorCode)
      Creates a new ApplicationFailedException containing the designated information which is a human readable message, the component-specific state and the ADEPT2-error code.
      Parameters:
      errorMessage - A human readable error message for this exception.
      state - Arbitrary state information specific to the component, comparable to the vendor code in SQLException.
      errorCode - The well-defined ADEPT2-error code.
    • ApplicationFailedException

      public ApplicationFailedException(String errorMessage, String state, long errorCode, Throwable cause)
      Creates a new ApplicationFailedException containing the designated information which is a human readable message, the component-specific state, the ADEPT2-error code and the cause for the failure.
      Parameters:
      errorMessage - A human readable error message for this exception.
      state - Arbitrary state information specific to the component, comparable to the vendor code in SQLException.
      errorCode - The well-defined ADEPT2-error code.
      cause - The cause for the failing of the application, for instance, another exception.
  • Method Details

    • getErrorCode

      public long getErrorCode()
      Returns the well-defined ADEPT2-error code.
      Returns:
      The well-defined ADEPT2-error code.
    • getState

      public String getState()
      Returns the component-specific state describing the failure further in a machine-readable form.
      Returns:
      The component-specific state describing the failure.
    • getCompleteStackTrace

      public String getCompleteStackTrace()
      Gets the complete stack trace of this exception as it would be printed to a print stream.
      Returns:
      The complete stack trace of this exception as it would be printed to a print stream.