1 type derived from Location
Microsoft.CodeAnalysis.LanguageServer.Protocol (1)
Protocol\Extensions\VSLocation.cs (1)
12internal class VSLocation : Location
6 instantiations of Location
Microsoft.CodeAnalysis.LanguageServer.Protocol (6)
Extensions\ProtocolConversions.cs (2)
483return new LSP.Location 513var location = new LSP.Location
Extensions\ProtocolConversions.Diagnostics.cs (1)
82Location = new LSP.Location
Handler\Definitions\AbstractGoToDefinitionHandler.cs (1)
87locations.Add(new LSP.Location
Handler\References\FindUsagesLSPContext.cs (1)
279return new LSP.Location
Handler\Symbols\DocumentSymbolsHandler.cs (1)
96var location = new LSP.Location()
71 references to Location
Microsoft.CodeAnalysis.LanguageServer.Protocol (70)
Extensions\ProtocolConversions.cs (6)
355public static Task<LSP.Location?> DocumentSpanToLocationAsync(DocumentSpan documentSpan, CancellationToken cancellationToken) 441public static Task<LSP.Location?> TextSpanToLocationAsync( 450public static async Task<LSP.Location?> TextSpanToLocationAsync( 489static async Task<LSP.Location> ConvertTextSpanToLocationAsync( 511static LSP.Location ConvertTextSpanWithTextToLocation(TextSpan span, SourceText text, Uri documentUri) 513var location = new LSP.Location
Handler\Definitions\AbstractGoToDefinitionHandler.cs (6)
20internal abstract class AbstractGoToDefinitionHandler : ILspServiceDocumentRequestHandler<LSP.TextDocumentPositionParams, LSP.Location[]?> 36public abstract Task<LSP.Location[]?> HandleRequestAsync(TextDocumentPositionParams request, RequestContext context, CancellationToken cancellationToken); 38protected Task<LSP.Location[]?> GetDefinitionAsync(LSP.TextDocumentPositionParams request, bool typeOnly, RequestContext context, CancellationToken cancellationToken) 43return SpecializedTasks.Null<LSP.Location[]>(); 50internal static async Task<LSP.Location[]?> GetDefinitionsAsync(IGlobalOptionService globalOptions, IMetadataAsSourceFileService? metadataAsSourceFileService, Workspace workspace, Document document, bool typeOnly, LinePosition linePosition, CancellationToken cancellationToken) 52var locations = ArrayBuilder<LSP.Location>.GetInstance();
Handler\Definitions\GoToDefinitionHandler.cs (1)
27public override Task<LSP.Location[]?> HandleRequestAsync(LSP.TextDocumentPositionParams request, RequestContext context, CancellationToken cancellationToken)
Handler\Definitions\GoToTypeDefinitionHandler.cs (1)
27public override Task<LSP.Location[]?> HandleRequestAsync(LSP.TextDocumentPositionParams request, RequestContext context, CancellationToken cancellationToken)
Handler\MapCode\MapCodeHandler.cs (2)
116Document document, TextDocumentIdentifier textDocumentIdentifier, LSP.Location[][]? focusLocations, CancellationToken cancellationToken) 125foreach (var location in locationsOfSamePriority)
Handler\References\FindAllReferencesHandler.cs (2)
25internal sealed class FindAllReferencesHandler : ILspServiceDocumentRequestHandler<VSInternalReferenceParams, LSP.SumType<VSInternalReferenceItem, LSP.Location>[]?> 48public async Task<LSP.SumType<VSInternalReferenceItem, LSP.Location>[]?> HandleRequestAsync(
Handler\References\FindImplementationsHandler.cs (4)
21internal sealed class FindImplementationsHandler : ILspServiceDocumentRequestHandler<LSP.TextDocumentPositionParams, LSP.Location[]> 37public Task<LSP.Location[]> HandleRequestAsync(LSP.TextDocumentPositionParams request, RequestContext context, CancellationToken cancellationToken) 47internal static async Task<LSP.Location[]> FindImplementationsAsync(Document document, LinePosition linePosition, OptionsProvider<ClassificationOptions> classificationOptions, bool supportsVisualStudioExtensions, CancellationToken cancellationToken) 49var locations = ArrayBuilder<LSP.Location>.GetInstance();
Handler\References\FindUsagesLSPContext.cs (11)
32private readonly IProgress<SumType<VSInternalReferenceItem, LSP.Location>[]> _progress; 53private readonly Dictionary<int, SumType<VSInternalReferenceItem, LSP.Location>> _definitionsWithoutReference = []; 70private readonly AsyncBatchingWorkQueue<SumType<VSInternalReferenceItem, LSP.Location>> _workQueue; 76IProgress<SumType<VSInternalReferenceItem, LSP.Location>[]> progress, 93_workQueue = new AsyncBatchingWorkQueue<SumType<VSInternalReferenceItem, LSP.Location>>( 177private async Task<SumType<VSInternalReferenceItem, LSP.Location>?> GenerateVSReferenceItemAsync( 194var location = await ComputeLocationAsync(documentSpan, cancellationToken).ConfigureAwait(false); 201private static SumType<VSInternalReferenceItem, LSP.Location>? CreateVsReference( 210LSP.Location? location) 247private async Task<LSP.Location?> ComputeLocationAsync(DocumentSpan? documentSpan, CancellationToken cancellationToken) 367private ValueTask ReportReferencesAsync(ImmutableSegmentedList<SumType<VSInternalReferenceItem, LSP.Location>> referencesToReport, CancellationToken cancellationToken)
Handler\Symbols\DocumentSymbolsHandler.cs (1)
96var location = new LSP.Location()
Handler\Symbols\SymbolInformationFactory.cs (1)
12public static SymbolInformation Create(string name, string? containerName, LSP.SymbolKind kind, LSP.Location location, Glyph glyph, bool supportsVSExtensions)
Protocol\DiagnosticRelatedInformation.cs (1)
22public Location Location { get; set; }
Protocol\Extensions\Converters\VSExtensionUtilities.cs (1)
35TryAddConverter<Location, VSLocation>();
Protocol\Extensions\VSLocation.cs (1)
10/// <see cref="VSLocation"/> extends <see cref="Location"/> providing additional properties used by Visual Studio.
Protocol\InlayHintLabelPart.cs (1)
59public Location? Location
Protocol\Internal\Converters\VSInternalExtensionUtilities.cs (1)
42AddOrReplaceConverter<Location, VSInternalLocation>();
Protocol\Internal\VSInternalLocation.cs (1)
12/// Extension class for <see cref="Protocol.Location"/>. Used to relay reference text information with colorization.
Protocol\Internal\VSInternalMapCodeMapping.cs (1)
39public Location[][]? FocusLocations
Protocol\Internal\VSInternalReferenceItem.cs (1)
34public Location Location
Protocol\Internal\VSInternalReferenceParams.cs (2)
13internal class VSInternalReferenceParams : ReferenceParams, IPartialResultParams<SumType<VSInternalReferenceItem, Location>[]> 30public new IProgress<SumType<VSInternalReferenceItem, Location>[]>? PartialResultToken { get; set; }
Protocol\Location.cs (3)
16internal class Location : IEquatable<Location> 42return this.Equals(obj as Location); 46public bool Equals(Location? other)
Protocol\Methods.Navigation.cs (9)
31public static readonly LspRequest<DeclarationParams, SumType<Location, Location[], LocationLink[]>?> TextDocumentDeclaration = new(TextDocumentDeclarationName); 50public static readonly LspRequest<DefinitionParams, SumType<Location, Location[], LocationLink[]>?> TextDocumentDefinition = new(TextDocumentDefinitionName); 69public static readonly LspRequest<TypeDefinitionParams, SumType<Location, Location[], LocationLink[]>?> TextDocumentTypeDefinition = new(TextDocumentTypeDefinitionName); 88public static readonly LspRequest<ImplementationParams, SumType<Location, Location[], LocationLink[]>?> TextDocumentImplementation = new(TextDocumentImplementationName); 104public static readonly LspRequest<ReferenceParams, Location[]?> TextDocumentReferences = new(TextDocumentReferencesName);
Protocol\Navigation\DeclarationParams.cs (2)
16internal class DeclarationParams : TextDocumentPositionParams, IWorkDoneProgressParams, IPartialResultParams<SumType<Location[], LocationLink[]>> 29public IProgress<SumType<Location[], LocationLink[]>>? PartialResultToken { get; set; }
Protocol\Navigation\DefinitionParams.cs (2)
16internal class DefinitionParams : TextDocumentPositionParams, IWorkDoneProgressParams, IPartialResultParams<SumType<Location[], LocationLink[]>> 29public IProgress<SumType<Location[], LocationLink[]>>? PartialResultToken { get; set; }
Protocol\Navigation\ImplementationParams.cs (2)
16internal class ImplementationParams : TextDocumentPositionParams, IWorkDoneProgressParams, IPartialResultParams<SumType<Location[], LocationLink[]>> 29public IProgress<SumType<Location[], LocationLink[]>>? PartialResultToken { get; set; }
Protocol\Navigation\ReferenceParams.cs (2)
16internal class ReferenceParams : TextDocumentPositionParams, IWorkDoneProgressParams, IPartialResultParams<Location[]> 33public IProgress<Location[]>? PartialResultToken { get; set; }
Protocol\Navigation\TypeDefinitionParams.cs (2)
16internal class TypeDefinitionParams : TextDocumentPositionParams, IWorkDoneProgressParams, IPartialResultParams<SumType<Location[], LocationLink[]>> 29public IProgress<SumType<Location[], LocationLink[]>>? PartialResultToken { get; set; }
Protocol\SymbolInformation.cs (2)
82public Location Location 122&& EqualityComparer<Location>.Default.Equals(this.Location, other.Location)
Protocol\WorkspaceSymbol.cs (1)
57public SumType<Location, WorkspaceSymbolLocation> Location { get; init; }
Microsoft.CodeAnalysis.LanguageServer.Protocol.UnitTests (1)
Completion\CompletionTests.cs (1)
1299var triggerLocation = GetLocationPlusOne(secondCaretLocation);