125 references to FilePath
Microsoft.CodeAnalysis (7)
MetadataReference\MetadataImageReference.cs (4)
45this.FilePath, 53return _display ?? FilePath ?? (Properties.Kind == MetadataImageKind.Assembly ? CodeAnalysisResources.InMemoryAssembly : CodeAnalysisResources.InMemoryModule); 73if (FilePath != null) 76sb.Append(FilePath);
MetadataReference\PortableExecutableReference.cs (1)
37get { return FilePath; }
PEWriter\MetadataWriter.PortablePdb.cs (2)
965if (referenceManager.GetMetadataReference(pair.AssemblySymbol) is PortableExecutableReference { FilePath: { } } portableReference) 967var fileName = PathUtilities.GetFileName(portableReference.FilePath);
Microsoft.CodeAnalysis.CSharp (3)
Symbols\Source\SourceAssemblySymbol.cs (2)
968if ((object)fileRef != null && (object)fileRef.FilePath != null) 970string fileName = FileNameUtilities.GetFileName(fileRef.FilePath);
Symbols\SymbolDistinguisher.cs (1)
185string path = metadataReference.FilePath;
Microsoft.CodeAnalysis.CSharp.Scripting.Desktop.UnitTests (2)
InteractiveSessionReferencesTests.cs (2)
646Assert.Equal(fileBase1.Path, ((PortableExecutableReference)libBaseRefAndSymbol.Key).FilePath); 704Assert.Equal(fileBase1.Path, ((PortableExecutableReference)libBaseRefAndSymbol.Key).FilePath);
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (3)
Compilation\ReferenceManagerTests.cs (3)
915Assert.Equal(p2, dr1.FilePath); 916Assert.Equal(p3, dr2.FilePath); 917Assert.Equal(p3, dr3.FilePath);
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (4)
MetadataAsSource\AbstractMetadataAsSourceTests.TestContext.cs (4)
110Assert.True(File.Exists(portableExecutable.FilePath), $"'{portableExecutable.FilePath}' does not exist for reference '{portableExecutable.Display}'"); 111Assert.True(Path.IsPathRooted(portableExecutable.FilePath), $"'{portableExecutable.FilePath}' is not a fully-qualified file name");
Microsoft.CodeAnalysis.Features (18)
AddImport\AbstractAddImportFeatureService.cs (4)
386return PathUtilities.ContainsPathComponent(reference.FilePath, pathComponent, ignoreCase: true); 411var path1 = x?.FilePath ?? x?.Display; 412var path2 = y?.FilePath ?? y?.Display; 421var path = obj.FilePath ?? obj.Display;
AddImport\AddImportFixData.cs (1)
71/// is the <see cref="PortableExecutableReference.FilePath"/> for it.
AddImport\CodeActions\MetadataSymbolReferenceCodeAction.cs (1)
33.First(pe => pe.FilePath == FixData.PortableExecutableReferenceFilePathToAdd);
AddImport\References\MetadataSymbolReference.cs (5)
54return (string.Format(FeaturesResources.Add_reference_to_0, Path.GetFileName(_reference.FilePath)), 64_referenceProjectId, _reference.FilePath); 78StringComparer.OrdinalIgnoreCase.Equals(_reference.FilePath, reference._reference.FilePath); 84StringComparer.OrdinalIgnoreCase.GetHashCode(_reference.FilePath));
Completion\Providers\ImportCompletionProvider\AbstractTypeImportCompletionService.cs (1)
157=> peReference.FilePath ?? peReference.Display;
Completion\Providers\ImportCompletionProvider\ExtensionMethodImportCompletionHelper.SymbolComputer.cs (1)
70=> peReference.FilePath ?? peReference.Display;
MetadataAsSource\DecompilationMetadataAsSourceFileProvider.cs (3)
203var assemblyLocation = (metadataReference as PortableExecutableReference)?.FilePath; 355if (peMetadataReference?.FilePath != null) 357return new UniqueDocumentKey(peMetadataReference.FilePath, peMetadataReference.GetMetadataId(), project.Language, SymbolKey.Create(topLevelNamedType, cancellationToken), signaturesOnly);
PdbSourceDocument\PdbSourceDocumentMetadataAsSourceFileProvider.cs (1)
107if (compilation.GetMetadataReference(symbol.ContainingAssembly) is not PortableExecutableReference { FilePath: not null and var dllPath })
UnusedReferences\UnusedReferencesRemover.cs (1)
52.Select(reference => reference.FilePath)
Microsoft.CodeAnalysis.InteractiveHost (4)
Interactive\Core\InteractiveHost.Service.cs (2)
566metadataReferencePaths.AddRange(resolvedReferences.Where(r => r.FilePath != null).Select(r => r.FilePath!));
Interactive\Core\InteractiveHost.ShadowCopyReference.cs (2)
33return _provider.GetMetadata(FilePath, Properties.Kind); 38return new ShadowCopyReference(_provider, FilePath!, properties);
Microsoft.CodeAnalysis.LanguageServerIndexFormat.Generator.UnitTests (2)
CompilerInvocationTests.vb (2)
34Assert.Equal(referencePath, DirectCast(metadataReference, PortableExecutableReference).FilePath) 61Assert.Equal(referencePath, DirectCast(metadataReference, PortableExecutableReference).FilePath)
Microsoft.CodeAnalysis.Scripting (2)
Hosting\Resolvers\RuntimeMetadataReferenceResolver.cs (1)
122var definitionDirectory = PathUtilities.GetDirectoryName((definition as PortableExecutableReference)?.FilePath);
ScriptBuilder.cs (1)
144var path = (referencedAssembly.Key as PortableExecutableReference)?.FilePath;
Microsoft.CodeAnalysis.Scripting.UnitTests (3)
RuntimeMetadataReferenceResolverTests.cs (3)
38AssertEx.SetEqual(actualReferences.SelectAsArray(r => r.FilePath), assembly1.Path, assembly2.Path); 44AssertEx.SetEqual(actualReferences.SelectAsArray(r => r.FilePath), assembly2.Path); 59AssertEx.SetEqual(actualReferences.SelectAsArray(r => r.FilePath), assembly2.Path);
Microsoft.CodeAnalysis.Test.Utilities (1)
TargetFrameworkUtil.cs (1)
302.Where(x => !(x is PortableExecutableReference pe && excludeReferenceNames.Contains(pe.FilePath)));
Microsoft.CodeAnalysis.UnitTests (22)
MetadataReferences\MetadataReferenceTests.cs (22)
69Assert.Null(r.FilePath); 85Assert.Null(r.FilePath); 103Assert.Null(r.FilePath); 134Assert.Null(r.FilePath); 150Assert.Null(r.FilePath); 166Assert.Equal(file.Path, r.FilePath); 189Assert.Equal(file.Path, r.FilePath); 209Assert.Equal(assembly.Location, r.FilePath); 226Assert.Equal(assembly.Location, r.FilePath); 264Assert.Equal(@"c:\temp", r.FilePath); 268Assert.Equal(@"c:\temp", r1.FilePath); 272Assert.Equal(@"c:\temp", r2.FilePath); 303Assert.Equal(@"c:\temp", r.FilePath); 307Assert.Equal(@"c:\temp", r2.FilePath); 315Assert.Equal(r.FilePath, r3.FilePath); 323Assert.Equal(r.FilePath, r4.FilePath); 405Assert.Null(mmr1.FilePath); 410Assert.Equal(path, r.FilePath); 420Assert.Null(mmr1.FilePath); 425Assert.Equal(path, r.FilePath);
Microsoft.CodeAnalysis.VisualBasic (2)
Symbols\Source\SourceAssemblySymbol.vb (2)
1314If fileRef IsNot Nothing AndAlso fileRef.FilePath IsNot Nothing Then 1315Dim fileName As String = FileNameUtilities.GetFileName(fileRef.FilePath)
Microsoft.CodeAnalysis.VisualBasic.CommandLine.UnitTests (2)
CommandLineTests.vb (2)
2537peRef.FilePath.EndsWith("mscorlib.dll", StringComparison.Ordinal) 2553peRef.FilePath.EndsWith("mscorlib.dll", StringComparison.Ordinal)
Microsoft.CodeAnalysis.Workspaces (13)
FindSymbols\SymbolTree\SymbolTreeInfo_Metadata.cs (1)
217=> "_Metadata_" + reference.FilePath;
Serialization\SerializerService_Reference.cs (4)
138writer.WriteString(reference.FilePath); 622throw new FileNotFoundException(FilePath); 626=> new MissingMetadataReference(properties, FilePath, _provider); 657=> new SerializedMetadataReference(properties, FilePath, _metadata, _storagesOpt, _provider);
Workspace\ProjectSystem\ProjectSystemProject.cs (2)
574.Single(m => m.FilePath == path && m.Properties == properties); 1135.Single(m => m.FilePath == fullPath && m.Properties == properties);
Workspace\ProjectSystem\ProjectSystemProjectFactory.cs (4)
411if (string.Equals(reference.FilePath, outputPath, StringComparison.OrdinalIgnoreCase)) 422(reference.FilePath!, projectReference)); 632if (portableExecutableReference.FilePath == fullFilePath) 638portableExecutableReference.FilePath,
Workspace\Workspace.cs (2)
1226(!RoslynString.IsNullOrEmpty(pemeta.FilePath) && outputAssemblyToProjectIdMap.TryGetValue(pemeta.FilePath, out matchingProjectId)))
Microsoft.CodeAnalysis.Workspaces.MSBuild (9)
MSBuild\MSBuildProjectLoader.Worker_ResolveReferences.cs (1)
86PortableExecutableReference portableExecutableReference => portableExecutableReference.FilePath,
MSBuild\ProjectFile\ProjectFile.cs (8)
346if (reference is PortableExecutableReference peRef && peRef.FilePath != null) 354if (IsInGAC(peRef.FilePath) && identity != null) 360else if (IsFrameworkReferenceAssembly(peRef.FilePath)) 363var fileName = identity != null ? identity.Name : Path.GetFileNameWithoutExtension(peRef.FilePath); 368var relativePath = PathUtilities.GetRelativePath(_loadedProject.DirectoryPath, peRef.FilePath); 369var fileName = Path.GetFileNameWithoutExtension(peRef.FilePath); 408if (reference is PortableExecutableReference peRef && peRef.FilePath != null) 410var item = FindReferenceItem(identity, peRef.FilePath);
Microsoft.CodeAnalysis.Workspaces.MSBuild.UnitTests (4)
VisualStudioMSBuildWorkspaceTests.cs (4)
79var fileNames = new HashSet<string>(references.Select(r => Path.GetFileName(((PortableExecutableReference)r).FilePath))); 170.SingleOrDefault(mr => mr.FilePath.Contains(name)); 775var csharpLib = refs.OfType<PortableExecutableReference>().FirstOrDefault(r => r.FilePath.Contains("Microsoft.CSharp")); 3154project.MetadataReferences.Select(r => Path.GetFileName(((PortableExecutableReference)r).FilePath)).OrderBy(StringComparer.Ordinal));
Microsoft.CodeAnalysis.Workspaces.UnitTests (2)
CommandLineProject\CommandLineProjectTests.cs (2)
169Assert.Single(info.MetadataReferences.OfType<PortableExecutableReference>(), r => r.FilePath == pathToAssembly); 181Assert.Single(info.MetadataReferences.OfType<PortableExecutableReference>(), r => r.FilePath == pathToAssembly);
Microsoft.VisualStudio.LanguageServices (18)
Library\ObjectBrowser\AbstractDescriptionBuilder.cs (1)
143AddText(portableExecutableReference.FilePath);
Library\ObjectBrowser\AbstractListItemFactory.cs (1)
627var assemblyIdentity = visitedAssemblies.GetOrAdd(portableExecutableReference.FilePath, filePath => AssemblyIdentityUtils.TryGetAssemblyIdentity(filePath));
Library\ObjectBrowser\ObjectList.cs (3)
856if (string.Equals(data.bstrFile, metadataReference.FilePath, StringComparison.OrdinalIgnoreCase)) 938var assemblyIdentity = AssemblyIdentityUtils.TryGetAssemblyIdentity(portableExecutableReference.FilePath); 944data.bstrFile = portableExecutableReference.FilePath;
Library\VsNavInfo\NavInfoFactory.cs (2)
29return new NavInfo(this, libraryName: portableExecutableReference.FilePath); 156? portableExecutableReference.FilePath
Progression\GraphNodeIdCreation.cs (2)
426if (compilation.GetMetadataReference(containingAssembly) is PortableExecutableReference reference && !string.IsNullOrEmpty(reference.FilePath)) 428return new Uri(reference.FilePath, UriKind.RelativeOrAbsolute);
ProjectSystem\MetadataReferences\VisualStudioMetadataReference.Snapshot.cs (6)
57return FileUtilities.GetFileTimeStamp(this.FilePath); 84return _provider.GetMetadata(this.FilePath, timestamp); 105=> new VisualStudioDocumentationProvider(this.FilePath, _provider.XmlMemberIndexService); 108=> new Snapshot(_provider, properties, this.FilePath, _fileChangeTrackerOpt); 111=> "Metadata File: " + FilePath; 114=> _provider.GetStorages(this.FilePath, _timestamp.Value);
ProjectSystem\VisualStudioWorkspaceImpl.AddMetadataReferenceUndoUnit.cs (1)
35.FirstOrDefault(p => StringComparer.OrdinalIgnoreCase.Equals(p.FilePath, _filePath));
ProjectSystem\VisualStudioWorkspaceImpl.cs (1)
573return fileMetadata.FilePath;
ProjectSystem\VisualStudioWorkspaceImpl.RemoveMetadataReferenceUndoUnit.cs (1)
36.FirstOrDefault(p => StringComparer.OrdinalIgnoreCase.Equals(p.FilePath!, _filePath));
Microsoft.VisualStudio.LanguageServices.CSharp.UnitTests (2)
ProjectSystemShim\CPS\CSharpReferencesTests.cs (2)
65Assert.True(GetProject3MetadataReferences().Any(mr => mr.FilePath == metadaRefFilePath)); 84Assert.False(GetProject3MetadataReferences().Any(mr => mr.FilePath == metadaRefFilePath));
Microsoft.VisualStudio.LanguageServices.Implementation (1)
CodeModel\ExternalElements\AbstractExternalCodeType.cs (1)
53return CodeModelService.GetExternalTypeExtender(name, metadataReference.FilePath);
Microsoft.VisualStudio.LanguageServices.Test.Utilities2 (1)
ProjectSystemShim\Framework\ExtensionMethods.vb (1)
12Return project.MetadataReferences.Cast(Of PortableExecutableReference).Any(Function(vsReference) String.Equals(vsReference.FilePath, path, StringComparison.OrdinalIgnoreCase))