Moodle  2.2.1
http://www.collinsharper.com
Zend_Gdata_MediaMimeStream Class Reference

Public Member Functions

 __construct ($xmlString=null, $filePath=null, $fileContentType=null)
 read ($bytesRequested)
 getTotalSize ()
 closeFileHandle ()
 getContentType ()

Protected Attributes

 $_boundaryString = null
 $_fileHandle = null
 $_currentPart = 0
 $_totalSize = 0
 $_parts = null

Detailed Description

Definition at line 44 of file MediaMimeStream.php.


Constructor & Destructor Documentation

__construct ( xmlString = null,
filePath = null,
fileContentType = null 
)

Create a new MimeMediaStream object.

Parameters:
string$xmlStringThe string corresponding to the XML section of the message, typically an atom entry or feed.
string$filePathThe path to the file that constitutes the binary part of the message.
string$fileContentTypeThe valid internet media type of the file.
Exceptions:
Zend_Gdata_App_IOExceptionIf the file cannot be read or does not exist. Also if mbstring.func_overload has been set > 1.

Definition at line 91 of file MediaMimeStream.php.


Member Function Documentation

Close the internal file that we are streaming to the socket.

Returns:
void

Definition at line 172 of file MediaMimeStream.php.

Return a Content-type header that includes the current boundary string.

Returns:
string A valid HTTP Content-Type header.

Definition at line 184 of file MediaMimeStream.php.

Return the total size of the mime message.

Returns:
integer Total size of the message to be sent.

Definition at line 162 of file MediaMimeStream.php.

read ( bytesRequested)

Read a specific chunk of the the MIME multipart message.

Parameters:
integer$bufferSizeThe size of the chunk that is to be read, must be lower than MAX_BUFFER_SIZE.
Returns:
string A corresponding piece of the message. This could be binary or regular text.

Definition at line 136 of file MediaMimeStream.php.


Field Documentation

$_boundaryString = null [protected]

Definition at line 52 of file MediaMimeStream.php.

$_currentPart = 0 [protected]

Definition at line 65 of file MediaMimeStream.php.

$_fileHandle = null [protected]

Definition at line 59 of file MediaMimeStream.php.

$_parts = null [protected]

Definition at line 78 of file MediaMimeStream.php.

$_totalSize = 0 [protected]

Definition at line 71 of file MediaMimeStream.php.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations