HttpCookieManager Klasse

Definition

Fügen Sie ein HttpCookie hinzu, oder löschen Sie sie, oder zeigen Sie die Cookies an, die einer App zugeordnet sind.

public ref class HttpCookieManager sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class HttpCookieManager final
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class HttpCookieManager final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class HttpCookieManager
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class HttpCookieManager
Public NotInheritable Class HttpCookieManager
Vererbung
Object Platform::Object IInspectable HttpCookieManager
Attribute

Windows-Anforderungen

Gerätefamilie
Windows 10 (eingeführt in 10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (eingeführt in v1.0)

Hinweise

Das HttpCookieManager-Objekt wird verwendet, um eine HttpCookie hinzuzufügen oder zu löschen oder die Cookies anzuzeigen, die einer App zugeordnet sind.

Die CookieManager-Eigenschaft für HttpBaseProtocolFilter gibt ein HttpCookieManager-Objekt zurück. Um einen HttpCookieManager zu erstellen, wird zuerst ein HttpBaseProtocolFilter-Objekt erstellt, und dann gibt die CookieManager-Eigenschaft für HttpBaseProtocolFilter das HttpCookieManager-Objekt zurück.

Methoden

DeleteCookie(HttpCookie)

Löschen Sie ein HttpCookie aus den Cookies, die einer App zugeordnet sind.

GetCookies(Uri)

Ruft eine HttpCookieCollection ab, die die HttpCookie-Instanzen enthält, die einem bestimmten URI zugeordnet sind.

SetCookie(HttpCookie)

Fügen Oder ändern Sie httpCookie in den Cookies, die einer App zugeordnet sind, die bei zukünftigen Anforderungen gesendet wird.

SetCookie(HttpCookie, Boolean)

Hinzufügen oder Ändern eines HttpCookie-Elements in den Cookies, die einer App zugeordnet sind.

Gilt für:

Weitere Informationen