aboutsummaryrefslogtreecommitdiffhomepage
path: root/application/config
diff options
context:
space:
mode:
authorVirtualTam <virtualtam@flibidi.net>2017-01-05 19:33:06 +0100
committerVirtualTam <virtualtam+github@flibidi.net>2017-01-05 19:52:04 +0100
commit93b1fe54fb99efff30eec0d405cc7319fbbc1f95 (patch)
tree21d2aa9b09c1944e19a4f8fe4741277a3213cc5b /application/config
parent724f1e322943b0506a4a4f17e78eaf4b2e464553 (diff)
downloadShaarli-93b1fe54fb99efff30eec0d405cc7319fbbc1f95.tar.gz
Shaarli-93b1fe54fb99efff30eec0d405cc7319fbbc1f95.tar.zst
Shaarli-93b1fe54fb99efff30eec0d405cc7319fbbc1f95.zip
Cleanup: explicit method visibility
Signed-off-by: VirtualTam <virtualtam@flibidi.net>
Diffstat (limited to 'application/config')
-rw-r--r--application/config/ConfigIO.php6
-rw-r--r--application/config/ConfigJson.php6
-rw-r--r--application/config/ConfigPhp.php6
3 files changed, 9 insertions, 9 deletions
diff --git a/application/config/ConfigIO.php b/application/config/ConfigIO.php
index 2b68fe6a..be78b1c7 100644
--- a/application/config/ConfigIO.php
+++ b/application/config/ConfigIO.php
@@ -14,7 +14,7 @@ interface ConfigIO
14 * 14 *
15 * @return array All configuration in an array. 15 * @return array All configuration in an array.
16 */ 16 */
17 function read($filepath); 17 public function read($filepath);
18 18
19 /** 19 /**
20 * Write configuration. 20 * Write configuration.
@@ -22,12 +22,12 @@ interface ConfigIO
22 * @param string $filepath Config file absolute path. 22 * @param string $filepath Config file absolute path.
23 * @param array $conf All configuration in an array. 23 * @param array $conf All configuration in an array.
24 */ 24 */
25 function write($filepath, $conf); 25 public function write($filepath, $conf);
26 26
27 /** 27 /**
28 * Get config file extension according to config type. 28 * Get config file extension according to config type.
29 * 29 *
30 * @return string Config file extension. 30 * @return string Config file extension.
31 */ 31 */
32 function getExtension(); 32 public function getExtension();
33} 33}
diff --git a/application/config/ConfigJson.php b/application/config/ConfigJson.php
index 30007eb4..6b5d73f1 100644
--- a/application/config/ConfigJson.php
+++ b/application/config/ConfigJson.php
@@ -10,7 +10,7 @@ class ConfigJson implements ConfigIO
10 /** 10 /**
11 * @inheritdoc 11 * @inheritdoc
12 */ 12 */
13 function read($filepath) 13 public function read($filepath)
14 { 14 {
15 if (! is_readable($filepath)) { 15 if (! is_readable($filepath)) {
16 return array(); 16 return array();
@@ -29,7 +29,7 @@ class ConfigJson implements ConfigIO
29 /** 29 /**
30 * @inheritdoc 30 * @inheritdoc
31 */ 31 */
32 function write($filepath, $conf) 32 public function write($filepath, $conf)
33 { 33 {
34 // JSON_PRETTY_PRINT is available from PHP 5.4. 34 // JSON_PRETTY_PRINT is available from PHP 5.4.
35 $print = defined('JSON_PRETTY_PRINT') ? JSON_PRETTY_PRINT : 0; 35 $print = defined('JSON_PRETTY_PRINT') ? JSON_PRETTY_PRINT : 0;
@@ -46,7 +46,7 @@ class ConfigJson implements ConfigIO
46 /** 46 /**
47 * @inheritdoc 47 * @inheritdoc
48 */ 48 */
49 function getExtension() 49 public function getExtension()
50 { 50 {
51 return '.json.php'; 51 return '.json.php';
52 } 52 }
diff --git a/application/config/ConfigPhp.php b/application/config/ConfigPhp.php
index 27187b66..9dd9a65d 100644
--- a/application/config/ConfigPhp.php
+++ b/application/config/ConfigPhp.php
@@ -71,7 +71,7 @@ class ConfigPhp implements ConfigIO
71 /** 71 /**
72 * @inheritdoc 72 * @inheritdoc
73 */ 73 */
74 function read($filepath) 74 public function read($filepath)
75 { 75 {
76 if (! file_exists($filepath) || ! is_readable($filepath)) { 76 if (! file_exists($filepath) || ! is_readable($filepath)) {
77 return array(); 77 return array();
@@ -91,7 +91,7 @@ class ConfigPhp implements ConfigIO
91 /** 91 /**
92 * @inheritdoc 92 * @inheritdoc
93 */ 93 */
94 function write($filepath, $conf) 94 public function write($filepath, $conf)
95 { 95 {
96 $configStr = '<?php '. PHP_EOL; 96 $configStr = '<?php '. PHP_EOL;
97 foreach (self::$ROOT_KEYS as $key) { 97 foreach (self::$ROOT_KEYS as $key) {
@@ -125,7 +125,7 @@ class ConfigPhp implements ConfigIO
125 /** 125 /**
126 * @inheritdoc 126 * @inheritdoc
127 */ 127 */
128 function getExtension() 128 public function getExtension()
129 { 129 {
130 return '.php'; 130 return '.php';
131 } 131 }