DL Logo

PDSRoleMap Typedefs

PDSRoleMap

Header: PDSExpT.h:130

Description

Represents mappings of structural element types present in a PDF document to standard element types having similar uses. There is one PDSClassMap per document, associated with the PDSTreeRoot.

Note: The write functions in the PDSEdit API are not available in Adobe Reader.

Syntax

typedef CosObj PDSRoleMap;

Used By

PDSRoleMap Functions

PDSRoleMapCopy

Header: PDSWriteProcs.h:662

Description

Makes a copy of a PDSRoleMap, making it the PDSRoleMap of the specified StructTreeRoot.

This may raise various exceptions.

Related Methods

Syntax

void PDSRoleMapCopy(IN PDSRoleMap srcRoleMap, IN PDSTreeRoot dstTreeRoot, OUT PDSRoleMap *dstRoleMap);

Parameters

srcRoleMap
The PDSRoleMap to copy.
dstTreeRoot
The structure tree root in which to place srcRoleMap.
dstRoleMap
(Filled by the method) If not NULL, it points to the new, copied PDSRoleMap.

PDSRoleMapDoesMap

Header: PDSReadProcs.h:555

Description

Determines whether the specified PDSRoleMap provides any mapping path for two given element types.

Related Methods

Syntax

ASBool PDSRoleMapDoesMap(IN PDSRoleMap roleMap, IN ASAtom src, IN ASAtom dst);

Parameters

roleMap
IN/OUT The PDSRoleMap.
src
IN/OUT The ASAtom for an element type whose mapping is tested.
dst
IN/OUT The ASAtom for an element type. Note that this may be a standard element type.

Returns

true if an mapping path was found, false otherwise.

Exceptions

is raised if an error is found in the PDF file.

PDSRoleMapGetDirectMap

Header: PDSReadProcs.h:539

Description

Gets the type, if any, directly mapped in the specified PDSRoleMap for the given element type.

Related Methods

Syntax

ASAtom PDSRoleMapGetDirectMap(IN PDSRoleMap roleMap, IN ASAtom type);

Parameters

roleMap
type
The ASAtom for an element type whose mapping is found.

Returns

The ASAtom for the equivalent type specified in roleMap, or ASAtomNull if type has no mapping in roleMap.

Exceptions

is raised if an error is found in the PDF file.

PDSRoleMapMap

Header: PDSWriteProcs.h:618

Description

Maps an element type ( src) to another element type ( dst) in the specified PDSRoleMap.

Related Methods

Syntax

void PDSRoleMapMap(IN PDSRoleMap roleMap, IN ASAtom src, IN ASAtom dst);

Parameters

roleMap
The PDSRoleMap in which to create a new mapping.
src
The element type to map to dst.
dst
The element type that src maps onto. Note that this may be a standard element type, such as P.

Exceptions

is raised if src is already mapped.

PDSRoleMapUnMapDst

Header: PDSWriteProcs.h:646

Description

Makes the specified element type have no mapping.

Related Methods

Syntax

void PDSRoleMapUnMapDst(IN PDSRoleMap roleMap, IN ASAtom dst);

Parameters

roleMap
The PDSRoleMap in which to un-map all element types that map onto the dst element type.
dst
The element type to which all mappings are removed. All element types that map to the dst element type are unmapped.

Exceptions

PDSRoleMapUnMapSrc

Header: PDSWriteProcs.h:634

Description

Makes the specified element type have no mapping.

This may raise various exceptions.

Related Methods

Syntax

void PDSRoleMapUnMapSrc(IN PDSRoleMap roleMap, IN ASAtom src, IN ASBool fixupOthers);

Parameters

roleMap
IN/OUT The PDSRoleMap in which to un-map the src element type.
src
IN/OUT The element type whose mapping is removed.
fixupOthers
IN/OUT If true, any element type that was directly mapped to src is mapped to whatever src previously mapped to. If false, PDSRoleMapUnMapSrc() only un-maps src.