Click or drag to resize

PdfTreeTKey, TValue Class

Represents a base class for name trees and number trees.
Inheritance Hierarchy
SystemObject
  SautinSoft.PdfPdfObject
    SautinSoft.PdfPdfCollection
      SautinSoft.PdfPdfCollectionKeyValuePairTKey, TValue
        SautinSoft.PdfPdfTreeTKey, TValue
          SautinSoft.PdfPdfEmbeddedFileSpecificationTree

Namespace: SautinSoft.Pdf
Assembly: SautinSoft.Pdf (in SautinSoft.Pdf.dll) Version: 2024.11.26
Syntax
public abstract class PdfTree<TKey, TValue> : PdfCollection<KeyValuePair<TKey, TValue>>, 
	IList, ICollection, IEnumerable, IList<KeyValuePair<TKey, TValue>>, 
	ICollection<KeyValuePair<TKey, TValue>>, IEnumerable<KeyValuePair<TKey, TValue>>

Type Parameters

TKey
The type of the keys in the tree. PdfString for name trees and PdfInteger for number trees.
TValue
The type of the values in the tree.

The PdfTreeTKey, TValue type exposes the following members.

Properties
 NameDescription
Public propertyItem Gets or sets the value associated with the specified key.
Top
Methods
 NameDescription
Public methodAdd Adds the specified key and value to the tree.
Public methodContainsKey Determines whether the tree contains the specified key.
Public methodRemove Removes the value with the specified key from the tree.
Public methodTryGetValue Gets the value associated with the specified key.
Top
Extension Methods
 NameDescription
Public Extension MethodGetArray Gets the PdfArray that serves as a backing storage of the specified PdfCollection.
(Defined by PdfObjectExtensions)
Public Extension MethodGetArray Gets the PdfArray that serves as a backing storage of the specified PdfObject or if no PdfArray serves as a backing storage of the specified PdfObject.
(Defined by PdfObjectExtensions)
Public Extension MethodGetDictionary Gets the PdfDictionary that serves as a backing storage of the specified PdfObject.
(Defined by PdfObjectExtensions)
Public Extension MethodGetOrAddArray Gets the PdfArray that serves as a backing storage of the specified PdfCollection.
(Defined by PdfObjectExtensions)
Public Extension MethodGetOrAddDictionary Gets the PdfDictionary that serves as a backing storage of the specified PdfObject.
(Defined by PdfObjectExtensions)
Top
Remarks

PdfString and PdfInteger are used as keys instead of String and Int32 to avoid, possibly costly, conversions.

SautinSoft.Pdf, currently, doesn't maintain the tree's structure when modifying the tree. Instead the entire tree structure is flattened into a single root node.

See Also