Skip to content

JsonSerializationMixin class

Defined in

Namespace: Akavache Assembly: Akavache.Core.dll Full name: Akavache.JsonSerializationMixin Modifiers: public static

Summary

View source

        Set of extension methods associated with JSON serialization.
        

Applies to

net9.0, net9.0-maccatalyst18.0, net9.0-macos15.0, net9.0-tvos18.0, net9.0-android35.0, net9.0-ios18.0, net8.0, net8.0-android34.0, net8.0-macos14.5, net8.0-ios18.0, net8.0-maccatalyst18.0, net8.0-macos15.0, net8.0-tvos18.0, net8.0-ios17.5, net8.0-maccatalyst17.5, net8.0-macos14.2, net8.0-tvos17.2, netstandard2.1, netstandard2.0

Methods

NameSummary
static InsertObjectInsert an object into the cache, via the JSON serializer.
static InsertAllObjectsInsert several objects into the cache, via the JSON serializer. Similarly to InsertAll, partial inserts should not happen.
static GetObjectGet an object from the cache and deserialize it via the JSON serializer.
static GetAllObjectsReturn all objects of a specific Type in the cache.
static GetOrFetchObjectAttempt to return an object from the cache. If the item doesn't exist or returns an error, call a Func to return the latest version of an object and insert the result in the cache.
static GetOrCreateObjectAttempt to return an object from the cache. If the item doesn't exist or returns an error, call a Func to create a new one.
static GetObjectCreatedAtReturns the time that the key was added to the cache, or returns null if the key isn't in the cache.
static GetAndFetchLatestThis method attempts to returned a cached value, while simultaneously calling a Func to return the latest value. When the latest data comes back, it replaces what was previously in the cache.
static InvalidateObjectInvalidates a single object from the cache. It is important that the Type Parameter for this method be correct, and you cannot use IBlobCache.Invalidate to perform the same...
static InvalidateAllObjectsInvalidates all objects of the specified type. To invalidate all objects regardless of type, use InvalidateAll.
Inherited members