lithium\console\Command::__construct PHP Method

__construct() public method

Constructor.
public __construct ( array $config = [] ) : void
$config array Available configuration options are: - `'request'` _object|null_ - `'response'` _array_ - `'classes'` _array_
return void
    public function __construct(array $config = array())
    {
        $defaults = array('request' => null, 'response' => array(), 'classes' => $this->_classes);
        parent::__construct($config + $defaults);
    }

Usage Example

示例#1
0
 /**
  * Constructor. Load the routes file and set the environment.
  *
  * @param array $config The default configuration, wherein the absolute path to the
  *        routes file to load may be specified, using the `'routes'` key.
  */
 public function __construct($config = array())
 {
     $defaults = array('routes' => Libraries::get(true, 'path') . '/config/routes.php');
     parent::__construct($config + $defaults);
 }
All Usage Examples Of lithium\console\Command::__construct