Share via


HttpContentDispositionHeaderValue.TryParse 方法

定義

判斷字串是否為有效的 HttpContentDispositionHeaderValue 資訊。

public:
 static bool TryParse(Platform::String ^ input, [Out] HttpContentDispositionHeaderValue ^ & contentDispositionHeaderValue);
 static bool TryParse(winrt::hstring const& input, [Out] HttpContentDispositionHeaderValue const& & contentDispositionHeaderValue);
public static bool TryParse(string input, out HttpContentDispositionHeaderValue contentDispositionHeaderValue);
Public Shared Function TryParse (input As String, ByRef contentDispositionHeaderValue As HttpContentDispositionHeaderValue) As Boolean

參數

input
String

Platform::String

winrt::hstring

要驗證的字串。

contentDispositionHeaderValue
HttpContentDispositionHeaderValue

字串的 HttpContentDispositionHeaderValue 版本。

傳回

Boolean

bool

如果input是有效的HttpContentDispositionHeaderValue資訊,則為true;否則為false

範例

請參閱 HttpContentHeaderCollection 類別中的程式代碼範例。

適用於