Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ A simple cache for Go using generics.
SimCache allows the creation of a thread-safe cache for any type, without the need to cast the returned value.
The cache **clears expired items upon any retrieval operation**, such as `Get` or `Items`.

This is essentially https://github.com/patrickmn/go-cache but with generics. Was made because of [go-cache #149](https://github.com/patrickmn/go-cache/pull/149).

## Installation
Assuming that [you have Go installed](https://go.dev/doc/install):
`go get -u github.com/willboland/simcache`
Expand Down Expand Up @@ -112,4 +114,4 @@ It returns the number of items deleted from the cache.
cache.Set("one", 1) // Expired
cache.Set("two", 2) // Expired
cache.Purge() // 2
```
```
Loading