Chromium Embedded Framework (CEF)  106.0.15+gbb70d04+chromium-106.0.5249.12
CefRequest Class Referenceabstract

Class used to represent a web request. More...

#include "include/cef_request.h"

Inheritance diagram for CefRequest:
CefBaseRefCounted

Public Types

typedef std::multimap< CefString, CefStringHeaderMap
 
typedef cef_referrer_policy_t ReferrerPolicy
 
typedef cef_resource_type_t ResourceType
 
typedef cef_transition_type_t TransitionType
 

Public Member Functions

virtual bool IsReadOnly ()=0
 Returns true if this object is read-only. More...
 
virtual CefString GetURL ()=0
 Get the fully qualified URL. More...
 
virtual void SetURL (const CefString &url)=0
 Set the fully qualified URL. More...
 
virtual CefString GetMethod ()=0
 Get the request method type. More...
 
virtual void SetMethod (const CefString &method)=0
 Set the request method type. More...
 
virtual void SetReferrer (const CefString &referrer_url, ReferrerPolicy policy)=0
 Set the referrer URL and policy. More...
 
virtual CefString GetReferrerURL ()=0
 Get the referrer URL. More...
 
virtual ReferrerPolicy GetReferrerPolicy ()=0
 Get the referrer policy. More...
 
virtual CefRefPtr< CefPostDataGetPostData ()=0
 Get the post data. More...
 
virtual void SetPostData (CefRefPtr< CefPostData > postData)=0
 Set the post data. More...
 
virtual void GetHeaderMap (HeaderMap &headerMap)=0
 Get the header values. More...
 
virtual void SetHeaderMap (const HeaderMap &headerMap)=0
 Set the header values. More...
 
virtual CefString GetHeaderByName (const CefString &name)=0
 Returns the first header value for |name| or an empty string if not found. More...
 
virtual void SetHeaderByName (const CefString &name, const CefString &value, bool overwrite)=0
 Set the header |name| to |value|. More...
 
virtual void Set (const CefString &url, const CefString &method, CefRefPtr< CefPostData > postData, const HeaderMap &headerMap)=0
 Set all values at one time. More...
 
virtual int GetFlags ()=0
 Get the flags used in combination with CefURLRequest. More...
 
virtual void SetFlags (int flags)=0
 Set the flags used in combination with CefURLRequest. More...
 
virtual CefString GetFirstPartyForCookies ()=0
 Get the URL to the first party for cookies used in combination with CefURLRequest. More...
 
virtual void SetFirstPartyForCookies (const CefString &url)=0
 Set the URL to the first party for cookies used in combination with CefURLRequest. More...
 
virtual ResourceType GetResourceType ()=0
 Get the resource type for this request. More...
 
virtual TransitionType GetTransitionType ()=0
 Get the transition type for this request. More...
 
virtual uint64 GetIdentifier ()=0
 Returns the globally unique identifier for this request or 0 if not specified. More...
 
- Public Member Functions inherited from CefBaseRefCounted
virtual void AddRef () const =0
 Called to increment the reference count for the object. More...
 
virtual bool Release () const =0
 Called to decrement the reference count for the object. More...
 
virtual bool HasOneRef () const =0
 Returns true if the reference count is 1. More...
 
virtual bool HasAtLeastOneRef () const =0
 Returns true if the reference count is at least 1. More...
 

Static Public Member Functions

static CefRefPtr< CefRequestCreate ()
 Create a new CefRequest object. More...
 

Additional Inherited Members

- Protected Member Functions inherited from CefBaseRefCounted
virtual ~CefBaseRefCounted ()
 

Detailed Description

Class used to represent a web request.

The methods of this class may be called on any thread.

Member Typedef Documentation

◆ HeaderMap

typedef std::multimap<CefString, CefString> CefRequest::HeaderMap

◆ ReferrerPolicy

◆ ResourceType

◆ TransitionType

Member Function Documentation

◆ Create()

static CefRefPtr<CefRequest> CefRequest::Create ( )
static

Create a new CefRequest object.

◆ GetFirstPartyForCookies()

virtual CefString CefRequest::GetFirstPartyForCookies ( )
pure virtual

Get the URL to the first party for cookies used in combination with CefURLRequest.

◆ GetFlags()

virtual int CefRequest::GetFlags ( )
pure virtual

Get the flags used in combination with CefURLRequest.

See cef_urlrequest_flags_t for supported values.

◆ GetHeaderByName()

virtual CefString CefRequest::GetHeaderByName ( const CefString name)
pure virtual

Returns the first header value for |name| or an empty string if not found.

Will not return the Referer value if any. Use GetHeaderMap instead if |name| might have multiple values.

◆ GetHeaderMap()

virtual void CefRequest::GetHeaderMap ( HeaderMap headerMap)
pure virtual

Get the header values.

Will not include the Referer value if any.

◆ GetIdentifier()

virtual uint64 CefRequest::GetIdentifier ( )
pure virtual

Returns the globally unique identifier for this request or 0 if not specified.

Can be used by CefResourceRequestHandler implementations in the browser process to track a single request across multiple callbacks.

◆ GetMethod()

virtual CefString CefRequest::GetMethod ( )
pure virtual

Get the request method type.

The value will default to POST if post data is provided and GET otherwise.

◆ GetPostData()

virtual CefRefPtr<CefPostData> CefRequest::GetPostData ( )
pure virtual

Get the post data.

◆ GetReferrerPolicy()

virtual ReferrerPolicy CefRequest::GetReferrerPolicy ( )
pure virtual

Get the referrer policy.

◆ GetReferrerURL()

virtual CefString CefRequest::GetReferrerURL ( )
pure virtual

Get the referrer URL.

◆ GetResourceType()

virtual ResourceType CefRequest::GetResourceType ( )
pure virtual

Get the resource type for this request.

Only available in the browser process.

◆ GetTransitionType()

virtual TransitionType CefRequest::GetTransitionType ( )
pure virtual

Get the transition type for this request.

Only available in the browser process and only applies to requests that represent a main frame or sub-frame navigation.

◆ GetURL()

virtual CefString CefRequest::GetURL ( )
pure virtual

Get the fully qualified URL.

◆ IsReadOnly()

virtual bool CefRequest::IsReadOnly ( )
pure virtual

Returns true if this object is read-only.

◆ Set()

virtual void CefRequest::Set ( const CefString url,
const CefString method,
CefRefPtr< CefPostData postData,
const HeaderMap headerMap 
)
pure virtual

Set all values at one time.

◆ SetFirstPartyForCookies()

virtual void CefRequest::SetFirstPartyForCookies ( const CefString url)
pure virtual

Set the URL to the first party for cookies used in combination with CefURLRequest.

◆ SetFlags()

virtual void CefRequest::SetFlags ( int  flags)
pure virtual

Set the flags used in combination with CefURLRequest.

See cef_urlrequest_flags_t for supported values.

◆ SetHeaderByName()

virtual void CefRequest::SetHeaderByName ( const CefString name,
const CefString value,
bool  overwrite 
)
pure virtual

Set the header |name| to |value|.

If |overwrite| is true any existing values will be replaced with the new value. If |overwrite| is false any existing values will not be overwritten. The Referer value cannot be set using this method.

◆ SetHeaderMap()

virtual void CefRequest::SetHeaderMap ( const HeaderMap headerMap)
pure virtual

Set the header values.

If a Referer value exists in the header map it will be removed and ignored.

◆ SetMethod()

virtual void CefRequest::SetMethod ( const CefString method)
pure virtual

Set the request method type.

◆ SetPostData()

virtual void CefRequest::SetPostData ( CefRefPtr< CefPostData postData)
pure virtual

Set the post data.

◆ SetReferrer()

virtual void CefRequest::SetReferrer ( const CefString referrer_url,
ReferrerPolicy  policy 
)
pure virtual

Set the referrer URL and policy.

If non-empty the referrer URL must be fully qualified with an HTTP or HTTPS scheme component. Any username, password or ref component will be removed.

◆ SetURL()

virtual void CefRequest::SetURL ( const CefString url)
pure virtual

Set the fully qualified URL.


The documentation for this class was generated from the following file: