Skip to content

Commit 813d98d

Browse files
committed
phpDoc: removed inherited docs
1 parent 7d024e7 commit 813d98d

File tree

6 files changed

+0
-95
lines changed

6 files changed

+0
-95
lines changed

src/Caching/Storages/DevNullStorage.php

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -19,42 +19,26 @@ class DevNullStorage implements Nette\Caching\IStorage
1919
{
2020
use Nette\SmartObject;
2121

22-
/**
23-
* Read from cache.
24-
* @return mixed
25-
*/
2622
public function read(string $key)
2723
{
2824
}
2925

3026

31-
/**
32-
* Prevents item reading and writing. Lock is released by write() or remove().
33-
*/
3427
public function lock(string $key): void
3528
{
3629
}
3730

3831

39-
/**
40-
* Writes item into the cache.
41-
*/
4232
public function write(string $key, $data, array $dependencies): void
4333
{
4434
}
4535

4636

47-
/**
48-
* Removes item from the cache.
49-
*/
5037
public function remove(string $key): void
5138
{
5239
}
5340

5441

55-
/**
56-
* Removes items from the cache by conditions & garbage collector.
57-
*/
5842
public function clean(array $conditions): void
5943
{
6044
}

src/Caching/Storages/FileStorage.php

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,6 @@ public function __construct($dir, IJournal $journal = null)
7878
}
7979

8080

81-
/**
82-
* Read from cache.
83-
* @return mixed
84-
*/
8581
public function read(string $key)
8682
{
8783
$meta = $this->readMetaAndLock($this->getCacheFile($key), LOCK_SH);
@@ -132,9 +128,6 @@ private function verify(array $meta): bool
132128
}
133129

134130

135-
/**
136-
* Prevents item reading and writing. Lock is released by write() or remove().
137-
*/
138131
public function lock(string $key): void
139132
{
140133
$cacheFile = $this->getCacheFile($key);
@@ -149,9 +142,6 @@ public function lock(string $key): void
149142
}
150143

151144

152-
/**
153-
* Writes item into the cache.
154-
*/
155145
public function write(string $key, $data, array $dp): void
156146
{
157147
$meta = [
@@ -231,19 +221,13 @@ public function write(string $key, $data, array $dp): void
231221
}
232222

233223

234-
/**
235-
* Removes item from the cache.
236-
*/
237224
public function remove(string $key): void
238225
{
239226
unset($this->locks[$key]);
240227
$this->delete($this->getCacheFile($key));
241228
}
242229

243230

244-
/**
245-
* Removes items from the cache by conditions & garbage collector.
246-
*/
247231
public function clean(array $conditions): void
248232
{
249233
$all = !empty($conditions[Cache::ALL]);

src/Caching/Storages/MemcachedStorage.php

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -75,10 +75,6 @@ public function getConnection(): \Memcached
7575
}
7676

7777

78-
/**
79-
* Read from cache.
80-
* @return mixed
81-
*/
8278
public function read(string $key)
8379
{
8480
$key = urlencode($this->prefix . $key);
@@ -108,10 +104,6 @@ public function read(string $key)
108104
}
109105

110106

111-
/**
112-
* Reads from cache in bulk.
113-
* @return array key => value pairs, missing items are omitted
114-
*/
115107
public function bulkRead(array $keys): array
116108
{
117109
$prefixedKeys = array_map(function ($key) {
@@ -140,17 +132,11 @@ public function bulkRead(array $keys): array
140132
}
141133

142134

143-
/**
144-
* Prevents item reading and writing. Lock is released by write() or remove().
145-
*/
146135
public function lock(string $key): void
147136
{
148137
}
149138

150139

151-
/**
152-
* Writes item into the cache.
153-
*/
154140
public function write(string $key, $data, array $dp): void
155141
{
156142
if (isset($dp[Cache::ITEMS])) {
@@ -185,18 +171,12 @@ public function write(string $key, $data, array $dp): void
185171
}
186172

187173

188-
/**
189-
* Removes item from the cache.
190-
*/
191174
public function remove(string $key): void
192175
{
193176
$this->memcached->delete(urlencode($this->prefix . $key), 0);
194177
}
195178

196179

197-
/**
198-
* Removes items from the cache by conditions & garbage collector.
199-
*/
200180
public function clean(array $conditions): void
201181
{
202182
if (!empty($conditions[Cache::ALL])) {

src/Caching/Storages/MemoryStorage.php

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -23,45 +23,29 @@ class MemoryStorage implements Nette\Caching\IStorage
2323
private $data = [];
2424

2525

26-
/**
27-
* Read from cache.
28-
* @return mixed
29-
*/
3026
public function read(string $key)
3127
{
3228
return $this->data[$key] ?? null;
3329
}
3430

3531

36-
/**
37-
* Prevents item reading and writing. Lock is released by write() or remove().
38-
*/
3932
public function lock(string $key): void
4033
{
4134
}
4235

4336

44-
/**
45-
* Writes item into the cache.
46-
*/
4737
public function write(string $key, $data, array $dependencies): void
4838
{
4939
$this->data[$key] = $data;
5040
}
5141

5242

53-
/**
54-
* Removes item from the cache.
55-
*/
5643
public function remove(string $key): void
5744
{
5845
unset($this->data[$key]);
5946
}
6047

6148

62-
/**
63-
* Removes items from the cache by conditions & garbage collector.
64-
*/
6549
public function clean(array $conditions): void
6650
{
6751
if (!empty($conditions[Nette\Caching\Cache::ALL])) {

src/Caching/Storages/SQLiteJournal.php

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,6 @@ private function open(): void
6363
}
6464

6565

66-
/**
67-
* Writes entry information into the journal.
68-
*/
6966
public function write(string $key, array $dependencies): void
7067
{
7168
if (!$this->pdo) {
@@ -93,10 +90,6 @@ public function write(string $key, array $dependencies): void
9390
}
9491

9592

96-
/**
97-
* Cleans entries from journal.
98-
* @return array|null removed items or null when performing a full cleanup
99-
*/
10093
public function clean(array $conditions): ?array
10194
{
10295
if (!$this->pdo) {

src/Caching/Storages/SQLiteStorage.php

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,6 @@ public function __construct($path)
5252
}
5353

5454

55-
/**
56-
* Read from cache.
57-
* @return mixed
58-
*/
5955
public function read(string $key)
6056
{
6157
$stmt = $this->pdo->prepare('SELECT data, slide FROM cache WHERE key=? AND (expire IS NULL OR expire >= ?)');
@@ -69,10 +65,6 @@ public function read(string $key)
6965
}
7066

7167

72-
/**
73-
* Reads from cache in bulk.
74-
* @return array key => value pairs, missing items are omitted
75-
*/
7668
public function bulkRead(array $keys): array
7769
{
7870
$stmt = $this->pdo->prepare('SELECT key, data, slide FROM cache WHERE key IN (?' . str_repeat(',?', count($keys) - 1) . ') AND (expire IS NULL OR expire >= ?)');
@@ -93,17 +85,11 @@ public function bulkRead(array $keys): array
9385
}
9486

9587

96-
/**
97-
* Prevents item reading and writing. Lock is released by write() or remove().
98-
*/
9988
public function lock(string $key): void
10089
{
10190
}
10291

10392

104-
/**
105-
* Writes item into the cache.
106-
*/
10793
public function write(string $key, $data, array $dependencies): void
10894
{
10995
$expire = isset($dependencies[Cache::EXPIRATION]) ? $dependencies[Cache::EXPIRATION] + time() : null;
@@ -125,19 +111,13 @@ public function write(string $key, $data, array $dependencies): void
125111
}
126112

127113

128-
/**
129-
* Removes item from the cache.
130-
*/
131114
public function remove(string $key): void
132115
{
133116
$this->pdo->prepare('DELETE FROM cache WHERE key=?')
134117
->execute([$key]);
135118
}
136119

137120

138-
/**
139-
* Removes items from the cache by conditions & garbage collector.
140-
*/
141121
public function clean(array $conditions): void
142122
{
143123
if (!empty($conditions[Cache::ALL])) {

0 commit comments

Comments
 (0)