PHP Interface Autarky\Config\ConfigInterface

ファイルを表示 Open project: autarky/framework Interface Usage Examples

Public Methods

Method Description
get ( string $key, mixed $default = null ) : mixed Get an item from the store.
has ( string $key ) : boolean Determine if a key exists in the store.
mount ( string $location, string $path ) : void Mount a path to a specific location in the config tree.
set ( string $key, mixed $value ) : void Set an item in the store temporarily - more specifically, the lifetime of the store object.
setEnvironment ( string $environment ) Set the environment.

Method Details

get() public method

Get an item from the store.
public get ( string $key, mixed $default = null ) : mixed
$key string
$default mixed If the value is not found, return this instead.
return mixed

has() public method

Should return true even if the value is null.
public has ( string $key ) : boolean
$key string
return boolean

mount() public method

Mount a path to a specific location in the config tree.
public mount ( string $location, string $path ) : void
$location string
$path string
return void

set() public method

Set an item in the store temporarily - more specifically, the lifetime of the store object.
public set ( string $key, mixed $value ) : void
$key string
$value mixed
return void

setEnvironment() public method

Set the environment.
public setEnvironment ( string $environment )
$environment string