Table of Contents

Method HasCodeFixes

Namespace
Alternet.Syntax.Parsers.Roslyn
Assembly
Alternet.Syntax.Parsers.Roslyn.v9.dll

HasCodeFixes(Document, TextSpan, Diagnostic, bool, CancellationToken)

Indicates whether the document has any code fixes for the specified text span.

public Task<bool> HasCodeFixes(Document document, TextSpan textSpan, Diagnostic diagnostic, bool allDocuments, CancellationToken cancellationToken)

Parameters

document Document

The document to fix.

textSpan TextSpan

Text span within the document.

diagnostic Diagnostic

Diagnostics to fix. All the diagnostics must have the same span.

allDocuments bool

Indicates whether all documents should be processed.

cancellationToken CancellationToken

Cancellation token.

Returns

Task<bool>

True if there is at least one fix for the specified span; otherwise, false.