CreateNameTree(IEnumerable<KeyValuePair<CosString, CosObject>>) Method

Definition

Namespace Broadside
Assembly Broadside.dll

Builds a new name tree holding entries, balanced, with every node a new indirect object.

public PdfNameTree CreateNameTree(IEnumerable<KeyValuePair<CosString, CosObject>> entries)

Parameters

entries
IEnumerable<KeyValuePair<CosString, CosObject>>

The keys and values, in any order; each key once. Values are stored as given.

Returns

PdfNameTree
A view of the new tree. Its RootReference is what an entry of the name dictionary (Dests, EmbeddedFiles, …) or any other owner refers to; the tree is not reachable from the document until something does.

Remarks

ISO 32000-2 §7.9.6, Table 36 (PDF 1.2). Keys are sorted byte by byte (Annex J.3.3). Up to 64 keys sit in the root's Names array; more are spread evenly over leaves of at most 64 pairs under intermediate nodes of at most 64 kids, every leaf at the same depth, every node below the root with Limits.