| 1 | <?php |
||
| 12 | class ThrowRuntimeExceptionIfStatusCodeIsAboveTheLimitBehaviour implements ResponseBehaviourInterface |
||
| 13 | { |
||
| 14 | /** @var int */ |
||
| 15 | private $statusCode; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @param int $firstStatusCodeThatIsOverTheLimit |
||
| 19 | */ |
||
| 20 | public function __construct($firstStatusCodeThatIsOverTheLimit = 400) |
||
| 24 | |||
| 25 | /** |
||
| 26 | * Since the Response is immutable, each behaviour has to return a new |
||
| 27 | * Response instance |
||
| 28 | * |
||
| 29 | * @param Response $response |
||
| 30 | * @return Response |
||
| 31 | * @throws Exception|RuntimeException |
||
| 32 | */ |
||
| 33 | public function behave(Response $response) |
||
| 46 | } |
||
| 47 |