コード例 #1
0
ファイル: PeclHttp.php プロジェクト: lhess/solarium
 /**
  * Initialization hook
  *
  * Checks the availability of pecl_http
  *
  * @throws RuntimeException
  */
 protected function init()
 {
     // @codeCoverageIgnoreStart
     if (!class_exists('HttpRequest', false)) {
         throw new RuntimeException('Pecl_http is not available, install it to use the PeclHttp adapter');
     }
     parent::init();
     // @codeCoverageIgnoreEnd
 }
コード例 #2
0
ファイル: Curl.php プロジェクト: lhess/solarium
 /**
  * Initialization hook
  *
  * Checks the availability of Curl_http
  *
  * @throws RuntimeException
  */
 protected function init()
 {
     // @codeCoverageIgnoreStart
     if (!function_exists('curl_init')) {
         throw new RuntimeException('cURL is not available, install it to use the CurlHttp adapter');
     }
     parent::init();
     // @codeCoverageIgnoreEnd
 }