Open Journal Systems
3.3.0
|
Public Member Functions | |
__construct (EntityBodyInterface $body, $limit, $offset=0) | |
__toString () | |
getContentLength () | |
isConsumed () | |
read ($length) | |
seek ($offset, $whence=SEEK_SET) | |
setLimit ($limit) | |
setOffset ($offset) | |
![]() | |
__call ($method, array $args) | |
__construct (EntityBodyInterface $body) | |
close () | |
compress ($filter='zlib.deflate') | |
detachStream () | |
feof () | |
ftell () | |
getContentEncoding () | |
getContentMd5 ($rawOutput=false, $base64Encode=false) | |
getContentType () | |
getCustomData ($key) | |
getMetaData ($key=null) | |
getSize () | |
getStream () | |
getStreamType () | |
getUri () | |
getWrapper () | |
getWrapperData () | |
isLocal () | |
isReadable () | |
isRepeatable () | |
isSeekable () | |
isWritable () | |
readLine ($maxLength=null) | |
rewind () | |
setCustomData ($key, $value) | |
setRewindFunction ($callable) | |
setSize ($size) | |
setStream ($stream, $size=0) | |
uncompress ($filter='zlib.inflate') | |
write ($string) | |
Protected Attributes | |
$limit | |
$offset | |
![]() | |
$body | |
EntityBody decorator used to return only a subset of an entity body
Definition at line 10 of file ReadLimitEntityBody.php.
Guzzle\Http\ReadLimitEntityBody::__construct | ( | EntityBodyInterface | $body, |
$limit, | |||
$offset = 0 |
|||
) |
EntityBodyInterface | $body | Body to wrap |
int | $limit | Total number of bytes to allow to be read from the stream |
int | $offset | Position to seek to before reading (only works on seekable streams) |
Definition at line 29 of file ReadLimitEntityBody.php.
References Guzzle\Http\AbstractEntityBodyDecorator\$body, Guzzle\Http\ReadLimitEntityBody\$limit, Guzzle\Http\ReadLimitEntityBody\$offset, and Guzzle\Http\ReadLimitEntityBody\setLimit().
Guzzle\Http\ReadLimitEntityBody::__toString | ( | ) |
Returns only a subset of the decorated entity body when cast as a string {Convert the stream to a string if the stream is readable and the stream is seekable.
Reimplemented from Guzzle\Http\AbstractEntityBodyDecorator.
Definition at line 39 of file ReadLimitEntityBody.php.
References Guzzle\Http\AbstractEntityBodyDecorator\feof(), and Guzzle\Http\ReadLimitEntityBody\read().
Guzzle\Http\ReadLimitEntityBody::getContentLength | ( | ) |
Returns the Content-Length of the limited subset of data {Get the Content-Length of the entity body if possible (alias of getSize)
Reimplemented from Guzzle\Http\AbstractEntityBodyDecorator.
Definition at line 68 of file ReadLimitEntityBody.php.
Guzzle\Http\ReadLimitEntityBody::isConsumed | ( | ) |
Check if the stream has been consumed
Reimplemented from Guzzle\Http\AbstractEntityBodyDecorator.
Definition at line 58 of file ReadLimitEntityBody.php.
References Guzzle\Http\ReadLimitEntityBody\$limit.
Guzzle\Http\ReadLimitEntityBody::read | ( | $length | ) |
Read data from the stream
int | $length | Up to length number of bytes read. |
Reimplemented from Guzzle\Http\AbstractEntityBodyDecorator.
Definition at line 117 of file ReadLimitEntityBody.php.
References Guzzle\Http\ReadLimitEntityBody\$limit.
Referenced by Guzzle\Http\ReadLimitEntityBody\__toString().
Guzzle\Http\ReadLimitEntityBody::seek | ( | $offset, | |
$whence = SEEK_SET |
|||
) |
Allow for a bounded seek on the read limited entity body {Seek to a position in the stream
int | $offset | Stream offset |
int | $whence | Where the offset is applied |
Reimplemented from Guzzle\Http\AbstractEntityBodyDecorator.
Definition at line 81 of file ReadLimitEntityBody.php.
References Guzzle\Http\ReadLimitEntityBody\$offset.
Guzzle\Http\ReadLimitEntityBody::setLimit | ( | $limit | ) |
Set the limit of bytes that the decorator allows to be read from the stream
int | $limit | Total number of bytes to allow to be read from the stream |
Definition at line 110 of file ReadLimitEntityBody.php.
References Guzzle\Http\ReadLimitEntityBody\$limit.
Referenced by Guzzle\Http\ReadLimitEntityBody\__construct().
Guzzle\Http\ReadLimitEntityBody::setOffset | ( | $offset | ) |
Set the offset to start limiting from
int | $offset | Offset to seek to and begin byte limiting from |
Definition at line 95 of file ReadLimitEntityBody.php.
References Guzzle\Http\ReadLimitEntityBody\$offset.
|
protected |
Limit the number of bytes that can be read
Definition at line 16 of file ReadLimitEntityBody.php.
Referenced by Guzzle\Http\ReadLimitEntityBody\__construct(), Guzzle\Http\ReadLimitEntityBody\isConsumed(), Guzzle\Http\ReadLimitEntityBody\read(), and Guzzle\Http\ReadLimitEntityBody\setLimit().
|
protected |
Offset to start reading from
Definition at line 22 of file ReadLimitEntityBody.php.
Referenced by Guzzle\Http\ReadLimitEntityBody\__construct(), Guzzle\Http\ReadLimitEntityBody\seek(), and Guzzle\Http\ReadLimitEntityBody\setOffset().