LayerPD_Layer
ObjectPDNumTree

A PDNumTree is used to map integers to arbitrary Cos objects just as a Cos dictionary is used to map Cos names to Cos objects. However, a number tree can have many more entries than a Cos dictionary.



Typedef Summary
 Typedef
 PDNumTree
An object that points to the root node of a number tree inside a PDF file. A number tree is used to map integers to arbitrary Cos objects just as a Cos dictionary is used to map Cos names to Cos objects. However, a number tree can have many more entries than a Cos dictionary can.
Method Summary
 Method
 
void PDNumTreeEnum(PDNumTree theTree, CosObjEnumProc proc, void* clientData)
Enumerates the entries in the tree.
 
ASBool PDNumTreeEqual(PDNumTree tree1, PDNumTree tree2)
Compares two number trees to determine if they are the same object.
 
Creates a type cast of the CosObj to a number tree.
 
ASBool PDNumTreeGet(PDNumTree theTree, ASInt32 key, CosObj* value)
Retrieves an object from the number tree.
 
Creates a type cast of the number tree to a CosObj.
 
ASBool PDNumTreeIsValid(PDNumTree theTree)
Validates whether a PDNumTree is a CosDict Cos object.
 
PDNumTree PDNumTreeNew(PDDoc pdDoc)
Creates a new number tree in the document.
 
void PDNumTreeNumAdded(PDNumTree numTree, ASInt32 key, CosObj value, void* clientData)
An entry was added to a name tree.
 
void PDNumTreeNumRemoved(PDNumTree numTree, ASInt32 key, void* clientData)
An entry was removed from a name tree.
 
void PDNumTreePut(PDNumTree theTree, ASInt32 key, CosObj value)
Puts a new entry in the number tree. If an entry with this number is already in the tree, it is replaced.
 
void PDNumTreeRemove(PDNumTree theTree, ASInt32 key)
Removes the specified object from the tree. It does nothing if no object with that number exists.

Typedefs Detail
PDNumTree 
Product availability: All
Platform availability: All

Syntax

typedef OPAQUE_64_BITS PDNumTree;

An object that points to the root node of a number tree inside a PDF file. A number tree is used to map integers to arbitrary Cos objects just as a Cos dictionary is used to map Cos names to Cos objects. However, a number tree can have many more entries than a Cos dictionary can.

See Also


File: PDExpT.h
Line: 5448



Method Detail
PDNumTreeEnum()
Product availability: All
Platform availability: All

Syntax

void PDNumTreeEnum(PDNumTree theTree, CosObjEnumProc proc, void* clientData)

Enumerates the entries in the tree.

Parameters

theTree — 

IN/OUT A number tree.

 
proc — 

IN/OUT A procedure to call once for each number destination pair in theTree.

 
clientData — 

IN/OUT Data used by the enumeration procedure. clientData is passed to the enumeration procedure proc each time a number tree is encountered.

See Also

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7647
PDNumTreeEqual() 
Product availability: All
Platform availability: All

Syntax

ASBool PDNumTreeEqual(PDNumTree tree1, PDNumTree tree2)

Compares two number trees to determine if they are the same object.

Parameters

tree1 — 

A number tree.

 
tree2 — 

Another number tree.

Returns

true if the two number trees are equivalent, false otherwise.

See Also

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7588
PDNumTreeFromCosObj() 
Product availability: All
Platform availability: All

Syntax

PDNumTree PDNumTreeFromCosObj(CosObj obj)

Creates a type cast of the CosObj to a number tree.

Parameters

obj — 

IN/OUT The CosObj for which a PDNumTree representation is desired.

Returns

A PDNumTree representation of obj.

See Also

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7553
PDNumTreeGet() 
Product availability: All
Platform availability: All

Syntax

ASBool PDNumTreeGet(PDNumTree theTree, ASInt32 key, CosObj* value)

Retrieves an object from the number tree.

Parameters

theTree — 

The PDNumTree requested.

 
key — 

The number of the entry to retrieve.

 
value — 

(Filled by the method) The value associated with key.

Returns

true if the object was retrieved, false if no object with this number exists.

See Also

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7617
PDNumTreeGetCosObj() 
Product availability: All
Platform availability: All

Syntax

CosObj PDNumTreeGetCosObj(PDNumTree theTree)

Creates a type cast of the number tree to a CosObj.

Parameters

theTree — 

IN/OUT The PDNumTree for which a CosObj representation is desired.

Returns

A CosObj representation of theTree.

See Also

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7565
PDNumTreeIsValid() 
Product availability: All
Platform availability: All

Syntax

ASBool PDNumTreeIsValid(PDNumTree theTree)

Validates whether a PDNumTree is a CosDict Cos object.

Parameters

theTree — 

The PDNumTree whose validity is desired.

Returns

true if the number tree is a CosDict, false otherwise.

See Also

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7576
PDNumTreeNew() 
Product availability: Acrobat, PDFL
Platform availability: Macintosh, Windows, UNIX

Syntax

PDNumTree PDNumTreeNew(PDDoc pdDoc)

Creates a new number tree in the document.

Parameters

pdDoc — 

The document for which a new number tree is desired.

Returns

The newly created number tree, or a NULL CosObj if Acrobat is unable to create a PDNumTree for the document specified by pdDoc.

PDNumTreeIsValid() should be called to determine if the number tree returned by PDNumTreeNew() is usable.

See Also

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7541
PDNumTreeNumAdded() 
Product availability: All
Platform availability: All

Syntax

void PDNumTreeNumAdded(PDNumTree numTree, ASInt32 key, CosObj value, void* clientData)

An entry was added to a name tree.

Parameters

numTree — 

IN/OUT The name tree to which an entry was added.

 
key — 

IN/OUT The key for the entry.

 
value — 

IN/OUT The Cos object for the value associated with key.

 
clientData — 

IN/OUT A pointer to a block of user-supplied data that was passed in by the calling application when this notification was registered for using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 1770
PDNumTreeNumRemoved() 
Product availability: All
Platform availability: All

Syntax

void PDNumTreeNumRemoved(PDNumTree numTree, ASInt32 key, void* clientData)

An entry was removed from a name tree.

Parameters

numTree — 

IN/OUT The name tree from which an entry was removed.

 
key — 

IN/OUT The key for the entry.

 
clientData — 

IN/OUT A pointer to a block of user-supplied data that was passed in by the calling application when this notification was registered for using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 1783
PDNumTreePut() 
Product availability: Acrobat, PDFL
Platform availability: Macintosh, Windows, UNIX

Syntax

void PDNumTreePut(PDNumTree theTree, ASInt32 key, CosObj value)

Puts a new entry in the number tree. If an entry with this number is already in the tree, it is replaced.

Parameters

theTree — 

IN/OUT The number tree for which a new entry is added

 
key — 

IN/OUT The number of the entry.

 
value — 

IN/OUT The value associated with key.

See Also

Notifications

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7603
PDNumTreeRemove() 
Product availability: Acrobat, PDFL
Platform availability: Macintosh, Windows, UNIX

Syntax

void PDNumTreeRemove(PDNumTree theTree, ASInt32 key)

Removes the specified object from the tree. It does nothing if no object with that number exists.

Parameters

theTree — 

IN/OUT The number tree from which an entry is removed.

 
key — 

IN/OUT The number of the entry to remove.

See Also

Notifications

Since

PI_PDMODEL_VERSION >= 0x00040000

File: PDProcs.h
Line: 7631