T
- the exception type supported by the factorypublic abstract class AbstractExceptionFactory<T extends Exception> extends Object implements ExceptionFactory<T>
getExceptionMappings()
method. This method returns all
exception mappings registered with this factory.ExceptionFactory.IntegrityCheckResult
Constructor and Description |
---|
AbstractExceptionFactory() |
Modifier and Type | Method and Description |
---|---|
ExceptionFactory.IntegrityCheckResult |
checkIntegrity()
Performs an integrity check on the factories exception mapping registries.
|
T |
createException(ErrorType fault,
Throwable cause)
This method creates a new exception instance for the given server fault.
|
protected abstract ExceptionMapping<T>[] |
getExceptionMappings()
This method returns all exception mappings registered with this factory.
|
Set<ErrorCodeType> |
getSupportedErrors()
Returns the supported error codes for this factory instance.
|
boolean |
supports(ErrorCodeType errorCode)
This method determines if an exception mapping for faults with the given error code exists in the factory
instance.
|
ExceptionMapping<T> |
valueOf(ErrorCodeType code)
Returns the exception mapping for this error code.
|
public T createException(ErrorType fault, Throwable cause)
ExceptionFactory
createException
in interface ExceptionFactory<T extends Exception>
fault
- the server error representationcause
- the exception causepublic Set<ErrorCodeType> getSupportedErrors()
public boolean supports(ErrorCodeType errorCode)
ExceptionFactory
supports
in interface ExceptionFactory<T extends Exception>
errorCode
- the server error codepublic ExceptionMapping<T> valueOf(ErrorCodeType code)
code
- the error code to retrieve a mapping forprotected abstract ExceptionMapping<T>[] getExceptionMappings()
public ExceptionFactory.IntegrityCheckResult checkIntegrity()
ExceptionFactory
checkIntegrity
in interface ExceptionFactory<T extends Exception>
Copyright © 2016 Lexmark Enterprise Software Deutschland GmbH. All rights reserved.