class InputStream implements IteratorAggregate

Provides a way to continuously write to the input of a Process until the InputStream is closed.

Methods

onEmpty(callable $onEmpty = null)

Sets a callback that is called when the write buffer becomes empty.

write(resource|string|int|float|bool|Traversable|null $input)

Appends an input to the write buffer.

close()

Closes the write buffer.

isClosed()

Tells whether the write buffer is closed or not.

getIterator()

No description

Details

at line 31
onEmpty(callable $onEmpty = null)

Sets a callback that is called when the write buffer becomes empty.

Parameters

callable $onEmpty

at line 42
write(resource|string|int|float|bool|Traversable|null $input)

Appends an input to the write buffer.

Parameters

resource|string|int|float|bool|Traversable|null $input The input to append as scalar, stream resource or \Traversable

at line 56
close()

Closes the write buffer.

at line 64
isClosed()

Tells whether the write buffer is closed or not.

at line 69
getIterator()