PHP Класс Phalcon\Db\Adapter\MongoDB\GridFS\ReadableStream

Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
__construct ( CollectionWrapper $collectionWrapper, stdClass $file ) Constructs a readable GridFS stream.
close ( )
downloadNumBytes ( integer $numBytes ) : string Read bytes from the stream.
downloadToStream ( resource $destination ) Writes the contents of this GridFS file to a writable stream.
getFile ( )
getId ( )
getSize ( )
isEOF ( )

Приватные методы

Метод Описание
advanceChunks ( )
initEmptyBuffer ( )

Описание методов

__construct() публичный Метод

Constructs a readable GridFS stream.
public __construct ( CollectionWrapper $collectionWrapper, stdClass $file )
$collectionWrapper CollectionWrapper GridFS collection wrapper
$file stdClass GridFS file document

close() публичный Метод

public close ( )

downloadNumBytes() публичный Метод

Note: this method may return a string smaller than the requested length if data is not available to be read.
public downloadNumBytes ( integer $numBytes ) : string
$numBytes integer Number of bytes to read
Результат string

downloadToStream() публичный Метод

Writes the contents of this GridFS file to a writable stream.
public downloadToStream ( resource $destination )
$destination resource Writable stream

getFile() публичный Метод

public getFile ( )

getId() публичный Метод

public getId ( )

getSize() публичный Метод

public getSize ( )

isEOF() публичный Метод

public isEOF ( )