__construct() public method

public __construct ( )
コード例 #1
1
ファイル: Curl.php プロジェクト: Zaszczyk/incubator
 public function __construct()
 {
     if (!self::isAvailable()) {
         throw new ProviderException('CURL extension is not loaded');
     }
     $this->handle = curl_init();
     $this->initOptions();
     parent::__construct();
 }
コード例 #2
1
ファイル: Stream.php プロジェクト: sneakybobito/incubator
 function __construct()
 {
     if (!self::isAvailable()) {
         throw new ProviderException('HTTP or HTTPS stream wrappers not registered');
     }
     $this->context = stream_context_create();
     $this->initOptions();
     parent::__construct();
 }
コード例 #3
1
ファイル: Curl.php プロジェクト: Ak-Army/incubator
 public function __construct()
 {
     if (!self::isAvailable()) {
         throw new ProviderException('CURL extension is not loaded');
     }
     $this->handle = curl_init();
     if ($this->handle === false) {
         throw new HttpException(curl_error($this->handle), 'curl');
     }
     $this->initOptions();
     parent::__construct();
 }