Open sandboxFocus

Interface ISdkCodeActionContext

Extends the ICodeActionContext interface with members that can be used by custom implementations of code fixes using the SDK.

Namespace: Metalama.Framework.Engine.CodeFixes
Assembly: Metalama.Framework.Sdk.dll
Syntax
public interface ISdkCodeActionContext : ICodeActionContext

Properties

Name Description
Compilation

Gets the current compilation. It must be updated using UpdateTree(SyntaxTree, SyntaxTree) or UpdateCompilation(IPartialCompilation).

Methods

Name Description
UpdateCompilation(IPartialCompilation)

Applies the modifications accumulated in a partial compilation, i.e. those done by WithSyntaxTreeTransformations(IReadOnlyList<SyntaxTreeTransformation>?).

UpdateTree(SyntaxNode, SyntaxTree)

Updates a SyntaxTree by passing the new root syntax node.

UpdateTree(SyntaxTree, SyntaxTree)

Updates a SyntaxTree.

Extension Methods