Class AppianErrorCode

java.lang.Object
com.appiancorp.exceptions.AppianErrorCode
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
ErrorCode, ValidationCode

public abstract class AppianErrorCode extends Object implements Serializable
See Also:
  • Constructor Details

  • Method Details

    • hasTitle

      public final boolean hasTitle()
      Indicates whether or not the given ErrorCode has a title corresponding to its message.
      Returns:
      true if the error code has a title
    • toErrorCode

      public static AppianErrorCode toErrorCode(String code)
      Returns the error code. Will return null if the error code is not found. Codes should generally be referenced explicitly from a static member of ErrorCode. This is used currently in GWT and PMM Connected Environments so the server can send down the string code of an ErrorCode and an instance can be returned from the string code. See https://source.appian.com/cru/CR-AE-1752#CFR-23290
      Parameters:
      code - The string representation of an error code, example APNX-1-0000-000
      Returns:
      An AppianErrorCode
    • getNamespace

      public int getNamespace()
    • getCategory

      public int getCategory()
    • getDetail

      public int getDetail()
    • equals

      public boolean equals(Object other)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getMessage

      public String getMessage(AppianErrorCodeFormatter callback, Object... arguments)
    • getTitle

      public String getTitle(AppianErrorCodeTitleFormatter callback, Object... arguments)
    • getMessageWithCode

      public String getMessageWithCode(AppianErrorCodeFormatter callback, Object... arguments)