setasign\SetaPDF2\Core\Canvas

Simple A class representing minimum functions to access a Canvas.

File: /SetaPDF v2/Core/Canvas/Simple.php
Old class name (alias): \SetaPDF_Core_Canvas_Simple

Class hierarchy

Summary

Properties

$_canvasContainer

The main dictionary of the canvas


Methods

__construct()

The constructor.

Parameters
$canvasContainer : \SetaPDF_Core_Canvas_ContainerInterface
 

cleanUp()

public Simple::cleanUp (
void
): void

Release memory and cycled references.

getContainer()

Get the container of the canvas (origin object).

getResources()

public Simple::getResources (
bool $inherited = true,
bool $create = false,
string $entryKey = null
): false|\SetaPDF_Core_Type_Dictionary|\SetaPDF_Core_Type_Array

Returns the resources dictionary or an entry of it.

If no resource dictionary exists it is possible to automatically create it and/or the desired entry.

Parameters
$inherited : bool

Check for a resources dictionary in parent nodes

$create : bool

Create dictionary/ies if they do not exists

$entryKey : string

The entries key (Font, XObject,...)

Return Values

Returns the resources dictionary, a dictionary by an entry key or false if none was found.

Exceptions

Throws \setasign\SetaPDF2\Core\Type\Exception

getStream()

public Simple::getStream (
void
): string

Get the whole byte stream of the canvas.

See