diff --git a/README.md b/README.md index 1d2bf31..02c7c55 100644 --- a/README.md +++ b/README.md @@ -57,7 +57,7 @@ $result = $s3->commands()->upload('filename.ext', '/path/to/local/file.ext')->wi $result = $s3->commands()->restore('filename.ext', $days = 7)->execute(); -$result = $s3->commands()->list('/path')->execute(); +$result = $s3->commands()->list('path/')->execute(); /** @var bool $exist */ $exist = $s3->commands()->exist('filename.ext')->execute(); @@ -86,6 +86,8 @@ $result = $s3->upload('filename.ext', '/path/to/local/file.ext'); $result = $s3->restore('filename.ext', $days = 7); +$result = $s3->list('path/'); + /** @var bool $exist */ $exist = $s3->exist('filename.ext'); @@ -110,6 +112,8 @@ $promise = $s3->commands()->put('filename.ext', 'body')->async()->execute(); $promise = $s3->commands()->delete('filename.ext')->async()->execute(); $promise = $s3->commands()->upload('filename.ext', 'source')->async()->execute(); + +$promise = $s3->commands()->list('path/')->async()->execute(); ``` ## Advanced usage diff --git a/src/Service.php b/src/Service.php index 399b937..9ea5f71 100644 --- a/src/Service.php +++ b/src/Service.php @@ -20,6 +20,7 @@ * @method ResultInterface delete(string $filename) * @method ResultInterface upload(string $filename, $source) * @method ResultInterface restore(string $filename, int $days) + * @method ResultInterface list(string $prefix) * @method bool exist(string $filename) * @method string getUrl(string $filename) * @method string getPresignedUrl(string $filename, $expires)