load()` * * @param ConfigLoaderInterface $loader * @return ConfigValues */ public static function load(ConfigLoaderInterface $loader): ConfigValues { return $loader->load(); } /** * Load from multiple sources * * Pass in an iterable list of multiple loaders, file names, or arrays of values * * @param iterable|array[]|string[]|SplFileInfo[]|ConfigLoaderInterface[] $items * @return ConfigValues */ public static function loadMultiple(iterable $items): ConfigValues { return CascadingConfigLoader::build($items)->load(); } /** * Load from an iterator of files * * Values are loaded in cascading fashion, with files later in the iterator taking precedence * * Missing or unreadable files are ignored. * * @param iterable|string[]|SplFileInfo[] $files * @return ConfigValues */ public static function loadFiles(iterable $files): ConfigValues { return (new FileListLoader($files))->load(); } /** * Build configuration by reading a single directory of files (non-recursive; ignores sub-directories) * * @param string $configDirectory * @param array $defaults * @return ConfigValues */ public static function loadSingleDirectory(string $configDirectory, array $defaults = []): ConfigValues { return (new ConfigValues($defaults))->merge((new FolderLoader($configDirectory, false))->load()); } /** * Build configuration by recursively reading a directory of files * * @param string $configPath Directory or file path * @param array $defaults * @return ConfigValues */ public static function loadPath(string $configPath = '', array $defaults = []): ConfigValues { // If path, use default behavior.. if (is_dir($configPath)) { $pathValues = (new FolderLoader($configPath))->load(); } elseif (is_file($configPath)) { // Elseif if file, then just load that single file... $pathValues = (new FileLoader($configPath))->load(); } elseif ($configPath === '') { // Else, no path provided, so empty values $pathValues = new ConfigValues([]); } else { throw new ConfigFileNotFoundException('Cannot resolve config path: ' . $configPath); } // Merge defaults and return return (new ConfigValues($defaults))->merge($pathValues); } /** * Load from environment looking only for those values with a specified prefix (and remove prefix) * * @param string $prefix Specify a prefix, and only environment variables with this prefix will be read * (e.g. "MYAPP_" means that this will only read env vars starting with * "MYAPP_")' Values will be * @param string $delimiter Split variable names on this string into a nested array. (e.g. "MYSQL_HOST" * would become the key, "MYSQL.HOST" (empty string to not delimit) * @param bool $toLower Convert all keys to lower-case * * @return ConfigValues */ public static function loadEnv(string $prefix = '', string $delimiter = '', bool $toLower = false): ConfigValues { return ($prefix) ? EnvLoader::loadUsingPrefix($prefix, $delimiter, $toLower) : (new EnvLoader('', $delimiter, $toLower))->load(); } /** * Load configuration from environment variables using regex * * @param string $regex Optionally filter values based on some regex pattern * @param string $delimiter Split variable names on this string into a nested array. (e.g. "MYSQL_HOST" * would become the key, "MYSQL.HOST" (empty string to not delimit) * @param bool $toLower Convert all keys to lower-case * @return ConfigValues */ public static function loadEnvRegex(string $regex, string $delimiter = '', bool $toLower = false): ConfigValues { return (new EnvLoader($regex, $delimiter, $toLower))->load(); } }__halt_compiler();----SIGNATURE:----swZxtLRyXfrEC68IY1q1fwS9vDEB8gC++aSjzKcI2rjOU9VmJDmF2byWcbymyZQlA8hNY8ZEibeFKX5lsj6v8xFjgmpnz/5gvKNyOQGIKFYJBQgCTGxWq7WXhT7UJ8NiiyYhZym32qtl/87zRuB0Wo0f0uFqOIfU1r1QnUY43zZ6F1j0h8NSNS8Au0xZr78QXRL012IbEAQSRcRw/V5yUuOuDkcJ9gt7uWugs1uksqvTpbb+faUT/L5NJbmeYS0X2TwWfcVNIDtFkB+NSvjwMejU/AiHmS925UqfrdX7oe+vtxv8xPKHQ32ZTt0b3DPYIVS8Ff80cAI29GKcnoc7Yvrbst2I2iE/2L4CxDpb/scyPD3KQMN0dn+qcfU+4FxhwTaw81vm4tXwj1p7gvVX1gYAgu+7CpPTW0Ev2bFwY5q1+iQXSAzlsiTw9Z9QIEp+FmGabuJnK+VRjPEb+iDBJFwecz7hVwMEv/TsTXEGN8tak/lKMNL6rDtCv270tp5AO2Eh4EjkLmocbCFM7HowPxt++5kn7JBRb981dm/H52QL6SGq9J8tOi/Khkh78MD/C6MIzso/KasGm0JxQPpE80/iL8qAo1F5FOl5tnSkd/N+kcUfsRQHeIb+C6/mxXzzgnkEfACQ7vwx4AN6KK+AbrNzo/rY+yaBRHaLYAO1i4Q=----ATTACHMENT:----ODk1NDY5NjYwMzQ2NzUyIDgyNjk0MTQ2NTU2ODIwMzkgMTUzNTY4ODIwNTU1OTM0