mtdowling / streamer

Experimental: easy to create PHP stream decorators. The name will probably change.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Example:

require 'vendor/autoload.php';

use GuzzleHttp\Streamer\Utils;
use GuzzleHttp\Streamer\BaseWrapper;
use GuzzleHttp\Streamer\NoSeek;

$base = Utils::fromString('foobar');
$f = NoSeek::wrap($base);

echo fread($f, 10);
fseek($f, 0);
echo fread($f, 10);
fseek($base, 0);
echo fread($base, 10);

About

Experimental: easy to create PHP stream decorators. The name will probably change.


Languages

Language:PHP 100.0%