Constants

CLIENT

CLIENT = 'client'

SERVER

SERVER = 'server'

Properties

$requestId

$requestId : string

Type

string — Request ID

$exceptionType

$exceptionType : string

Type

string — Exception type (client / server)

$exceptionCode

$exceptionCode : string

Type

string — Exception code

$exceptionMessage

$exceptionMessage : string

Type

string — Exception message

Methods

__construct()

__construct(  $message = null,   $code = null,   $previous = null) 

Parameters

$message
$code
$previous

setExceptionCode()

setExceptionCode(string  $code) 

Set the exception code

Parameters

string $code

Exception code

getExceptionCode()

getExceptionCode() : string|null

Get the exception code

Returns

string|null

setExceptionMessage()

setExceptionMessage(  $message) 

Parameters

$message

getExceptionMessage()

getExceptionMessage() 

setExceptionType()

setExceptionType(string  $type) 

Set the exception type

Parameters

string $type

Exception type

getExceptionType()

getExceptionType() : string|null

Get the exception type (one of client or server)

Returns

string|null

setRequestId()

setRequestId(string  $id) 

Set the request ID

Parameters

string $id

Request ID

getRequestId()

getRequestId() : string|null

Get the Request ID

Returns

string|null

setResponse()

setResponse(\GuzzleHttp\Psr7\Response  $response) 

Set the associated response

Parameters

\GuzzleHttp\Psr7\Response $response

Response

getResponse()

getResponse() : \GuzzleHttp\Psr7\Response|null

Get the associated response object

Returns

\GuzzleHttp\Psr7\Response|null

setRequest()

setRequest(\GuzzleHttp\Psr7\Request  $request) 

Set the associated request

Parameters

\GuzzleHttp\Psr7\Request $request

getRequest()

getRequest() : \Obs\Common\RequestInterface|null

Get the associated request object

Returns

\Obs\Common\RequestInterface|null

getStatusCode()

getStatusCode() : integer|null

Get the status code of the response

Returns

integer|null

__toString()

__toString() : string

Cast to a string

Returns

string