ICoreWebView2Cookie

Trait ICoreWebView2Cookie 

Source
pub trait ICoreWebView2Cookie: IUnknown {
Show 14 methods // Required methods unsafe fn get_name(&self, name: *mut LPWSTR) -> HRESULT; unsafe fn get_value(&self, value: *mut LPWSTR) -> HRESULT; unsafe fn put_value(&self, value: LPCWSTR) -> HRESULT; unsafe fn get_domain(&self, domain: *mut LPWSTR) -> HRESULT; unsafe fn get_path(&self, path: *mut LPWSTR) -> HRESULT; unsafe fn get_expires(&self, expires: *mut f64) -> HRESULT; unsafe fn put_expires(&self, expires: f64) -> HRESULT; unsafe fn get_is_http_only(&self, is_http_only: *mut BOOL) -> HRESULT; unsafe fn put_is_http_only(&self, is_http_only: BOOL) -> HRESULT; unsafe fn get_same_site( &self, same_site: *mut CookieSameSiteKind, ) -> HRESULT; unsafe fn put_same_site(&self, same_site: CookieSameSiteKind) -> HRESULT; unsafe fn get_is_secure(&self, is_secure: *mut BOOL) -> HRESULT; unsafe fn put_is_secure(&self, is_secure: BOOL) -> HRESULT; unsafe fn get_is_session(&self, is_session: *mut BOOL) -> HRESULT;
}
Expand description

Provides a set of properties that are used to manage an ICoreWebView2Cookie.

\snippet ScenarioCookieManagement.cpp CookieObject

Required Methods§

Source

unsafe fn get_name(&self, name: *mut LPWSTR) -> HRESULT

Cookie name.

Source

unsafe fn get_value(&self, value: *mut LPWSTR) -> HRESULT

Cookie value.

Source

unsafe fn put_value(&self, value: LPCWSTR) -> HRESULT

Set the cookie value property.

Source

unsafe fn get_domain(&self, domain: *mut LPWSTR) -> HRESULT

The domain for which the cookie is valid. The default is the host that this cookie has been received from. Note that, for instance, “.bing.com”, “bing.com”, and “www.bing.com” are considered different domains.

Source

unsafe fn get_path(&self, path: *mut LPWSTR) -> HRESULT

The path for which the cookie is valid. The default is “/”, which means this cookie will be sent to all pages on the Domain.

Source

unsafe fn get_expires(&self, expires: *mut f64) -> HRESULT

The expiration date and time for the cookie as the number of seconds since the UNIX epoch. The default is -1.0, which means cookies are session cookies by default.

Source

unsafe fn put_expires(&self, expires: f64) -> HRESULT

Set the Expires property. Cookies are session cookies and will not be persistent if Expires is set to -1.0. NaN, infinity, and any negative value set other than -1.0 is disallowed.

Source

unsafe fn get_is_http_only(&self, is_http_only: *mut BOOL) -> HRESULT

Whether this cookie is http-only. True if a page script or other active content cannot access this cookie. The default is false.

Source

unsafe fn put_is_http_only(&self, is_http_only: BOOL) -> HRESULT

Set the IsHttpOnly property.

Source

unsafe fn get_same_site(&self, same_site: *mut CookieSameSiteKind) -> HRESULT

SameSite status of the cookie which represents the enforcement mode of the cookie. The default is COREWEBVIEW2_COOKIE_SAME_SITE_KIND_LAX.

Source

unsafe fn put_same_site(&self, same_site: CookieSameSiteKind) -> HRESULT

Set the SameSite property.

Source

unsafe fn get_is_secure(&self, is_secure: *mut BOOL) -> HRESULT

The security level of this cookie. True if the client is only to return the cookie in subsequent requests if those requests use HTTPS. The default is false. Note that cookie that requests COREWEBVIEW2_COOKIE_SAME_SITE_KIND_NONE but is not marked Secure will be rejected.

Source

unsafe fn put_is_secure(&self, is_secure: BOOL) -> HRESULT

Set the IsSecure property.

Source

unsafe fn get_is_session(&self, is_session: *mut BOOL) -> HRESULT

Whether this is a session cookie. The default is false.

Trait Implementations§

Source§

impl ComInterface for dyn ICoreWebView2Cookie

Source§

const IID: IID = IID_ICORE_WEB_VIEW2_COOKIE

The associated id for this interface
Source§

type VTable = ICoreWebView2CookieVTable

A COM compatible V-Table
Source§

type Super = dyn IUnknown

The interface that this interface inherits from
Source§

fn is_iid_in_inheritance_chain(riid: &GUID) -> bool

Check whether a given IID is in the inheritance hierarchy of this interface
Source§

impl<C: ICoreWebView2Cookie> ProductionComInterface<C> for dyn ICoreWebView2Cookie

Source§

fn vtable<O: Offset>() -> Self::VTable

Get the vtable for a particular COM interface

Implementations on Foreign Types§

Source§

impl<T: ICoreWebView2Cookie + ComInterface + ?Sized> ICoreWebView2Cookie for ComPtr<T>

Source§

unsafe fn get_name(&self, name: *mut LPWSTR) -> HRESULT

Source§

unsafe fn get_value(&self, value: *mut LPWSTR) -> HRESULT

Source§

unsafe fn put_value(&self, value: LPCWSTR) -> HRESULT

Source§

unsafe fn get_domain(&self, domain: *mut LPWSTR) -> HRESULT

Source§

unsafe fn get_path(&self, path: *mut LPWSTR) -> HRESULT

Source§

unsafe fn get_expires(&self, expires: *mut f64) -> HRESULT

Source§

unsafe fn put_expires(&self, expires: f64) -> HRESULT

Source§

unsafe fn get_is_http_only(&self, is_http_only: *mut BOOL) -> HRESULT

Source§

unsafe fn put_is_http_only(&self, is_http_only: BOOL) -> HRESULT

Source§

unsafe fn get_same_site(&self, same_site: *mut CookieSameSiteKind) -> HRESULT

Source§

unsafe fn put_same_site(&self, same_site: CookieSameSiteKind) -> HRESULT

Source§

unsafe fn get_is_secure(&self, is_secure: *mut BOOL) -> HRESULT

Source§

unsafe fn put_is_secure(&self, is_secure: BOOL) -> HRESULT

Source§

unsafe fn get_is_session(&self, is_session: *mut BOOL) -> HRESULT

Source§

impl<T: ICoreWebView2Cookie + ComInterface + ?Sized> ICoreWebView2Cookie for ComRc<T>

Source§

unsafe fn get_name(&self, name: *mut LPWSTR) -> HRESULT

Source§

unsafe fn get_value(&self, value: *mut LPWSTR) -> HRESULT

Source§

unsafe fn put_value(&self, value: LPCWSTR) -> HRESULT

Source§

unsafe fn get_domain(&self, domain: *mut LPWSTR) -> HRESULT

Source§

unsafe fn get_path(&self, path: *mut LPWSTR) -> HRESULT

Source§

unsafe fn get_expires(&self, expires: *mut f64) -> HRESULT

Source§

unsafe fn put_expires(&self, expires: f64) -> HRESULT

Source§

unsafe fn get_is_http_only(&self, is_http_only: *mut BOOL) -> HRESULT

Source§

unsafe fn put_is_http_only(&self, is_http_only: BOOL) -> HRESULT

Source§

unsafe fn get_same_site(&self, same_site: *mut CookieSameSiteKind) -> HRESULT

Source§

unsafe fn put_same_site(&self, same_site: CookieSameSiteKind) -> HRESULT

Source§

unsafe fn get_is_secure(&self, is_secure: *mut BOOL) -> HRESULT

Source§

unsafe fn put_is_secure(&self, is_secure: BOOL) -> HRESULT

Source§

unsafe fn get_is_session(&self, is_session: *mut BOOL) -> HRESULT

Implementors§