public function __construct($host = 'localhost', $port = 9200, $timeout = null) { parent::__construct($host, $port); if (null !== $timeout) { $this->setTimeout($timeout); } $this->ch = curl_init(); }