1 | <?php |
||
24 | class NoSuchKeyException extends RuntimeException |
||
25 | { |
||
26 | /** |
||
27 | * Creates an exception for a key that was not found. |
||
28 | * |
||
29 | * @param string|int $key The key that was not found. |
||
30 | * @param Exception|null $cause The exception that caused this exception. |
||
31 | * |
||
32 | * @return static The created exception. |
||
33 | */ |
||
34 | 15 | public static function forKey($key, Exception $cause = null) |
|
41 | |||
42 | /** |
||
43 | * Creates an exception for multiple keys that were not found. |
||
44 | * |
||
45 | * @param array[] $keys The keys that were not found. |
||
46 | * @param Exception|null $cause The exception that caused this exception. |
||
47 | * |
||
48 | * @return static The created exception. |
||
49 | */ |
||
50 | 11 | public static function forKeys(array $keys, Exception $cause = null) |
|
57 | } |
||
58 |