6 overrides of Path
Microsoft.Analyzers.Extra.Tests (1)
Resources\FileVisibleToAnalyzer.cs (1)
24public override string Path => System.IO.Path.Combine(Directory.GetCurrentDirectory(), _fileName);
Microsoft.Analyzers.Local.Tests (1)
Resources\FileVisibleToAnalyzer.cs (1)
24public override string Path => System.IO.Path.Combine(Directory.GetCurrentDirectory(), _fileName);
Microsoft.CodeAnalysis (1)
AdditionalTextFile.cs (1)
47public override string Path => _sourceFile.Path;
Microsoft.CodeAnalysis.Test.Utilities (2)
Mocks\TestAdditionalText.cs (1)
27public override string Path { get; }
SourceGeneration\TestGenerators.cs (1)
148public override string Path { get; }
System.Windows.Forms.Analyzers.CSharp.Tests (1)
TestAdditionalText.cs (1)
31public override string Path { get; }
73 references to Path
CSharpSyntaxGenerator (2)
SourceGenerator.cs (2)
52var syntaxXmlFiles = context.AdditionalTextsProvider.Where(at => Path.GetFileName(at.Path) == "Syntax.xml").Collect(); 92location: Location.Create(input.Path, span, lineSpan),
Microsoft.Analyzers.Local (1)
ApiLifecycle\ModelLoader.cs (1)
28var filePath = file.Path;
Microsoft.CodeAnalysis (9)
CommandLine\CommonCompiler.cs (1)
1072additionalTextFiles.SelectAsArray(f => analyzerConfigSet.GetOptionsForSourcePath(f.Path));
Compilation\DeterministicKeyBuilder.cs (1)
164WriteFilePath(writer, "fileName", additionalText.Path, pathMap, options);
DiagnosticAnalyzer\AdditionalTextComparer.cs (3)
30if (!PathUtilities.Comparer.Equals(x.Path, y.Path)) 55return Hash.Combine(PathUtilities.Comparer.GetHashCode(obj.Path),
DiagnosticAnalyzer\AnalysisContextInfo.cs (1)
102sb.AppendLine($"{nameof(AdditionalText)}: {_file.Value.AdditionalFile.Path}");
DiagnosticAnalyzer\AnalysisResultBuilder.cs (1)
76var path = file.Path ?? string.Empty;
DiagnosticAnalyzer\AnalysisScope.cs (1)
310!PathUtilities.Comparer.Equals(externalFileLocation.GetLineSpan().Path, filterFile.AdditionalFile.Path))
DiagnosticAnalyzer\AnalyzerExecutor.AnalyzerDiagnosticReporter.cs (1)
135return PathUtilities.Comparer.Equals(_contextFile.Value.AdditionalFile.Path, externalFileLocation.GetLineSpan().Path);
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (3)
Diagnostics\DiagnosticAnalyzerTests.cs (3)
3906Assert.Equal(additionalFile.Path, location.GetLineSpan().Path); 3968d => d.Id == analyzer.Descriptor.Id && PathUtilities.Comparer.Equals(d.Location.GetLineSpan().Path, additionalFile.Path)); 3969if (additionalFile.Path == null)
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (25)
SourceGeneration\GeneratorDriverFuzzTests.cs (5)
87var provider1 = provider.Select((additionalText, _) => (AdditionalText)new InMemoryAdditionalText(additionalText.Path, additionalText.GetText()!.ToString() switch 291editedInputs.Add(new InMemoryAdditionalText(originalInputs[i].Path, getRandomLetter())); 355context.AddSource(((InMemoryAdditionalText)text).Path, ((InMemoryAdditionalText)text).GetText()!.ToString()); 433new InMemoryAdditionalText("{text.Path}", "{text.GetText()}"), 452new InMemoryAdditionalText("{text.Path}", "{text.GetText()}"),
SourceGeneration\GeneratorDriverTests.cs (20)
2707ctx.RegisterSourceOutput(ctx.AdditionalTextsProvider.Select((t, _) => t.Path).WithTrackingName("Paths"), (spc, p) => { }); 2721Assert.Equal("path1.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2737Assert.Equal("path2.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2753Assert.Equal("path3.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2774Assert.Equal("path1.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2790Assert.Equal("path2.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2806Assert.Equal("path3.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2830Assert.Equal("path1.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2846Assert.Equal("path4.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2862Assert.Equal("path3.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2893var paths = texts.Select((t, _) => t?.Path).WithTrackingName("Path"); 2911Assert.Equal("path.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2928Assert.Equal("path.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2949Assert.Equal("path.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2966Assert.Equal("path.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 2991Assert.Equal("path.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 3008Assert.Equal("path.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 3033Assert.Equal("path2.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 3050Assert.Equal("path2.txt", Assert.IsType<InMemoryAdditionalText>(consumedInput.Value).Path); 3312context.AddSource(Path.GetFileName(text.Path), "");
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (1)
CodeFixes\CodeFixServiceTests.cs (1)
927var location = Location.Create(context.AdditionalFile.Path, span, text.Lines.GetLinePositionSpan(span));
Microsoft.CodeAnalysis.EditorFeatures2.UnitTests (1)
Diagnostics\AdditionalFileDiagnosticsTests.vb (1)
83If item.Path.EndsWith("app.config", StringComparison.OrdinalIgnoreCase) Then
Microsoft.CodeAnalysis.Features.Test.Utilities (1)
EditAndContinue\EditAndContinueWorkspaceTestBase.cs (1)
428Generate(additionalFile.GetText()!.ToString(), PathUtilities.GetFileName(additionalFile.Path));
Microsoft.CodeAnalysis.LanguageServer.Protocol.UnitTests (1)
Diagnostics\AdditionalFileDiagnosticsTests.cs (1)
139location: Location.Create(context.AdditionalFile.Path, Text.TextSpan.FromBounds(0, 0), new Text.LinePositionSpan(new Text.LinePosition(0, 0), new Text.LinePosition(0, 0))), "args"));
Microsoft.CodeAnalysis.Test.Utilities (4)
Diagnostics\CommonDiagnosticAnalyzers.cs (2)
2654if (context.AdditionalFile.Path == null) 2660var location = Location.Create(context.AdditionalFile.Path, _diagnosticSpan, text.Lines.GetLinePositionSpan(_diagnosticSpan));
Diagnostics\OptionsDiagnosticAnalyzer.cs (2)
57if (actual.AdditionalFiles[i].Path != expected.AdditionalFiles[i].Path)
Microsoft.CodeAnalysis.VisualBasic.CommandLine.UnitTests (1)
CommandLineTests.vb (1)
11073ReportDiagnostic(additionalFile.Path, context)
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (1)
Diagnostics\DiagnosticAnalyzerTests.vb (1)
1681Assert.Equal(additionalFile.Path, location.GetLineSpan().Path)
Microsoft.CodeAnalysis.Workspaces (4)
Diagnostics\DocumentAnalysisScope.cs (1)
59return TextDocument.Project.AnalyzerOptions.AdditionalFiles.First(a => PathUtilities.Comparer.Equals(a.Path, filePath));
Shared\Extensions\ProjectExtensions.cs (1)
29=> project.GetDocumentIdWithFilePath(additionalText.Path);
Workspace\Solution\ProjectState.cs (2)
399return GetOptionsForSourcePath(GetCache(), textFile.Path); 478return GetOptionsForSourcePath(GetCache(), textFile.Path);
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (1)
GenerateFileForEachAdditionalFileWithContentsCommented.cs (1)
22GetGeneratedFileName(additionalText.Path),
Microsoft.DotNet.CodeAnalysis (4)
Analyzers\BaseAnalyzer.cs (1)
23var configFile = context.Options.AdditionalFiles.FirstOrDefault(file => file.Path.Contains(ConfigFileName));
Analyzers\MembersMustExistAnalyzer.cs (1)
48var additionalAnalyzerFiles = context.Options.AdditionalFiles.Where(af => af.Path.IndexOf(s_analyzerName, 0, StringComparison.OrdinalIgnoreCase) >= 0);
Analyzers\PinvokeAnalyzer.cs (2)
30_allowedPinvokeFile = obj.Options.AdditionalFiles.FirstOrDefault(f => Path.GetFileName(f.Path).IndexOf("PinvokeAnalyzer_", StringComparison.OrdinalIgnoreCase) >= 0); 31_exceptionFile = obj.Options.AdditionalFiles.FirstOrDefault(f => Path.GetFileName(f.Path).IndexOf("PinvokeAnalyzerExceptionList.analyzerdata", StringComparison.OrdinalIgnoreCase) >= 0);
Microsoft.ML.AutoML.SourceGenerator (11)
EstimatorTypeGenerator.cs (3)
25if (context.AdditionalFiles.Where(f => f.Path.Contains("code_gen_flag.json")).First() is AdditionalText text) 35var trainers = context.AdditionalFiles.Where(f => f.Path.Contains("trainer-estimators.json")) 40var transformers = context.AdditionalFiles.Where(f => f.Path.Contains("transformer-estimators.json"))
SearchSpaceGenerator.cs (2)
22if (context.AdditionalFiles.Where(f => f.Path.Contains("code_gen_flag.json")).First() is AdditionalText text) 32var searchSpacesJson = context.AdditionalFiles.Where(f => f.Path.Contains("search_space.json"))
SweepableEstimatorFactoryGenerator.cs (3)
22if (context.AdditionalFiles.Where(f => f.Path.Contains("code_gen_flag.json")).First() is AdditionalText text) 32var trainers = context.AdditionalFiles.Where(f => f.Path.Contains("trainer-estimators.json")) 37var transformers = context.AdditionalFiles.Where(f => f.Path.Contains("transformer-estimators.json"))
SweepableEstimatorGenerator.cs (3)
21if (context.AdditionalFiles.Where(f => f.Path.Contains("code_gen_flag.json")).First() is AdditionalText text) 31var estimators = context.AdditionalFiles.Where(f => f.Path.Contains("trainer-estimators.json") || f.Path.Contains("transformer-estimators.json"))
System.Windows.Forms.Analyzers (3)
System\Windows\Forms\Analyzers\AppManifestAnalyzer.cs (3)
30if (context.AdditionalFile.Path.EndsWith(".manifest", StringComparison.OrdinalIgnoreCase)) 68appManifest.Path, 75appManifest.Path,