Enum ApplicationExceptionFactory.ApplicationErrors
- java.lang.Object
-
- java.lang.Enum<ApplicationExceptionFactory.ApplicationErrors>
-
- com.lexmark.saperion.exceptions.mappings.ApplicationExceptionFactory.ApplicationErrors
-
- All Implemented Interfaces:
ExceptionMapping<com.lexmark.saperion.exceptions.application.ApplicationException>
,java.io.Serializable
,java.lang.Comparable<ApplicationExceptionFactory.ApplicationErrors>
- Enclosing class:
- ApplicationExceptionFactory
public static enum ApplicationExceptionFactory.ApplicationErrors extends java.lang.Enum<ApplicationExceptionFactory.ApplicationErrors> implements ExceptionMapping<com.lexmark.saperion.exceptions.application.ApplicationException>
Application error definitions.- Author:
- owaeldrich
-
-
Enum Constant Summary
Enum Constants Enum Constant Description APPLICATION_MALFORMED_ENTITY_ERROR
GENERAL_ERROR
SEARCH_ERROR
SEARCH_STATEMENT_EXECUTION_ERROR
SEARCH_STATEMENT_SYNTAX_ERROR
WORKFLOW_ACTOR_REQUIRED_ERROR
WORKFLOW_GENERAL_ERROR
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description com.lexmark.saperion.exceptions.application.ApplicationException
createException(com.lexmark.saperion.exceptions.ErrorType fault, java.lang.Throwable cause)
Creates a new exception for the given server fault.com.lexmark.saperion.exceptions.application.ApplicationException
createException(java.lang.String message)
Creates a new exception for the given server fault.com.lexmark.saperion.exceptions.application.ApplicationException
createException(java.lang.String message, java.lang.Throwable cause)
Creates a new exception for the given server fault.com.lexmark.saperion.exceptions.application.ApplicationException
createException(java.lang.Throwable cause)
Creates a new exception for the given server fault.com.lexmark.saperion.exceptions.ErrorCodeType
getErrorCode()
Returns the error code this exception mapping applies to.boolean
validate()
Validates the integrity of the exception mapping.static ApplicationExceptionFactory.ApplicationErrors
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static ApplicationExceptionFactory.ApplicationErrors[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
GENERAL_ERROR
public static final ApplicationExceptionFactory.ApplicationErrors GENERAL_ERROR
-
WORKFLOW_GENERAL_ERROR
public static final ApplicationExceptionFactory.ApplicationErrors WORKFLOW_GENERAL_ERROR
-
WORKFLOW_ACTOR_REQUIRED_ERROR
public static final ApplicationExceptionFactory.ApplicationErrors WORKFLOW_ACTOR_REQUIRED_ERROR
-
APPLICATION_MALFORMED_ENTITY_ERROR
public static final ApplicationExceptionFactory.ApplicationErrors APPLICATION_MALFORMED_ENTITY_ERROR
-
SEARCH_ERROR
public static final ApplicationExceptionFactory.ApplicationErrors SEARCH_ERROR
-
SEARCH_STATEMENT_EXECUTION_ERROR
public static final ApplicationExceptionFactory.ApplicationErrors SEARCH_STATEMENT_EXECUTION_ERROR
-
SEARCH_STATEMENT_SYNTAX_ERROR
public static final ApplicationExceptionFactory.ApplicationErrors SEARCH_STATEMENT_SYNTAX_ERROR
-
-
Method Detail
-
values
public static ApplicationExceptionFactory.ApplicationErrors[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ApplicationExceptionFactory.ApplicationErrors c : ApplicationExceptionFactory.ApplicationErrors.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ApplicationExceptionFactory.ApplicationErrors valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
createException
public com.lexmark.saperion.exceptions.application.ApplicationException createException(com.lexmark.saperion.exceptions.ErrorType fault, java.lang.Throwable cause)
Description copied from interface:ExceptionMapping
Creates a new exception for the given server fault.- Specified by:
createException
in interfaceExceptionMapping<com.lexmark.saperion.exceptions.application.ApplicationException>
- Parameters:
fault
- the server errorcause
- the exception cause- Returns:
- the new exception
-
createException
public com.lexmark.saperion.exceptions.application.ApplicationException createException(java.lang.String message)
Description copied from interface:ExceptionMapping
Creates a new exception for the given server fault.- Specified by:
createException
in interfaceExceptionMapping<com.lexmark.saperion.exceptions.application.ApplicationException>
- Parameters:
message
- the error message- Returns:
- the new exception
-
createException
public com.lexmark.saperion.exceptions.application.ApplicationException createException(java.lang.String message, java.lang.Throwable cause)
Description copied from interface:ExceptionMapping
Creates a new exception for the given server fault.- Specified by:
createException
in interfaceExceptionMapping<com.lexmark.saperion.exceptions.application.ApplicationException>
- Parameters:
message
- the error messagecause
- the exception cause- Returns:
- the new exception
-
createException
public com.lexmark.saperion.exceptions.application.ApplicationException createException(java.lang.Throwable cause)
Description copied from interface:ExceptionMapping
Creates a new exception for the given server fault.- Specified by:
createException
in interfaceExceptionMapping<com.lexmark.saperion.exceptions.application.ApplicationException>
- Parameters:
cause
- the exception cause- Returns:
- the new exception
-
getErrorCode
public com.lexmark.saperion.exceptions.ErrorCodeType getErrorCode()
Description copied from interface:ExceptionMapping
Returns the error code this exception mapping applies to.- Specified by:
getErrorCode
in interfaceExceptionMapping<com.lexmark.saperion.exceptions.application.ApplicationException>
- Returns:
- the exception mapping's error code
-
validate
public boolean validate()
Description copied from interface:ExceptionMapping
Validates the integrity of the exception mapping. An exception mapping is valid if the mapped exception class can be instantiated and an appropriate factory constructor exists. Appropriate exception implementations must provide a factory constructors that consume anErrorType
and aThrowable
.- Specified by:
validate
in interfaceExceptionMapping<com.lexmark.saperion.exceptions.application.ApplicationException>
- Returns:
true
if the mapping is valid and the mapped exception fits the design rules, otherwisefalse
-
-