Package com.cefrium
package com.cefrium
Cefrium: the Chromium engine in an Android app, through CEF.
Cefrium initializes the engine and
CefriumBrowser is one browser, on a surface or off
screen. This package is the whole public API. The engine's own classes
(org.chromium.*, GEN_JNI) are on the classpath too, but code
that calls them or reaches them by reflection breaks on the next engine
update; Public API, not
engine internals lists the call to use instead.
Guides: cefrium.com/guides. A summary of the docs for tools that read them: cefrium.com/llms.txt.
-
ClassDescriptionJava side of Cefrium's APK asset/resource URL loading (FEATURE-061).Contact Picker delegate for the embedding (navigator.contacts.select).A
ModalDialogManager.Presenterthat renders Chromium dialog models with a plain AndroidAlertDialog.Entry point for the Cefrium SDK.The result of loading a filter list.The renderer process services the engine uses; seeCefrium.getRendererServices().Raw PCM tap of the page's audio, mirroring CEF'sCefAudioHandler.A browser instance backed by Chromium via CEF (Chromium Embedded Framework).Receives the captured page bitmap (null on failure).Deprecated.Deprecated.A candidate device offered to aCefriumBrowser.DeviceChooserSession.Deprecated.UseCefriumProfile.getCookieManager(): per profile, with expiry.Deprecated.UseCefriumProfile.getCookieManager(): per profile, with expiry.Presents device chooser UI for the frontier web device APIs.A live device chooser.DevTools protocol events of this browser.Snapshot of a download plus in-progress controls.Receives the app's credentials (or cancel) for an HTTP auth challenge.Deprecated.Receives an image fetched viaCefriumBrowser.downloadImage(String, int, ImageCallback).Resolves a JS dialog.Deprecated.One entry in the navigation history.Deprecated.Deprecated.Deprecated.Deprecated.Deprecated.Deprecated.Deprecated.Deprecated.Deprecated.UseCefriumChromeClient.onPermissionRequest(CefriumBrowser, CefriumPermissionRequest): a typed request instead of engine bits.Deprecated.Takes a page'swindow.print().Resolves aCefriumBrowser.QueryHandlerquery back to JavaScript.Handles JavaScriptwindow.cefriumQuery({request, onSuccess, onFailure})calls from page content (the JS ↔ native bridge).Decides which origins may reach aCefriumBrowser.QueryHandler.Deprecated.A request asCefriumResourceInterceptorsees it.A script added withCefriumBrowser.addDocumentStartJavaScript(String, Set).Receives the app's proceed/cancel decision for an invalid certificate.Deprecated.Called on the UI thread.Answers a server's request for a client certificate (seeCefriumNavigationClient.onSelectClientCertificate(CefriumBrowser, boolean, String, int, List, CefriumClientCertificateCallback)), from any thread.Handles Chrome command IDs, mirroring CEF'sCefCommandHandler.A message a page wrote to its console, likeandroid.webkit.ConsoleMessage.How severe the message is.A request to aCefriumContentServer.The answer of aCefriumContentServer: status, MIME type, headers and a body stream.Answers the requests for an https origin the app owns, from Java: the app's assets, files, or bytes it generates.Ready-madeCefriumContentServers for the app's assets, files and resources, and the MIME types they use.A stored decision for a permission and an origin.A context menu the page asks for (a long press or a right click on a link or an image), asCefriumChromeClient.onContextMenu(CefriumBrowser, CefriumContextMenu)sees it.What kind of media the menu is for.A cookie of a profile, asCefriumCookieManager.getCookies(String, Consumer)gives it.The cookie's SameSite attribute.The cookies of oneCefriumProfile, fromCefriumProfile.getCookieManager().The kind of date or time input a picker is for.What a device chooser picks: the Web API that asked for a device.Deprecated.Supplies the selected file path(s)/URI(s), or cancels.Deprecated.Called on the UI thread.Why a download stopped before it completed.HTML5 drag-and-drop notifications, mirroring CEF'sCefDragHandler.Marks API that may still change, or go, in a later release without the deprecation period the rest of the API gets: new API until a release has shipped it unchanged, and API kept for desktop CEF parity that no app has been seen to need.Answers a file chooser (seeCefriumChromeClient.onShowFileChooser(CefriumBrowser, CefriumFileChooserParams, CefriumFileChooserCallback)), from any thread.What a file input asks for, asCefriumChromeClient.onShowFileChooser(CefriumBrowser, CefriumFileChooserParams, CefriumFileChooserCallback)sees it.What the page wants chosen.Focus coordination between the web view and native Android views, mirroring CEF'sCefFocusHandler.Frame lifecycle notifications, mirroring CEF'sCefFrameHandler.Shows the account chooser of a FedCM request (navigator.credentials.get({identity})), which "Sign in with" prompts such as Google's use.An account an identity provider offers.Answers oneCefriumIdentityHandler.onShowAccountChooser(String, List, CefriumIdentityHandler.Request)call; only the first answer counts.Zero-config setup for the Cefrium SDK.Which JavaScript dialog a page opened.Deprecated.UseCefriumChromeClient.shouldOverrideKeyEvent(CefriumBrowser, KeyEvent)andCefriumChromeClient.onUnhandledKeyEvent(CefriumBrowser, KeyEvent): an Android KeyEvent instead of the engine's codes.Why a page failed to load, like androidxWebResourceErrorCompat.Deprecated.Foreground service that hosts the media-playback notification forCefriumMediaSession.Bridges the page'snavigator.mediaSession(Chromium MediaSession) to an AndroidMediaSessionCompatand a lock-screen / shade media notification.Called on the UI thread.A navigation a page is about to make, asCefriumNavigationClient.onBeforeNavigate(CefriumBrowser, CefriumNavigationRequest)sees it.Sends each request to the server registered for the longest prefix of its path, with the prefix removed: under/assets/,/assets/img/a.pngreaches that server as/img/a.png.Builds aCefriumPathContentServer.A web permission a page can ask for.A page asking for permissions, asCefriumChromeClient.onPermissionRequest(CefriumBrowser, CefriumPermissionRequest)sees it.Shows the pickers of<select>, the date and time inputs and<input type=color>for an off-screen browser.One entry of a<select>.Where a browser keeps its cookies, local storage, IndexedDB, service workers and cache.Receives every change to a download of a profile, on the UI thread.ReceivesCefriumProfile.getDownloads(CefriumProfile.DownloadsCallback)'s result, on the UI thread.Told when a request fails because of the proxy, on the main thread.One site's data in a profile, asCefriumProfile.listSiteData(CefriumProfile.SiteDataCallback)reports it.ReceivesCefriumProfile.listSiteData(CefriumProfile.SiteDataCallback)'s result, on the UI thread.How a profile reaches the network.Delivers Web Push messages to the engine.Receives Web Push messages for an app that has noFirebaseMessagingServiceof its own.A push service for Web Push other than Firebase Cloud Messaging.Web Push through the app's own Firebase project and a cefrium-relay the app developer runs, instead of the Chromium channel Google provides for testing.Why a page's renderer process ended.Callback interface for receiving rendered frames from aCefriumBrowser.A text-selection handle of an off-screen browser, asCefriumRenderHandler.onTouchHandleChanged(CefriumRenderHandler.TouchHandle)reports it.Deprecated.UseCefriumResourceInterceptorfor the resource events and cookie filter,CefriumNavigationClientfor the renderer and the document.Supplies the chosen client certificate (or none) for an mTLS challenge.Sees every request aCefriumBrowsermakes, and may cancel it or answer it instead of the network.What a request is for, asCefriumResourceInterceptorsees it.Chrome's secure DNS setting.A certificate that failed validation, asCefriumNavigationClient.onSslError(CefriumBrowser, CefriumSslError, CefriumBrowser.SslErrorCallback)sees it.FrameLayout that hosts the browser surface and participates in Android nested scrolling.The keyboard a focused field asks for: its HTMLinputmode, asCefriumRenderHandler.onVirtualKeyboardRequested(CefriumTextInputMode)reports it.Which interfaces WebRTC may use.Cefrium'sActivityWindowAndroid, adding aModalDialogManager.Cefrium's child process services, under Cefrium's own class names.
CefriumNavigationClient(URL, loading state),CefriumChromeClient(title, fullscreen, find, context menu),CefriumDownloadClient(downloads) andCefriumResourceInterceptor.onRequestFiltered(String, String, boolean)(requests).