Annotation Interface HelixException


@Retention(RUNTIME) @Target(TYPE) public @interface HelixException
Annotation that marks Helix exceptions for specialized error handling and error message creation by the framework.
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Sets the error code.
    Sets the error message.
    boolean
    Sets whether fields with getters on the exception will be included as "attributes" on the error message.
    int
    Sets the http status.
  • Element Details

    • code

      String code
      Sets the error code.
      Returns:
      error code
      Default:
      ""
    • status

      int status
      Sets the http status.
      Returns:
      http status
      Default:
      500
    • message

      String message
      Sets the error message.

      Message may contain placeholder strings in the format `${variable}` for replacement by exception properties at runtime.

      Returns:
      error message
      Default:
      ""
    • showFields

      boolean showFields
      Sets whether fields with getters on the exception will be included as "attributes" on the error message.
      Returns:
      true if fields will be included, false if not
      Default:
      false