API Documentation

Gdata/MediaMimeStream.php

Includes Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Gdata
subpackage
Gdata
version
$Id: MediaMimeStream.php 20096 2010-01-06 02:05:09Z bkarwin $
Classes
Zend_Gdata_MediaMimeStream

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Gdata_MediaMimeStream

category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Gdata
subpackage
Gdata
Properties
$_boundaryString
$_fileHandle
$_currentPart
$_totalSize
$_parts
Methods
__construct
wrapEntry
read
getTotalSize
closeFileHandle
getContentType

Description

A streaming Media MIME class that allows for buffered read operations.

Properties

$_boundaryString

string $_boundaryString = 'null'

A valid MIME boundary.

Details

$_boundaryString
string
visibility
protected
default
null
final
false
static
false

$_currentPart

integer $_currentPart = '0'

The current part being read from.

Details

$_currentPart
integer
visibility
protected
default
0
final
false
static
false

$_fileHandle

resource $_fileHandle = 'null'

A handle to the file that is part of the message.

Details

$_fileHandle
resource
visibility
protected
default
null
final
false
static
false

$_parts

array $_parts = 'null'

An array of all the parts to be sent. Array members are either a MimeFile or a MimeBodyString object.

Details

$_parts
array
visibility
protected
default
null
final
false
static
false

$_totalSize

integer $_totalSize = '0'

The size of the MIME message.

Details

$_totalSize
integer
visibility
protected
default
0
final
false
static
false

Methods

__construct

__construct( string $xmlString = null, string $filePath = null, string $fileContentType = null ) :

Create a new MimeMediaStream object.

Arguments
$xmlString
string
The string corresponding to the XML section of the message, typically an atom entry or feed.
$filePath
string
The path to the file that constitutes the binary part of the message.
$fileContentType
string
The valid internet media type of the file.
Details
visibility
public
final
false
static
false
throws
If the file cannot be read or does not exist. Also if mbstring.func_overload has been set > 1.

closeFileHandle

closeFileHandle( ) : void

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

Details
visibility
public
final
false
static
false

getContentType

getContentType( ) : string

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

Output
string
A valid HTTP Content-Type header.
Details
visibility
public
final
false
static
false

getTotalSize

getTotalSize( ) : integer

Return the total size of the mime message.

Output
integer
Total size of the message to be sent.
Details
visibility
public
final
false
static
false

read

read(  $bytesRequested ) : string

Read a specific chunk of the the MIME multipart message.

Arguments
$bytesRequested
Output
string
A corresponding piece of the message. This could be binary or regular text.
Details
visibility
public
final
false
static
false

wrapEntry

wrapEntry(  $entry,  $fileMimeType ) : void

Sandwiches the entry body into a MIME message

Arguments
$entry
$fileMimeType
Details
visibility
private
final
false
static
false
Documentation was generated by DocBlox.