Click or drag to resize

PdfObjectExtensionsGetOrAddArray Method

Gets the PdfArray that serves as a backing storage of the specified PdfCollection.

Namespace: SautinSoft.Pdf.Objects
Assembly: SautinSoft.Pdf (in SautinSoft.Pdf.dll) Version: 2024.11.26
Syntax
public static PdfArray GetOrAddArray(
	this PdfCollection collection
)

Parameters

collection  PdfCollection
The PdfCollection for which the backing PdfArray should be retrieved.

Return Value

PdfArray
A PdfArray that serves as a backing storage of the specified PdfCollection.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type PdfCollection. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
Exceptions
ExceptionCondition
ArgumentNullExceptioncollection is .
Remarks

If the backing PdfArray is null (lazily created when modifying the PdfCollection), then the backing PdfArray is created, added to the underlying model and returned.

Caution note  Caution
Changes made to the returned PdfArray are not verified to be in accordance with the PDF Specification ISO 32000-1:2008 so make them at your own risk.
See Also