Package io.github.qubitpi.athena.config
Enum Class ErrorMessageFormat
- All Implemented Interfaces:
MessageFormatter
,Serializable
,Comparable<ErrorMessageFormat>
,Constable
Common message formats for errors.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionWhen aSystemConfig
doesn't find a config key.When aList
instance is empty and is not allowed.When an invalid GraphQL query is seen.When an invalid JSON is seen.When meta data not found.When aMap
is missing a required key.WhenSystemConfig
initialization fails. -
Method Summary
Modifier and TypeMethodDescriptionReturns the message format used for logging.Returns the message used for publishing out of the system, typically in error messages.static ErrorMessageFormat
Returns the enum constant of this class with the specified name.static ErrorMessageFormat[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
Methods inherited from interface io.github.qubitpi.athena.config.MessageFormatter
format, logFormat
-
Enum Constant Details
-
CONFIG_NOT_FOUND
When aSystemConfig
doesn't find a config key. -
SYSTEM_CONFIG_LOADING_ERROR_MESSAGE
WhenSystemConfig
initialization fails. -
EMPTY_LIST
When aList
instance is empty and is not allowed. -
MISSING_MAP_KEY
When aMap
is missing a required key. -
JSON_DESERIALIZATION_ERROR
When an invalid JSON is seen. -
INVALID_GRAPHQL_REQUEST
When an invalid GraphQL query is seen. -
META_DATA_NOT_FOUND
When meta data not found.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getMessageFormat
Description copied from interface:MessageFormatter
Returns the message used for publishing out of the system, typically in error messages.- Specified by:
getMessageFormat
in interfaceMessageFormatter
- Returns:
- the format for a message
-
getLoggingFormat
Description copied from interface:MessageFormatter
Returns the message format used for logging.- Specified by:
getLoggingFormat
in interfaceMessageFormatter
- Returns:
- the format for a log message
-