43 lines
876 B
PHP
43 lines
876 B
PHP
<?php
|
|
|
|
// src/Utils/Configuration/ConfigurationInterface.php
|
|
|
|
namespace RprtCli\Utils\Configuration;
|
|
|
|
interface PonsapiConfigInterface
|
|
{
|
|
/**
|
|
* Checks for config file.
|
|
*
|
|
* @return string|bool
|
|
* Full path to config file or FALSE if it doesn't exist.
|
|
*/
|
|
// function findConfig($file);
|
|
|
|
/**
|
|
* Get and read the configuration from file.
|
|
*/
|
|
function getConfig();
|
|
|
|
/**
|
|
* Get a specific configuration for key.
|
|
*
|
|
* @param string $key
|
|
* Config key.
|
|
* @param mixed $default
|
|
* Default value if config for key is not yet specified.
|
|
*
|
|
* @return mixed
|
|
* Data.
|
|
*/
|
|
public function get($key, $default = null);
|
|
|
|
/**
|
|
* Checks if key exists in the configuration file.
|
|
*
|
|
* @param string $key
|
|
* Key to check for.
|
|
*/
|
|
public function exists($key);
|
|
}
|