THPDFHeadlessRenderAccess

The record in HPDFHeadlessRenderAccess is returned by THPDFHeadlessDocument.GetRenderAccess(PageIndex) for serial read-only access to the current document graph

The owning document must stay loaded and unchanged throughout use; pointers, resource dictionaries, and callback results are borrowed, and callers must not free or mutate them

FieldContract
ContextOpaque document pointer passed unchanged to every callback
PageDictionary, PageResourcesResolved page dictionary and inherited resource dictionary
Resolve: THPDFHeadlessRenderResolveResolves a borrowed object through the existing xref, object-stream, and security paths
ReadStream: THPDFHeadlessRenderReadStreamReturns decoded bytes with the supplied maximum applied before decoding, capped by the document budget
ReadImageBytes: THPDFHeadlessRenderReadImageAuthenticates and decrypts an image stream, decodes bounded prefix filters, and returns either decoded samples or the final JPEG, JPEG 2000, CCITT, or JBIG2 payload together with its terminal filter name and borrowed DecodeParms dictionary
FontResolver: THPDFHeadlessRenderFontResolverCreates an interface to the existing resource font decoder
RequireExtractionPermission: THPDFHeadlessRenderPermissionChecks cancellation and authenticated extraction permission
RequireOutputPath: THPDFHeadlessRenderOutputPathChecks cancellation and rejects source aliases by canonical path and physical file identity without creating a file
CancellationTokenBorrowed caller-owned document cancellation token
MaxDecodedBytes, MaxDepthUpper bounds inherited from document options

CatalogDictionary: THPDFDictionaryObject lends the resolved catalog for optional-content configuration; nil means no catalog was supplied and optional-content structures have no visibility effect

ResolveOptional: THPDFHeadlessRenderResolve resolves optional group memberships and returns nil for missing, deleted, or stale-generation references; valid live objects retain normal parsing, object-stream, security, cancellation, and depth checks, and their errors propagate

Initialize manually assembled access records with Default(THPDFHeadlessRenderAccess) before assigning callbacks; a nil ResolveOptional uses the ordinary resolver, and nil catalog preserves rendering without optional-content configuration

Output renderers must call RequireOutputPath(Context, FileName) before creating a file and apply their own staging, publication, and destination budget policies

Lifetime: IHPDFHeadlessRenderLifetime retains a graph-lifetime lease; nil remains valid for static rendering, while explicit viewer states require a valid lease and reject expired access before invoking callbacks

A view is invalid after the owning document is closed, reloaded, modified, or destroyed