Package score

Class UserRevertException

  • All Implemented Interfaces:
    java.io.Serializable

    public class UserRevertException
    extends java.lang.RuntimeException
    Signals failure of an External method. If an external method is called by an external transaction or an internal transaction and the method throws an exception of this class or subclass of this class during the execution, the transaction fails and the code returned by getCode() is used as user failure code of the transaction. If the code is out of range, the code is clamped.

    User may extend this class and override getCode() method.

    See Also:
    Serialized Form
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int getCode()
      Returns error code.
      • 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 Detail

      • UserRevertException

        public UserRevertException()
      • UserRevertException

        public UserRevertException​(java.lang.String message)
      • UserRevertException

        public UserRevertException​(java.lang.String message,
                                   java.lang.Throwable cause)
      • UserRevertException

        public UserRevertException​(java.lang.Throwable cause)
    • Method Detail

      • getCode

        public int getCode()
        Returns error code. Subclass may override this method to change failure code. Default implementation returns 0.
        Returns:
        error code.