class VMware_VCloud_SDK_Http_Client implements VMware_VCloud_SDK_Http_Client_Interface
|
__construct()
Constructor, creates a new HTTP_Request2 instance. |
||
| null |
setAuth(array $auth)
Set the login user name and password. |
|
|
setConfig(array $config)
Set the HTTP configurations |
||
|
setAPIVersion(array $apiVersion)
Set the API Version |
||
| String |
getVcloudToken()
Gets the vcloud token |
|
|
setVcloudToken(string $vcloudToken)
Sets the vcloud token |
||
| VMware_VCloud_SDK_Http_Response_Interface |
get(string $url, array $headers = null)
Send an HTTP GET request. |
|
| VMware_VCloud_SDK_Http_Response_Interface |
post(string $url, array $headers = null, mixed $data = null)
Send an HTTP POST request. |
|
| VMware_VCloud_SDK_Http_Response_Interface |
put(string $url, array $headers = null, mixed $data = null)
Send an HTTP PUT request. |
|
| VMware_VCloud_SDK_Http_Response_Interface|null |
delete(string $url)
Send an HTTP DELETE request. |
|
| null |
download(string $url, array $headers, string $dest)
Download a file and dump to specified location. |
|
| null |
upload(string $url, array $headers, string $file, int $windowSize = 10485760, function $onProgress = false)
Upload a file. |
|
|
putAndCheck($url, $headers, $data, $attemptNumber, $sendAttempts = 5)
|
||
| string |
getUsername()
|
|
| Returns |
getToken()
|
public
__construct()
Constructor, creates a new HTTP_Request2 instance.
public null
setAuth(array $auth)
Set the login user name and password.
public
setConfig(array $config)
Set the HTTP configurations
public
setAPIVersion(array $apiVersion)
Set the API Version
public String
getVcloudToken()
Gets the vcloud token
public
setVcloudToken(string $vcloudToken)
Sets the vcloud token
public VMware_VCloud_SDK_Http_Response_Interface
get(string $url, array $headers = null)
Send an HTTP GET request.
public VMware_VCloud_SDK_Http_Response_Interface
post(string $url, array $headers = null, mixed $data = null)
Send an HTTP POST request.
public VMware_VCloud_SDK_Http_Response_Interface
put(string $url, array $headers = null, mixed $data = null)
Send an HTTP PUT request.
public VMware_VCloud_SDK_Http_Response_Interface|null
delete(string $url)
Send an HTTP DELETE request.
public null
download(string $url, array $headers, string $dest)
Download a file and dump to specified location.
public null
upload(string $url, array $headers, string $file, int $windowSize = 10485760, function $onProgress = false)
Upload a file.
public
putAndCheck($url, $headers, $data, $attemptNumber, $sendAttempts = 5)
public string
getUsername()
public Returns
getToken()