DocumentsHierarchyNode

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

  1. documentReference

    (Optional)

  2. documentsHierarchy

    (Optional)

Properties

children

documentReference

Type: DocumentReference | NULL

Describes the document being referenced at this point in the hierarchy

parent

Methods

addChild

Type: Function

Append a child

Arguments

getId

Type: Function

Get the unique identifier for this hierarchyNode.

Returns

removeAllChildren

Type: Function

Remove all the children of this node

setDocumentReference

Type: Function

Should be called to set, change or clear the documentReference for this hierarchy node.

Arguments