Package com.orchestranetworks.instance
Interface ValueContextForValidationOnRecord
public interface ValueContextForValidationOnRecord
This interface represents a validation context for a record,
in the scope of a constraint on table that performs checks at the record-level.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addMessage
(UserMessage aMessage) Adds the specified validation message to the current validation context.void
addMessage
(SchemaNode aNode, UserMessage aMessage) Adds the specified validation message concerning a node in the current record.Returns the record currently being created or modified.getTable()
Returns the table that contains the record currently being created or modified.boolean
Returnstrue
if the associated constraint validates the value at user input.boolean
Returnstrue
if the current record is being created.void
removeRecordFromMessages
(ValueContext aRecord) Deprecated.
-
Method Details
-
getTable
AdaptationTable getTable()Returns the table that contains the record currently being created or modified. -
getRecord
ValueContext getRecord()Returns the record currently being created or modified. It contains the values as they are entered by the end user in the user interface. New values are not yet persisted. -
addMessage
Adds the specified validation message concerning a node in the current record. This method is equivalent toValueContextForValidationOnTable.addMessage(Adaptation, SchemaNode, UserMessage)
.- Throws:
IllegalArgumentException
- if the specified message isnull
.IllegalArgumentException
- if the specified node isnull
.IllegalArgumentException
- if the specified node is not consistent with the current context. That is, specified node must be in the same record that is currently being created or modified.- See Also:
-
addMessage
Adds the specified validation message to the current validation context. This method is equivalent toValueContextForValidationOnTable.addMessage(Adaptation, UserMessage)
.- Throws:
IllegalArgumentException
- if the specified message isnull
.- See Also:
-
removeRecordFromMessages
Deprecated.Validating a record does not modify the persisted validation report. Therefore this method has no effect. -
isCheckOnUserInput
boolean isCheckOnUserInput()Returnstrue
if the associated constraint validates the value at user input.- Since:
- 5.4.1
- See Also:
-
isRecordCreation
boolean isRecordCreation()Returnstrue
if the current record is being created.- Since:
- 6.1.0
- See Also:
-