Table of Contents

Class BulkOperationsMixin

Namespace
Akavache
Assembly
Akavache.Core.dll

Extension methods for the IBlobCache that provide bulk operations.

public static class BulkOperationsMixin
Inheritance
BulkOperationsMixin

Methods

Get(IBlobCache, IEnumerable<string>)

Gets a dictionary filled with the specified keys with their corresponding values.

public static IObservable<IDictionary<string, byte[]>> Get(this IBlobCache blobCache, IEnumerable<string> keys)

Parameters

blobCache IBlobCache

The blob cache to extract the values from.

keys IEnumerable<string>

The keys to get the values for.

Returns

IObservable<IDictionary<string, byte[]>>

A observable with the specified values.

GetCreatedAt(IBlobCache, IEnumerable<string>)

Gets a dictionary filled with the specified keys with their corresponding created DateTimeOffset if it's available.

public static IObservable<IDictionary<string, DateTimeOffset?>> GetCreatedAt(this IBlobCache blobCache, IEnumerable<string> keys)

Parameters

blobCache IBlobCache

The blob cache to extract the values from.

keys IEnumerable<string>

The keys to get the values for.

Returns

IObservable<IDictionary<string, DateTimeOffset?>>

A observable with the specified values.

GetObjects<T>(IBlobCache, IEnumerable<string>)

Gets a dictionary filled with the specified keys with their corresponding values.

public static IObservable<IDictionary<string, T>> GetObjects<T>(this IBlobCache blobCache, IEnumerable<string> keys)

Parameters

blobCache IBlobCache

The blob cache to extract the values from.

keys IEnumerable<string>

The keys to get the values for.

Returns

IObservable<IDictionary<string, T>>

A observable with the specified values.

Type Parameters

T

The type of item to get.

Insert(IBlobCache, IDictionary<string, byte[]>, DateTimeOffset?)

Inserts the specified key/value pairs into the blob.

public static IObservable<Unit> Insert(this IBlobCache blobCache, IDictionary<string, byte[]> keyValuePairs, DateTimeOffset? absoluteExpiration = null)

Parameters

blobCache IBlobCache

The blob cache to insert the values to.

keyValuePairs IDictionary<string, byte[]>

The key/value to insert.

absoluteExpiration DateTimeOffset?

An optional expiration date.

Returns

IObservable<Unit>

A observable which signals when complete.

InsertObjects<T>(IBlobCache, IDictionary<string, T>, DateTimeOffset?)

Inserts the specified key/value pairs into the blob.

public static IObservable<Unit> InsertObjects<T>(this IBlobCache blobCache, IDictionary<string, T> keyValuePairs, DateTimeOffset? absoluteExpiration = null)

Parameters

blobCache IBlobCache

The blob cache to insert the values to.

keyValuePairs IDictionary<string, T>

The key/value to insert.

absoluteExpiration DateTimeOffset?

An optional expiration date.

Returns

IObservable<Unit>

A observable which signals when complete.

Type Parameters

T

The type of item to insert.

Invalidate(IBlobCache, IEnumerable<string>)

Invalidates all the entries at the specified keys, causing them in future to have to be re-fetched.

public static IObservable<Unit> Invalidate(this IBlobCache blobCache, IEnumerable<string> keys)

Parameters

blobCache IBlobCache

The blob cache to invalidate values from.

keys IEnumerable<string>

The keys to invalid.

Returns

IObservable<Unit>

A observable which signals when complete.

InvalidateObjects<T>(IBlobCache, IEnumerable<string>)

Invalidates all the entries at the specified keys, causing them in future to have to be re-fetched.

public static IObservable<Unit> InvalidateObjects<T>(this IBlobCache blobCache, IEnumerable<string> keys)

Parameters

blobCache IBlobCache

The blob cache to invalidate values from.

keys IEnumerable<string>

The keys to invalid.

Returns

IObservable<Unit>

A observable which signals when complete.

Type Parameters

T

The type of item to invalidate.