/** * Constructor * * @param ConfigScope effective configuration scope * @param ConfigDAO parent object * @param string absolute key * @param array reference to data */ protected function __construct(ConfigScope $scope, $parent, $key, &$dataPtr) { $this->data =& $dataPtr; $this->scope = $scope; $this->fallbackScope = $scope->getFallbackScope(); $this->parent = $parent; $this->key = $key; }
/** * Constructor * * @param DibiConnection database connection * @param string|null scope name, if null this scope won't perform any load * @param ConfigScope|null reference to fallback config scope or null if there isn't one */ function __construct(DibiConnection $dbConnection, $name, $fallback = null) { $this->db = $dbConnection; // Scope name if ($name !== null) { $this->setScopeName($name); } parent::__construct($fallback); }
public function __construct(array $filenames, $fallback = null) { foreach ($filenames as $filename) { $ext = \pathinfo($filename, PATHINFO_EXTENSION); if (\is_file($filename) and \is_readable($filename) and in_array($ext, array('neon', 'ini'))) { $this->filenames[] = $filename; } else { throw new Nette\InvalidArgumentException("Invalid file '{$filename}'."); } } parent::__construct($fallback); }