interface ClientInterface
Same name in this branch
- 11.1.x vendor/psr/http-client/src/ClientInterface.php \Psr\Http\Client\ClientInterface
Client interface for sending HTTP requests.
Hierarchy
- interface \GuzzleHttp\ClientInterface
Expanded class hierarchy of ClientInterface
All classes that implement ClientInterface
10 files declare their use of ClientInterface
- AnnounceFetcher.php in core/
modules/ announcements_feed/ src/ AnnounceFetcher.php - Client.php in vendor/
php-http/ guzzle7-adapter/ src/ Client.php - CredentialForm.php in core/
modules/ migrate_drupal_ui/ src/ Form/ CredentialForm.php - Download.php in core/
modules/ migrate/ src/ Plugin/ migrate/ process/ Download.php - OEmbed.php in core/
modules/ media/ src/ Plugin/ media/ Source/ OEmbed.php
File
-
vendor/
guzzlehttp/ guzzle/ src/ ClientInterface.php, line 14
Namespace
GuzzleHttpView source
interface ClientInterface {
/**
* The Guzzle major version.
*/
public const MAJOR_VERSION = 7;
/**
* Send an HTTP request.
*
* @param RequestInterface $request Request to send
* @param array $options Request options to apply to the given
* request and to the transfer.
*
* @throws GuzzleException
*/
public function send(RequestInterface $request, array $options = []) : ResponseInterface;
/**
* Asynchronously send an HTTP request.
*
* @param RequestInterface $request Request to send
* @param array $options Request options to apply to the given
* request and to the transfer.
*/
public function sendAsync(RequestInterface $request, array $options = []) : PromiseInterface;
/**
* Create and send an HTTP request.
*
* Use an absolute path to override the base path of the client, or a
* relative path to append to the base path of the client. The URL can
* contain the query string as well.
*
* @param string $method HTTP method.
* @param string|UriInterface $uri URI object or string.
* @param array $options Request options to apply.
*
* @throws GuzzleException
*/
public function request(string $method, $uri, array $options = []) : ResponseInterface;
/**
* Create and send an asynchronous HTTP request.
*
* Use an absolute path to override the base path of the client, or a
* relative path to append to the base path of the client. The URL can
* contain the query string as well. Use an array to provide a URL
* template and additional variables to use in the URL template expansion.
*
* @param string $method HTTP method
* @param string|UriInterface $uri URI object or string.
* @param array $options Request options to apply.
*/
public function requestAsync(string $method, $uri, array $options = []) : PromiseInterface;
/**
* Get a client configuration option.
*
* These options include default request options of the client, a "handler"
* (if utilized by the concrete client), and a "base_uri" if utilized by
* the concrete client.
*
* @param string|null $option The config option to retrieve.
*
* @return mixed
*
* @deprecated ClientInterface::getConfig will be removed in guzzlehttp/guzzle:8.0.
*/
public function getConfig(?string $option = null);
}
Members
Title Sort descending | Deprecated | Modifiers | Object type | Summary | Overrides |
---|---|---|---|---|---|
ClientInterface::getConfig | Deprecated | public | function | Get a client configuration option. | 1 |
ClientInterface::MAJOR_VERSION | public | constant | The Guzzle major version. | ||
ClientInterface::request | public | function | Create and send an HTTP request. | ||
ClientInterface::requestAsync | public | function | Create and send an asynchronous HTTP request. | ||
ClientInterface::send | public | function | Send an HTTP request. | 1 | |
ClientInterface::sendAsync | public | function | Asynchronously send an HTTP request. | 1 |