Interface for one cache layer.
More...
|
| Task< OpResponse > | Fetch (RequestOp requestOp) |
| | Fetches a cached response for a given request operation.
|
| Task< OpResponse > | Store (OpResponse opResponse) |
| | Stores the given operation response in the cache.
|
| Task | Store (Type type, object id, object model, long arrivedAt) |
| | Stores a model in the cache.
|
| Task | StoreCollection (Type type, string key, IEnumerable? ids, long arrivedAt) |
| | Stores a collection of model ids in the cache.
|
| string? | GetBlobAbsoluteFilePath (string blobPath) |
| | Given a blob path (always relative) return an absolute local file system path for that blob.
|
| Task | ClearAll (bool exceptHeld=true, DateTime? olderThan=null) |
|
Task | ClearByType (Type type, bool exceptHeld=true, DateTime? olderThan=null) |
|
Task | ClearBlobs (bool exceptHeld=true, DateTime? olderThan=null) |
|
Task | ClearBlob (string path) |
| Task | NotifyBlobIsFresh (string blobPath, long arrivedAtMs) |
| | Set the ArrivedAtMs value for the given blobPath to the given value. This is not absolutely necessary but for maximum efficiency should be implemented. It is only used when eTags indicate that a local blob is still fresh.
|
|
| CascadeDataLayer | Cascade [get, set] |
| | Cascade reference.
|
|
bool | SupportsBlobs [get] |
|
bool | SupportsGetBlobAbsoluteFilePath [get] |
Interface for one cache layer.
◆ ClearAll()
| Task Buzzware.Cascade.ICascadeCache.ClearAll |
( |
bool | exceptHeld = true, |
|
|
DateTime? | olderThan = null ) |
Clears stored data from the cache. Removes all entries currently held except those that need to be held. Optionally clears entries older than a specified DateTime.
- Parameters
-
| exceptHeld | If true, entries marked to be held will not be cleared. |
| olderThan | If specified, only entries older than this date will be cleared. |
Implemented in Buzzware.Cascade.ModelCache.
◆ Fetch()
Fetches a cached response for a given request operation.
- Parameters
-
| requestOp | The operation representing the request, which is used to locate the cached value |
- Returns
- The operation response
Implemented in Buzzware.Cascade.ModelCache.
◆ GetBlobAbsoluteFilePath()
| string? Buzzware.Cascade.ICascadeCache.GetBlobAbsoluteFilePath |
( |
string | blobPath | ) |
|
Given a blob path (always relative) return an absolute local file system path for that blob.
- Parameters
-
- Returns
Implemented in Buzzware.Cascade.ModelCache.
◆ NotifyBlobIsFresh()
| Task Buzzware.Cascade.ICascadeCache.NotifyBlobIsFresh |
( |
string | blobPath, |
|
|
long | arrivedAtMs ) |
Set the ArrivedAtMs value for the given blobPath to the given value. This is not absolutely necessary but for maximum efficiency should be implemented. It is only used when eTags indicate that a local blob is still fresh.
- Parameters
-
- Returns
Implemented in Buzzware.Cascade.ModelCache.
◆ Store() [1/2]
Stores the given operation response in the cache.
- Parameters
-
| opResponse | The response from an operation that includes data to be cached. |
Implemented in Buzzware.Cascade.ModelCache.
◆ Store() [2/2]
| Task Buzzware.Cascade.ICascadeCache.Store |
( |
Type | type, |
|
|
object | id, |
|
|
object | model, |
|
|
long | arrivedAt ) |
Stores a model in the cache.
- Parameters
-
| type | The type of the model to store. |
| id | The unique identifier for the model being cached. |
| model | The actual model object to be cached. |
| arrivedAt | Timestamp of when the model data arrived from the origin |
Implemented in Buzzware.Cascade.ModelCache.
◆ StoreCollection()
| Task Buzzware.Cascade.ICascadeCache.StoreCollection |
( |
Type | type, |
|
|
string | key, |
|
|
IEnumerable? | ids, |
|
|
long | arrivedAt ) |
Stores a collection of model ids in the cache.
- Parameters
-
| type | The type of models in the collection to be cached. |
| key | A string key to reference the cached collection. |
| ids | The identifiers of the models contained in the collection. |
| arrivedAt | Timestamp indicating when this collection was cached. |
◆ Cascade
The documentation for this interface was generated from the following file:
- Buzzware.Cascade/interfaces/ICascadeCache.cs