|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
A constraint operates on some form Component providing means
for defining the conditions under which Component is considered
valid. During validation, Constraint may produce appropriate error messages.
BaseConstraint| Method Summary | |
void |
clearErrors()
Clears the the errors produced while validating this Constraint. |
Set |
getErrors()
Returns the validation errors produced while validating this Constraint. |
void |
setCustomErrorMessage(String customErrorMessage)
Sets the custom error message, that will be used in place of default ones when this Constraint does not hold. |
void |
setEnvironment(Environment environment)
Sets the Environment of this Constraint. |
boolean |
validate()
This method validates this Constraint conditions. |
| Method Detail |
public boolean validate()
throws Exception
Constraint conditions.
Exceptionpublic Set getErrors()
Constraint.
public void clearErrors()
Constraint.
public void setCustomErrorMessage(String customErrorMessage)
Constraint does not hold.
customErrorMessage - custom error messagepublic void setEnvironment(Environment environment)
Environment of this Constraint.
Environment should come from whatever Component
that this Constraint is operating on.
The Environment of a Constraint may be set to
non-null value only once, further calls are ignored. Application programmer
typically never calls this method as Environment is
propagated seamlessly.
environment - the Environment for this constraint.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||