__construct() публичный Метод

Constructor. Adds config values to the public properties when a new object is created.
См. также: lithium\net\http\Message::__construct()
См. также: lithium\net\Message::__construct()
public __construct ( array $config = [] ) : void
$config array The available configuration options are the following. Further options are inherited from the parent classes. - `'message'` _string_: Defaults to `null`. - `'status'` _mixed_: Defaults to `null`. - `'type'` _string_: Defaults to `null`. - `'cookies'` _array_: Defaults to `array()`.
Результат void
Пример #1
0
 public function __construct(array $config = array())
 {
     $defaults = array('buffer' => 8192, 'location' => null, 'status' => 0, 'request' => null, 'decode' => false);
     parent::__construct($config + $defaults);
 }
Пример #2
0
 public function __construct($config = array())
 {
     $defaults = array('buffer' => 8192, 'request' => null);
     parent::__construct((array) $config + $defaults);
 }