You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// You can choose MemoryCache<<#Key#>, <#Value#>> or Cache<<#Key#>, <#Value#>> as well as DiskCache<<#Key#>>.
21
+
let cache = DiskCache<String>(options: .default(path: .default("caches")))
22
+
23
+
// read
24
+
tryawait cache.value(for: "item0")
25
+
26
+
// write
27
+
cache.store(Data(), for: "item0")
28
+
29
+
// remove
30
+
cache.remove(for: "item0")
31
+
32
+
// remove all
33
+
cache.removeAll()
34
+
```
35
+
36
+
## License
37
+
38
+
DataCacheKit is available under the MIT license, and uses source code from open source projects. See the [LICENSE](https://github.com/swiftty/DataCacheKit/blob/main/LICENSE) file for more info.
0 commit comments