Class MemoryCacheUserInfoUpdaterCache
This implementation of the IUserInfoUpdater
uses the Asp.Net Core
Inheritance
System.Object
MemoryCacheUserInfoUpdaterCache
Implements
Namespace: Dangl.Identity.Client.Mvc.Services
Assembly: Dangl.Identity.Client.Mvc.dll
Syntax
public class MemoryCacheUserInfoUpdaterCache : object, IUserInfoUpdaterCache
Constructors
| Improve this Doc View SourceMemoryCacheUserInfoUpdaterCache(IMemoryCache)
This implementation of the IUserInfoUpdater
uses the Asp.Net Core
Declaration
public MemoryCacheUserInfoUpdaterCache(IMemoryCache memoryCache)
Parameters
| Type | Name | Description |
|---|---|---|
| IMemoryCache | memoryCache |
Methods
| Improve this Doc View SourceCacheUserIdAsync(Guid, DateTime)
Caches the UserId with a given expiration time
Declaration
public Task CacheUserIdAsync(Guid userId, DateTime expiration)
Parameters
| Type | Name | Description |
|---|---|---|
| Guid | userId | |
| DateTime | expiration |
Returns
| Type | Description |
|---|---|
| Task |
HasUserIdCachedAsync(Guid)
Returns true if the UserId is in the cache
Declaration
public Task<bool> HasUserIdCachedAsync(Guid userId)
Parameters
| Type | Name | Description |
|---|---|---|
| Guid | userId |
Returns
| Type | Description |
|---|---|
| Task<System.Boolean> |