Class ServerError

java.lang.Object
ai.chalk.exceptions.ServerError

public class ServerError extends Object
ServerError is an error that occurred in Chalk's server, for example, when a resolver unexpectedly fails to run.
  • Constructor Details

  • Method Details

    • getCode

      public ErrorCode getCode()
      The type of the error.
    • getCategory

      public ErrorCodeCategory getCategory()
      The category of the error, given in the type field for the error codes. This will be one of "REQUEST", "NETWORK", and "FIELD".
    • getMessage

      public String getMessage()
      A readable description of the error message.
    • getException

      public ResolverException getException()
      The exception that caused the failure, if applicable.
    • getFeature

      public String getFeature()
      The fully qualified name of the failing feature, e.g. `user.identity.has_voip_phone`.
    • getResolver

      public String getResolver()
      The fully qualified name of the failing resolver, e.g. `my.project.get_fraud_score`.
    • setCode

      public void setCode(ErrorCode code)
      The type of the error.
    • setCategory

      public void setCategory(ErrorCodeCategory category)
      The category of the error, given in the type field for the error codes. This will be one of "REQUEST", "NETWORK", and "FIELD".
    • setMessage

      public void setMessage(String message)
      A readable description of the error message.
    • setException

      public void setException(ResolverException exception)
      The exception that caused the failure, if applicable.
    • setFeature

      public void setFeature(String feature)
      The fully qualified name of the failing feature, e.g. `user.identity.has_voip_phone`.
    • setResolver

      public void setResolver(String resolver)
      The fully qualified name of the failing resolver, e.g. `my.project.get_fraud_score`.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

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

      public String toString()
      Overrides:
      toString in class Object