Open Journal Systems
3.3.0
|
Public Member Functions | |
__construct (StreamInterface $stream, StreamInterface $target=null) | |
close () | |
eof () | |
getSize () | |
read ($length) | |
rewind () | |
seek ($offset, $whence=SEEK_SET) | |
write ($string) | |
![]() | |
__toString () | |
detach () | |
getContents () | |
getMetadata ($key=null) | |
isReadable () | |
isSeekable () | |
isWritable () | |
tell () | |
Stream decorator that can cache previously read bytes from a sequentially read stream.
Definition at line 10 of file CachingStream.php.
GuzzleHttp\Psr7\CachingStream::__construct | ( | StreamInterface | $stream, |
StreamInterface | $target = null |
||
) |
We will treat the buffer object as the body of the stream
StreamInterface | $stream | Stream to cache |
StreamInterface | $target | Optionally specify where data is cached |
Definition at line 32 of file CachingStream.php.
GuzzleHttp\Psr7\CachingStream::close | ( | ) |
Close both the remote stream and buffer stream
Implements Psr\Http\Message\StreamInterface.
Definition at line 132 of file CachingStream.php.
GuzzleHttp\Psr7\CachingStream::eof | ( | ) |
Returns true if the stream is at the end of the stream.
Implements Psr\Http\Message\StreamInterface.
Definition at line 124 of file CachingStream.php.
GuzzleHttp\Psr7\CachingStream::getSize | ( | ) |
Get the size of the stream if known.
Implements Psr\Http\Message\StreamInterface.
Definition at line 40 of file CachingStream.php.
GuzzleHttp\Psr7\CachingStream::read | ( | $length | ) |
Read data from the stream.
int | $length | Read up to $length bytes from the object and return them. Fewer than $length bytes may be returned if underlying stream call returns fewer bytes. |
Implements Psr\Http\Message\StreamInterface.
Definition at line 81 of file CachingStream.php.
Referenced by GuzzleHttp\Psr7\CachingStream\seek().
GuzzleHttp\Psr7\CachingStream::rewind | ( | ) |
Seek to the beginning of the stream.
If the stream is not seekable, this method will raise an exception; otherwise, it will perform a seek(0).
Implements Psr\Http\Message\StreamInterface.
Definition at line 45 of file CachingStream.php.
References GuzzleHttp\Psr7\CachingStream\seek().
GuzzleHttp\Psr7\CachingStream::seek | ( | $offset, | |
$whence = SEEK_SET |
|||
) |
Seek to a position in the stream.
Implements Psr\Http\Message\StreamInterface.
Definition at line 50 of file CachingStream.php.
References GuzzleHttp\Psr7\CachingStream\read(), and Psr\Http\Message\StreamInterface\tell().
Referenced by GuzzleHttp\Psr7\CachingStream\rewind().
GuzzleHttp\Psr7\CachingStream::write | ( | $string | ) |
Write data to the stream.
string | $string | The string that is to be written. |
Implements Psr\Http\Message\StreamInterface.
Definition at line 110 of file CachingStream.php.
References Psr\Http\Message\StreamInterface\tell().