Open sandboxFocus

Class 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.

Inheritance
NotCacheKeyAttribute
Namespace: PostSharp.Patterns.Caching
Assembly: PostSharp.Patterns.Caching.dll
Syntax
[AttributeUsage(AttributeTargets.Parameter)]
public sealed class NotCacheKeyAttribute : Attribute
Remarks

Calls that differ only by the value of an excluded parameter share the same cache item. An InvalidateCacheAttribute does not need a matching parameter for an excluded parameter. To exclude the this instance from the cache key, set IgnoreThisParameter instead.

Constructors

Name Description
NotCacheKeyAttribute()

See Also