Zend Framework
1.12
|
Public Member Functions | |
__destruct () | |
Object destructor. | |
readBytes ($byteCount) | |
Returns the specified number of raw bytes from the data source at the byte offset of the current read position. | |
readAllBytes () | |
Returns the entire contents of the data source as a string. | |
__toString () | |
Returns a description of the object for debugging purposes. | |
getOffset () | |
Returns the byte offset of the current read position within the data source. | |
getSize () | |
Returns the total size in bytes of the data source. | |
moveToOffset ($offset) | |
Moves the current read position to the specified byte offset. | |
skipBytes ($byteCount) | |
Shifts the current read position within the data source by the specified number of bytes. | |
Protected Attributes | |
$_size = 0 | |
$_offset = 0 | |
|
abstract |
Object destructor.
Closes the data source.
May also perform cleanup tasks such as deleting temporary files.
__toString | ( | ) |
Returns a description of the object for debugging purposes.
Subclasses should override this method to provide a more specific description of the actual object being represented.
getOffset | ( | ) |
Returns the byte offset of the current read position within the data source.
getSize | ( | ) |
Returns the total size in bytes of the data source.
moveToOffset | ( | $offset | ) |
Moves the current read position to the specified byte offset.
Throws an exception you attempt to move before the beginning or beyond the end of the data source.
If a subclass needs to perform additional tasks (such as performing a fseek() on a filesystem source), it should do so after calling this parent method.
integer | $offset | Destination byte offset. |
Zend_Pdf_Exception |
|
abstract |
Returns the entire contents of the data source as a string.
This method may be called at any time and so must preserve the byte offset of the read position, both through $this->_offset and whatever other additional pointers (such as the seek position of a file pointer) that might be used.
|
abstract |
Returns the specified number of raw bytes from the data source at the byte offset of the current read position.
Must advance the read position by the number of bytes read by updating $this->_offset.
Throws an exception if there is insufficient data to completely fulfill the request or if an error occurs.
integer | $byteCount | Number of bytes to read. |
Zend_Pdf_Exception |
skipBytes | ( | $byteCount | ) |
Shifts the current read position within the data source by the specified number of bytes.
You may move forward (positive numbers) or backward (negative numbers). Throws an exception you attempt to move before the beginning or beyond the end of the data source.
integer | $byteCount | Number of bytes to skip. |
Zend_Pdf_Exception |
|
protected |
|
protected |