Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
zendframework1
library
Zend
Pdf
Resource.php
Go to the documentation of this file.
1
<?php
30
abstract
class
Zend_Pdf_Resource
31
{
50
protected
$_objectFactory
;
51
57
protected
$_resource
;
58
67
public
function
__construct
(
$resource
)
68
{
69
if
(
$resource
instanceof
Zend_Pdf_Element_Object
) {
70
$this->_objectFactory =
$resource
->getFactory();
71
$this->_resource =
$resource
;
72
73
return
;
74
}
75
76
#require_once 'Zend/Pdf/ElementFactory.php';
77
78
$this->_objectFactory =
Zend_Pdf_ElementFactory::createFactory
(1);
79
if
(
$resource
instanceof
Zend_Pdf_Element
) {
80
$this->_resource = $this->_objectFactory->newObject(
$resource
);
81
}
else
{
82
$this->_resource = $this->_objectFactory->newStreamObject(
$resource
);
83
}
84
}
85
90
public
function
__clone
()
91
{
94
// $factory = Zend_Pdf_ElementFactory::createFactory(1);
95
// $processed = array();
96
//
97
// // Clone dictionary object.
98
// // Do it explicitly to prevent sharing resource attributes between different
99
// // results of clone operation (other resources are still shared)
100
// $dictionary = new Zend_Pdf_Element_Dictionary();
101
// foreach ($this->_pageDictionary->getKeys() as $key) {
102
// $dictionary->$key = $this->_pageDictionary->$key->makeClone($factory->getFactory(),
103
// $processed,
104
// Zend_Pdf_Element::CLONE_MODE_SKIP_PAGES);
105
// }
106
//
107
// $this->_pageDictionary = $factory->newObject($dictionary);
108
// $this->_objectFactory = $factory;
109
// $this->_attached = false;
110
// $this->_style = null;
111
// $this->_font = null;
112
}
113
123
public
function
cloneResource
(
$factory
, &$processed)
124
{
127
// // Clone dictionary object.
128
// // Do it explicitly to prevent sharing page attributes between different
129
// // results of clonePage() operation (other resources are still shared)
130
// $dictionary = new Zend_Pdf_Element_Dictionary();
131
// foreach ($this->_pageDictionary->getKeys() as $key) {
132
// $dictionary->$key = $this->_pageDictionary->$key->makeClone($factory->getFactory(),
133
// $processed,
134
// Zend_Pdf_Element::CLONE_MODE_SKIP_PAGES);
135
// }
136
//
137
// $clonedPage = new Zend_Pdf_Page($factory->newObject($dictionary), $factory);
138
// $clonedPage->_attached = false;
139
//
140
// return $clonedPage;
141
}
142
150
public
function
getResource
()
151
{
152
return
$this->_resource
;
153
}
154
161
public
function
getFactory
()
162
{
163
return
$this->_objectFactory
;
164
}
165
}
Zend_Pdf_Resource\getResource
getResource()
Definition:
Resource.php:150
Zend_Pdf_Resource\$_resource
$_resource
Definition:
Resource.php:57
Zend_Pdf_Element_Object
Definition:
Object.php:35
Zend_Pdf_Resource\$_objectFactory
$_objectFactory
Definition:
Resource.php:50
Zend_Pdf_Resource\__clone
__clone()
Definition:
Resource.php:90
$resource
$resource
Definition:
bulk.php:12
Zend_Pdf_Resource\getFactory
getFactory()
Definition:
Resource.php:161
Zend_Pdf_Element
Definition:
Element.php:30
Zend_Pdf_Resource\__construct
__construct($resource)
Definition:
Resource.php:67
$factory
$factory
Definition:
category_multiple_stores.php:10
Zend_Pdf_Resource\cloneResource
cloneResource($factory, &$processed)
Definition:
Resource.php:123
Zend_Pdf_ElementFactory\createFactory
static createFactory($objCount)
Definition:
ElementFactory.php:135
Zend_Pdf_Resource
Definition:
Resource.php:30