定制 kohkimakimoto/temporary 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

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

kohkimakimoto/temporary

最新稳定版本:v1.0.1

Composer 安装命令:

composer require kohkimakimoto/temporary

包简介

A PHP helper class to manipulate a temporary file.

关键字:

README 文档

README

Build Status Latest Stable Version Total Downloads Latest Unstable Version License

A PHP helper class to manipulate a temporary file and directory.

temporary file.

use Kohkimakimoto\Temporary\TemporaryFile;

$tmpfile = new TemporaryFile();

echo $tmpfile->path();  // ex) /private/var/folders/bt/xwh9qmcj00dctz53_rxclgtr0000gn/T/phpqWK5fj
$tmpfile->write("temporary data...");

echo $data = $tmpfile->read(); // temporary data...

// You don't need to close it. The temporary file will be closed automatically when the object removes.

temporary directory.

use Kohkimakimoto\Temporary\TemporaryDir;

$tmpdir = new TemporaryDir();
echo $tmpdir->path();   // ex) /private/var/folders/bt/xwh9qmcj00dctz53_rxclgtr0000gn/T/KFHg4L

// You don't need to close it. The temporary dir will be deleted automatically when the object removes.

Requirements

  • PHP5.3 or later

Installation

Create composer.json for installing via composer..

{
    "require": {
        "kohkimakimoto/temporary": "1.0.*"
    }
}

Run composer install command.

composer install

Author

Kohki Makimoto kohki.makimoto@gmail.com

License

MIT license.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-07-29