|
| __construct (Registry $options=null, TransportInterface $transport=null) |
|
| getOption ($key) |
|
| setOption ($key, $value) |
|
| options ($url, array $headers=null, $timeout=null) |
|
| head ($url, array $headers=null, $timeout=null) |
|
| get ($url, array $headers=null, $timeout=null) |
|
| post ($url, $data, array $headers=null, $timeout=null) |
|
| put ($url, $data, array $headers=null, $timeout=null) |
|
| delete ($url, array $headers=null, $timeout=null) |
|
| trace ($url, array $headers=null, $timeout=null) |
|
| patch ($url, $data, array $headers=null, $timeout=null) |
|
HTTP client class.
- Depuis
- 1.7.3
◆ __construct()
◆ delete()
delete |
( |
|
$url, |
|
|
array |
$headers = null , |
|
|
|
$timeout = null |
|
) |
| |
Method to send the DELETE command to the server.
- Paramètres
-
string | $url | Path to the resource. |
array | $headers | An array of name-value pairs to include in the header of the request. |
integer | $timeout | Read timeout in seconds. |
- Renvoie
- Response
- Depuis
- 1.7.3
Références $key, $url, et null.
◆ get()
get |
( |
|
$url, |
|
|
array |
$headers = null , |
|
|
|
$timeout = null |
|
) |
| |
Method to send the GET command to the server.
- Paramètres
-
string | $url | Path to the resource. |
array | $headers | An array of name-value pairs to include in the header of the request. |
integer | $timeout | Read timeout in seconds. |
- Renvoie
- Response
- Depuis
- 1.7.3
Références $key, $url, et null.
◆ getOption()
Get an option from the HTTP client.
- Paramètres
-
string | $key | The name of the option to get. |
- Renvoie
- mixed The option value.
- Depuis
- 1.7.3
Références $key.
◆ head()
head |
( |
|
$url, |
|
|
array |
$headers = null , |
|
|
|
$timeout = null |
|
) |
| |
Method to send the HEAD command to the server.
- Paramètres
-
string | $url | Path to the resource. |
array | $headers | An array of name-value pairs to include in the header of the request. |
integer | $timeout | Read timeout in seconds. |
- Renvoie
- Response
- Depuis
- 1.7.3
Références $key, $url, et null.
◆ options()
options |
( |
|
$url, |
|
|
array |
$headers = null , |
|
|
|
$timeout = null |
|
) |
| |
Method to send the OPTIONS command to the server.
- Paramètres
-
string | $url | Path to the resource. |
array | $headers | An array of name-value pairs to include in the header of the request. |
integer | $timeout | Read timeout in seconds. |
- Renvoie
- Response
- Depuis
- 1.7.3
Références $key, $url, et null.
◆ patch()
patch |
( |
|
$url, |
|
|
|
$data, |
|
|
array |
$headers = null , |
|
|
|
$timeout = null |
|
) |
| |
Method to send the PATCH command to the server.
- Paramètres
-
string | $url | Path to the resource. |
mixed | $data | Either an associative array or a string to be sent with the request. |
array | $headers | An array of name-value pairs to include in the header of the request. |
integer | $timeout | Read timeout in seconds. |
- Renvoie
- Response
- Depuis
- 3.0.1
Références $data, $key, $url, et null.
◆ post()
post |
( |
|
$url, |
|
|
|
$data, |
|
|
array |
$headers = null , |
|
|
|
$timeout = null |
|
) |
| |
Method to send the POST command to the server.
- Paramètres
-
string | $url | Path to the resource. |
mixed | $data | Either an associative array or a string to be sent with the request. |
array | $headers | An array of name-value pairs to include in the header of the request |
integer | $timeout | Read timeout in seconds. |
- Renvoie
- Response
- Depuis
- 1.7.3
Références $data, $key, $url, et null.
◆ put()
put |
( |
|
$url, |
|
|
|
$data, |
|
|
array |
$headers = null , |
|
|
|
$timeout = null |
|
) |
| |
Method to send the PUT command to the server.
- Paramètres
-
string | $url | Path to the resource. |
mixed | $data | Either an associative array or a string to be sent with the request. |
array | $headers | An array of name-value pairs to include in the header of the request. |
integer | $timeout | Read timeout in seconds. |
- Renvoie
- Response
- Depuis
- 1.7.3
Références $data, $key, $url, et null.
◆ setOption()
setOption |
( |
|
$key, |
|
|
|
$value |
|
) |
| |
Set an option for the HTTP client.
- Paramètres
-
string | $key | The name of the option to set. |
mixed | $value | The option value to set. |
- Renvoie
- Http This object for method chaining.
- Depuis
- 1.7.3
Références $key, et $value.
◆ trace()
trace |
( |
|
$url, |
|
|
array |
$headers = null , |
|
|
|
$timeout = null |
|
) |
| |
Method to send the TRACE command to the server.
- Paramètres
-
string | $url | Path to the resource. |
array | $headers | An array of name-value pairs to include in the header of the request. |
integer | $timeout | Read timeout in seconds. |
- Renvoie
- Response
- Depuis
- 1.7.3
Références $key, $url, et null.
◆ $options
◆ $transport
La documentation de cette classe a été générée à partir du fichier suivant :