Table of Contents

Class PdfReference

Namespace
PdfSharp.Pdf.Advanced
Assembly
PdfSharp.dll

Represents an indirect reference to a PdfObject.

public sealed class PdfReference : PdfItem, ICloneable
Inheritance
PdfReference
Implements
Inherited Members

Constructors

PdfReference(PdfObject)

Initializes a new PdfReference instance for the specified indirect object.

public PdfReference(PdfObject pdfObject)

Parameters

pdfObject PdfObject

PdfReference(PdfObjectID, long)

Initializes a new PdfReference instance from the specified object identifier and file position.

public PdfReference(PdfObjectID objectID, long position)

Parameters

objectID PdfObjectID
position long

Properties

Document

Gets or sets the document this object belongs to.

public PdfDocument Document { get; set; }

Property Value

PdfDocument

GenerationNumber

Gets the generation number of the object identifier.

public int GenerationNumber { get; }

Property Value

int

ObjectID

Gets or sets the object identifier.

public PdfObjectID ObjectID { get; set; }

Property Value

PdfObjectID

ObjectNumber

Gets the object number of the object identifier.

public int ObjectNumber { get; }

Property Value

int

Position

Gets or sets the file position of the related PdfObject.

public long Position { get; set; }

Property Value

long

Value

Gets or sets the referenced PdfObject.

public PdfObject Value { get; set; }

Property Value

PdfObject

Methods

Dereference(ref PdfItem)

Dereferences the specified item. If the item is a PdfReference, the item is set to the referenced value. Otherwise no action is taken.

public static void Dereference(ref PdfItem item)

Parameters

item PdfItem

Dereference(ref object)

Dereferences the specified item. If the item is a PdfReference, the item is set to the referenced value. Otherwise, no action is taken.

public static void Dereference(ref object item)

Parameters

item object

ToString()

Gets a string representing the object identifier.

public override string ToString()

Returns

string