diff options
author | 2023-04-19 13:46:42 +0200 | |
---|---|---|
committer | 2023-04-19 13:46:42 +0200 | |
commit | a3d2774db5e5be5b99d652a88d1a13223d3d834d (patch) | |
tree | cd5622dca8b38fc54dc72dfb1793353300486098 /vendor/codeberg.org/gruf/go-cache/v3/cache.go | |
parent | [chore]: Bump mvdan.cc/xurls/v2 from 2.4.0 to 2.5.0 (#1702) (diff) | |
download | gotosocial-a3d2774db5e5be5b99d652a88d1a13223d3d834d.tar.xz |
[chore]: Bump codeberg.org/gruf/go-cache/v3 from 3.2.3 to 3.2.5 (#1701)
Bumps codeberg.org/gruf/go-cache/v3 from 3.2.3 to 3.2.5.
---
updated-dependencies:
- dependency-name: codeberg.org/gruf/go-cache/v3
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Diffstat (limited to 'vendor/codeberg.org/gruf/go-cache/v3/cache.go')
-rw-r--r-- | vendor/codeberg.org/gruf/go-cache/v3/cache.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/vendor/codeberg.org/gruf/go-cache/v3/cache.go b/vendor/codeberg.org/gruf/go-cache/v3/cache.go index dc1df46b1..8271036a5 100644 --- a/vendor/codeberg.org/gruf/go-cache/v3/cache.go +++ b/vendor/codeberg.org/gruf/go-cache/v3/cache.go @@ -26,10 +26,10 @@ type Cache[Key comparable, Value any] interface { // Get fetches the value with key from the cache, extending its TTL. Get(key Key) (value Value, ok bool) - // Add attempts to place the value at key in the cache, doing nothing if a value with this key already exists. Returned bool is success state. + // Add attempts to place the value at key in the cache, doing nothing if a value with this key already exists. Returned bool is success state. Calls invalidate callback on success. Add(key Key, value Value) bool - // Set places the value at key in the cache. This will overwrite any existing value, and call the update callback so. Existing values will have their TTL extended upon update. + // Set places the value at key in the cache. This will overwrite any existing value. Existing values will have their TTL extended upon update. Always calls invalidate callback. Set(key Key, value Value) // CAS will attempt to perform a CAS operation on 'key', using provided old and new values, and comparator function. Returned bool is success. @@ -44,7 +44,7 @@ type Cache[Key comparable, Value any] interface { // Invalidate deletes a value from the cache, calling the invalidate callback. Invalidate(key Key) bool - // Clear empties the cache, calling the invalidate callback. + // Clear empties the cache, calling the invalidate callback on each entry. Clear() // Len returns the current length of the cache. |