Pajdeg  0.2.2
Pajdeg
PDParserAttachment.h File Reference

An attachment between two parsers. More...

#include "PDDefines.h"

Go to the source code of this file.

Functions

PDParserAttachmentRef PDParserAttachmentCreate (PDParserRef parser, PDParserRef foreignParser)
 
PDObjectRef PDParserAttachmentImportObject (PDParserAttachmentRef attachment, PDObjectRef foreignObject, const char **excludeKeys, PDInteger excludeKeysCount)
 

Detailed Description

An attachment between two parsers.

PDF parser attachment header file.

Function Documentation

PDParserAttachmentRef PDParserAttachmentCreate ( PDParserRef  parser,
PDParserRef  foreignParser 
)

Create a foreign parser attachment, so that importing objects into parser from foreignParser becomes possible.

Parameters
parserThe native parser, which will receive imported objects
foreignParserThe foreign parser, which will provide existing objects in import operations
Returns
A retained PDParserAttachment instance
PDObjectRef PDParserAttachmentImportObject ( PDParserAttachmentRef  attachment,
PDObjectRef  foreignObject,
const char **  excludeKeys,
PDInteger  excludeKeysCount 
)

Iterate over the given foreign object recursively, creating appended objects for every indirect reference encountered. The resulting (new) indirect references, along with any direct references and associated stream (if any) are copied into a new object which is returned to the caller autoreleased.

A set of keys which should not be imported can be set. This set only applies to the object itself, and is not recursive. Thus, if an excluded key is encountered in one of the indirectly referenced objects, it will be included.

Parameters
parserThe parser which should import the foreign object
attachmentThe attachment to a foreign parser
foreignObjectThe foreign object
excludeKeysArray of strings that should not be imported, if any
excludeKeysCountSize of excludeKeys array
Returns
The new, native object based on the foreign object