Table of Contents

Interface IPostgrestCacheProvider

Namespace
Supabase.Postgrest.Interfaces
Assembly
Supabase.Postgrest.dll

A caching provider than can be used by postgrest to store requests.

public interface IPostgrestCacheProvider

Methods

ClearItem(string)

Clear an item within a caching solution by a key.

Task ClearItem(string key)

Parameters

key string

A reproducible key for a defined query.

Returns

Task

Empty()

An empty/clear cache implementation.

Task Empty()

Returns

Task

GetItem<T>(string)

Gets an item from a caching solution, should coerce into a datatype.

This will most likely be a JSON deserialization approach.

Task<T?> GetItem<T>(string key)

Parameters

key string

A reproducible key for a defined query.

Returns

Task<T>

Type Parameters

T

SetItem(string, object)

Sets an item within a caching solution, should store in a way that the data can be retrieved and coerced into a generic type by GetItem<T>(string)

This will most likely be a JSON serialization approach.

Task SetItem(string key, object value)

Parameters

key string

A reproducible key for a defined query.

value object

An object of serializable data.

Returns

Task