public interface ConstraintContext extends DependenciesDefinitionContext
Constraint
Modifier and Type | Method and Description |
---|---|
void |
setBlocksCommitToNever()
Specifies that the current constraint must never
block an operation, even if it adds validation errors.
|
void |
setDependencyToLocalNode()
Specifies that the validation result of the current constraint depends
only on the local value of the underlying node.
|
addDependencyToInsertAndDelete, addDependencyToInsertAndDeleteInOtherInstance, addDependencyToInsertAndDeleteInOtherInstance, addDependencyToInsertDeleteAndModify, addDependencyToInsertDeleteAndModifyInOtherInstance, addDependencyToInsertDeleteAndModifyInOtherInstance, addDependencyToModify
addError, addError, addInfo, addMessage, addWarning, getSchemaNode
void setDependencyToLocalNode()
For more information, see Dependencies and Validation section.
IllegalStateException
- if a value dependency has been added to this constraint
or if the associated field is computed.void setBlocksCommitToNever()
When submitting a form in the context of the user interface, the current constraint will not be checked on user input. This allows relaxing the default behavior which prevents from submitting erroneous values. The current constraint will be still checked after submitting a form, if the form is valid and modified values have been committed.