Namespace: Metalama.Framework.Aspects
Assembly: Metalama.Framework.dll
Syntax
[CompileTime]
public static class AspectQueryExtensions
Methods
Name | Description |
---|---|
AddAspectIfEligible<TAspect>(IQuery<IDeclaration>, EligibleScenarios) | Adds an aspect to the current set of declarations using the default constructor of the aspect type. This method
does not verify the eligibility of the declaration for the aspect unless you specify the |
AddAspectIfEligible<TDeclaration>(IQuery<TDeclaration>, Type, Func<TDeclaration, IAspect>, EligibleScenarios) | Adds an aspect to the current set of declarations but only if the aspect is eligible for the declaration. This overload is non-generic. |
AddAspectIfEligible<TDeclaration, TAspect>(IQuery<TDeclaration>, Func<TDeclaration, TAspect>, EligibleScenarios) | Adds an aspect to the current set of declarations but only if the aspect is eligible for the declaration. |
AddAspectIfEligible<TDeclaration, TTag>(ITaggedQuery<TDeclaration, TTag>, Type, Func<TDeclaration, TTag, IAspect>, EligibleScenarios) | Adds an aspect to the current set of declarations but only if the aspect is eligible for the declaration. This overload is non-generic. |
AddAspectIfEligible<TDeclaration, TTag, TAspect>(ITaggedQuery<TDeclaration, TTag>, Func<TDeclaration, TTag, TAspect>, EligibleScenarios) | Adds an aspect to the current set of declarations but only if the aspect is eligible for the declaration. |
AddAspect<TAspect>(IQuery<IDeclaration>) | Adds an aspect to the current set of declarations or throws an exception if the aspect is not eligible for the aspect. This overload creates a new instance of the aspect class for each target declaration. |
AddAspect<TDeclaration>(IQuery<TDeclaration>, Type, Func<TDeclaration, IAspect>) | Adds a aspect to the current set of declarations or throws an exception if the aspect is not eligible for the aspect. This overload is non-generic. |
AddAspect<TDeclaration, TAspect>(IQuery<TDeclaration>, Func<TDeclaration, TAspect>) | Adds an aspect to the current set of declarations or throws an exception if the aspect is not eligible for the aspect. |
AddAspect<TDeclaration, TTag>(ITaggedQuery<TDeclaration, TTag>, Type, Func<TDeclaration, TTag, IAspect>) | Adds a aspect to the current set of declarations or throws an exception if the aspect is not eligible for the aspect. This overload is non-generic. |
AddAspect<TDeclaration, TTag, TAspect>(ITaggedQuery<TDeclaration, TTag>, Func<TDeclaration, TTag, TAspect>) | Adds an aspect to the current set of declarations or throws an exception if the aspect is not eligible for the aspect. |
RequireAspect<TAspect>(IQuery<IDeclaration>) | Requires an instance of a specified aspect type to be present on a specified declaration. If the aspect is not present, this method adds a new instance of the aspect by using the default aspect constructor. |