Definition at line 30 of file Element.php.
◆ cleanUp()
Clean up resources, used by object
Definition at line 124 of file Element.php.
◆ getParentObject()
◆ getType()
Return type of the element. See ZPdfPDFConst for possible values
- Returns
- integer
◆ makeClone()
Detach PDF object from the factory (if applicable), clone it and attach to new factory.
- Todo:
- It's nevessry to check if SplObjectStorage class works faster (Needs PHP 5.3.x to attach object with additional data to storage)
- Parameters
-
Zend_Pdf_ElementFactory | $factory | The factory to attach |
array | &$processed | List of already processed indirect objects, used to avoid objects duplication |
integer | $mode | Cloning mode (defines filter for objects cloning) |
- Returns
- Zend_Pdf_Element
Definition at line 81 of file Element.php.
◆ phpToPdf()
static phpToPdf |
( |
|
$input | ) |
|
|
static |
Convert PHP value into PDF element.
- Parameters
-
- Returns
- Zend_Pdf_Element
Definition at line 145 of file Element.php.
147 if (is_numeric($input)) {
148 #require_once 'Zend/Pdf/Element/Numeric.php'; 150 }
else if (is_bool($input)) {
151 #require_once 'Zend/Pdf/Element/Boolean.php'; 153 }
else if (is_array($input)) {
154 $pdfElementsArray = array();
155 $isDictionary =
false;
157 foreach ($input as $key =>
$value) {
158 if (is_string($key)) {
159 $isDictionary =
true;
165 #require_once 'Zend/Pdf/Element/Dictionary.php'; 168 #require_once 'Zend/Pdf/Element/Array.php'; 172 #require_once 'Zend/Pdf/Element/String.php';
◆ setParentObject()
Set top level parent indirect object.
- Parameters
-
Definition at line 91 of file Element.php.
93 $this->_parentObject = $parent;
◆ toPhp()
Convert PDF element to PHP type.
- Returns
- mixed
Definition at line 134 of file Element.php.
◆ toString()
toString |
( |
|
$factory = null | ) |
|
|
abstract |
Convert element to a string, which can be directly written to a PDF file.
$factory parameter defines operation context.
- Parameters
-
- Returns
- string
◆ touch()
Mark object as modified, to include it into new PDF file segment.
We don't automate this action to keep control on PDF update process. All new objects are treated as "modified" automatically.
Definition at line 114 of file Element.php.
116 if ($this->_parentObject !==
null) {
117 $this->_parentObject->touch();
◆ CLONE_MODE_FORCE_CLONING
const CLONE_MODE_FORCE_CLONING = 2 |
◆ CLONE_MODE_SKIP_PAGES
const CLONE_MODE_SKIP_PAGES = 1 |
◆ TYPE_ARRAY
◆ TYPE_BOOL
◆ TYPE_DICTIONARY
const TYPE_DICTIONARY = 6 |
◆ TYPE_NAME
◆ TYPE_NULL
◆ TYPE_NUMERIC
◆ TYPE_STREAM
◆ TYPE_STRING
The documentation for this class was generated from the following file:
- vendor/magento/zendframework1/library/Zend/Pdf/Element.php