public function setStatusCode(int $statusCode, string $reasonPhrase = null) : Response
    {
        if ($statusCode < 100 || $statusCode > 999) {
            throw new \InvalidArgumentException('Invalid  status code: ' . $statusCode);
        }

        if ($reasonPhrase === null) {
            $reasonPhrase = isset(self::$statusCodes[$statusCode])
                ? self::$statusCodes[$statusCode]
                : 'Unknown';
        } else {
            $reasonPhrase = (string) $reasonPhrase;
        }

        $this->statusCode   = $statusCode;
        $this->reasonPhrase = $reasonPhrase;

        return $this;
    }