Open sandboxFocus

Namespace PostSharp.Patterns.Caching

Classes

CacheAttribute

Custom attribute that, when applied to a method, causes the return value of the method to be cached for the specific list of arguments passed to this method call.

CacheAttribute.Serializer

CacheConfigurationAttribute

Custom attribute that, when applied to a type, configures the CacheAttribute aspects applied to the methods of this type or its derived types. When applied to an assembly, the CacheConfigurationAttribute custom attribute configures all methods of the current assembly.

CachingException

Represents an exception thrown by PostSharp.Patterns.Caching.

CachingProfile

Allows for centralized and run-time configuration of several instances of the CacheAttribute aspect.

CachingProfileRegistry

Allows the configuration of caching profiles (CachingProfile), and therefore influences the behavior of the CacheAttribute aspect at run time. This class is exposed by the Profiles property of each service, and by the Profiles property for DefaultService.

CachingService

The default implementation of ICachingService: a cache made of a backend, a key builder and caching profiles. Register an instance as a singleton in a dependency injection container, or configure DefaultService.

CachingServices

The entry point to configure PostSharp.Patterns.Caching at run time.

CachingServices.CachingProfileRegistry

The former name of CachingProfileRegistry, kept so that the assemblies compiled against previous versions run.

CachingServices.Formatters

Allows getting and registering formatters used to generate caching keys.

CachingServices.Invalidation

Invalidates the cache.

InvalidCacheItemException

Represents an exception thrown by a caching backend during cache item retrieval (e.g. when the cached data cannot be serialized by the current object model). Throwing this exception causes the removal of the invalid item.

InvalidateCacheAttribute

Custom attribute that, when applied to a method, causes an invocation of this method to remove from the cache the result of invocations of other given methods with the same parameter values.

InvalidateCacheAttribute.Serializer

NotCacheKeyAttribute

Custom attribute that, when applied to a parameter of a cached method (i.e. a method enhanced by the CacheAttribute aspect), excludes this parameter from the cache key.

Interfaces

ICachingContext

Represents the context in which a method being cached is executing.

ICachingService

Represents a cache: the backend that stores the items, the key builder that computes their keys, the caching profiles, and the operations that the caching aspects call. The default implementation is CachingService.

Enums

CachingContextKind

Enumerates the kinds of ICachingContext.