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
FileParserDataSource.php
Go to the documentation of this file.
1
<?php
41
abstract
class
Zend_Pdf_FileParserDataSource
42
{
43
/**** Instance Variables ****/
44
45
50
protected
$_size
= 0;
51
56
protected
$_offset
= 0;
57
58
59
60
/**** Public Interface ****/
61
62
63
/* Abstract Methods */
64
70
abstract
public
function
__destruct
();
71
86
abstract
public
function
readBytes
($byteCount);
87
98
abstract
public
function
readAllBytes
();
99
100
101
/* Object Magic Methods */
102
111
public
function
__toString
()
112
{
113
return
get_class($this);
114
}
115
116
117
/* Accessors */
118
125
public
function
getOffset
()
126
{
127
return
$this->_offset
;
128
}
129
135
public
function
getSize
()
136
{
137
return
$this->_size
;
138
}
139
140
141
/* Primitive Methods */
142
156
public
function
moveToOffset
($offset)
157
{
158
if
($this->_offset == $offset) {
159
return
;
// Not moving; do nothing.
160
}
161
if
($offset < 0) {
162
#require_once 'Zend/Pdf/Exception.php';
163
throw
new
Zend_Pdf_Exception
(
'Attempt to move before start of data source'
,
164
Zend_Pdf_Exception::MOVE_BEFORE_START_OF_FILE
);
165
}
166
if
($offset >= $this->_size) {
// Offsets are zero-based.
167
#require_once 'Zend/Pdf/Exception.php';
168
throw
new
Zend_Pdf_Exception
(
'Attempt to move beyond end of data source'
,
169
Zend_Pdf_Exception::MOVE_BEYOND_END_OF_FILE
);
170
}
171
$this->_offset = $offset;
172
}
173
185
public
function
skipBytes
($byteCount)
186
{
187
$this->
moveToOffset
($this->_offset + $byteCount);
188
}
189
}
Zend_Pdf_FileParserDataSource
Definition:
FileParserDataSource.php:41
Zend_Pdf_FileParserDataSource\readAllBytes
readAllBytes()
Zend_Pdf_FileParserDataSource\__toString
__toString()
Definition:
FileParserDataSource.php:111
Zend_Pdf_FileParserDataSource\$_offset
$_offset
Definition:
FileParserDataSource.php:56
Zend_Pdf_FileParserDataSource\getOffset
getOffset()
Definition:
FileParserDataSource.php:125
Zend_Pdf_FileParserDataSource\$_size
$_size
Definition:
FileParserDataSource.php:50
Zend_Pdf_Exception\MOVE_BEYOND_END_OF_FILE
const MOVE_BEYOND_END_OF_FILE
Definition:
Exception.php:152
Zend_Pdf_FileParserDataSource\getSize
getSize()
Definition:
FileParserDataSource.php:135
Zend_Pdf_FileParserDataSource\readBytes
readBytes($byteCount)
Zend_Pdf_FileParserDataSource\moveToOffset
moveToOffset($offset)
Definition:
FileParserDataSource.php:156
Zend_Pdf_Exception
Definition:
Exception.php:51
Zend_Pdf_FileParserDataSource\__destruct
__destruct()
Zend_Pdf_FileParserDataSource\skipBytes
skipBytes($byteCount)
Definition:
FileParserDataSource.php:185
Zend_Pdf_Exception\MOVE_BEFORE_START_OF_FILE
const MOVE_BEFORE_START_OF_FILE
Definition:
Exception.php:146