3) Introducing ConfigFactory
This commit is contained in:
parent
5c50684b50
commit
4af0119b73
23 changed files with 843 additions and 632 deletions
34
src/Core/Config/IConfigCache.php
Normal file
34
src/Core/Config/IConfigCache.php
Normal file
|
@ -0,0 +1,34 @@
|
|||
<?php
|
||||
|
||||
namespace Friendica\Core\Config;
|
||||
|
||||
interface IConfigCache
|
||||
{
|
||||
/**
|
||||
* @param string $cat Config category
|
||||
* @param string $key Config key
|
||||
* @param mixed $default Default value if it isn't set
|
||||
*
|
||||
* @return mixed Returns the value of the Config entry
|
||||
*/
|
||||
function get($cat, $key = null, $default = null);
|
||||
|
||||
/**
|
||||
* Sets a value in the config cache. Accepts raw output from the config table
|
||||
*
|
||||
* @param string $cat Config category
|
||||
* @param string $key Config key
|
||||
* @param mixed $value Value to set
|
||||
*/
|
||||
function set($cat, $key, $value);
|
||||
|
||||
/**
|
||||
* Deletes a value from the config cache
|
||||
*
|
||||
* @param string $cat Config category
|
||||
* @param string $key Config key
|
||||
*/
|
||||
function delete($cat, $key);
|
||||
|
||||
function getAll();
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue