Skip to content

Commit 9d053bc

Browse files
committed
fixed phpDoc
1 parent 0f4b4a2 commit 9d053bc

12 files changed

+55
-66
lines changed

src/Caching/Cache.php

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,9 @@ public function derive($namespace)
8181

8282
/**
8383
* Reads the specified item from the cache or generate it.
84-
* @param mixed key
84+
* @param mixed
8585
* @param callable
86-
* @return mixed|NULL
86+
* @return mixed
8787
*/
8888
public function load($key, $fallback = NULL)
8989
{
@@ -157,9 +157,8 @@ public function bulkLoad(array $keys, $fallback = NULL)
157157
* - Cache::ITEMS => (array|string) cache items
158158
* - Cache::CONSTS => (array|string) cache items
159159
*
160-
* @param mixed key
161-
* @param mixed value
162-
* @param array dependencies
160+
* @param mixed
161+
* @param mixed
163162
* @return mixed value itself
164163
* @throws Nette\InvalidArgumentException
165164
*/
@@ -234,7 +233,7 @@ private function completeDependencies($dp)
234233

235234
/**
236235
* Removes item from the cache.
237-
* @param mixed key
236+
* @param mixed
238237
* @return void
239238
*/
240239
public function remove($key)
@@ -281,7 +280,6 @@ public function call($function)
281280
/**
282281
* Caches results of function/method calls.
283282
* @param mixed
284-
* @param array dependencies
285283
* @return \Closure
286284
*/
287285
public function wrap($function, array $dependencies = NULL)
@@ -302,7 +300,7 @@ public function wrap($function, array $dependencies = NULL)
302300

303301
/**
304302
* Starts the output cache.
305-
* @param mixed key
303+
* @param mixed
306304
* @return OutputHelper|NULL
307305
*/
308306
public function start($key)
@@ -317,8 +315,7 @@ public function start($key)
317315

318316
/**
319317
* Generates internal cache key.
320-
*
321-
* @param string
318+
* @param mixed
322319
* @return string
323320
*/
324321
protected function generateKey($key)
@@ -361,7 +358,7 @@ private static function checkConst($const, $value)
361358
/**
362359
* Checks FILES dependency.
363360
* @param string
364-
* @param int
361+
* @param int|NULL
365362
* @return bool
366363
*/
367364
private static function checkFile($file, $time)

src/Caching/IBulkReader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ interface IBulkReader
1616

1717
/**
1818
* Reads from cache in bulk.
19-
* @param string key
19+
* @param string
2020
* @return array key => value pairs, missing items are omitted
2121
*/
2222
function bulkRead(array $keys);

src/Caching/IStorage.php

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,30 +16,29 @@ interface IStorage
1616

1717
/**
1818
* Read from cache.
19-
* @param string key
20-
* @return mixed|NULL
19+
* @param string
20+
* @return mixed
2121
*/
2222
function read($key);
2323

2424
/**
2525
* Prevents item reading and writing. Lock is released by write() or remove().
26-
* @param string key
26+
* @param string
2727
* @return void
2828
*/
2929
function lock($key);
3030

3131
/**
3232
* Writes item into the cache.
33-
* @param string key
34-
* @param mixed data
35-
* @param array dependencies
33+
* @param string
34+
* @param mixed
3635
* @return void
3736
*/
3837
function write($key, $data, array $dependencies);
3938

4039
/**
4140
* Removes item from the cache.
42-
* @param string key
41+
* @param string
4342
* @return void
4443
*/
4544
function remove($key);

src/Caching/OutputHelper.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ public function __construct(Cache $cache, $key)
3737

3838
/**
3939
* Stops and saves the cache.
40-
* @param array dependencies
4140
* @return void
4241
*/
4342
public function end(array $dependencies = NULL)

src/Caching/Storages/DevNullStorage.php

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ class DevNullStorage implements Nette\Caching\IStorage
1919

2020
/**
2121
* Read from cache.
22-
* @param string key
23-
* @return mixed|NULL
22+
* @param string
23+
* @return mixed
2424
*/
2525
public function read($key)
2626
{
@@ -29,7 +29,7 @@ public function read($key)
2929

3030
/**
3131
* Prevents item reading and writing. Lock is released by write() or remove().
32-
* @param string key
32+
* @param string
3333
* @return void
3434
*/
3535
public function lock($key)
@@ -39,9 +39,8 @@ public function lock($key)
3939

4040
/**
4141
* Writes item into the cache.
42-
* @param string key
43-
* @param mixed data
44-
* @param array dependencies
42+
* @param string
43+
* @param mixed
4544
* @return void
4645
*/
4746
public function write($key, $data, array $dependencies)
@@ -51,7 +50,7 @@ public function write($key, $data, array $dependencies)
5150

5251
/**
5352
* Removes item from the cache.
54-
* @param string key
53+
* @param string
5554
* @return void
5655
*/
5756
public function remove($key)

src/Caching/Storages/FileStorage.php

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,8 @@ public function __construct($dir, IJournal $journal = NULL)
8181

8282
/**
8383
* Read from cache.
84-
* @param string key
85-
* @return mixed|NULL
84+
* @param string
85+
* @return mixed
8686
*/
8787
public function read($key)
8888
{
@@ -138,7 +138,7 @@ private function verify($meta)
138138

139139
/**
140140
* Prevents item reading and writing. Lock is released by write() or remove().
141-
* @param string key
141+
* @param string
142142
* @return void
143143
*/
144144
public function lock($key)
@@ -157,9 +157,8 @@ public function lock($key)
157157

158158
/**
159159
* Writes item into the cache.
160-
* @param string key
161-
* @param mixed data
162-
* @param array dependencies
160+
* @param string
161+
* @param mixed
163162
* @return void
164163
*/
165164
public function write($key, $data, array $dp)
@@ -243,7 +242,7 @@ public function write($key, $data, array $dp)
243242

244243
/**
245244
* Removes item from the cache.
246-
* @param string key
245+
* @param string
247246
* @return void
248247
*/
249248
public function remove($key)

src/Caching/Storages/IJournal.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ function write($key, array $dependencies);
2626
/**
2727
* Cleans entries from journal.
2828
* @param array
29-
* @return array of removed items or NULL when performing a full cleanup
29+
* @return array|NULL of removed items or NULL when performing a full cleanup
3030
*/
3131
function clean(array $conditions);
3232

src/Caching/Storages/MemcachedStorage.php

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,8 @@ public function getConnection()
7878

7979
/**
8080
* Read from cache.
81-
* @param string key
82-
* @return mixed|NULL
81+
* @param string
82+
* @return mixed
8383
*/
8484
public function read($key)
8585
{
@@ -112,7 +112,7 @@ public function read($key)
112112

113113
/**
114114
* Prevents item reading and writing. Lock is released by write() or remove().
115-
* @param string key
115+
* @param string
116116
* @return void
117117
*/
118118
public function lock($key)
@@ -122,9 +122,8 @@ public function lock($key)
122122

123123
/**
124124
* Writes item into the cache.
125-
* @param string key
126-
* @param mixed data
127-
* @param array dependencies
125+
* @param string
126+
* @param mixed
128127
* @return void
129128
*/
130129
public function write($key, $data, array $dp)
@@ -163,7 +162,7 @@ public function write($key, $data, array $dp)
163162

164163
/**
165164
* Removes item from the cache.
166-
* @param string key
165+
* @param string
167166
* @return void
168167
*/
169168
public function remove($key)

src/Caching/Storages/MemoryStorage.php

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ class MemoryStorage implements Nette\Caching\IStorage
2323

2424
/**
2525
* Read from cache.
26-
* @param string key
27-
* @return mixed|NULL
26+
* @param string
27+
* @return mixed
2828
*/
2929
public function read($key)
3030
{
@@ -34,7 +34,7 @@ public function read($key)
3434

3535
/**
3636
* Prevents item reading and writing. Lock is released by write() or remove().
37-
* @param string key
37+
* @param string
3838
* @return void
3939
*/
4040
public function lock($key)
@@ -44,9 +44,8 @@ public function lock($key)
4444

4545
/**
4646
* Writes item into the cache.
47-
* @param string key
48-
* @param mixed data
49-
* @param array dependencies
47+
* @param string
48+
* @param mixed
5049
* @return void
5150
*/
5251
public function write($key, $data, array $dependencies)
@@ -57,7 +56,7 @@ public function write($key, $data, array $dependencies)
5756

5857
/**
5958
* Removes item from the cache.
60-
* @param string key
59+
* @param string
6160
* @return void
6261
*/
6362
public function remove($key)

src/Caching/Storages/NewMemcachedStorage.php

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,8 @@ public function getConnection()
7878

7979
/**
8080
* Read from cache.
81-
* @param string key
82-
* @return mixed|NULL
81+
* @param string
82+
* @return mixed
8383
*/
8484
public function read($key)
8585
{
@@ -112,7 +112,7 @@ public function read($key)
112112

113113
/**
114114
* Reads from cache in bulk.
115-
* @param string key
115+
* @param string
116116
* @return array key => value pairs, missing items are omitted
117117
*/
118118
public function bulkRead(array $keys)
@@ -145,7 +145,7 @@ public function bulkRead(array $keys)
145145

146146
/**
147147
* Prevents item reading and writing. Lock is released by write() or remove().
148-
* @param string key
148+
* @param string
149149
* @return void
150150
*/
151151
public function lock($key)
@@ -155,9 +155,8 @@ public function lock($key)
155155

156156
/**
157157
* Writes item into the cache.
158-
* @param string key
159-
* @param mixed data
160-
* @param array dependencies
158+
* @param string
159+
* @param mixed
161160
* @return void
162161
*/
163162
public function write($key, $data, array $dp)
@@ -196,7 +195,7 @@ public function write($key, $data, array $dp)
196195

197196
/**
198197
* Removes item from the cache.
199-
* @param string key
198+
* @param string
200199
* @return void
201200
*/
202201
public function remove($key)

0 commit comments

Comments
 (0)