55 references to ParsedUri
Microsoft.CodeAnalysis.LanguageServer (2)
HostWorkspace\AutoLoadProjectsInitializer.cs (2)
137if (folder.DocumentUri.ParsedUri is null || folder.DocumentUri.ParsedUri.Scheme != Uri.UriSchemeFile)
Microsoft.CodeAnalysis.LanguageServer.Protocol (32)
Extensions\Extensions.cs (10)
64Contract.ThrowIfNull(documentUri.ParsedUri, $"URI {documentUri} could not be parsed"); 65return documentUri.ParsedUri; 70return uri.ParsedUri?.IsFile == true ? uri.ParsedUri.LocalPath : uri.UriString; 97if (documentUri.ParsedUri is null) 105if (documentUri.ParsedUri.Scheme != SourceGeneratedDocumentUri.Scheme) 111var documentId = SourceGeneratedDocumentUri.DeserializeIdentity(solution, documentUri.ParsedUri)?.DocumentId; 140if (documentUri.ParsedUri?.Scheme == SourceGeneratedDocumentUri.Scheme) 200if (projectIdentifier.DocumentUri.ParsedUri is null) 205var projects = solution.Projects.WhereAsArray(project => project.FilePath == projectIdentifier.DocumentUri.ParsedUri.LocalPath);
Handler\InitializeManager.cs (1)
42if (workspaceFolder.DocumentUri.ParsedUri is not { } parsedUri)
Handler\TextDocumentContent\AbstractTextDocumentContentRefreshQueue.cs (1)
98if (uri.ParsedUri is { } parsedUri && parsedUri.Scheme == Scheme)
Handler\TextDocumentContent\TextDocumentContentHandler.cs (1)
31var scheme = request.Uri.ParsedUri?.Scheme;
LanguageInfoProvider.cs (4)
51if (requestUri.ParsedUri is not null && (requestUri.ParsedUri.IsFile || requestUri.ParsedUri.IsAbsoluteUri)) 53var localPath = requestUri.ParsedUri.LocalPath;
Protocol\DocumentUri.cs (12)
79if (otherUri.ParsedUri is null || this.ParsedUri is null) 96return (this.ParsedUri.IsAbsoluteUri && otherUri.ParsedUri.IsAbsoluteUri && this.ParsedUri.AbsoluteUri == otherUri.ParsedUri.AbsoluteUri) || 97Equals(this.ParsedUri, otherUri.ParsedUri); 103if (this.ParsedUri is null) 117return this.ParsedUri.IsAbsoluteUri 118? StringComparer.OrdinalIgnoreCase.GetHashCode(this.ParsedUri.AbsoluteUri) 119: this.ParsedUri.GetHashCode();
Workspaces\LspWorkspaceManager.cs (3)
111if (uri.ParsedUri is null) 375_trackedDocuments.Keys.Where(static trackedDocument => trackedDocument.ParsedUri?.Scheme == SourceGeneratedDocumentUri.Scheme) 377.Select(uri => (identity: SourceGeneratedDocumentUri.DeserializeIdentity(workspaceCurrentSolution, uri.ParsedUri!), _trackedDocuments[uri].SourceText))
Microsoft.CodeAnalysis.LanguageServer.Protocol.UnitTests (11)
Diagnostics\PullDiagnosticTests.cs (6)
84Assert.NotNull(results.Single().Diagnostics!.Single().CodeDescription!.Href.ParsedUri); 629Assert.NotNull(results.Single().Diagnostics!.Single().CodeDescription!.Href.ParsedUri); 1035Assert.NotNull(results.Single().Diagnostics!.Single().CodeDescription!.Href.ParsedUri); 1527Assert.True(results[0].Uri.ParsedUri!.AbsolutePath.EndsWith("file.cs")); 1532Assert.True(results[1].Uri.ParsedUri!.AbsolutePath.EndsWith("GeneratedFile.cs")); 1535Assert.True(results[2].Uri.ParsedUri!.AbsolutePath.EndsWith("Assembly1.csproj"));
ProtocolConversionsTests.cs (2)
149Assert.Null(uri.ParsedUri); 161Assert.Null(uri.ParsedUri);
UriTests.cs (3)
342Assert.Null(invalidUri.ParsedUri); 364Assert.Null(unparseableUri.ParsedUri); 387Assert.Null(unparseableUri.ParsedUri);
Microsoft.CodeAnalysis.Razor.Workspaces (1)
UriExtensions.cs (1)
15=> uri.ParsedUri.AssumeNotNull();
Microsoft.VisualStudio.LanguageServices.Razor (4)
LanguageClient\Cohost\CohostTextPresentationEndpoint.cs (1)
71if (edit.TextDocument.DocumentUri.ParsedUri is { } uri &&
LanguageClient\Cohost\CohostUriPresentationEndpoint.cs (1)
112if (edit.TextDocument.DocumentUri.ParsedUri is { } uri &&
src\Razor\src\Razor\src\Microsoft.CodeAnalysis.Razor.CohostingShared\IncompatibleProjectService.cs (1)
33if (textDocumentIdentifier?.DocumentUri.ParsedUri is not Uri uri)
src\Razor\src\Razor\src\Microsoft.CodeAnalysis.Razor.CohostingShared\Navigation\CohostGoToImplementationEndpoint.cs (1)
120if (location?.DocumentUri.ParsedUri is { } uri &&
Microsoft.VisualStudio.LanguageServices.Razor.UnitTests (1)
src\Razor\src\Razor\test\Microsoft.CodeAnalysis.Razor.CohostingShared.UnitTests\Endpoints\CohostTypeHierarchyEndpointTest.cs (1)
210Assert.Equal(expectedItem.Uri, item.Uri.ParsedUri);
Microsoft.VisualStudioCode.RazorExtension (3)
Endpoints\RazorDocumentClosedEndpoint.cs (1)
37if (textDocument.DocumentUri.ParsedUri is Uri parsedUri)
src\Razor\src\Razor\src\Microsoft.CodeAnalysis.Razor.CohostingShared\IncompatibleProjectService.cs (1)
33if (textDocumentIdentifier?.DocumentUri.ParsedUri is not Uri uri)
src\Razor\src\Razor\src\Microsoft.CodeAnalysis.Razor.CohostingShared\Navigation\CohostGoToImplementationEndpoint.cs (1)
120if (location?.DocumentUri.ParsedUri is { } uri &&
Microsoft.VisualStudioCode.RazorExtension.UnitTests (1)
src\Razor\src\Razor\test\Microsoft.CodeAnalysis.Razor.CohostingShared.UnitTests\Endpoints\CohostTypeHierarchyEndpointTest.cs (1)
210Assert.Equal(expectedItem.Uri, item.Uri.ParsedUri);