crysalead/storage-stream 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

crysalead/storage-stream

最新稳定版本:1.0.6

Composer 安装命令:

composer require crysalead/storage-stream

包简介

Object-Oriented API for PHP streams

关键字:

README 文档

README

Build Status Code Coverage

Object-Oriented API for PHP streams (PSR-7 compatible).

Installation

composer require crysalead/storage-stream

Example

use Lead\Storage\Stream;

$stream = new Stream(fopen('smiley.png', 'r'));
$image = '';
while (!$stream->eof()) {
  $image .= $stream->read();
}

echo $stream->mime(); // 'image/png'

Pipe Example

use Lead\Storage\Stream;

$stream1 = new Stream("Hello");
$stream2 = new Stream("xxxxxWorld");

// copy the contents from the first stream to the second one
$stream1->pipe($stream2);

echo (string) $stream2; // 'HelloWorld'

Acknowledgements

Original implementation: Francois Zaninotto.

统计信息

  • 总下载量: 19.91k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-01-04