|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Constraint
Interface that defines a validatable constraint
Method Summary | |
---|---|
String |
getName()
|
String |
getPropertyName()
|
void |
setMessageSource(MessageSource source)
The message source to evaluate the default messages from |
void |
setOwningClass(Class owningClass)
The class the constraint applies to |
void |
setParameter(Object parameter)
The parameter which the constraint is validated against |
void |
setPropertyName(String propertyName)
The name of the property the constraint applies to |
boolean |
supports(Class type)
Returns whether the constraint supports being applied against the specified type; |
void |
validate(Object target,
Object propertyValue,
Errors errors)
Validate this constraint against a property value. |
Method Detail |
---|
boolean supports(Class type)
type
- The type to support
void validate(Object target, Object propertyValue, Errors errors)
target
- propertyValue
- The property value to validateerrors
- The errors instance to record errors againstvoid setParameter(Object parameter)
parameter
- void setOwningClass(Class owningClass)
owningClass
- void setPropertyName(String propertyName)
propertyName
- String getName()
String getPropertyName()
void setMessageSource(MessageSource source)
source
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |