A base aspect that overrides the implementation of a method.
Namespace: Metalama.Framework.Aspects
Assembly: Metalama.Framework.dll
Syntax
[AttributeUsage(AttributeTargets.Method)]
public abstract class OverrideMethodAspect : MethodAspect, IAspect<IMethod>, IAspect, ICompileTimeSerializable, ITemplateProvider, IEligible<IMethod>
Constructors
Name | Description |
---|---|
OverrideMethodAspect() |
Properties
Name | Description |
---|---|
UseAsyncTemplateForAnyAwaitable | Gets or sets a value indicating whether the OverrideEnumerableMethod(), OverrideEnumeratorMethod(),
|
UseEnumerableTemplateForAnyEnumerable | Gets or sets a value indicating whether the OverrideAsyncMethod() template must be applied to all methods returning an awaitable
type (including |
Methods
Name | Description |
---|---|
BuildAspect(IAspectBuilder<IMethod>) | Initializes the aspect. The implementation must add advice, child aspects and validators
using the |
BuildEligibility(IEligibilityBuilder<IMethod>) | Configures the eligibility of the aspect or attribute. Implementations are not allowed to reference non-static members. Implementations must call the implementation of the base class if it exists. |
OverrideAsyncEnumerableMethod() | |
OverrideAsyncEnumeratorMethod() | |
OverrideAsyncMethod() | |
OverrideEnumerableMethod() | |
OverrideEnumeratorMethod() | |
OverrideMethod() | Default template of the new method implementation. |