Accessing local cache only  
 More...
|  | 
|  | CacheLocal (DefaultCacheOptions options, IMemoryCache l1Cache) | 
|  | 
| virtual bool | Get< T > (string key, out T item) | 
|  | Retrieves an item from the Cache  More... 
 | 
|  | 
| virtual void | Set< T > (string key, T item) | 
|  | Sets an item into cache  More... 
 | 
|  | 
| virtual T | Get< T > (string key, Func< T > method) | 
|  | Attempts to retrieve an item from cache. If not found in cache, will make callback to obtain the item from the caller which will be stored for later use  More... 
 | 
|  | 
| virtual Task< T > | GetAsync< T > (string key, Func< Task< T >> method) | 
|  | Attempts to retrieve an item from cache. If not found in cache, will make callback to obtain the item from the caller which will be stored for later use  More... 
 | 
|  | 
| virtual void | Remove (string key) | 
|  | Removes the given object from local cache  More... 
 | 
|  | 
| virtual Task< Exception > | RemoveAsync (string key) | 
|  | Removes the given object from local cache  More... 
 | 
|  | 
Accessing local cache only 
◆ CacheLocal()
      
        
          | Sphyrnidae.Common.Cache.CacheLocal.CacheLocal | ( | DefaultCacheOptions | options, | 
        
          |  |  | IMemoryCache | l1Cache | 
        
          |  | ) |  |  | 
      
 
 
◆ Get< T >() [1/2]
  
  | 
        
          | virtual T Sphyrnidae.Common.Cache.CacheLocal.Get< T > | ( | string | key, |  
          |  |  | Func< T > | method |  
          |  | ) |  |  |  | virtual | 
 
Attempts to retrieve an item from cache. If not found in cache, will make callback to obtain the item from the caller which will be stored for later use 
Attempts to retrieve an item from cache. If not found in cache, will make callback to obtain the item from the caller which will be stored for later use
- Template Parameters
- 
  
  
- Parameters
- 
  
    | key | Name of the item in cache |  | method | The callback function returning the item if not initially found in cache |  
 
- Returns
- The object from cache/callback function
Implements Sphyrnidae.Common.Cache.ICache.
 
 
◆ Get< T >() [2/2]
  
  | 
        
          | virtual bool Sphyrnidae.Common.Cache.CacheLocal.Get< T > | ( | string | key, |  
          |  |  | out T | item |  
          |  | ) |  |  |  | virtual | 
 
Retrieves an item from the Cache 
Retrieves an item from the Cache
- Template Parameters
- 
  
  
- Parameters
- 
  
    | key | Name of the item in cache |  | item | If the object is not found in the Cache, this will be populated |  
 
- Returns
- True if the object was found, False if not found
Implements Sphyrnidae.Common.Cache.ICache.
 
 
◆ GetAsync< T >()
  
  | 
        
          | virtual Task<T> Sphyrnidae.Common.Cache.CacheLocal.GetAsync< T > | ( | string | key, |  
          |  |  | Func< Task< T >> | method |  
          |  | ) |  |  |  | virtual | 
 
Attempts to retrieve an item from cache. If not found in cache, will make callback to obtain the item from the caller which will be stored for later use 
Attempts to retrieve an item from cache. If not found in cache, will make callback to obtain the item from the caller which will be stored for later use
- Template Parameters
- 
  
  
- Parameters
- 
  
    | key | Name of the item in cache |  | method | The callback function returning the item if not initially found in cache |  
 
- Returns
- The object from cache/callback function
Implements Sphyrnidae.Common.Cache.ICache.
 
 
◆ Remove()
  
  | 
        
          | virtual void Sphyrnidae.Common.Cache.CacheLocal.Remove | ( | string | key | ) |  |  | virtual | 
 
Removes the given object from local cache 
Removes the given object from cache
- Parameters
- 
  
    | key | Name of the item in cache |  
 
Implements Sphyrnidae.Common.Cache.ICache.
 
 
◆ RemoveAsync()
  
  | 
        
          | virtual Task<Exception> Sphyrnidae.Common.Cache.CacheLocal.RemoveAsync | ( | string | key | ) |  |  | virtual | 
 
Removes the given object from local cache 
Removes the given object from cache
- Parameters
- 
  
    | key | Name of the item in cache |  
 
- Returns
- Always default(Exception) - eg. null
Implements Sphyrnidae.Common.Cache.ICache.
 
 
◆ Set< T >()
  
  | 
        
          | virtual void Sphyrnidae.Common.Cache.CacheLocal.Set< T > | ( | string | key, |  
          |  |  | T | item |  
          |  | ) |  |  |  | virtual | 
 
Sets an item into cache 
Sets an item into cache
- Template Parameters
- 
  
  
- Parameters
- 
  
    | key | Name of the item in cache |  | item | The item being set into cache |  
 
Implements Sphyrnidae.Common.Cache.ICache.
 
 
◆ L1Cache
  
  | 
        
          | IMemoryCache Sphyrnidae.Common.Cache.CacheLocal.L1Cache |  | getprotected | 
 
 
◆ Options
The documentation for this class was generated from the following file:
- C:/Users/dougb/Desktop/Sphyrnidae/New/Common/Common/Cache/CacheLocal.cs