__construct() public method

Constructor.
public __construct ( array $config = [] ) : void
$config array Available configuration options are: - `'persistent'`: Use a persistent connection (defaults to `false`). - `'protocol'`: Transfer protocol to use (defaults to `'tcp'`). - `'host'`: Host name or address (defaults to `'localhost'`). - `'login'`: Username for a login (defaults to `'root'`). - `'password'`: Password for a login (defaults to `''`). - `'port'`: Host port (defaults to `80`). - `'timeout'`: Seconds after opening the socket times out (defaults to `30`).
return void
コード例 #1
0
ファイル: Context.php プロジェクト: fedeisas/lithium
 /**
  * Constructor.
  *
  * @param array $config Available configuration options are:
  *        - `'mode'` _string_
  *        - `'message'` _object_
  * @return void
  */
 public function __construct(array $config = array())
 {
     $defaults = array('mode' => 'r', 'message' => null);
     parent::__construct($config + $defaults);
     $this->timeout($this->_config['timeout']);
 }
コード例 #2
0
ファイル: MockSocket.php プロジェクト: fedeisas/lithium
 public function __construct(array $config = array())
 {
     parent::__construct((array) $config);
 }
コード例 #3
0
ファイル: MockSocket.php プロジェクト: EHER/chegamos
 public function __construct(array $config = array())
 {
     $this->configs[] = $config;
     parent::__construct((array) $config);
 }
コード例 #4
0
ファイル: Curl.php プロジェクト: rapzo/lithium
 /**
  * Constructor
  *
  * @param array $config
  */
 public function __construct(array $config = array())
 {
     $defaults = array('ignoreExpect' => true);
     parent::__construct($config + $defaults);
 }
コード例 #5
0
ファイル: Push.php プロジェクト: keyteqlabs/li3_mixpanel
 /**
  * Constructor
  *
  * @param array $config
  */
 public function __construct(array $config = array())
 {
     $defaults = array('scheme' => 'http');
     parent::__construct($config + $defaults);
     $this->timeout($this->_config['timeout']);
 }