public interface ValueConstraint
Interface for objects which provide constraints for values.
| Nested Class Summary | |
|---|---|
static class |
ValueConstraint.Violation
|
| Method Summary | |
|---|---|
void |
assertConstraint(Object val)
Throws a Violation condition if the input is not acceptable. |
Object |
coerceValue(Object val)
Returns the constrained value, which can differ from the input. |
Object |
defaultValue()
Returns the default value for this constraint |
| Method Detail |
|---|
void assertConstraint(Object val)
throws ValueConstraint.Violation,
LogoException
ValueConstraint.Violation
LogoException
Object coerceValue(Object val)
throws ValueConstraint.Violation,
LogoException
ValueConstraint.Violation
LogoExceptionObject defaultValue()