Class Guzzle\Http\Message\RequestFactory

InheritanceGuzzle\Http\Message\RequestFactory
ImplementsGuzzle\Http\Message\RequestFactoryInterface

Default HTTP request factory used to create the default {@see Request} and {@see EntityEnclosingRequest} objects.

Protected Properties

Hide inherited properties

PropertyTypeDescriptionDefined By
$entityEnclosingRequestClass string Class to instantiate for requests with a body Guzzle\Http\Message\RequestFactory
$instance Guzzle\Http\Message\RequestFactory Singleton instance of the default request factory Guzzle\Http\Message\RequestFactory
$methods array Hash of methods available to the class (provides fast isset() lookups) Guzzle\Http\Message\RequestFactory
$requestClass string Class to instantiate for requests with no body Guzzle\Http\Message\RequestFactory

Public Methods

Hide inherited methods

MethodDescriptionDefined By
__construct() Guzzle\Http\Message\RequestFactory
applyOptions() Guzzle\Http\Message\RequestFactory
cloneRequestWithMethod() Clone a request while changing the method. Emulates the behavior of {@see Guzzle\Http\Message\Request::clone}, but can change the HTTP method. Guzzle\Http\Message\RequestFactory
create() Guzzle\Http\Message\RequestFactory
fromMessage() Guzzle\Http\Message\RequestFactory
fromParts() Guzzle\Http\Message\RequestFactory
getInstance() Get a cached instance of the default request factory Guzzle\Http\Message\RequestFactory

Property Details

$entityEnclosingRequestClass protected property

Class to instantiate for requests with a body

protected string $entityEnclosingRequestClass 'Guzzle\\Http\\Message\\EntityEnclosingRequest'
$instance protected static property

Singleton instance of the default request factory

$methods protected property

Hash of methods available to the class (provides fast isset() lookups)

protected array $methods null
$requestClass protected property

Class to instantiate for requests with no body

protected string $requestClass 'Guzzle\\Http\\Message\\Request'

Method Details

__construct() public method

public void __construct ( )
applyOptions() public method

public void applyOptions ( Guzzle\Http\Message\RequestInterface $request, array $options = [], $flags self::OPTIONS_NONE )
$request
$options
$flags
cloneRequestWithMethod() public method

Clone a request while changing the method. Emulates the behavior of {@see Guzzle\Http\Message\Request::clone}, but can change the HTTP method.

public Guzzle\Http\Message\RequestInterface cloneRequestWithMethod ( Guzzle\Http\Message\RequestInterface $request, $method )
$request Guzzle\Http\Message\RequestInterface

Request to clone

$method string

Method to set

create() public method

public void create ( $method, $url, $headers null, $body null, array $options = [] )
$method
$url
$headers
$body
$options
fromMessage() public method

public void fromMessage ( $message )
$message
fromParts() public method

public void fromParts ( $method, array $urlParts, $headers null, $body null, $protocol 'HTTP', $protocolVersion '1.1' )
$method
$urlParts
$headers
$body
$protocol
$protocolVersion
getInstance() public static method

Get a cached instance of the default request factory

public static Guzzle\Http\Message\RequestFactory getInstance ( )
visit_allow_redirects() protected method

protected void visit_allow_redirects ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_auth() protected method

protected void visit_auth ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_body() protected method

protected void visit_body ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_cert() protected method

protected void visit_cert ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_connect_timeout() protected method

protected void visit_connect_timeout ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_cookies() protected method

protected void visit_cookies ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_debug() protected method

protected void visit_debug ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_events() protected method

protected void visit_events ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_exceptions() protected method

protected void visit_exceptions ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_headers() protected method

protected void visit_headers ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_params() protected method

protected void visit_params ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_plugins() protected method

protected void visit_plugins ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_proxy() protected method

protected void visit_proxy ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_query() protected method

protected void visit_query ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_save_to() protected method

protected void visit_save_to ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_ssl_key() protected method

protected void visit_ssl_key ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_timeout() protected method

protected void visit_timeout ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags
visit_verify() protected method

protected void visit_verify ( Guzzle\Http\Message\RequestInterface $request, $value, $flags )
$request
$value
$flags