Interface RequestFactoryInterface
Request factory used to create HTTP requests
Methods summary
public
Guzzle\Http\Message\RequestInterface
|
#
fromMessage( string $message )
Create a new request based on an HTTP message
Create a new request based on an HTTP message
Parameters
- $message
string $message HTTP message as a string
Returns
|
public
Guzzle\Http\Message\RequestInterface
|
#
fromParts( string $method, array $urlParts, array|Guzzle\Common\Collection $headers = null, string|resource|array|Guzzle\Http\EntityBodyInterface $body = null, string $protocol = 'HTTP', string $protocolVersion = '1.1' )
Create a request from URL parts as returned from parse_url()
Create a request from URL parts as returned from parse_url()
Parameters
- $method
string $method HTTP method (GET, POST, PUT, HEAD, DELETE, etc)
- $urlParts
array $urlParts URL parts containing the same keys as parse_url() - scheme: e.g. http
- host: e.g. www.guzzle-project.com
- port: e.g. 80 - user: e.g. michael - pass: e.g. rocks - path: e.g. / OR
/index.html - query: after the question mark ?
- $headers
array|Guzzle\Common\Collection $headers HTTP headers
- $body
string|resource|array|Guzzle\Http\EntityBodyInterface $body Body to send in the request
- $protocol
string $protocol Protocol (HTTP, SPYDY, etc)
- $protocolVersion
string $protocolVersion 1.0, 1.1, etc
Returns
|
public
Guzzle\Http\Message\RequestInterface
|
|