@@ -13,7 +13,7 @@ |
||
| 13 | 13 | * @author Antoine Hérault <[email protected]> |
| 14 | 14 | */ |
| 15 | 15 | class InMemory implements Adapter, |
| 16 | - MimeTypeProvider |
|
| 16 | + MimeTypeProvider |
|
| 17 | 17 | { |
| 18 | 18 | protected $files = array(); |
| 19 | 19 | |
@@ -121,7 +121,7 @@ discard block |
||
| 121 | 121 | $this->ensureDirectoryExists($this->directory, $this->create); |
| 122 | 122 | |
| 123 | 123 | $file = $this->computePath($key); |
| 124 | - $lines = ftp_rawlist($this->getConnection(), '-al ' . \Gaufrette\Util\Path::dirname($file)); |
|
| 124 | + $lines = ftp_rawlist($this->getConnection(), '-al '.\Gaufrette\Util\Path::dirname($file)); |
|
| 125 | 125 | |
| 126 | 126 | if (false === $lines) { |
| 127 | 127 | return false; |
@@ -526,7 +526,7 @@ discard block |
||
| 526 | 526 | } |
| 527 | 527 | |
| 528 | 528 | // enable utf8 mode if configured |
| 529 | - if($this->utf8 == true) { |
|
| 529 | + if ($this->utf8 == true) { |
|
| 530 | 530 | ftp_raw($this->connection, "OPTS UTF8 ON"); |
| 531 | 531 | } |
| 532 | 532 | |
@@ -12,9 +12,9 @@ discard block |
||
| 12 | 12 | * @author Antoine Hérault <[email protected]> |
| 13 | 13 | */ |
| 14 | 14 | class Ftp implements Adapter, |
| 15 | - FileFactory, |
|
| 16 | - ListKeysAware, |
|
| 17 | - SizeCalculator |
|
| 15 | + FileFactory, |
|
| 16 | + ListKeysAware, |
|
| 17 | + SizeCalculator |
|
| 18 | 18 | { |
| 19 | 19 | protected $connection = null; |
| 20 | 20 | protected $directory; |
@@ -263,8 +263,8 @@ discard block |
||
| 263 | 263 | $this->fileData = array_merge($fileData, $this->fileData); |
| 264 | 264 | |
| 265 | 265 | return array( |
| 266 | - 'keys' => array_keys($fileData), |
|
| 267 | - 'dirs' => $dirs, |
|
| 266 | + 'keys' => array_keys($fileData), |
|
| 267 | + 'dirs' => $dirs, |
|
| 268 | 268 | ); |
| 269 | 269 | } |
| 270 | 270 | |
@@ -138,7 +138,7 @@ |
||
| 138 | 138 | * @param string $key - by default '' |
| 139 | 139 | * @param int $format - by default APC_ITER_NONE |
| 140 | 140 | * |
| 141 | - * @return \APCIterator |
|
| 141 | + * @return \Traversable |
|
| 142 | 142 | */ |
| 143 | 143 | protected function getCachedKeysIterator($key = '', $format = APC_ITER_NONE) |
| 144 | 144 | { |
@@ -213,7 +213,7 @@ |
||
| 213 | 213 | /** |
| 214 | 214 | * @param string $path |
| 215 | 215 | * |
| 216 | - * @return mixed |
|
| 216 | + * @return boolean |
|
| 217 | 217 | */ |
| 218 | 218 | public function unlink($path) |
| 219 | 219 | { |
@@ -305,7 +305,7 @@ discard block |
||
| 305 | 305 | /** |
| 306 | 306 | * Gets a new stream instance of the specified file. |
| 307 | 307 | * |
| 308 | - * @param $key |
|
| 308 | + * @param string $key |
|
| 309 | 309 | * |
| 310 | 310 | * @return Stream|Stream\InMemoryBuffer |
| 311 | 311 | * |
@@ -325,7 +325,7 @@ discard block |
||
| 325 | 325 | /** |
| 326 | 326 | * Creates a new file in a filesystem. |
| 327 | 327 | * |
| 328 | - * @param $key |
|
| 328 | + * @param string $key |
|
| 329 | 329 | * |
| 330 | 330 | * @return File |
| 331 | 331 | * |
@@ -287,6 +287,9 @@ |
||
| 287 | 287 | return true; |
| 288 | 288 | } |
| 289 | 289 | |
| 290 | + /** |
|
| 291 | + * @param string $key |
|
| 292 | + */ |
|
| 290 | 293 | protected function getOptions($key, array $options = []) |
| 291 | 294 | { |
| 292 | 295 | $options['ACL'] = $this->options['acl']; |
@@ -12,10 +12,10 @@ |
||
| 12 | 12 | * @author Michael Dowling <[email protected]> |
| 13 | 13 | */ |
| 14 | 14 | class AwsS3 implements Adapter, |
| 15 | - MetadataSupporter, |
|
| 16 | - ListKeysAware, |
|
| 17 | - SizeCalculator, |
|
| 18 | - MimeTypeProvider |
|
| 15 | + MetadataSupporter, |
|
| 16 | + ListKeysAware, |
|
| 17 | + SizeCalculator, |
|
| 18 | + MimeTypeProvider |
|
| 19 | 19 | { |
| 20 | 20 | /** @var S3Client */ |
| 21 | 21 | protected $service; |
@@ -186,6 +186,9 @@ |
||
| 186 | 186 | return $this->users; |
| 187 | 187 | } |
| 188 | 188 | |
| 189 | + /** |
|
| 190 | + * @param string $key |
|
| 191 | + */ |
|
| 189 | 192 | private function updateAcl($key) |
| 190 | 193 | { |
| 191 | 194 | $response = $this->s3->set_object_acl($this->bucketName, $key, $this->getAcl()); |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | * @deprecated The AclAwareAmazonS3 adapter is deprecated since version 0.4 and will be removed in 1.0. Use the AwsS3 adapter instead. |
| 20 | 20 | */ |
| 21 | 21 | class AclAwareAmazonS3 implements Adapter, |
| 22 | - MetadataSupporter |
|
| 22 | + MetadataSupporter |
|
| 23 | 23 | { |
| 24 | 24 | protected $delegate; |
| 25 | 25 | protected $s3; |
@@ -18,7 +18,7 @@ |
||
| 18 | 18 | * @deprecated The AmazonS3 adapter is deprecated since version 0.4 and will be removed in 1.0. Use the AwsS3 adapter instead. |
| 19 | 19 | */ |
| 20 | 20 | class AmazonS3 implements Adapter, |
| 21 | - MetadataSupporter |
|
| 21 | + MetadataSupporter |
|
| 22 | 22 | { |
| 23 | 23 | protected $service; |
| 24 | 24 | protected $bucket; |
@@ -11,7 +11,7 @@ |
||
| 11 | 11 | * @deprecated The Sftp adapter is deprecated since version 0.4 and will be removed in 1.0. |
| 12 | 12 | */ |
| 13 | 13 | class Sftp implements Adapter, |
| 14 | - ChecksumCalculator |
|
| 14 | + ChecksumCalculator |
|
| 15 | 15 | { |
| 16 | 16 | protected $sftp; |
| 17 | 17 | protected $directory; |