@@ -31,9 +31,9 @@ |
||
31 | 31 | |
32 | 32 | public function __construct( |
33 | 33 | $server = '127.0.0.1', |
34 | - $port=6379, |
|
35 | - $timeout=0, |
|
36 | - LoggerInterface $logger=null |
|
34 | + $port = 6379, |
|
35 | + $timeout = 0, |
|
36 | + LoggerInterface $logger = null |
|
37 | 37 | ) { |
38 | 38 | |
39 | 39 | if ( empty($server) ) { |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | /** |
61 | 61 | * Set provider in error state |
62 | 62 | * |
63 | - * @param bool $status |
|
63 | + * @param bool $state |
|
64 | 64 | * Current status |
65 | 65 | * |
66 | 66 | * @param string $message |
@@ -85,6 +85,9 @@ discard block |
||
85 | 85 | |
86 | 86 | public function getNamespace(); |
87 | 87 | |
88 | + /** |
|
89 | + * @return \Comodojo\Cache\Traits\NamespaceTrait |
|
90 | + */ |
|
88 | 91 | public function setNamespace($namespace); |
89 | 92 | |
90 | 93 | public function clearNamespace(); |
@@ -36,7 +36,7 @@ |
||
36 | 36 | throw new InvalidSimpleCacheArgumentException("Invalid or unspecified cache folder"); |
37 | 37 | } |
38 | 38 | |
39 | - if ( $cache_folder[strlen($cache_folder)-1] != "/" ) $cache_folder = "$cache_folder/"; |
|
39 | + if ( $cache_folder[strlen($cache_folder) - 1] != "/" ) $cache_folder = "$cache_folder/"; |
|
40 | 40 | |
41 | 41 | if ( self::isXattrSupported($cache_folder) ) { |
42 | 42 | $this->driver = new FilesystemXattrDriver(['cache-folder'=>$cache_folder]); |
@@ -30,10 +30,10 @@ discard block |
||
30 | 30 | |
31 | 31 | public function __construct( |
32 | 32 | $server = '127.0.0.1', |
33 | - $port=11211, |
|
34 | - $weight=0, |
|
35 | - $persistent_id=null, |
|
36 | - LoggerInterface $logger=null |
|
33 | + $port = 11211, |
|
34 | + $weight = 0, |
|
35 | + $persistent_id = null, |
|
36 | + LoggerInterface $logger = null |
|
37 | 37 | ) { |
38 | 38 | |
39 | 39 | if ( empty($server) ) { |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | |
77 | 77 | $objects = 0; |
78 | 78 | |
79 | - foreach ($info as $key => $value) { |
|
79 | + foreach ( $info as $key => $value ) { |
|
80 | 80 | |
81 | 81 | $objects = max($objects, $value['curr_items']); |
82 | 82 |
@@ -58,7 +58,7 @@ |
||
58 | 58 | */ |
59 | 59 | public function setLogger(LoggerInterface $logger = null) { |
60 | 60 | |
61 | - $this->logger = is_null($logger) ? LogManager::create('cache',false)->getLogger() : $logger; |
|
61 | + $this->logger = is_null($logger) ? LogManager::create('cache', false)->getLogger() : $logger; |
|
62 | 62 | |
63 | 63 | return $this; |
64 | 64 |
@@ -31,9 +31,9 @@ |
||
31 | 31 | |
32 | 32 | public function __construct( |
33 | 33 | $server = '127.0.0.1', |
34 | - $port=6379, |
|
35 | - $timeout=0, |
|
36 | - LoggerInterface $logger=null |
|
34 | + $port = 6379, |
|
35 | + $timeout = 0, |
|
36 | + LoggerInterface $logger = null |
|
37 | 37 | ) { |
38 | 38 | |
39 | 39 | if ( empty($server) ) { |
@@ -119,7 +119,7 @@ discard block |
||
119 | 119 | |
120 | 120 | $return = []; |
121 | 121 | |
122 | - foreach ($data as $scoped_key => $value) { |
|
122 | + foreach ( $data as $scoped_key => $value ) { |
|
123 | 123 | $key = substr($scoped_key, strlen("$scope-")); |
124 | 124 | $return[$key] = $value; |
125 | 125 | } |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | |
141 | 141 | $shadowNames = []; |
142 | 142 | |
143 | - foreach ($key_values as $key => $value) { |
|
143 | + foreach ( $key_values as $key => $value ) { |
|
144 | 144 | $shadowNames["$scope-$key"] = $value; |
145 | 145 | } |
146 | 146 |