Curl
in package
Table of Contents
- $OnLoad : Closure|null
- Callback which is being called at the end of request. Expects the next signature: `OnLoad(?string $body, resource $ch) : void`
- __construct() : mixed
- Creates an object of asynchronous cUrl
- Execute() : void
- Runs request in the asynchronous task. At the finish calls `Curl->OnLoad(?string $body, resource $ch) : void`
- GetCurlHandle() : resource
- Returns a cUrl handler. Can be used for such functions as "curl_setopt()", etc.
- IsExecuting() : bool
Properties
$OnLoad
Callback which is being called at the end of request. Expects the next signature: `OnLoad(?string $body, resource $ch) : void`
public
Closure|null
$OnLoad
= null
string $body, resource $ch
Methods
__construct()
Creates an object of asynchronous cUrl
public
__construct([string|null $url = null ]) : mixed
Parameters
- $url : string|null = null
Return values
mixed —Execute()
Runs request in the asynchronous task. At the finish calls `Curl->OnLoad(?string $body, resource $ch) : void`
public
Execute() : void
Return values
void —GetCurlHandle()
Returns a cUrl handler. Can be used for such functions as "curl_setopt()", etc.
public
GetCurlHandle() : resource
Return values
resource —IsExecuting()
public
IsExecuting() : bool
Return values
bool —Is request executing right now