Table of Contents

Interface ISyncCacheProvider

Namespace
Polly.Caching
Assembly
Polly.dll

Defines methods for classes providing synchronous cache functionality for Polly CachePolicys.

public interface ISyncCacheProvider
Extension Methods

Methods

Get(string)

Gets a value from cache.

object Get(string key)

Parameters

key string

The cache key.

Returns

object

The value from cache; or null, if none was found.

Put(string, object, Ttl)

Puts the specified value in the cache.

void Put(string key, object value, Ttl ttl)

Parameters

key string

The cache key.

value object

The value to put into the cache.

ttl Ttl

The time-to-live for the cache entry.