|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.exolab.castor.xml.validators.SimpleTypeValidator
A class for defining simple rules used for validating a content model.
| Constructor Summary | |
SimpleTypeValidator()
Creates a default SimpleTypeValidator. |
|
SimpleTypeValidator(TypeValidator validator)
Creates a SimpleTypeValidator using the given TypeValidator for delegating validation. |
|
| Method Summary | |
void |
setMaxOccurs(int maxOccurs)
Sets the maximum number of times that the described field may occur. |
void |
setMinOccurs(int minOccurs)
Sets the minimum number of times that the described field may occur. |
void |
setValidator(TypeValidator validator)
Sets the TypeValidator to delegate validation to. |
void |
validate(java.lang.Object object,
ValidationContext context)
Validates the given Object. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public SimpleTypeValidator()
public SimpleTypeValidator(TypeValidator validator)
validator - The TypeValidator to use| Method Detail |
public void setMaxOccurs(int maxOccurs)
maxOccurs - the maximum number of times that the described field may
occur.public void setMinOccurs(int minOccurs)
minOccurs - the minimum number of times that the described field may
occur.public void setValidator(TypeValidator validator)
validator - the TypeValidator to delegate validation to.
public void validate(java.lang.Object object,
ValidationContext context)
throws ValidationException
validate in interface TypeValidatorobject - the Object to validate.context - the ValidationContext.
ValidationException - if validation fails.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||