| Total Complexity | 2 |
| Total Lines | 37 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 5 | class RuntimeException extends \RuntimeException |
||
| 6 | { |
||
| 7 | /** |
||
| 8 | * @param string $command |
||
| 9 | * @param int $exitStatusCode |
||
| 10 | * @param int $code |
||
| 11 | * @param \Exception|\Throwable|null $previous |
||
| 12 | * |
||
| 13 | * @return static |
||
| 14 | */ |
||
| 15 | public static function commandExecutionFailed( |
||
| 16 | $command, |
||
| 17 | $exitStatusCode, |
||
| 18 | $code = 0, |
||
| 19 | $previous = null |
||
| 20 | ) { |
||
| 21 | $message = sprintf( |
||
| 22 | "\"$command\" exited with %s status code", |
||
| 23 | $exitStatusCode |
||
| 24 | ); |
||
| 25 | |||
| 26 | return new static($message, $code, $previous); |
||
| 27 | } |
||
| 28 | |||
| 29 | /** |
||
| 30 | * @param string $path |
||
| 31 | * @param int $code |
||
| 32 | * @param \Exception|\Throwable|null $previous |
||
| 33 | * |
||
| 34 | * @return static |
||
| 35 | */ |
||
| 36 | public static function noAccessTo( |
||
| 42 | } |
||
| 43 | } |
||
| 44 |