PostSharpAPI ReferencePost­Sharp.​Patterns.​Dynamic­AdvisingDynamic­Advice
Open sandboxFocus

DynamicAdvice Class

A base implementation of the IDynamicAdvice interface.

Namespace: PostSharp.Patterns.DynamicAdvising
Assembly: PostSharp.Patterns.Common.dll
Syntax
public abstract class DynamicAdvice : Object, IDynamicAdvice, IDynamicInterfaceImplementation

Constructors

Name Description
DynamicAdvice(IQueryInterface)

Initializes a new DynamicAdvice.

Properties

Name Description
AdvisedObject

Gets the advised object.

Identity

Gets the type identity of the advice, which should correspond to the first parameter of the Advise(Type, Func<IQueryInterface, IDynamicAdvice>) method. This is typically the generic type definition of the advice

Order

Gets the execution order of the dynamic advice. See DynamicAdviceOrder.

Methods

Name Description
Dispose()

Disposes the current advice. // We don't use IDisposable so that advises are not be cast to IDisposable by default.

Initialize(IQueryInterface, AdviceEnumerator<IDynamicAdvice>)

Initializes the current advice.

QueryInterface<TInterface>()

Gets the implementation of an interface.

Explicit Interface Implementations

Name Description
IDynamicInterfaceImplementation.AdvisedObject

Gets the principal object for which the current object is an indirect interface implementation.