Interface NiceModelTree
- All Known Implementing Classes:
NiceModuleTreeImpl
A tree containing model information per module. It has the following outline:
.root |-- module nodes | |-- model-element nodes (entity) | | |-- column nodes | |-- model-element nodes (relation)
The module node holds a reference to a module.
Below the module nodes, there are model-element nodes which hold either an
entity model or a
relation model. An entity-node in turn
has one ore more column nodes, which hold information in a
ModelColumnInfo object
that either refers to a field model or a
relation model where the relation
represents a 1:n relation with the foreign key located in the corresponding entity. You can
get foreign key information by getForeignKey()
method.
Since the foreign key values are inside each specific entity model node, all n:0..1 relations are covered by column nodes. The model element nodes containing relation models only hold the remaining n:m relations.
The tree reflects the model as it is defined in the corresponding modules. It does not
represent the "merged" or "overall" model (for that use NiceDataModel)
but it shows the model separated by modules. The ModelElementNode.Entity node only holds
the columns/fields that are defined in the corresponding module. If the module extends an
existing entity can be obtained via ModelElementNode.Entity.isExtended()
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescription@Nullable ModuleNodegetModuleNode(String modulename) Returns the module node in this tree for the specified module name, ornullif not found.getRoot()Returns the root node that holds all other nodes of the tree.
-
Field Details
-
MODULE_NAME_COMPARATOR
-
-
Method Details
-
getRoot
RootNode getRoot()Returns the root node that holds all other nodes of the tree. -
getModuleNode
Returns the module node in this tree for the specified module name, ornullif not found.- Parameters:
modulename- the module name of the module to lookup
-