Metalama//API Documentation/Aspect API/Metalama.​Framework.​Aspects/IAspect­Receiver<TDeclaration>/Select
Open sandboxFocus

Method Select

Select<TMember>(Func<TDeclaration, TMember>)

Selects a member or the parent of the target declaration of the current aspect or fabric with the purpose of adding aspects, annotations or validators to them using e.g. AddAspectIfEligible<TAspect>(EligibleScenarios). Validate(ValidatorDelegate<DeclarationValidationContext>) or ValidateReferences(ValidatorDelegate<ReferenceValidationContext>, ReferenceKinds).

Declaration
IAspectReceiver<TMember> Select<TMember>(Func<TDeclaration, TMember> selector)
where TMember : class, IDeclaration
Parameters
Type Name Description
Func<TDeclaration, TMember> selector
Returns
Type Description
IAspectReceiver<TMember>
Type Parameters
Name Description
TMember