IFileToContentTypeService.GetContentTypeForFilePath(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.
Get the default IContentType for a file located at filePath
.
public:
Microsoft::VisualStudio::Utilities::IContentType ^ GetContentTypeForFilePath(System::String ^ filePath);
public Microsoft.VisualStudio.Utilities.IContentType GetContentTypeForFilePath (string filePath);
abstract member GetContentTypeForFilePath : string -> Microsoft.VisualStudio.Utilities.IContentType
Public Function GetContentTypeForFilePath (filePath As String) As IContentType
Parameters
- filePath
- String
Name of the file in question.
Returns
Excpected content type or UnknownContentType if no content type is found.
Remarks
If no IContentType is found using declared IFilePathToContentTypeProvider assets, then the GetContentTypeForFileNameOrExtension(String) is used.