Solution.GetDocumentIdsWithFilePath(String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the set of DocumentIds in this Solution with a FilePath that matches the given file path. This may return IDs for any type of document including AdditionalDocuments or AnalyzerConfigDocuments.
public:
System::Collections::Immutable::ImmutableArray<Microsoft::CodeAnalysis::DocumentId ^> GetDocumentIdsWithFilePath(System::String ^ filePath);
public System.Collections.Immutable.ImmutableArray<Microsoft.CodeAnalysis.DocumentId> GetDocumentIdsWithFilePath(string filePath);
public System.Collections.Immutable.ImmutableArray<Microsoft.CodeAnalysis.DocumentId> GetDocumentIdsWithFilePath(string? filePath);
member this.GetDocumentIdsWithFilePath : string -> System.Collections.Immutable.ImmutableArray<Microsoft.CodeAnalysis.DocumentId>
Public Function GetDocumentIdsWithFilePath (filePath As String) As ImmutableArray(Of DocumentId)
Parameters
- filePath
- String
Returns
Remarks
It's possible (but unlikely) that the same file may exist as more than one type of document in the same solution. If this were to return more than one DocumentId, you should not assume that just because one is a regular source file means that all of them would be.
Applies to
.NET