\CodeIgniter\ConfigConfig

Class Config

Summary

Methods
Properties
Constants
get()
injectMock()
reset()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
createClass()
$instances
N/A

Properties

$instances

$instances : array

Cache for instance of any configurations that have been requested as "shared" instance.

Type

array

Methods

get()

get(string  $name, boolean  $getShared = true) : mixed|null

Create new configuration instances or return a shared instance

Parameters

string $name

Configuration name

boolean $getShared

Use shared instance

Returns

mixed|null

injectMock()

injectMock(string  $class,   $instance) 

Helper method for injecting mock instances while testing.

Parameters

string $class
$instance

reset()

reset() 

Resets the instances array

createClass()

createClass(string  $name) : mixed|null

Find configuration class and create instance

Parameters

string $name

Classname

Returns

mixed|null