Documents Hierarchy Node
Type: Class
How to get DocumentsHierarchyNode?
JavaScript
import DocumentsHierarchyNode from 'fontoxml-documents/src/DocumentsHierarchyNode.js'
The DocumentsHierarchyNode represents a subtree of the primary hierarchical relationship between documents.
Do not construct documents hierarchy nodes. Instead, obtain them from the DocumentsHierarchy.
Constructor arguments
document
Reference (Optional)
Type: DocumentReference
documents
Hierarchy (Optional)
Type: DocumentsHierarchy
Properties
children
Type: Array<DocumentsHierarchyNode>
document Reference
Type: DocumentReference | NULL
Describes the document being referenced at this point in the hierarchy
parent
Type: DocumentsHierarchyNode | NULL
Methods
add Child
Type: Function
Append a child
Arguments
get Id
Type: Function
Get the unique identifier for this hierarchyNode.
Returns
remove All Children
Type: Function
Remove all the children of this node
set Document Reference
Type: Function
Should be called to set, change or clear the documentReference for this hierarchy node.
Arguments