CefRequestContext Methods |
The CefRequestContext type exposes the following members.
Name | Description | |
---|---|---|
CanSetPreference |
Returns true if the preference with the specified |name| can be modified
using SetPreference. As one example preferences set via the command-line
usually cannot be modified. This method must be called on the browser
process UI thread.
| |
ClearCertificateExceptions |
Clears all certificate exceptions that were added as part of handling
CefRequestHandler::OnCertificateError(). If you call this it is
recommended that you also call CloseAllConnections() or you risk not
being prompted again for server certificates if you reconnect quickly.
If |callback| is non-NULL it will be executed on the UI thread after
completion.
| |
ClearSchemeHandlerFactories |
Clear all registered scheme handler factories. Returns false on error. This
function may be called on any thread in the browser process.
| |
CloseAllConnections |
Clears all active and idle connections that Chromium currently has.
This is only recommended if you have released all other CEF objects but
don't yet want to call CefShutdown(). If |callback| is non-NULL it will be
executed on the UI thread after completion.
| |
CreateContext(CefRequestContext, CefRequestContextHandler) |
Creates a new context object that shares storage with |other| and uses an
optional |handler|.
| |
CreateContext(CefRequestContextSettings, CefRequestContextHandler) |
Creates a new context object with the specified |settings| and optional
|handler|.
| |
Dispose | ||
Equals | Determines whether the specified object is equal to the current object. (Inherited from Object.) | |
Finalize | (Overrides ObjectFinalize.) | |
GetAllPreferences |
Returns all preferences as a dictionary. If |include_defaults| is true then
preferences currently at their default value will be included. The returned
object contains a copy of the underlying preference values and
modifications to the returned object will not modify the underlying
preference values. This method must be called on the browser process UI
thread.
| |
GetDefaultCookieManager |
Returns the default cookie manager for this object. This will be the global
cookie manager if this object is the global request context. Otherwise,
this will be the default cookie manager used when this request context does
not receive a value via CefRequestContextHandler::GetCookieManager(). If
|callback| is non-NULL it will be executed asnychronously on the IO thread
after the manager's storage has been initialized.
| |
GetGlobalContext |
Returns the global context object.
| |
GetHandler |
Returns the handler for this context if any.
| |
GetHashCode | Serves as the default hash function. (Inherited from Object.) | |
GetPreference |
Returns the value for the preference with the specified |name|. Returns
NULL if the preference does not exist. The returned object contains a copy
of the underlying preference value and modifications to the returned object
will not modify the underlying preference value. This method must be called
on the browser process UI thread.
| |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
HasPreference |
Returns true if a preference with the specified |name| exists. This method
must be called on the browser process UI thread.
| |
IsSame |
Returns true if this object is pointing to the same context as |that|
object.
| |
IsSharingWith |
Returns true if this object is sharing the same storage as |that| object.
| |
PurgePluginListCache |
Tells all renderer processes associated with this context to throw away
their plugin list cache. If |reload_pages| is true they will also reload
all pages with plugins. CefRequestContextHandler::OnBeforePluginLoad may
be called to rebuild the plugin list cache.
| |
RegisterSchemeHandlerFactory |
Register a scheme handler factory for the specified |scheme_name| and
optional |domain_name|. An empty |domain_name| value for a standard scheme
will cause the factory to match all domain names. The |domain_name| value
will be ignored for non-standard schemes. If |scheme_name| is a built-in
scheme and no handler is returned by |factory| then the built-in scheme
handler factory will be called. If |scheme_name| is a custom scheme then
you must also implement the CefApp::OnRegisterCustomSchemes() method in all
processes. This function may be called multiple times to change or remove
the factory that matches the specified |scheme_name| and optional
|domain_name|. Returns false if an error occurs. This function may be
called on any thread in the browser process.
| |
ResolveHost |
Attempts to resolve |origin| to a list of associated IP addresses.
|callback| will be executed on the UI thread after completion.
| |
ResolveHostCached |
Attempts to resolve |origin| to a list of associated IP addresses using
cached data. |resolved_ips| will be populated with the list of resolved IP
addresses or empty if no cached data is available. Returns ERR_NONE on
success. This method must be called on the browser process IO thread.
| |
SetPreference |
Set the |value| associated with preference |name|. Returns true if the
value is set successfully and false otherwise. If |value| is NULL the
preference will be restored to its default value. If setting the preference
fails then |error| will be populated with a detailed description of the
problem. This method must be called on the browser process UI thread.
| |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
Name | Description | |
---|---|---|
MethodInvoke |
Calls the object method by name.
(Defined by ObjectEx.) | |
PropertyGet(String, Object, Boolean) | Overloaded.
Gets the value of the object property by name.
(Defined by ObjectEx.) | |
PropertyGetT(String, Object, Boolean) | Overloaded.
Gets the value of the object property by name.
(Defined by ObjectEx.) | |
PropertySet |
Sets the value of the object property by name.
(Defined by ObjectEx.) |