Marks a class as a Metalama plug-in that extends the compiler pipeline.
Namespace: Metalama.Framework.Engine
Assembly: Metalama.Framework.Sdk.dll
Syntax
[AttributeUsage(AttributeTargets.Class)]
[CompileTime]
public sealed class MetalamaPlugInAttribute : AttributeRemarks
Classes marked with this attribute are discovered and instantiated by Metalama during compilation. The class must have a public parameterless constructor.
This attribute is used for:
- IAspectWeaver implementations: Low-level aspect weavers that perform Roslyn-based transformations.
- Custom metric providers: Classes deriving from
MetricProvider<T>orSyntaxMetricProvider<T>. - IProjectService implementations: Project-scoped services that are automatically added to the service collection.
Plug-in classes must be in an assembly that references Metalama.Framework.Sdk with PrivateAssets="all".
Constructors
| Name | Description |
|---|---|
| MetalamaPlugInAttribute() |