Provides a read only stream that pumps data from a PHP callable.

When invoking the provided callable, the PumpStream will pass the amount of
data requested to read to the callable. The callable can choose to ignore
this value and return fewer or more bytes than requested. Any extra data
returned by the provided callable is buffered internally until drained using
the read() function of the PumpStream. The provided callable MUST return
false when there is no more data to read.

CloneableInstantiable
ImplementsPsr\Http\Message\StreamInterface
Methods
public __construct(callable $source, array $options = [])
 
    public __toString()
    public close()
    public detach()
    public eof()
    public getContents()
    public getMetadata( $key = NULL)
    public getSize()
    public isReadable()
    public isSeekable()
    public isWritable()
    public read( $length)
    public rewind()
    public seek( $offset, $whence = 0)
    public tell()
    public write( $string)
    Properties
    private $buffer
    private $metadata
     
    • var array
    private $size
     
    • var int
    private $source
     
    • var callable
    private $tellPos
     
    • var int
    Methods
    private pump( $length)
    © 2020 Bruce Wells
    Search Namespaces \ Classes
    ConfigurationNumbers (0-9.) only