Overview   Project   Class   Tree   Index 
CEF3 C++ API Docs - Version 75.1.4+g4210896+chromium-75.0.3770.100
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD

(default)
Class CefRequestContextHandler

CefBaseRefCounted
   |
   +--CefRequestContextHandler

   in cef_request_context_handler.h

class CefRequestContextHandler
extends CefBaseRefCounted

Implement this interface to provide handler implementations. The handler instance will not be released until all objects related to the context have been destroyed.


Inner Classes, Typedefs, and Enums
typedef CefRequestContextHandler::PluginPolicy
          
 
Method Summary
 virtual CefRefPtr< CefResourceRequestHandler > GetResourceRequestHandler( CefRefPtr< CefBrowser > browser, CefRefPtr< CefFrame > frame, CefRefPtr< CefRequest > request, bool is_navigation, bool is_download, const CefString& request_initiator, bool& disable_default_handling )
          Called on the browser process IO thread before a resource request is initiated.
 virtual bool OnBeforePluginLoad( const CefString& mime_type, const CefString& plugin_url, bool is_main_frame, const CefString& top_origin_url, CefRefPtr< CefWebPluginInfo > plugin_info, CefRequestContextHandler::PluginPolicy* plugin_policy )
          Called on multiple browser process threads before a plugin instance is loaded.
 virtual void OnRequestContextInitialized( CefRefPtr< CefRequestContext > request_context )
          Called on the browser process UI thread immediately after the request context has been initialized.
   
Methods inherited from class CefBaseRefCounted
AddRef, Release, HasOneRef, HasAtLeastOneRef
 

Method Detail

GetResourceRequestHandler

public virtual CefRefPtr< CefResourceRequestHandler > GetResourceRequestHandler( CefRefPtr< CefBrowser > browser, CefRefPtr< CefFrame > frame, CefRefPtr< CefRequest > request, bool is_navigation, bool is_download, const CefString& request_initiator, bool& disable_default_handling );
Called on the browser process IO thread before a resource request is initiated. The |browser| and |frame| values represent the source of the request, and may be NULL for requests originating from service workers or CefURLRequest. |request| represents the request contents and cannot be modified in this callback. |is_navigation| will be true if the resource request is a navigation. |is_download| will be true if the resource request is a download. |request_initiator| is the origin (scheme + domain) of the page that initiated the request. Set |disable_default_handling| to true to disable default handling of the request, in which case it will need to be handled via CefResourceRequestHandler::GetResourceHandler or it will be canceled. To allow the resource load to proceed with default handling return NULL. To specify a handler for the resource return a CefResourceRequestHandler object. This method will not be called if the client associated with |browser| returns a non-NULL value from CefRequestHandler::GetResourceRequestHandler for the same request (identified by CefRequest::GetIdentifier).

OnBeforePluginLoad

public virtual bool OnBeforePluginLoad( const CefString& mime_type, const CefString& plugin_url, bool is_main_frame, const CefString& top_origin_url, CefRefPtr< CefWebPluginInfo > plugin_info, CefRequestContextHandler::PluginPolicy* plugin_policy );
Called on multiple browser process threads before a plugin instance is loaded. |mime_type| is the mime type of the plugin that will be loaded. |plugin_url| is the content URL that the plugin will load and may be empty. |is_main_frame| will be true if the plugin is being loaded in the main (top-level) frame, |top_origin_url| is the URL for the top-level frame that contains the plugin when loading a specific plugin instance or empty when building the initial list of enabled plugins for 'navigator.plugins' JavaScript state. |plugin_info| includes additional information about the plugin that will be loaded. |plugin_policy| is the recommended policy. Modify |plugin_policy| and return true to change the policy. Return false to use the recommended policy. The default plugin policy can be set at runtime using the `--plugin-policy=[allow|detect|block]` command-line flag. Decisions to mark a plugin as disabled by setting |plugin_policy| to PLUGIN_POLICY_DISABLED may be cached when |top_origin_url| is empty. To purge the plugin list cache and potentially trigger new calls to this method call CefRequestContext::PurgePluginListCache.

OnRequestContextInitialized

public virtual void OnRequestContextInitialized( CefRefPtr< CefRequestContext > request_context );
Called on the browser process UI thread immediately after the request context has been initialized.

 Overview   Project   Class   Tree   Index 
CEF3 C++ API Docs - Version 75.1.4+g4210896+chromium-75.0.3770.100
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD

Chromium Embedded Framework (CEF) Copyright © 2016 Marshall A. Greenblatt