public abstract class AbstractValidationExceptionHandler<R> extends HapiContextSupport implements ValidationExceptionHandler<R>
Constructor and Description |
---|
AbstractValidationExceptionHandler(HapiContext context) |
Modifier and Type | Method and Description |
---|---|
void |
error(ValidationException exception)
Called on ValidationExceptions with error severity
|
Object |
getValidationSubject() |
void |
info(ValidationException exception)
Called on ValidationExceptions with info severity
|
void |
onExceptions(ValidationException... exceptions)
Called in case of validation rule violations.
|
void |
setValidationSubject(Object subject)
Sets the object that is the target of validation.
|
void |
warning(ValidationException exception)
Called on ValidationExceptions with warning severity
|
getHapiContext, setHapiContext
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
hasFailed, result
public AbstractValidationExceptionHandler(HapiContext context)
context
- Hapi Contextpublic void onExceptions(ValidationException... exceptions)
ValidationExceptionHandler
onExceptions
in interface ValidationExceptionHandler<R>
exceptions
- the exceptions that describe the validatin errorspublic void error(ValidationException exception)
exception
- ValidationExceptionpublic void warning(ValidationException exception)
exception
- ValidationExceptionpublic void info(ValidationException exception)
exception
- ValidationExceptionpublic void setValidationSubject(Object subject)
setValidationSubject
in interface ValidationExceptionHandler<R>
subject
- subject to be validatedpublic Object getValidationSubject()
Copyright © 2001–2017 University Health Network. All rights reserved.