public function __construct(array $data = [], array $constants = []) { $this->_data = $data ?: static::$_defaults; $userland = get_defined_constants(true); if (isset($userland['user'])) { $this->_addConstants($userland['user']); } $this->_addConstants($constants); }