Udostępnij za pośrednictwem


IFilePathToContentTypeProvider.TryGetContentTypeForFilePath Method

Definition

Gets the content-type for the given filePath.

public:
 bool TryGetContentTypeForFilePath(System::String ^ filePath, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Utilities::IContentType ^ % contentType);
public bool TryGetContentTypeForFilePath (string filePath, out Microsoft.VisualStudio.Utilities.IContentType contentType);
abstract member TryGetContentTypeForFilePath : string * IContentType -> bool
Public Function TryGetContentTypeForFilePath (filePath As String, ByRef contentType As IContentType) As Boolean

Parameters

filePath
String

The path of the file to assign a content-type to.

contentType
IContentType

The IContentType of the file path.

Returns

true if content type is known for filePath.

Applies to