TooManyRedirectsException
extends BadResponseException
in package
Http request exception thrown when a bad response is received
Table of Contents
Properties
Methods
- factory() : BadResponseException
- Factory method to create a new response exception based on the response code.
- getRequest() : RequestInterface
- Get the request that caused the exception
- getResponse() : Response
- Get the response that caused the exception
- setRequest() : RequestException
- Set the request that caused the exception
- setResponse() : mixed
- Set the response that caused the exception
Properties
$request
protected
RequestInterface
$request
$response
private
Response
$response
Methods
factory()
Factory method to create a new response exception based on the response code.
public
static factory(RequestInterface $request, Response $response) : BadResponseException
Parameters
- $request : RequestInterface
-
Request
- $response : Response
-
Response received
Return values
BadResponseExceptiongetRequest()
Get the request that caused the exception
public
getRequest() : RequestInterface
Return values
RequestInterfacegetResponse()
Get the response that caused the exception
public
getResponse() : Response
Return values
ResponsesetRequest()
Set the request that caused the exception
public
setRequest(RequestInterface $request) : RequestException
Parameters
- $request : RequestInterface
-
Request to set
Return values
RequestExceptionsetResponse()
Set the response that caused the exception
public
setResponse(Response $response) : mixed
Parameters
- $response : Response
-
Response to set