class final Core · roukmoute/pdf 0.6.1

PDF\Serialization\SerializationContext
An identity map and serialization guard scoped to one PDF file.

Read the source declaration ↗

Inheritance and contracts

This type declares no parent, interface or trait.

Construction

__construct()

Declared by PDF\Serialization\SerializationContext · View the code ↗

Declared methods

effectiveReferenceValue()

public function effectiveReferenceValue(PDF\Syntax\Object\IndirectReference $reference): PDF\Syntax\FileStructure\BasicType
Resolve a known generation without allocating unknown targets or reparsing historical builders.

Declared by PDF\Serialization\SerializationContext · View the code ↗

encryptStream()

public function encryptStream(PDF\Syntax\Object\StreamObject $stream, string $bytes): string
Stream encoders run before encryption; xref and excluded metadata bytes stay clear.

Declared by PDF\Serialization\SerializationContext · View the code ↗

excludeDocumentMetadata()

public function excludeDocumentMetadata(PDF\Security\DocumentMetadataExemption $exemption): void
Select the effective root metadata after incremental bindings have been staged.

Declared by PDF\Serialization\SerializationContext · View the code ↗

identifier()

Declared by PDF\Serialization\SerializationContext · View the code ↗

isByteRangeSignature()

public function isByteRangeSignature(PDF\Syntax\Object\DictionaryType $dictionary): bool
Recognizes byte-range signature containers; object signatures without ByteRange use normal encryption.

Declared by PDF\Serialization\SerializationContext · View the code ↗

isHistorical()

public function isHistorical(PDF\Syntax\FileStructure\BasicType $object): bool

Declared by PDF\Serialization\SerializationContext · View the code ↗

knownIdentifier()

Inspect an existing identity without allocating or discovering another object.

Declared by PDF\Serialization\SerializationContext · View the code ↗

objects()

public function objects(): array
@return array<int, BasicType>

Declared by PDF\Serialization\SerializationContext · View the code ↗

prepare()

Discover explicit identifiers before assigning automatic numbers.

Declared by PDF\Serialization\SerializationContext · View the code ↗

prepareFile()

public function prepareFile(PDF\Syntax\FileStructure\FileBody $body, PDF\Syntax\Object\IndirectReference $root, ?PDF\Syntax\Object\DictionaryType $trailer = null): void
Discover trailer values without promoting direct values to orphan indirect objects.

Declared by PDF\Serialization\SerializationContext · View the code ↗

recordStreamEmission()

public function recordStreamEmission(PDF\Syntax\Object\StreamObject $stream, PDF\Syntax\Object\DictionaryType $dictionary, string $encoded): void
Called by StreamObject with the actual final dictionary and same-call pre-encryption bytes.

Declared by PDF\Serialization\SerializationContext · View the code ↗

reference()

Declared by PDF\Serialization\SerializationContext · View the code ↗

referenceTo()

Declared by PDF\Serialization\SerializationContext · View the code ↗

references()

public function references(): array
@return list<RevisionReference>

Declared by PDF\Serialization\SerializationContext · View the code ↗

register()

Declared by PDF\Serialization\SerializationContext · View the code ↗

serialize()

public function serialize(PDF\Syntax\FileStructure\BasicType $object): string

Declared by PDF\Serialization\SerializationContext · View the code ↗

serializeEntry()

public function serializeEntry(PDF\Syntax\Object\DictionaryType $dictionary, PDF\Syntax\Object\DictionaryObject\Entry $entry): string
Signature container Contents stay clear; this also matches qpdf's signature handling.

Declared by PDF\Serialization\SerializationContext · View the code ↗

serializeIndirect()

public function serializeIndirect(PDF\Syntax\FileStructure\BasicType $object, ?PDF\Syntax\Object\IndirectObject\ObjectIdentifier $containingIdentifier = null): string
A normalized copy may use its containing object's identifier without acquiring a second identity.

Declared by PDF\Serialization\SerializationContext · View the code ↗

serializeStreamValue()

Embedded object and content-stream strings are encrypted with their containing stream.

Declared by PDF\Serialization\SerializationContext · View the code ↗

serializedSnapshot()

Declared by PDF\Serialization\SerializationContext · View the code ↗

stage()

Select an explicit addition or replacement; historical references alone never stage a value.

Declared by PDF\Serialization\SerializationContext · View the code ↗

stageReused()

A reuse is authorized only against the preceding effective free index.

Declared by PDF\Serialization\SerializationContext · View the code ↗

streamFilters()

public function streamFilters(PDF\Syntax\Object\StreamObject $stream): array
@return list<Filter>

Declared by PDF\Serialization\SerializationContext · View the code ↗

wasSerializedExternalStream()

public function wasSerializedExternalStream(PDF\Syntax\Object\StreamObject $stream): bool
An unchanged emitted stream must not lose the declaration that made its retained bytes external.

Declared by PDF\Serialization\SerializationContext · View the code ↗