public function __construct() { $this->curl = new Curl(); $this->curl->onComplete([$this, 'onComplete']); $this->curl->onSuccess([$this, 'onSuccess']); $this->curl->onError([$this, 'onError']); $this->curl->onBeforeSend([$this, 'onBeforeSend']); }