dev-master
9999999-dev
MIT
The Requires
- php ^7.1
The Development Requires
v1.0.0
1.0.0.0
MIT
The Requires
- php ^7.1
The Development Requires
![Scrutinizer Build Status][scrutinizer-build-image]
![Scrutinizer Code Quality][scrutinizer-code-quality-image]
![Scrutinizer Code Coverage][scrutinizer-code-coverage-image]
, (*1)
A set of interfaces for working with streams, as well as an in-memory implementation., (*2)
With Composer:, (*3)
composer require meekframework/stream
Using the interfaces:, (*4)
// write to stdout... class CliOutput implements Meek\Stream\Writable { public function write(string $data): int { // implementation here... } } // read from stdin... class CliInput implements Meek\Stream\Readable, Meek\Stream\Seekable { // implement methods from contracts... }
Using the in-memory Buffer
class:, (*5)
$stream = new Buffer('hello'); $stream->read(2); // returns 'he' $stream->getContents(); // returns 'llo' $stream->write(' world'); $stream->rewind(); $stream->getContents(); // returns 'hello world'
See CONTRIBUTING.md., (*6)
The MIT License (MIT). Please see LICENSE.md for more information., (*7)
MIT
MIT