@@ 40-46 (lines=7) @@ | ||
37 | /** |
|
38 | * @inheritdoc |
|
39 | */ |
|
40 | public function getItemsAsJsonString(array $keys = [], $option = 0, $depth = 512) |
|
41 | { |
|
42 | $callback = function (CacheItemInterface $item) { |
|
43 | return $item->get(); |
|
44 | }; |
|
45 | return json_encode(array_map($callback, array_values($this->getItems($keys))), $option, $depth); |
|
46 | } |
|
47 | ||
48 | /** |
|
49 | * @inheritdoc |
|
@@ 117-124 (lines=8) @@ | ||
114 | /** |
|
115 | * @inheritdoc |
|
116 | */ |
|
117 | public function getItemsByTagsAsJsonString(array $tagNames, $option = 0, $depth = 512) |
|
118 | { |
|
119 | $callback = function (CacheItemInterface $item) { |
|
120 | return $item->get(); |
|
121 | }; |
|
122 | ||
123 | return json_encode(array_map($callback, array_values($this->getItemsByTags($tagNames))), $option, $depth); |
|
124 | } |
|
125 | ||
126 | /** |
|
127 | * @inheritdoc |