wispx/flysystem-upyun
最新稳定版本:1.0
Composer 安装命令:
composer require wispx/flysystem-upyun
包简介
Flysystem adapter for the Upyun storage.
README 文档
README
💾 Flysystem adapter for the Upyun cloud storage.
This package is modified from overtrue/flysystem-qiniu
Requirement
- PHP >= 8.0.2
Installation
$ composer require "wispx/flysystem-upyun"
Usage
use League\Flysystem\Filesystem; use WispX\Flysystem\Upyun\UpyunAdapter; $service = 'xxxxxx'; $operator = 'xxxxxx'; $password = 'xxxxxx'; $domain = 'xxxx.test.upcdn.net'; // or with protocol: https://xxxx.test.upcdn.net $adapter = new UpyunAdapter($service, $operator, $password, $domain); $flysystem = new League\Flysystem\Filesystem($adapter);
API
bool $flysystem->write('file.md', 'contents'); bool $flysystem->write('file.md', 'http://httpbin.org/robots.txt'); bool $flysystem->writeStream('file.md', fopen('path/to/your/local/file.jpg', 'r')); bool $flysystem->copy('foo.md', 'foo2.md'); bool $flysystem->delete('file.md'); bool $flysystem->has('file.md'); bool $flysystem->fileExists('file.md'); bool $flysystem->directoryExists('path/to/dir'); string|false $flysystem->read('file.md'); array $flysystem->listContents(); int $flysystem->fileSize('file.md'); string $flysystem->mimeType('file.md');
Adapter extended methods:
string $adapter->getUrl('file.md');
License
MIT
统计信息
- 总下载量: 7.08k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 2
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-03-10