Class TransformerContext
Context passed to a source transformer when Execute(TransformerContext) is called. The implementation can modify the compilation using the methods AddSyntaxTrees(SyntaxTree[]), ReplaceSyntaxTree(SyntaxTree, SyntaxTree) or AddResources(ManagedResource[]). It can report a diagnostic using ReportDiagnostic(Diagnostic) or suppress diagnostics using RegisterDiagnosticFilter(SuppressionDescriptor, Action<DiagnosticFilteringRequest>).
Namespace: Metalama.Compiler
Assembly: Metalama.Compiler.Interface.dll
Syntax
public sealed class TransformerContext : Object
Properties
Name | Description |
---|---|
AnalyzerConfigOptionsProvider | Gets the AnalyzerConfigOptionsProvider, which allows to access |
Compilation | Gets or sets the Compilation. Transformers typically replace the value of this property. |
Options | Gets options of the current TransformerContext. |
Resources | Gets the list of managed resources. |
Services | Gets the services initialized by the compiler. This property can be |