public class ListDefinition extends DataDefinition
| Constructor and Description |
|---|
ListDefinition(DataDefinition elementType) |
| Modifier and Type | Method and Description |
|---|---|
void |
accept(DefinitionVisitor visitor)
Applies a visitor to this data-definition.
|
void |
completeValue(DataValue value)
Check the value to see if the data-definition can fill in any missing
data before validation
|
boolean |
equals(Object other) |
DataDefinition |
getElementType() |
DataType |
getType()
Returns the
DataType for this type. |
int |
hashCode() |
ListValue |
newInstance() |
String |
toString() |
List<Message> |
validate(DataValue value)
Validates that the specified
DataValue is an instance of this
data definition. |
validInstanceOfpublic ListDefinition(DataDefinition elementType)
public DataType getType()
DataDefinitionDataType for this type.getType in class DataDefinitionDataType for this typepublic DataDefinition getElementType()
public ListValue newInstance()
public List<Message> validate(DataValue value)
DataValue is an instance of this
data definition.
Validates that supplied value is not null
and it's type matches the type of this definition.
In addition, validates that all entries from the list value
expected type for this definition
validate in class DataDefinitionvalue - the DataValue to validatepublic void completeValue(DataValue value)
DataDefinitioncompleteValue in class DataDefinitionvalue - the value to checkpublic String toString()
DataDefinitiontoString in class DataDefinitionpublic void accept(DefinitionVisitor visitor)
DataDefinitionaccept in class DataDefinitionvisitor - the visitor operating on this data-definitionCopyright © 2022. All rights reserved.