PHP Class React\HttpClient\ChunkedStreamDecoder

Inheritance: implements React\Stream\ReadableStreamInterface, use trait Evenement\EventEmitterTrait
Show file Open project: reactphp/http-client Class Usage Examples

Protected Properties

Property Type Description
$buffer string
$closed boolean
$nextChunkIsLength boolean
$reachedEnd boolean
$remainingLength integer
$stream React\Stream\ReadableStreamInterface

Public Methods

Method Description
__construct ( React\Stream\ReadableStreamInterface $stream )
close ( )
handleData ( $data )
handleEnd ( )
isReadable ( )
pause ( )
pipe ( React\Stream\WritableStreamInterface $dest, array $options = [] )
resume ( )

Protected Methods

Method Description
getChunkLength ( )
iterateBuffer ( )

Method Details

__construct() public method

public __construct ( React\Stream\ReadableStreamInterface $stream )
$stream React\Stream\ReadableStreamInterface

close() public method

public close ( )

getChunkLength() protected method

protected getChunkLength ( )

handleData() public method

public handleData ( $data )

handleEnd() public method

public handleEnd ( )

isReadable() public method

public isReadable ( )

iterateBuffer() protected method

protected iterateBuffer ( )

pause() public method

public pause ( )

pipe() public method

public pipe ( React\Stream\WritableStreamInterface $dest, array $options = [] )
$dest React\Stream\WritableStreamInterface
$options array

resume() public method

public resume ( )

Property Details

$buffer protected property

protected string $buffer
return string

$closed protected property

protected bool $closed
return boolean

$nextChunkIsLength protected property

protected bool $nextChunkIsLength
return boolean

$reachedEnd protected property

protected bool $reachedEnd
return boolean

$remainingLength protected property

protected int $remainingLength
return integer

$stream protected property

protected ReadableStreamInterface,React\Stream $stream
return React\Stream\ReadableStreamInterface