語言

HttpResponseMessageProperty.Headers 屬性

定義

從 HTTP 回應取得 HTTP 標頭。

public:
 property System::Net::WebHeaderCollection ^ Headers { System::Net::WebHeaderCollection ^ get(); };
public System.Net.WebHeaderCollection Headers { get; }
member this.Headers : System.Net.WebHeaderCollection
Public ReadOnly Property Headers As WebHeaderCollection

屬性值

回傳包含 HTTP 回應中 HTTP 標頭的 a WebHeaderCollection 。

範例

此圖展示了如何從 HTTP 回應取得 HTTP 標頭:

WebHeaderCollection whCollection =
responseProperty.Headers;

適用於