setasign\SetaPDF2\Core\Document\Catalog

Outlines Class for handling a documents outline

File: /SetaPDF v2/Core/Document/Catalog/Outlines.php
Old class name (alias): \SetaPDF_Core_Document_Catalog_Outlines

Class hierarchy

Implements

Summary

Properties

$_catalog

The documents catalog instance.

$_outlinesDictionary


Methods

__construct()

appendChild()

Append an item to the outline.

Parameters
$item : \setasign\SetaPDF2\Core\Document\OutlinesItem

The outline item that should be appended

Exceptions

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

Throws \setasign\SetaPDF2\Core\Type\Exception

appendChildCopy()

Append a copy of an item or outline to this outline.

Parameters
$item : \setasign\SetaPDF2\Core\Document\OutlinesItem|Outlines

The item or root outlines dictionary

Exceptions

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

Throws \setasign\SetaPDF2\Core\Type\Exception

cleanUp()

public Outlines::cleanUp (
void
): void

Release memory / Cycled references.

getDocument()

Get the document instance.

getFirstItem()

Get an item instance of the item referenced in the 'First' key.

Return Values

The first item of the outlines root dictionary or false if no item is set.

Exceptions

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

Throws \setasign\SetaPDF2\Core\Type\Exception

getIterator()

Get the iterator reference for the outlines.

Return Values

A reference to the iterator

Exceptions

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

Throws \setasign\SetaPDF2\Core\Type\Exception

See
  • \setasign\SetaPDF2\Core\Document\Catalog\IteratorAggregate::getIterator()

getLastItem()

Get an item instance of the item referenced in the 'Last' key.

Return Values

The last item of the outlines root dictionary or false if no item is set.

Exceptions

Throws \setasign\SetaPDF2\Core\Type\Exception

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

offsetExists()

public Outlines::offsetExists (
string|int $offset
): bool

Checks if an item exists at a specific position.

Parameters
$offset : string|int
 
Exceptions

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

Throws \setasign\SetaPDF2\Core\Type\Exception

See
  • \setasign\SetaPDF2\Core\Document\Catalog\ArrayAccess::offsetExists()

offsetGet()

Get an item by a specific position.

Parameters
$offset : string|int
 
Exceptions

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

Throws \setasign\SetaPDF2\Core\Type\Exception

See
  • \setasign\SetaPDF2\Core\Document\Catalog\ArrayAccess::offsetGet()

offsetSet()

public Outlines::offsetSet (
null|string|int $offset,
\setasign\SetaPDF2\Core\Document\OutlinesItem $value
): void

Set an item at a specific position.

Parameters
$offset : null|string|int
 
$value : \setasign\SetaPDF2\Core\Document\OutlinesItem
 
Exceptions

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

Throws \setasign\SetaPDF2\Core\Type\Exception

See

offsetUnset()

Removes an item at a specific position.

Parameters
$offset : string|int
 
Exceptions

Throws \setasign\SetaPDF2\Core\SecHandler\Exception

Throws \setasign\SetaPDF2\Core\Type\Exception

See
  • \setasign\SetaPDF2\Core\Document\Catalog\ArrayAccess::offsetUnset()