public abstract class CefRequestContextHandlerAdapter extends java.lang.Object implements CefRequestContextHandler
构造器和说明 |
---|
CefRequestContextHandlerAdapter() |
限定符和类型 | 方法和说明 |
---|---|
CefResourceRequestHandler |
getResourceRequestHandler(CefBrowser browser, CefFrame frame, CefRequest request, boolean isNavigation, boolean isDownload, java.lang.String requestInitiator, BoolRef disableDefaultHandling)
Called on the IO thread before a resource request is initiated.
(在启动资源请求之前在IO线程上调用。)
|
boolean |
onBeforePluginLoad(java.lang.String mime_type, java.lang.String plugin_url, boolean is_main_frame, java.lang.String top_origin_url, CefWebPluginInfo plugin_info)
Called on multiple browser process threads before a plugin instance is loaded.
(在加载插件实例之前,在多个浏览器进程线程上调用。)
|
public CefResourceRequestHandler getResourceRequestHandler(CefBrowser browser, CefFrame frame, CefRequest request, boolean isNavigation, boolean isDownload, java.lang.String requestInitiator, BoolRef disableDefaultHandling)
CefRequestContextHandler
getResourceRequestHandler
在接口中
CefRequestContextHandler
browser
- The corresponding browser.
(-相应的浏览器。)
frame
- The frame generating the event. Instance only valid within the scope of this method.
(-生成事件的框架。实例仅在此方法的范围内有效。)
request
- The request itself. Cannot be modified in this callback. Instance only valid within the scope of this method.
(-请求本身。无法在此回调中修改。实例仅在此方法的范围内有效。)
isNavigation
- True if the resource request is a navigation.
(-如果资源请求是导航,则为true。)
isDownload
- True if the resource request is a download.
(-如果资源请求是下载,则为true。)
requestInitiator
- The origin (scheme + domain) of the page that initiated the request.
(-发起请求的页面的来源(方案+域)。)
disableDefaultHandling
- Set 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.
(-设置为true可禁用请求的默认处理,在这种情况下,需要通过CefResourceRequestHandler.getResourceHandler进行处理,否则将被取消。)
public boolean onBeforePluginLoad(java.lang.String mime_type, java.lang.String plugin_url, boolean is_main_frame, java.lang.String top_origin_url, CefWebPluginInfo plugin_info)
CefRequestContextHandler
onBeforePluginLoad
在接口中
CefRequestContextHandler
mime_type
- is the mime type of the plugin that will be loaded.
(-是将要加载的插件的mime类型。)
plugin_url
- is the content URL that the plugin will load and may be empty.
(-是插件将加载的内容URL,可能为空。)
is_main_frame
- will be true if the plugin is being loaded in the main (top-level) frame.
(-如果插件在主(顶层)框架中加载,则为true。)
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.
(-是在加载特定插件实例时包含插件的顶级框架的URL,或者在为“ navigator.plugins” JavaScript状态构建启用的插件的初始列表时为空白。)
plugin_info
- includes additional information about the plugin that will be loaded. |plugin_policy| is the recommended policy.
(-包括有关将要加载的插件的其他信息。 | plugin_policy |是推荐的政策。)