Class InvalidateCacheAttribute
Custom attribute that, when applied on 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.
Inheritance
Implements
Namespace: PostSharp.Patterns.Caching
Assembly: PostSharp.Patterns.Caching.dll
Syntax
[MulticastAttributeUsage]
[Metric("UsedFeatures", "Patterns.Caching.InvalidateCache")]
[ProvideAspectRole("CacheInvalidation")]
[AspectRoleDependency]
[AspectRoleDependency]
[LinesOfCodeAvoided(1)]
[Serializer]
public sealed class InvalidateCacheAttribute : MethodInterceptionAspect, IMethodLevelAspectBuildSemantics, IAspectBuildSemantics, IValidableAnnotation, IAsyncMethodInterceptionAspect, IMethodInterceptionAspect, IMethodLevelAspect, IAspect
Constructors
Name | Description |
---|---|
InvalidateCacheAttribute(PortableFormatterConstructorContext) | |
InvalidateCacheAttribute(String[]) | Initializes a new InvalidateCacheAttribute that invalidates method of the same type as the type to which the current InvalidateCacheAttribute aspect is being applied. |
InvalidateCacheAttribute(Type, String[]) | Initializes a new InvalidateCacheAttribute that invalidates method of a different type than the type to which the current InvalidateCacheAttribute aspect is being applied. |
Properties
Name | Description |
---|---|
AllowMultipleOverloads | Determines whether the current InvalidateCacheAttribute can match several overloads of the methods.
The default value is |
Methods
Name | Description |
---|---|
CompileTimeValidate(MethodBase) | |
OnInvoke(MethodInterceptionArgs) | |
OnInvokeAsync(MethodInterceptionArgs) | |
RuntimeInitialize(MethodBase) |