1 | <?php |
||
5 | class Xhgui_Config |
||
6 | { |
||
7 | private static $_config = array(); |
||
8 | |||
9 | /** |
||
10 | * Load a config file, it will replace |
||
11 | * all the currently loaded configuration. |
||
12 | * |
||
13 | * @param string $file |
||
14 | * @return void |
||
15 | */ |
||
16 | public static function load($file) |
||
21 | |||
22 | /** |
||
23 | * Read a config value. |
||
24 | * |
||
25 | * @param string $name The name of the config variable |
||
26 | * @return The value or null. |
||
27 | */ |
||
28 | public static function read($name) |
||
35 | |||
36 | /** |
||
37 | * Get all the configuration options. |
||
38 | * |
||
39 | * @return array |
||
40 | */ |
||
41 | public static function all() |
||
45 | |||
46 | /** |
||
47 | * Write a config value. |
||
48 | * |
||
49 | * @param string $name The name of the config variable |
||
50 | * @param mixed $value The value of the config variable |
||
51 | * @return void |
||
52 | */ |
||
53 | public static function write($name, $value) |
||
57 | |||
58 | /** |
||
59 | * Clear out the data stored in the config class. |
||
60 | * |
||
61 | * @return void |
||
62 | */ |
||
63 | public static function clear() |
||
67 | |||
68 | /** |
||
69 | * Called during profiler initialization |
||
70 | * |
||
71 | * Allows arbitrary conditions to be added configuring how |
||
72 | * Xhgui profiles runs. |
||
73 | * |
||
74 | * @return boolean |
||
75 | */ |
||
76 | public static function shouldRun() |
||
84 | |||
85 | } |
||
86 |