https://github.com/milovidov983/concurrentcache
Easy to use library for local cache
https://github.com/milovidov983/concurrentcache
cache localcache threadsafe
Last synced: about 1 year ago
JSON representation
Easy to use library for local cache
- Host: GitHub
- URL: https://github.com/milovidov983/concurrentcache
- Owner: milovidov983
- License: mit
- Created: 2020-12-26T04:15:29.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2021-01-03T04:28:19.000Z (about 5 years ago)
- Last Synced: 2025-01-14T01:34:56.713Z (about 1 year ago)
- Topics: cache, localcache, threadsafe
- Language: C#
- Homepage:
- Size: 32.2 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ConcurrentCache - An easy-to-use, thread-safe local cache library for dotnet
__Package__ - [ConcurrentLocalCache](https://www.nuget.org/packages/ConcurrentLocalCache/)
## Overview
An easy-to-use, thread-safe local cache library for dotnet. It is based on the implementation recommended by Microsoft `Microsoft.Extensions.Caching.Memory`.
---
## Super simple to use
```csharp
// Create instance
ICache localCache = new Cache();
var key = "42number";
// Get or add value from cache by key "42number"
var result = await cache.GetOrAdd(key, () => Task.FromResult(42));
```