]>
Commit | Line | Data |
---|---|---|
59404d79 A |
1 | <?php |
2 | ||
3 | /** | |
4 | * Interface ConfigIO | |
5 | * | |
6 | * This describes how Config types should store their configuration. | |
7 | */ | |
8 | interface ConfigIO | |
9 | { | |
10 | /** | |
11 | * Read configuration. | |
12 | * | |
13 | * @param string $filepath Config file absolute path. | |
14 | * | |
15 | * @return array All configuration in an array. | |
16 | */ | |
93b1fe54 | 17 | public function read($filepath); |
59404d79 A |
18 | |
19 | /** | |
20 | * Write configuration. | |
21 | * | |
22 | * @param string $filepath Config file absolute path. | |
23 | * @param array $conf All configuration in an array. | |
24 | */ | |
93b1fe54 | 25 | public function write($filepath, $conf); |
59404d79 A |
26 | |
27 | /** | |
28 | * Get config file extension according to config type. | |
29 | * | |
30 | * @return string Config file extension. | |
31 | */ | |
93b1fe54 | 32 | public function getExtension(); |
59404d79 | 33 | } |