Package io.lionweb.model.impl
Class DynamicNode
- All Implemented Interfaces:
ClassifierInstance<Concept>,HasFeatureValues,HasSettableParent,Node
public class DynamicNode
extends DynamicClassifierInstance<Concept>
implements Node, HasSettableParent
DynamicNode can be used to represent Node of any Concept. The drawback is that this class expose
only homogeneous-APIs (e.g., getProperty('book')) and not heterogeneous-APIs (e.g., getBook()).
-
Field Summary
Fields inherited from class io.lionweb.model.impl.DynamicClassifierInstance
containmentValues, id, propertyValues, referenceValuesFields inherited from class io.lionweb.model.impl.AbstractClassifierInstance
annotations -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanThe concept of which this Node is an instance.The immediate parent of the Node.inthashCode()voidsetConcept(Concept concept) setParent(ClassifierInstance<?> parent) Set a new parent.toString()Methods inherited from class io.lionweb.model.impl.DynamicClassifierInstance
addChild, addReferenceValue, getChildren, getID, getPropertyValue, getReferenceValues, removeChild, removeChild, removeReferenceValue, removeReferenceValue, setID, setPropertyValue, setReferenceValuesMethods inherited from class io.lionweb.model.impl.AbstractClassifierInstance
addAnnotation, getAnnotations, getAnnotations, removeAnnotationMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface io.lionweb.model.ClassifierInstance
addAnnotation, getAnnotations, getAnnotations, removeAnnotationMethods inherited from interface io.lionweb.model.HasFeatureValues
addChild, addReferenceValue, getChildren, getPropertyValue, getReferenceValues, removeChild, removeChild, removeReferenceValue, removeReferenceValue, setPropertyValue, setReferenceValuesMethods inherited from interface io.lionweb.model.Node
getContainmentFeature, getID, getRoot, isRoot, thisAndAllDescendants
-
Constructor Details
-
DynamicNode
-
DynamicNode
public DynamicNode()
-
-
Method Details
-
setConcept
-
getParent
Description copied from interface:ClassifierInstanceThe immediate parent of the Node. This should be null only for root nodes.- Specified by:
getParentin interfaceClassifierInstance<Concept>- Specified by:
getParentin interfaceNode
-
getClassifier
Description copied from interface:NodeThe concept of which this Node is an instance. The Concept should not be abstract.- Specified by:
getClassifierin interfaceClassifierInstance<Concept>- Specified by:
getClassifierin interfaceNode
-
setParent
Description copied from interface:HasSettableParentSet a new parent.- Specified by:
setParentin interfaceHasSettableParent- Parameters:
parent- the new parent to be assigned- Returns:
- the element itself
-
equals
-
hashCode
public int hashCode() -
toString
-