|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface MethodConstraintViolation<T>
Describes the violation of a method-level constraint by providing access to the method/parameter hosting the violated constraint etc.
MethodValidator
Nested Class Summary | |
---|---|
static class |
MethodConstraintViolation.Kind
The kind of a MethodConstraintViolation . |
Method Summary | |
---|---|
MethodConstraintViolation.Kind |
getKind()
Returns the kind of this method constraint violation. |
Method |
getMethod()
Returns the method during which's validation this constraint violation occurred. |
Integer |
getParameterIndex()
Returns the index of the parameter holding the constraint which caused this constraint violation. |
String |
getParameterName()
Returns the name of the parameter holding the constraint which caused this constraint violation. |
Methods inherited from interface javax.validation.ConstraintViolation |
---|
getConstraintDescriptor, getInvalidValue, getLeafBean, getMessage, getMessageTemplate, getPropertyPath, getRootBean, getRootBeanClass |
Method Detail |
---|
Method getMethod()
Integer getParameterIndex()
MethodConstraintViolation.Kind.PARAMETER
.String getParameterName()
Returns the name of the parameter holding the constraint which caused this constraint violation.
Currently a synthetic name following the form "arg" + index
will be returned, e.g. "arg0"
. In future versions it might
be possible to specify real parameter names, e.g. using an
annotation-based approach around javax.inject.Named
.
MethodConstraintViolation.Kind.PARAMETER
.MethodConstraintViolation.Kind getKind()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |