\GuzzleHttp\Command\Guzzle\ResponseLocationStatusCodeLocation

Extracts the status code of a response into a result field

Summary

Methods
Properties
Constants
__construct()
before()
after()
visit()
No public properties found
No constants found
No protected methods found
$locationName
N/A
No private methods found
No private properties found
N/A

Properties

$locationName

$locationName : string

Type

string

Methods

__construct()

__construct(string  $locationName = 'statusCode') : mixed

Set the name of the location

Parameters

string $locationName

Returns

mixed —

before()

before(\GuzzleHttp\Command\ResultInterface  $result, \Psr\Http\Message\ResponseInterface  $response, \GuzzleHttp\Command\Guzzle\Parameter  $model) : \GuzzleHttp\Command\ResultInterface

Called before visiting all parameters. This can be used for seeding the result of a command with default data (e.g. populating with JSON data in the response then adding to the parsed data).

Parameters

\GuzzleHttp\Command\ResultInterface $result
\Psr\Http\Message\ResponseInterface $response
\GuzzleHttp\Command\Guzzle\Parameter $model

Returns

\GuzzleHttp\Command\ResultInterface —

after()

after(\GuzzleHttp\Command\ResultInterface  $result, \Psr\Http\Message\ResponseInterface  $response, \GuzzleHttp\Command\Guzzle\Parameter  $model) : \GuzzleHttp\Command\ResultInterface

Called after visiting all parameters

Parameters

\GuzzleHttp\Command\ResultInterface $result
\Psr\Http\Message\ResponseInterface $response
\GuzzleHttp\Command\Guzzle\Parameter $model

Returns

\GuzzleHttp\Command\ResultInterface —

visit()

visit(\GuzzleHttp\Command\ResultInterface  $result, \Psr\Http\Message\ResponseInterface  $response, \GuzzleHttp\Command\Guzzle\Parameter  $param) : \GuzzleHttp\Command\ResultInterface

Called once for each parameter being visited that matches the location type.

Parameters

\GuzzleHttp\Command\ResultInterface $result
\Psr\Http\Message\ResponseInterface $response
\GuzzleHttp\Command\Guzzle\Parameter $param

Returns

\GuzzleHttp\Command\ResultInterface —