| @@ 78-87 (lines=10) @@ | ||
| 75 | * @return bool |
|
| 76 | * @throws InvalidArgumentException |
|
| 77 | */ |
|
| 78 | protected function isFileReadable($file) |
|
| 79 | { |
|
| 80 | if (!is_string($file)) { |
|
| 81 | throw new InvalidArgumentException( |
|
| 82 | "Invalid type '" . gettype($file) . "' for argument 'file'." |
|
| 83 | ); |
|
| 84 | } |
|
| 85 | ||
| 86 | return is_readable($file); |
|
| 87 | } |
|
| 88 | ||
| 89 | /** |
|
| 90 | * @inheritdoc |
|
| @@ 167-176 (lines=10) @@ | ||
| 164 | * @return bool |
|
| 165 | * @throws InvalidArgumentException |
|
| 166 | */ |
|
| 167 | protected function isDirectoryReadable($directory) |
|
| 168 | { |
|
| 169 | if (!is_string($directory)) { |
|
| 170 | throw new InvalidArgumentException( |
|
| 171 | "Invalid type '" . gettype($directory) . "' for argument 'directory'." |
|
| 172 | ); |
|
| 173 | } |
|
| 174 | ||
| 175 | return is_readable($directory); |
|
| 176 | } |
|
| 177 | ||
| 178 | /** |
|
| 179 | * @param string $directory |
|
| @@ 184-193 (lines=10) @@ | ||
| 181 | * @return bool |
|
| 182 | * @throws InvalidArgumentException |
|
| 183 | */ |
|
| 184 | protected function isDirectoryWritable($directory) |
|
| 185 | { |
|
| 186 | if (!is_string($directory)) { |
|
| 187 | throw new InvalidArgumentException( |
|
| 188 | "Invalid type '" . gettype($directory) . "' for argument 'directory'." |
|
| 189 | ); |
|
| 190 | } |
|
| 191 | ||
| 192 | return is_writable($directory); |
|
| 193 | } |
|
| 194 | ||
| 195 | /** |
|
| 196 | * @inheritdoc |
|
| @@ 152-161 (lines=10) @@ | ||
| 149 | * @return bool |
|
| 150 | * @throws InvalidArgumentException |
|
| 151 | */ |
|
| 152 | protected function isFileReadable($file) |
|
| 153 | { |
|
| 154 | if (!is_string($file)) { |
|
| 155 | throw new InvalidArgumentException( |
|
| 156 | "Invalid type '" . gettype($file) . "' for argument 'file'." |
|
| 157 | ); |
|
| 158 | } |
|
| 159 | ||
| 160 | return is_readable($file); |
|
| 161 | } |
|
| 162 | ||
| 163 | /** |
|
| 164 | * @param AdapterInterface $adapter |
|