MediaWiki REL1_28
HashConfig Class Reference

A Config instance which stores all settings as a member variable. More...

Inheritance diagram for HashConfig:
Collaboration diagram for HashConfig:

Public Member Functions

 __construct (array $settings=[])
 
 get ( $name)
 
 has ( $name)
 
 set ( $name, $value)
 

Static Public Member Functions

static newInstance ()
 

Private Attributes

array $settings
 Array of config settings.
 

Detailed Description

A Config instance which stores all settings as a member variable.

Since
1.24
Examples
/src/tests/phpunit/MediaWikiTestCase.php.

Definition at line 28 of file HashConfig.php.

Constructor & Destructor Documentation

◆ __construct()

HashConfig::__construct ( array  $settings = [])
Parameters
array$settingsAny current settings to pre-load

Definition at line 47 of file HashConfig.php.

References $settings, and settings.

Member Function Documentation

◆ get()

HashConfig::get (   $name)
See also
Config::get

Implements Config.

Definition at line 54 of file HashConfig.php.

References $name, has(), and settings.

◆ has()

HashConfig::has (   $name)
See also
Config::has

Implements Config.

Definition at line 65 of file HashConfig.php.

References $name, and settings.

Referenced by get().

◆ newInstance()

static HashConfig::newInstance ( )
static
Returns
HashConfig

Definition at line 40 of file HashConfig.php.

Referenced by HashConfigTest\testNewInstance().

◆ set()

HashConfig::set (   $name,
  $value 
)
See also
Config::set

Implements MutableConfig.

Definition at line 72 of file HashConfig.php.

References $name, $value, and settings.

Member Data Documentation

◆ $settings

array HashConfig::$settings
private

Array of config settings.

Definition at line 35 of file HashConfig.php.

Referenced by __construct().


The documentation for this class was generated from the following file: