PostSharp.Aspects Namespace

AdviceArgs Class

Arguments Class

Aspect Class

AspectDescriptionAttribute Class

AspectInfo Class

AspectInstance Class

AspectSpecification Class

AspectUtilities Class

AssemblyLevelAspect Class

CompositionAspect Class

ConstructorDepth Structure

CustomAttributeIntroductionAspect Class

EventInterceptionArgs Class

EventInterceptionAspect Class

EventLevelAspect Class

FieldLevelAspect Class

FlowBehavior Enumeration

IAspect Interface

IAspectBuildSemantics Interface

IAspectInstance Interface

IAspectProvider Interface

IAspectRepositoryService Interface

IAssemblyLevelAspect Interface

IAssemblyLevelAspectBuildSemantics Interface

ICloneAwareAspect Interface

ICompositionAspect Interface

ICustomAttributeIntroductionAspect Interface

IEventBinding Interface

IEventInterceptionAspect Interface

IEventLevelAspect Interface

IEventLevelAspectBuildSemantics Interface

IFieldLevelAspect Interface

IFieldLevelAspectBuildSemantics Interface

IInstanceScopedAspect Interface

ILocationBinding Interface

ILocationBinding(T) Interface

ILocationBindingAction(TPayload) Interface

ILocationInterceptionArgs Interface

ILocationInterceptionArgs(T) Interface

ILocationInterceptionArgsAction(TPayload) Interface

ILocationInterceptionAspect Interface

ILocationLevelAspect Interface

ILocationLevelAspectBuildSemantics Interface

ILocationValidationAspect Interface

ILocationValidationAspect(T) Interface

IManagedResourceIntroductionAspect Interface

IMethodBinding Interface

IMethodInterceptionAspect Interface

IMethodLevelAspect Interface

IMethodLevelAspectBuildSemantics Interface

InstanceLevelAspect Class

IOnExceptionAspect Interface

IOnMethodBoundaryAspect Interface

IOnStateMachineBoundaryAspect Interface

ITypeLevelAspect Interface

ITypeLevelAspectBuildSemantics Interface

LinesOfCodeAvoidedAttribute Class

LocationBindingExtensions Class

LocationInterceptionArgs Class

LocationInterceptionAspect Class

LocationLevelAspect Class

LocationValidationContext Enumeration

ManagedResourceIntroductionAspect Class

MethodExecutionArgs Class

MethodImplementationAspect Class

MethodInterceptionArgs Class

MethodInterceptionAspect Class

MethodLevelAspect Class

ModuleInitializerAttribute Class

OnExceptionAspect Class

OnMethodBoundaryAspect Class

TypeIdentity Class

TypeLevelAspect Class

This is the online documentation for PostSharp 4.3.
Download PDF or CHM. Go to v4.3 or v5.0
PostSharp.Aspects Namespace
The PostSharp.Aspects namespace provides the primitives of the PostSharp aspect-oriented framework, such as abstract aspect classes, aspect interfaces, and advise argument classes.
Classes
  ClassDescription
Public classAdviceArgs
Base class for arguments of all advices.
Public classArguments
Encapsulation of method arguments.
Public classAspect
Base class for all aspects that are declared using multicast custom attributes (MulticastAttribute).
Public classAspectDescriptionAttribute
Custom attribute that, when applied to an aspect class, specifies a human-readable description of the aspect that can be displayed in PostSharp Tools for Visual Studio.
Public classAspectInfo
Reserved for future usage.
Public classAspectInstance
Completely specifies an aspect instance, including its target code element. An AspectInstance contains either the aspect instance itself (Aspect property), either information allowing to construct the aspect (AspectConstruction) and configure the weaver (AspectConfiguration).
Public classAspectSpecification
Completely specifies an aspect instance (but not its target). An AspectSpecification either the aspect instance itself (Aspect property), either information allowing to construct the aspect (AspectConstruction) and configure the weaver (AspectConfiguration).
Public classAspectUtilities
Utility methods for PostSharp.Aspects.
Public classAssemblyLevelAspect
Base class for all aspects applied on assemblies.
Public classCompositionAspect
Aspect that, when applied on a type, introduces one or many new interfaces into that type.
Public classCustomAttributeIntroductionAspect
Aspect that, when applied to a target, adds a custom attribute to this target.
Public classEventInterceptionArgs
Arguments of handlers of aspects of the type EventInterceptionAspect.
Public classEventInterceptionAspect
Aspect that, when applied on an event, intercepts invocations of its semantics Add (OnAddHandler(EventInterceptionArgs)), Remove (OnRemoveHandler(EventInterceptionArgs)) and Invoke (OnInvokeHandler(EventInterceptionArgs)).
Public classEventLevelAspect
Base class for all aspects applied on events.
Public classFieldLevelAspect
Base class for all aspects applied on fields.
Public classInstanceLevelAspect
Base class for aspects applied on types, but having the same lifetime as instances of the type to which they are applied.
Public classLinesOfCodeAvoidedAttribute
Custom attribute that, when applied to an aspect class, specifies how many manual lines of code are avoided every time the aspect is being used.
Public classLocationBindingExtensions
Extension methods for the ILocationBinding interface.
Public classLocationInterceptionArgs
Arguments of advices of aspect type LocationInterceptionAspect.
Public classLocationInterceptionAspect
Aspect that, when applied on a location (field or property), intercepts invocations of the Get (OnGetValue(LocationInterceptionArgs)) and Set (OnSetValue(LocationInterceptionArgs)) semantics.
Public classLocationLevelAspect
Base class for aspects defined in fields, properties, or parameters.
Public classManagedResourceIntroductionAspect
Aspect that, when applied to an assembly, adds a custom attribute to this assembly.
Public classMethodExecutionArgs
Arguments of advices of aspects of type OnMethodBoundaryAspect and OnExceptionAspect
Public classMethodImplementationAspect
Aspect that, when applied on an abstract or extern method, creates an implementation for this method.
Public classMethodInterceptionArgs
Arguments of advices of aspect type MethodInterceptionAspect.
Public classMethodInterceptionAspect
Aspect that, when applied on a method, intercepts invocations of this method.
Public classMethodLevelAspect
Base class for all aspects applied on methods.
Public classModuleInitializerAttribute
Custom attribute that, when added to a static method, causes the method to be executed immediately after the assembly is loaded by the CLR. The target method must be public, parameterless, void, and non-generic.
Public classOnExceptionAspect
Aspect that, when applied to a method, defines an exception handler around the whole method and calls a custom method in this exception handler.
Public classOnMethodBoundaryAspect
Aspect that, when applied to a method defined in the current assembly, inserts a piece of code before and after the body of these methods.
Public classTypeIdentity
Wraps a Type or a type name.
Public classTypeLevelAspect
Base class for all aspects applied on types.
Structures
  StructureDescription
Public structureConstructorDepth
System type used in the implementation of the OnInstanceConstructedAdvice. Do not use in user code.
Public structureInstanceCredentialsObsolete.
Credentials that give access to 'protected' semantics.
Interfaces
  InterfaceDescription
Public interfaceIAspect
Base interface for run-time semantics of all aspects.
Public interfaceIAspectBuildSemantics
Compile-time semantics of IAspect.
Public interfaceIAspectInstance
Represents an instance of an aspect applied to a declaration.
Public interfaceIAspectProvider
Interface that, when implemented by an aspect class, allows aspect instances to provide other aspects to the weaver.
Public interfaceIAspectRepositoryService
Service that allows to determine which aspects have been applied to a given declaration, whether declaratively through custom attributes or MulticastAttribute, or programmatically using IAspectProvider.
Public interfaceIAssemblyLevelAspect
Runtime semantics of aspects applied at assembly level.
Public interfaceIAssemblyLevelAspectBuildSemantics
Build-time semantics of aspects applied at assembly level.
Public interfaceICloneAwareAspect
Defines the semantics of aspects that require to be notified after a target object is cloned using MemberwiseClone().
Public interfaceIComposed<T>Obsolete.
Interface exposing the implementation of another interface introduced by a CompositionAspect.
Public interfaceICompositionAspect
Defines the semantics of an aspect that, when applied on a type, introduce one or many new interfaces into that type, and let these interfaces be implemented by an object created at runtime.
Public interfaceICustomAttributeIntroductionAspect
Semantics of an aspect that, when applied to a target, adds a custom attribute to this target.
Public interfaceIEventBinding
Interface through which an event-level aspect or advice can invoke the next node in the chain of invocation.
Public interfaceIEventInterceptionAspect
Runtime semantics of an aspect that, when applied on an event, intercepts invocations of its semantics Add (OnAddHandler(EventInterceptionArgs)), Remove (OnRemoveHandler(EventInterceptionArgs)) and Invoke (OnInvokeHandler(EventInterceptionArgs)) semantics.
Public interfaceIEventLevelAspect
Runtime semantics of aspects that can be applied on events.
Public interfaceIEventLevelAspectBuildSemantics
Build-time semantics of aspects that can be applied on events.
Public interfaceIFieldLevelAspect
Run-time semantics of aspects applied to fields.
Public interfaceIFieldLevelAspectBuildSemantics
Compile-time semantics of IFieldLevelAspect.
Public interfaceIInstanceScopedAspect
Runtime semantics of aspects that have the same lifetime as instance of types to which their are applied (or instance of the declaring type of members to which they are applied).
Public interfaceILocationBinding
Interface through which a field- or property-level aspect or advice can invoke the next node in the chain of invocation.
Public interfaceILocationBinding<T>
A strongly-typed variant for ILocationBinding.
Public interfaceILocationBindingAction<TPayload>
Exposes an Execute<TValue>(ILocationBinding<TValue>, TPayload) method invoked by the Execute<TPayload>(ILocationBindingAction<TPayload>, TPayload) method, which allows to execute strongly-typed operations and avoid boxing required by the weakly typed ILocationBinding interface.
Public interfaceILocationInterceptionArgs
An interface for LocationInterceptionArgs.
Public interfaceILocationInterceptionArgs<T>
A strongly-typed specialization of the ILocationInterceptionArgs interface.
Public interfaceILocationInterceptionArgsAction<TPayload>
Exposes an Execute<TValue>(ILocationInterceptionArgs<TValue>, TPayload) method invoked by the Execute<TPayload>(ILocationInterceptionArgsAction<TPayload>, TPayload) method, which allows to execute strongly-typed operations and avoid boxing required by the weakly typed ILocationInterceptionArgs interface.
Public interfaceILocationInterceptionAspect
Runtime semantics of an aspect that, when applied on a location (field or property), intercepts invocations of the Get (OnGetValue(LocationInterceptionArgs)) and Set (OnSetValue(LocationInterceptionArgs)) semantics.
Public interfaceILocationLevelAspect
Runtime semantics of aspects defined on a field, property, or parameter.
Public interfaceILocationLevelAspectBuildSemantics
Compile-time semantics of ILocationLevelAspect.
Public interfaceILocationValidationAspect
Public interfaceILocationValidationAspect<T>
Runtime semantics of an aspect that, when applied on a location (field, property, or parameter), validates the value assigned to this location using method ValidateValue(T, String, LocationKind), and throws the exception returned by this method if any.
Public interfaceIManagedResourceIntroductionAspect
Semantics of an aspect that, when applied to an assembly, adds a managed resource to this assembly.
Public interfaceIMethodBinding
Interface through which a method-level aspect or advice can invoke the next node in the chain of invocation.
Public interfaceIMethodInterceptionAspect
Runtime semantics of an aspect that, when applied on a method, intercepts invocations of this method.
Public interfaceIMethodLevelAspect
Runtime semantics of aspects applied to methods.
Public interfaceIMethodLevelAspectBuildSemantics
Compile-time semantics of IMethodLevelAspect.
Public interfaceIOnExceptionAspect
Runtime semantics of an aspect that, when applied on a method, defines an exception handler around the whole method body and let the implementation of this interface handle the exception.
Public interfaceIOnMethodBoundaryAspect
Runtime semantics of OnMethodBoundaryAspect.
Public interfaceIOnStateMachineBoundaryAspect
Extends the IOnMethodBoundaryAspect interface with two advises to be applied on state machines.
Public interfaceIProtectedInterface<T>Obsolete.
Gives access to a 'protected' interface, typically introduced by a CompositionAspect or a IntroduceInterfaceAttribute
Public interfaceITypeLevelAspect
Run-time semantics of aspects applied to types.
Public interfaceITypeLevelAspectBuildSemantics
Compile-time semantics of ITypeLevelAspect.
Enumerations
  EnumerationDescription
Public enumerationFlowBehavior
Enumerates the possible behaviors of the calling method after the calling method has returned.
Public enumerationLocationValidationContext
Enumerates the possible contexts in which the location validation advices can be invoked.