Class rex_config

Class for handling configurations. The configuration is persisted between requests.

Package: redaxo\core
Author: staabm
Located at redaxo/src/core/lib/config.php

Methods summary

public static boolean
# set( string $namespace, string|array $key, mixed $value = null )

Method which saves an arbitary value associated to the given namespace and key. If the second parameter is an associative array, all key/value pairs will be saved.

public static mixed
# get( string $namespace, string $key = null, mixed $default = null )

Method which returns an associated value for the given namespace and key. If $key is null, an array of all key/value pairs for the given namespace will be returned.

public static boolean
# has( string $namespace, string $key = null )

Returns if the given key is set.

public static boolean
# remove( string $namespace, string $key )

Removes the setting associated with the given namespace and key.

public static boolean
# removeNamespace( string $namespace )

Removes all settings associated with the given namespace.

public static
# refresh( )

Refreshes rex_config by reloading config from db.

protected static
# init( )

initilizes the rex_config class.

protected static
# load( )

load the config-data.

public static
# save( )

persists the config-data and truncates the file-cache.