public final class TableGroup extends DiagramNode
DatasetGroup).| Modifier and Type | Method and Description |
|---|---|
TableField |
addField(String name)
Adds a child field node inside the current group node.
|
TableGroup |
addGroup(String name)
Adds a child group to the current group.
|
TableField |
addPrimaryKeyField(String name)
Adds a child field node as the primary key for the current group node.
|
List<DiagramNode> |
getChildren()
Returns an unmodifiable list of direct child nodes inside the current group node.
|
Table |
getContainerTable()
Returns the container table.
|
String |
getDataType()
Returns a string that describes the node data type.
|
int |
getMaxOccurrence()
Returns the maximum number of occurrences of this node.
|
int |
getMinOccurrence()
Returns the minimum number of occurrences of this node.
|
TableGroup |
getParent()
Returns the direct parent group node of the current node;
returns
null if the current group node is a direct child of the table node. |
boolean |
isTableGroup()
Returns
true if the current node is a group contained in a table node. |
void |
setCardinality(int minOccurrence,
int maxOccurrence)
Sets a node's cardinality.
|
void |
setDataType(String dataType)
Sets the node dataType.
|
getLabel, getName, isDatasetField, isDatasetGroup, isTable, isTableField, setLabel, setLabelpublic TableGroup getParent()
null if the current group node is a direct child of the table node.getParent in class DiagramNodepublic boolean isTableGroup()
DiagramNodetrue if the current node is a group contained in a table node.isTableGroup in class DiagramNodepublic Table getContainerTable()
public List<DiagramNode> getChildren()
public int getMinOccurrence()
public int getMaxOccurrence()
public void setCardinality(int minOccurrence,
int maxOccurrence)
minOccurrence - minimum number of occurrencemaxOccurrence - maximum number of occurrencepublic String getDataType()
public void setDataType(String dataType)
dataType - - a string describes the data typepublic TableGroup addGroup(String name)
name - a specific name for the child groupTableGrouppublic TableField addField(String name)
name - a specific name for the child field nodeDatasetFieldpublic TableField addPrimaryKeyField(String name)
name - a specific name for the child field nodeTableField