1 import android.app.Activity;
2 import android.app.PendingIntent;
3 import android.content.Context;
4 import android.content.Intent;
5 import android.content.res.Configuration;
6 import android.graphics.Bitmap;
7 import android.graphics.Canvas;
8 import android.graphics.Matrix;
9 import android.graphics.Point;
10 import android.graphics.Rect;
11 import android.graphics.RectF;
12 import android.graphics.Region;
13 import android.net.Uri;
14 import android.os.Bundle;
15 import android.os.CancellationSignal;
16 import android.os.Handler;
17 import android.os.Looper;
18 import android.os.Parcel;
19 import android.os.ParcelFileDescriptor;
20 import android.os.Parcelable;
21 import android.print.PageRange;
22 import android.print.PrintAttributes;
23 import android.print.PrintDocumentAdapter;
24 import android.util.AttributeSet;
25 import android.util.SparseArray;
26 import android.view.ActionMode;
27 import android.view.DragEvent;
28 import android.view.KeyEvent;
29 import android.view.Menu;
30 import android.view.MenuItem;
31 import android.view.MotionEvent;
32 import android.view.PointerIcon;
33 import android.view.Surface;
34 import android.view.SurfaceControl;
35 import android.view.View;
36 import android.view.ViewStructure;
37 import android.view.autofill.AutofillValue;
38 import android.view.inputmethod.CursorAnchorInfo;
39 import android.view.inputmethod.EditorInfo;
40 import android.view.inputmethod.ExtractedText;
41 import android.view.inputmethod.ExtractedTextRequest;
42 import android.view.inputmethod.InputConnection;
43 import android.widget.FrameLayout;
44 import androidx.annotation.AnyThread;
45 import androidx.annotation.NonNull;
46 import androidx.annotation.Nullable;
47 import androidx.annotation.UiThread;
49 import java.io.InputStream;
50 import java.lang.Boolean;
51 import java.lang.CharSequence;
52 import java.lang.Class;
53 import java.lang.Comparable;
54 import java.lang.Deprecated;
55 import java.lang.Double;
56 import java.lang.Exception;
57 import java.lang.Float;
58 import java.lang.FunctionalInterface;
59 import java.lang.Integer;
60 import java.lang.Long;
61 import java.lang.Object;
62 import java.lang.Runnable;
63 import java.lang.RuntimeException;
64 import java.lang.SafeVarargs;
65 import java.lang.String;
66 import java.lang.Thread;
67 import java.lang.Throwable;
68 import java.lang.Void;
69 import java.lang.annotation.Documented;
70 import java.lang.annotation.ElementType;
71 import java.lang.annotation.Retention;
72 import java.lang.annotation.RetentionPolicy;
73 import java.lang.annotation.Target;
74 import java.net.InetAddress;
75 import java.nio.ByteBuffer;
76 import java.security.cert.X509Certificate;
77 import java.util.AbstractSequentialList;
78 import java.util.Collection;
79 import java.util.List;
81 import org.json.JSONObject;
82 import org.mozilla.geckoview.AllowOrDeny;
83 import org.mozilla.geckoview.Autocomplete;
84 import org.mozilla.geckoview.Autofill;
85 import org.mozilla.geckoview.CompositorController;
86 import org.mozilla.geckoview.ContentBlocking;
87 import org.mozilla.geckoview.ContentBlockingController;
88 import org.mozilla.geckoview.CrashHandler;
89 import org.mozilla.geckoview.DeprecationSchedule;
90 import org.mozilla.geckoview.ExperimentDelegate;
91 import org.mozilla.geckoview.GeckoDisplay;
92 import org.mozilla.geckoview.GeckoResult;
93 import org.mozilla.geckoview.GeckoRuntime;
94 import org.mozilla.geckoview.GeckoRuntimeSettings;
95 import org.mozilla.geckoview.GeckoSession;
96 import org.mozilla.geckoview.GeckoSessionSettings;
97 import org.mozilla.geckoview.GeckoView;
98 import org.mozilla.geckoview.Image;
99 import org.mozilla.geckoview.MediaSession;
100 import org.mozilla.geckoview.OrientationController;
101 import org.mozilla.geckoview.OverscrollEdgeEffect;
102 import org.mozilla.geckoview.PanZoomController;
103 import org.mozilla.geckoview.ProfilerController;
104 import org.mozilla.geckoview.RuntimeSettings;
105 import org.mozilla.geckoview.RuntimeTelemetry;
106 import org.mozilla.geckoview.ScreenLength;
107 import org.mozilla.geckoview.SessionAccessibility;
108 import org.mozilla.geckoview.SessionFinder;
109 import org.mozilla.geckoview.SessionPdfFileSaver;
110 import org.mozilla.geckoview.SessionTextInput;
111 import org.mozilla.geckoview.SlowScriptResponse;
112 import org.mozilla.geckoview.StorageController;
113 import org.mozilla.geckoview.TranslationsController;
114 import org.mozilla.geckoview.WebExtension;
115 import org.mozilla.geckoview.WebExtensionController;
116 import org.mozilla.geckoview.WebMessage;
117 import org.mozilla.geckoview.WebNotification;
118 import org.mozilla.geckoview.WebNotificationDelegate;
119 import org.mozilla.geckoview.WebPushController;
120 import org.mozilla.geckoview.WebPushDelegate;
121 import org.mozilla.geckoview.WebPushSubscription;
122 import org.mozilla.geckoview.WebRequest;
123 import org.mozilla.geckoview.WebRequestError;
124 import org.mozilla.geckoview.WebResponse;
126 package org.mozilla.geckoview {
128 @AnyThread public final enum AllowOrDeny {
129 method public static AllowOrDeny valueOf(String);
130 method public static AllowOrDeny[] values();
131 enum_constant public static final AllowOrDeny ALLOW;
132 enum_constant public static final AllowOrDeny DENY;
135 public class Autocomplete {
136 ctor protected Autocomplete();
139 public static class Autocomplete.Address {
140 ctor @AnyThread protected Address();
141 field @NonNull public final String additionalName;
142 field @NonNull public final String addressLevel1;
143 field @NonNull public final String addressLevel2;
144 field @NonNull public final String addressLevel3;
145 field @NonNull public final String country;
146 field @NonNull public final String email;
147 field @NonNull public final String familyName;
148 field @NonNull public final String givenName;
149 field @Nullable public final String guid;
150 field @NonNull public final String name;
151 field @NonNull public final String organization;
152 field @NonNull public final String postalCode;
153 field @NonNull public final String streetAddress;
154 field @NonNull public final String tel;
157 public static class Autocomplete.Address.Builder {
158 ctor @AnyThread public Builder();
159 method @AnyThread @NonNull public Autocomplete.Address.Builder additionalName(@Nullable String);
160 method @AnyThread @NonNull public Autocomplete.Address.Builder addressLevel1(@Nullable String);
161 method @AnyThread @NonNull public Autocomplete.Address.Builder addressLevel2(@Nullable String);
162 method @AnyThread @NonNull public Autocomplete.Address.Builder addressLevel3(@Nullable String);
163 method @AnyThread @NonNull public Autocomplete.Address build();
164 method @AnyThread @NonNull public Autocomplete.Address.Builder country(@Nullable String);
165 method @AnyThread @NonNull public Autocomplete.Address.Builder email(@Nullable String);
166 method @AnyThread @NonNull public Autocomplete.Address.Builder familyName(@Nullable String);
167 method @AnyThread @NonNull public Autocomplete.Address.Builder givenName(@Nullable String);
168 method @AnyThread @NonNull public Autocomplete.Address.Builder guid(@Nullable String);
169 method @AnyThread @NonNull public Autocomplete.Address.Builder name(@Nullable String);
170 method @AnyThread @NonNull public Autocomplete.Address.Builder organization(@Nullable String);
171 method @AnyThread @NonNull public Autocomplete.Address.Builder postalCode(@Nullable String);
172 method @AnyThread @NonNull public Autocomplete.Address.Builder streetAddress(@Nullable String);
173 method @AnyThread @NonNull public Autocomplete.Address.Builder tel(@Nullable String);
176 public static class Autocomplete.AddressSaveOption extends Autocomplete.SaveOption<Autocomplete.Address> {
177 ctor public AddressSaveOption(@NonNull Autocomplete.Address);
180 public static class Autocomplete.AddressSelectOption extends Autocomplete.SelectOption<Autocomplete.Address> {
181 ctor public AddressSelectOption(@NonNull Autocomplete.Address);
184 @Retention(value=RetentionPolicy.SOURCE) public static interface Autocomplete.AddressSelectOption.AddressSelectHint {
187 public static class Autocomplete.AddressSelectOption.Hint {
189 field public static final int INSECURE_FORM = 2;
190 field public static final int NONE = 0;
193 public static class Autocomplete.CreditCard {
194 ctor @AnyThread protected CreditCard();
195 field @NonNull public final String expirationMonth;
196 field @NonNull public final String expirationYear;
197 field @Nullable public final String guid;
198 field @NonNull public final String name;
199 field @NonNull public final String number;
202 public static class Autocomplete.CreditCard.Builder {
203 ctor @AnyThread public Builder();
204 method @AnyThread @NonNull public Autocomplete.CreditCard build();
205 method @AnyThread @NonNull public Autocomplete.CreditCard.Builder expirationMonth(@Nullable String);
206 method @AnyThread @NonNull public Autocomplete.CreditCard.Builder expirationYear(@Nullable String);
207 method @AnyThread @NonNull public Autocomplete.CreditCard.Builder guid(@Nullable String);
208 method @AnyThread @NonNull public Autocomplete.CreditCard.Builder name(@Nullable String);
209 method @AnyThread @NonNull public Autocomplete.CreditCard.Builder number(@Nullable String);
212 public static class Autocomplete.CreditCardSaveOption extends Autocomplete.SaveOption<Autocomplete.CreditCard> {
213 ctor public CreditCardSaveOption(@NonNull Autocomplete.CreditCard);
216 public static class Autocomplete.CreditCardSelectOption extends Autocomplete.SelectOption<Autocomplete.CreditCard> {
217 ctor public CreditCardSelectOption(@NonNull Autocomplete.CreditCard);
220 @Retention(value=RetentionPolicy.SOURCE) public static interface Autocomplete.CreditCardSelectOption.CreditCardSelectHint {
223 public static class Autocomplete.CreditCardSelectOption.Hint {
225 field public static final int INSECURE_FORM = 2;
226 field public static final int NONE = 0;
229 @Retention(value=RetentionPolicy.SOURCE) public static interface Autocomplete.LSUsedField {
232 public static class Autocomplete.LoginEntry {
233 ctor @AnyThread protected LoginEntry();
234 field @Nullable public final String formActionOrigin;
235 field @Nullable public final String guid;
236 field @Nullable public final String httpRealm;
237 field @NonNull public final String origin;
238 field @NonNull public final String password;
239 field @NonNull public final String username;
242 public static class Autocomplete.LoginEntry.Builder {
243 ctor @AnyThread public Builder();
244 method @AnyThread @NonNull public Autocomplete.LoginEntry build();
245 method @AnyThread @NonNull public Autocomplete.LoginEntry.Builder formActionOrigin(@Nullable String);
246 method @AnyThread @NonNull public Autocomplete.LoginEntry.Builder guid(@Nullable String);
247 method @AnyThread @NonNull public Autocomplete.LoginEntry.Builder httpRealm(@Nullable String);
248 method @AnyThread @NonNull public Autocomplete.LoginEntry.Builder origin(@NonNull String);
249 method @AnyThread @NonNull public Autocomplete.LoginEntry.Builder password(@NonNull String);
250 method @AnyThread @NonNull public Autocomplete.LoginEntry.Builder username(@NonNull String);
253 public static class Autocomplete.LoginSaveOption extends Autocomplete.SaveOption<Autocomplete.LoginEntry> {
254 ctor public LoginSaveOption(@NonNull Autocomplete.LoginEntry);
257 public static class Autocomplete.LoginSelectOption extends Autocomplete.SelectOption<Autocomplete.LoginEntry> {
258 ctor public LoginSelectOption(@NonNull Autocomplete.LoginEntry);
261 public abstract static class Autocomplete.Option<T> {
262 ctor public Option(@NonNull T, int);
263 field public final int hint;
264 field @NonNull public final T value;
267 public abstract static class Autocomplete.SaveOption<T> extends Autocomplete.Option<T> {
268 ctor public SaveOption(@NonNull T, int);
271 public static class Autocomplete.SaveOption.Hint {
272 ctor protected Hint();
273 field public static final int GENERATED = 1;
274 field public static final int LOW_CONFIDENCE = 2;
275 field public static final int NONE = 0;
278 @Retention(value=RetentionPolicy.SOURCE) public static interface Autocomplete.SaveOption.SaveOptionHint {
281 public abstract static class Autocomplete.SelectOption<T> extends Autocomplete.Option<T> {
282 ctor public SelectOption(@NonNull T, int);
285 public static class Autocomplete.SelectOption.Hint {
287 field public static final int DUPLICATE_USERNAME = 4;
288 field public static final int GENERATED = 1;
289 field public static final int INSECURE_FORM = 2;
290 field public static final int MATCHING_ORIGIN = 8;
291 field public static final int NONE = 0;
294 @Retention(value=RetentionPolicy.SOURCE) public static interface Autocomplete.SelectOption.SelectOptionHint {
297 public static interface Autocomplete.StorageDelegate {
298 method @Nullable @UiThread default public GeckoResult<Autocomplete.Address[]> onAddressFetch();
299 method @UiThread default public void onAddressSave(@NonNull Autocomplete.Address);
300 method @Nullable @UiThread default public GeckoResult<Autocomplete.CreditCard[]> onCreditCardFetch();
301 method @UiThread default public void onCreditCardSave(@NonNull Autocomplete.CreditCard);
302 method @Nullable @UiThread default public GeckoResult<Autocomplete.LoginEntry[]> onLoginFetch(@NonNull String);
303 method @Nullable @UiThread default public GeckoResult<Autocomplete.LoginEntry[]> onLoginFetch();
304 method @UiThread default public void onLoginSave(@NonNull Autocomplete.LoginEntry);
305 method @UiThread default public void onLoginUsed(@NonNull Autocomplete.LoginEntry, int);
308 public static class Autocomplete.UsedField {
309 ctor protected UsedField();
310 field public static final int PASSWORD = 1;
313 public class Autofill {
314 ctor public Autofill();
317 @Retention(value=RetentionPolicy.SOURCE) public static interface Autofill.AutofillHint {
320 @Retention(value=RetentionPolicy.SOURCE) public static interface Autofill.AutofillInputType {
323 public static interface Autofill.AutofillNotify {
326 public static interface Autofill.Delegate {
327 method @UiThread default public void onNodeAdd(@NonNull GeckoSession, @NonNull Autofill.Node, @NonNull Autofill.NodeData);
328 method @UiThread default public void onNodeBlur(@NonNull GeckoSession, @NonNull Autofill.Node, @NonNull Autofill.NodeData);
329 method @UiThread default public void onNodeFocus(@NonNull GeckoSession, @NonNull Autofill.Node, @NonNull Autofill.NodeData);
330 method @UiThread default public void onNodeRemove(@NonNull GeckoSession, @NonNull Autofill.Node, @NonNull Autofill.NodeData);
331 method @UiThread default public void onNodeUpdate(@NonNull GeckoSession, @NonNull Autofill.Node, @NonNull Autofill.NodeData);
332 method @UiThread default public void onSessionCancel(@NonNull GeckoSession);
333 method @UiThread default public void onSessionCommit(@NonNull GeckoSession, @NonNull Autofill.Node, @NonNull Autofill.NodeData);
334 method @UiThread default public void onSessionStart(@NonNull GeckoSession);
337 public static final class Autofill.Hint {
338 method @AnyThread @Nullable public static String toString(int);
339 field public static final int EMAIL_ADDRESS = 0;
340 field public static final int NONE = -1;
341 field public static final int PASSWORD = 1;
342 field public static final int URI = 2;
343 field public static final int USERNAME = 3;
346 public static final class Autofill.InputType {
347 method @AnyThread @Nullable public static String toString(int);
348 field public static final int NONE = -1;
349 field public static final int NUMBER = 1;
350 field public static final int PHONE = 2;
351 field public static final int TEXT = 0;
354 public static final class Autofill.Node {
355 method @AnyThread @Nullable public String getAttribute(@NonNull String);
356 method @AnyThread @NonNull public Map<String,String> getAttributes();
357 method @AnyThread @NonNull public Collection<Autofill.Node> getChildren();
358 method @AnyThread @NonNull public String getDomain();
359 method @AnyThread public boolean getEnabled();
360 method @AnyThread public boolean getFocusable();
361 method @AnyThread public int getHint();
362 method @AnyThread public int getInputType();
363 method @AnyThread @NonNull public Rect getScreenRect();
364 method @AnyThread @NonNull public String getTag();
367 public static class Autofill.NodeData {
368 method @AnyThread public int getId();
369 method @AnyThread @Nullable public String getValue();
372 public static final class Autofill.Session {
373 method @UiThread public void autofill(@NonNull SparseArray<CharSequence>);
374 method @NonNull @UiThread public Autofill.NodeData dataFor(@NonNull Autofill.Node);
375 method @UiThread public void fillViewStructure(@NonNull View, @NonNull ViewStructure, int);
376 method @UiThread public void fillViewStructure(@NonNull Autofill.Node, @NonNull View, @NonNull ViewStructure, int);
377 method @NonNull @UiThread public Rect getDefaultDimensions();
378 method @Nullable @UiThread public Autofill.Node getFocused();
379 method @Nullable @UiThread public Autofill.NodeData getFocusedData();
380 method @AnyThread @NonNull public Autofill.Node getRoot();
381 method @UiThread public boolean isVisible(@NonNull Autofill.Node);
384 @UiThread public class BasicSelectionActionDelegate implements ActionMode.Callback GeckoSession.SelectionActionDelegate {
385 ctor public BasicSelectionActionDelegate(@NonNull Activity);
386 ctor public BasicSelectionActionDelegate(@NonNull Activity, boolean);
387 method public boolean areExternalActionsEnabled();
388 method public void clearSelection();
389 method public void enableExternalActions(boolean);
390 method @Nullable public GeckoSession.SelectionActionDelegate.Selection getSelection();
391 method public boolean isActionAvailable();
392 method public void onGetContentRect(@Nullable ActionMode, @Nullable View, @NonNull Rect);
393 method @NonNull protected String[] getAllActions();
394 method protected boolean isActionAvailable(@NonNull String);
395 method protected boolean performAction(@NonNull String, @NonNull MenuItem);
396 method protected void prepareAction(@NonNull String, @NonNull MenuItem);
397 field protected static final String ACTION_PROCESS_TEXT = "android.intent.action.PROCESS_TEXT";
398 field @Nullable protected ActionMode mActionMode;
399 field @NonNull protected final Activity mActivity;
400 field protected boolean mRepopulatedMenu;
401 field @Nullable protected GeckoSession.SelectionActionDelegate.Selection mSelection;
402 field @Nullable protected GeckoSession mSession;
403 field protected final boolean mUseFloatingToolbar;
406 @UiThread public final class CompositorController {
407 method public void addDrawCallback(@NonNull Runnable);
408 method public int getClearColor();
409 method @Nullable public Runnable getFirstPaintCallback();
410 method public void removeDrawCallback(@NonNull Runnable);
411 method public void setClearColor(int);
412 method public void setFirstPaintCallback(@Nullable Runnable);
415 @AnyThread public class ContentBlocking {
416 ctor protected ContentBlocking();
417 field public static final ContentBlocking.SafeBrowsingProvider GOOGLE_LEGACY_SAFE_BROWSING_PROVIDER;
418 field public static final ContentBlocking.SafeBrowsingProvider GOOGLE_SAFE_BROWSING_PROVIDER;
421 public static class ContentBlocking.AntiTracking {
422 ctor protected AntiTracking();
423 field public static final int AD = 2;
424 field public static final int ANALYTIC = 4;
425 field public static final int CONTENT = 16;
426 field public static final int CRYPTOMINING = 64;
427 field public static final int DEFAULT = 46;
428 field public static final int EMAIL = 512;
429 field public static final int FINGERPRINTING = 128;
430 field public static final int NONE = 0;
431 field public static final int SOCIAL = 8;
432 field public static final int STP = 256;
433 field public static final int STRICT = 766;
434 field public static final int TEST = 32;
437 public static class ContentBlocking.BlockEvent {
438 ctor public BlockEvent(@NonNull String, int, int, int, boolean);
439 method @UiThread public int getAntiTrackingCategory();
440 method @UiThread public int getCookieBehaviorCategory();
441 method @UiThread public int getSafeBrowsingCategory();
442 method @UiThread public boolean isBlocking();
443 field @NonNull public final String uri;
446 @Retention(value=RetentionPolicy.SOURCE) public static interface ContentBlocking.CBAntiTracking {
449 @Retention(value=RetentionPolicy.SOURCE) public static interface ContentBlocking.CBCookieBannerMode {
452 @Retention(value=RetentionPolicy.SOURCE) public static interface ContentBlocking.CBCookieBehavior {
455 @Retention(value=RetentionPolicy.SOURCE) public static interface ContentBlocking.CBEtpLevel {
458 @Retention(value=RetentionPolicy.SOURCE) public static interface ContentBlocking.CBSafeBrowsing {
461 public static class ContentBlocking.CookieBannerMode {
462 ctor protected CookieBannerMode();
463 field public static final int COOKIE_BANNER_MODE_DISABLED = 0;
464 field public static final int COOKIE_BANNER_MODE_REJECT = 1;
465 field public static final int COOKIE_BANNER_MODE_REJECT_OR_ACCEPT = 2;
468 public static class ContentBlocking.CookieBehavior {
469 ctor protected CookieBehavior();
470 field public static final int ACCEPT_ALL = 0;
471 field public static final int ACCEPT_FIRST_PARTY = 1;
472 field public static final int ACCEPT_FIRST_PARTY_AND_ISOLATE_OTHERS = 5;
473 field public static final int ACCEPT_NONE = 2;
474 field public static final int ACCEPT_NON_TRACKERS = 4;
475 field public static final int ACCEPT_VISITED = 3;
478 public static interface ContentBlocking.Delegate {
479 method @UiThread default public void onContentBlocked(@NonNull GeckoSession, @NonNull ContentBlocking.BlockEvent);
480 method @UiThread default public void onContentLoaded(@NonNull GeckoSession, @NonNull ContentBlocking.BlockEvent);
483 public static class ContentBlocking.EtpLevel {
484 ctor public EtpLevel();
485 field public static final int DEFAULT = 1;
486 field public static final int NONE = 0;
487 field public static final int STRICT = 2;
490 public static class ContentBlocking.SafeBrowsing {
491 ctor protected SafeBrowsing();
492 field public static final int DEFAULT = 15360;
493 field public static final int HARMFUL = 4096;
494 field public static final int MALWARE = 1024;
495 field public static final int NONE = 0;
496 field public static final int PHISHING = 8192;
497 field public static final int UNWANTED = 2048;
500 @AnyThread public static class ContentBlocking.SafeBrowsingProvider extends RuntimeSettings {
501 method @NonNull public static ContentBlocking.SafeBrowsingProvider.Builder from(@NonNull ContentBlocking.SafeBrowsingProvider);
502 method @Nullable public String getAdvisoryName();
503 method @Nullable public String getAdvisoryUrl();
504 method @Nullable public Boolean getDataSharingEnabled();
505 method @Nullable public String getDataSharingUrl();
506 method @Nullable public String getGetHashUrl();
507 method @NonNull public String[] getLists();
508 method @NonNull public String getName();
509 method @Nullable public String getReportMalwareMistakeUrl();
510 method @Nullable public String getReportPhishingMistakeUrl();
511 method @Nullable public String getReportUrl();
512 method @Nullable public String getUpdateUrl();
513 method @Nullable public String getVersion();
514 method @NonNull public static ContentBlocking.SafeBrowsingProvider.Builder withName(@NonNull String);
515 field public static final Parcelable.Creator<ContentBlocking.SafeBrowsingProvider> CREATOR;
518 @AnyThread public static class ContentBlocking.SafeBrowsingProvider.Builder {
519 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder advisoryName(@NonNull String);
520 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder advisoryUrl(@NonNull String);
521 method @NonNull public ContentBlocking.SafeBrowsingProvider build();
522 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder dataSharingEnabled(boolean);
523 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder dataSharingUrl(@NonNull String);
524 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder getHashUrl(@NonNull String);
525 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder lists(@NonNull String...);
526 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder reportMalwareMistakeUrl(@NonNull String);
527 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder reportPhishingMistakeUrl(@NonNull String);
528 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder reportUrl(@NonNull String);
529 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder updateUrl(@NonNull String);
530 method @NonNull public ContentBlocking.SafeBrowsingProvider.Builder version(@NonNull String);
533 @AnyThread public static class ContentBlocking.Settings extends RuntimeSettings {
534 method public int getAntiTrackingCategories();
535 method public boolean getCookieBannerDetectOnlyMode();
536 method public boolean getCookieBannerGlobalRulesEnabled();
537 method public boolean getCookieBannerGlobalRulesSubFramesEnabled();
538 method public int getCookieBannerMode();
539 method public int getCookieBannerModePrivateBrowsing();
540 method public int getCookieBehavior();
541 method public int getCookieBehaviorPrivateMode();
542 method public boolean getCookiePurging();
543 method @NonNull public Boolean getEmailTrackerBlockingPrivateBrowsingEnabled();
544 method public int getEnhancedTrackingProtectionLevel();
545 method @NonNull public String[] getQueryParameterStrippingAllowList();
546 method public boolean getQueryParameterStrippingEnabled();
547 method public boolean getQueryParameterStrippingPrivateBrowsingEnabled();
548 method @NonNull public String[] getQueryParameterStrippingStripList();
549 method public int getSafeBrowsingCategories();
550 method @NonNull public String[] getSafeBrowsingMalwareTable();
551 method @NonNull public String[] getSafeBrowsingPhishingTable();
552 method @NonNull public Collection<ContentBlocking.SafeBrowsingProvider> getSafeBrowsingProviders();
553 method public boolean getStrictSocialTrackingProtection();
554 method @NonNull public ContentBlocking.Settings setAntiTracking(int);
555 method @NonNull public ContentBlocking.Settings setCookieBannerDetectOnlyMode(boolean);
556 method @NonNull public ContentBlocking.Settings setCookieBannerGlobalRulesEnabled(boolean);
557 method @NonNull public ContentBlocking.Settings setCookieBannerGlobalRulesSubFramesEnabled(boolean);
558 method @NonNull public ContentBlocking.Settings setCookieBannerMode(int);
559 method @NonNull public ContentBlocking.Settings setCookieBannerModePrivateBrowsing(int);
560 method @NonNull public ContentBlocking.Settings setCookieBehavior(int);
561 method @NonNull public ContentBlocking.Settings setCookieBehaviorPrivateMode(int);
562 method @NonNull public ContentBlocking.Settings setCookiePurging(boolean);
563 method @NonNull public ContentBlocking.Settings setEmailTrackerBlockingPrivateBrowsing(boolean);
564 method @NonNull public ContentBlocking.Settings setEnhancedTrackingProtectionLevel(int);
565 method @NonNull public ContentBlocking.Settings setQueryParameterStrippingAllowList(@NonNull String...);
566 method @NonNull public ContentBlocking.Settings setQueryParameterStrippingEnabled(boolean);
567 method @NonNull public ContentBlocking.Settings setQueryParameterStrippingPrivateBrowsingEnabled(boolean);
568 method @NonNull public ContentBlocking.Settings setQueryParameterStrippingStripList(@NonNull String...);
569 method @NonNull public ContentBlocking.Settings setSafeBrowsing(int);
570 method @NonNull public ContentBlocking.Settings setSafeBrowsingMalwareTable(@NonNull String...);
571 method @NonNull public ContentBlocking.Settings setSafeBrowsingPhishingTable(@NonNull String...);
572 method @NonNull public ContentBlocking.Settings setSafeBrowsingProviders(@NonNull ContentBlocking.SafeBrowsingProvider...);
573 method @NonNull public ContentBlocking.Settings setStrictSocialTrackingProtection(boolean);
574 field public static final Parcelable.Creator<ContentBlocking.Settings> CREATOR;
577 @AnyThread public static class ContentBlocking.Settings.Builder extends RuntimeSettings.Builder<ContentBlocking.Settings> {
578 ctor public Builder();
579 method @NonNull public ContentBlocking.Settings.Builder antiTracking(int);
580 method @NonNull public ContentBlocking.Settings.Builder cookieBannerGlobalRulesEnabled(boolean);
581 method @NonNull public ContentBlocking.Settings.Builder cookieBannerGlobalRulesSubFramesEnabled(boolean);
582 method @NonNull public ContentBlocking.Settings.Builder cookieBannerHandlingDetectOnlyMode(boolean);
583 method @NonNull public ContentBlocking.Settings.Builder cookieBannerHandlingMode(int);
584 method @NonNull public ContentBlocking.Settings.Builder cookieBannerHandlingModePrivateBrowsing(int);
585 method @NonNull public ContentBlocking.Settings.Builder cookieBehavior(int);
586 method @NonNull public ContentBlocking.Settings.Builder cookieBehaviorPrivateMode(int);
587 method @NonNull public ContentBlocking.Settings.Builder cookiePurging(boolean);
588 method @NonNull public ContentBlocking.Settings.Builder emailTrackerBlockingPrivateMode(boolean);
589 method @NonNull public ContentBlocking.Settings.Builder enhancedTrackingProtectionLevel(int);
590 method @NonNull public ContentBlocking.Settings.Builder queryParameterStrippingAllowList(@NonNull String...);
591 method @NonNull public ContentBlocking.Settings.Builder queryParameterStrippingEnabled(boolean);
592 method @NonNull public ContentBlocking.Settings.Builder queryParameterStrippingPrivateBrowsingEnabled(boolean);
593 method @NonNull public ContentBlocking.Settings.Builder queryParameterStrippingStripList(@NonNull String...);
594 method @NonNull public ContentBlocking.Settings.Builder safeBrowsing(int);
595 method @NonNull public ContentBlocking.Settings.Builder safeBrowsingMalwareTable(@NonNull String[]);
596 method @NonNull public ContentBlocking.Settings.Builder safeBrowsingPhishingTable(@NonNull String[]);
597 method @NonNull public ContentBlocking.Settings.Builder safeBrowsingProviders(@NonNull ContentBlocking.SafeBrowsingProvider...);
598 method @NonNull public ContentBlocking.Settings.Builder strictSocialTrackingProtection(boolean);
599 method @NonNull protected ContentBlocking.Settings newSettings(@Nullable ContentBlocking.Settings);
602 @AnyThread public class ContentBlockingController {
603 ctor public ContentBlockingController();
604 method @NonNull @UiThread public GeckoResult<List<ContentBlockingController.LogEntry>> getLog(@NonNull GeckoSession);
607 public static class ContentBlockingController.Event {
608 ctor protected Event();
609 field public static final int ALLOWED_TRACKING_CONTENT = 32;
610 field public static final int BLOCKED_CRYPTOMINING_CONTENT = 2048;
611 field public static final int BLOCKED_EMAILTRACKING_CONTENT = 4194304;
612 field public static final int BLOCKED_FINGERPRINTING_CONTENT = 64;
613 field public static final int BLOCKED_SOCIALTRACKING_CONTENT = 65536;
614 field public static final int BLOCKED_TRACKING_CONTENT = 4096;
615 field public static final int BLOCKED_UNSAFE_CONTENT = 16384;
616 field public static final int COOKIES_BLOCKED_ALL = 1073741824;
617 field public static final int COOKIES_BLOCKED_BY_PERMISSION = 268435456;
618 field public static final int COOKIES_BLOCKED_FOREIGN = 128;
619 field public static final int COOKIES_BLOCKED_SOCIALTRACKER = 16777216;
620 field public static final int COOKIES_BLOCKED_TRACKER = 536870912;
621 field public static final int COOKIES_LOADED = 32768;
622 field public static final int COOKIES_LOADED_SOCIALTRACKER = 524288;
623 field public static final int COOKIES_LOADED_TRACKER = 262144;
624 field public static final int COOKIES_PARTITIONED_FOREIGN = -2147483648;
625 field public static final int LOADED_CRYPTOMINING_CONTENT = 2097152;
626 field public static final int LOADED_EMAILTRACKING_LEVEL_1_CONTENT = 8388608;
627 field public static final int LOADED_EMAILTRACKING_LEVEL_2_CONTENT = 256;
628 field public static final int LOADED_FINGERPRINTING_CONTENT = 1024;
629 field public static final int LOADED_LEVEL_1_TRACKING_CONTENT = 8192;
630 field public static final int LOADED_LEVEL_2_TRACKING_CONTENT = 1048576;
631 field public static final int LOADED_SOCIALTRACKING_CONTENT = 131072;
632 field public static final int REPLACED_TRACKING_CONTENT = 16;
635 @AnyThread public static class ContentBlockingController.LogEntry {
636 ctor protected LogEntry();
637 field @NonNull public final List<ContentBlockingController.LogEntry.BlockingData> blockingData;
638 field @NonNull public final String origin;
641 public static class ContentBlockingController.LogEntry.BlockingData {
642 ctor protected BlockingData();
643 field public final boolean blocked;
644 field public final int category;
645 field public final int count;
648 @Retention(value=RetentionPolicy.SOURCE) public static interface ContentBlockingController.LogEntry.BlockingData.LogEvent {
651 @FunctionalInterface public class CrashHandler implements Thread.UncaughtExceptionHandler {
652 ctor public CrashHandler(@Nullable Class<? extends android.app.Service>);
653 ctor public CrashHandler(@Nullable Context, @Nullable Class<? extends android.app.Service>);
654 ctor public CrashHandler(Thread, Class<? extends android.app.Service>);
655 ctor public CrashHandler(@Nullable Thread, Context, Class<? extends android.app.Service>);
656 method @AnyThread @NonNull public static CrashHandler createDefaultCrashHandler(@NonNull Context);
657 method @AnyThread @Nullable public Context getAppContext();
658 method @AnyThread @Nullable public String getAppPackageName();
659 method @AnyThread @NonNull public byte[] getCrashDump(@Nullable Thread, @Nullable Throwable);
660 method @AnyThread @NonNull public Bundle getCrashExtras(@NonNull Thread, @NonNull Throwable);
661 method @AnyThread @NonNull public static String getExceptionStackTrace(@NonNull Throwable);
662 method @AnyThread @NonNull public static Throwable getRootException(@NonNull Throwable);
663 method @AnyThread @NonNull public String getServerUrl(@NonNull Bundle);
664 method @AnyThread public boolean launchCrashReporter(@NonNull String, @NonNull String);
665 method @AnyThread public static void logException(@NonNull Thread, @NonNull Throwable);
666 method @AnyThread public boolean reportException(@NonNull Thread, @NonNull Throwable);
667 method @AnyThread public static void terminateProcess();
668 method @AnyThread public void unregister();
671 public class CrashReporter {
672 ctor public CrashReporter();
673 method @AnyThread @NonNull public static GeckoResult<String> sendCrashReport(@NonNull Context, @NonNull Intent, @NonNull String);
674 method @AnyThread @NonNull public static GeckoResult<String> sendCrashReport(@NonNull Context, @NonNull Bundle, @NonNull String);
675 method @AnyThread @NonNull public static GeckoResult<String> sendCrashReport(@NonNull Context, @NonNull File, @NonNull File, @NonNull String);
676 method @AnyThread @NonNull public static GeckoResult<String> sendCrashReport(@NonNull String, @NonNull File, @NonNull JSONObject);
679 @Documented @Retention(value=RetentionPolicy.RUNTIME) @Target(value={ElementType.CONSTRUCTOR, ElementType.FIELD, ElementType.LOCAL_VARIABLE, ElementType.METHOD, ElementType.PACKAGE, ElementType.PARAMETER, ElementType.TYPE}) public interface DeprecationSchedule {
680 element public String id();
681 element public int version();
684 public interface ExperimentDelegate {
685 method @AnyThread @NonNull default public GeckoResult<JSONObject> onGetExperimentFeature(@NonNull String);
686 method @AnyThread @NonNull default public GeckoResult<Void> onRecordExperimentExposureEvent(@NonNull String, @NonNull String);
687 method @AnyThread @NonNull default public GeckoResult<Void> onRecordExposureEvent(@NonNull String);
688 method @AnyThread @NonNull default public GeckoResult<Void> onRecordMalformedConfigurationEvent(@NonNull String, @NonNull String);
691 public static class ExperimentDelegate.ExperimentException extends Exception {
692 ctor public ExperimentException(int);
693 field public static final int ERROR_EXPERIMENT_DELEGATE_NOT_IMPLEMENTED = -4;
694 field public static final int ERROR_EXPERIMENT_SLUG_NOT_FOUND = -3;
695 field public static final int ERROR_FEATURE_NOT_FOUND = -2;
696 field public static final int ERROR_UNKNOWN = -1;
697 field public final int code;
700 @Retention(value=RetentionPolicy.SOURCE) public static interface ExperimentDelegate.ExperimentException.Codes {
703 public class GeckoDisplay {
704 ctor protected GeckoDisplay(GeckoSession);
705 method @NonNull @UiThread public GeckoResult<Bitmap> capturePixels();
706 method @UiThread public void safeAreaInsetsChanged(int, int, int, int);
707 method @UiThread public void screenOriginChanged(int, int);
708 method @NonNull @UiThread public GeckoDisplay.ScreenshotBuilder screenshot();
709 method @UiThread public void setDynamicToolbarMaxHeight(int);
710 method @UiThread public void setVerticalClipping(int);
711 method @UiThread public boolean shouldPinOnScreen();
712 method @UiThread public void surfaceChanged(@NonNull GeckoDisplay.SurfaceInfo);
713 method @UiThread public void surfaceDestroyed();
716 public static interface GeckoDisplay.NewSurfaceProvider {
717 method @UiThread public void requestNewSurface();
720 public static final class GeckoDisplay.ScreenshotBuilder {
721 method @AnyThread @NonNull public GeckoDisplay.ScreenshotBuilder aspectPreservingSize(int);
722 method @AnyThread @NonNull public GeckoDisplay.ScreenshotBuilder bitmap(@Nullable Bitmap);
723 method @NonNull @UiThread public GeckoResult<Bitmap> capture();
724 method @AnyThread @NonNull public GeckoDisplay.ScreenshotBuilder scale(float);
725 method @AnyThread @NonNull public GeckoDisplay.ScreenshotBuilder size(int, int);
726 method @AnyThread @NonNull public GeckoDisplay.ScreenshotBuilder source(int, int, int, int);
727 method @AnyThread @NonNull public GeckoDisplay.ScreenshotBuilder source(@NonNull Rect);
730 public static class GeckoDisplay.SurfaceInfo {
733 public static class GeckoDisplay.SurfaceInfo.Builder {
734 ctor public Builder(@NonNull Surface);
735 method @NonNull @UiThread public GeckoDisplay.SurfaceInfo build();
736 method @NonNull @UiThread public GeckoDisplay.SurfaceInfo.Builder newSurfaceProvider(@Nullable GeckoDisplay.NewSurfaceProvider);
737 method @NonNull @UiThread public GeckoDisplay.SurfaceInfo.Builder offset(int, int);
738 method @NonNull @UiThread public GeckoDisplay.SurfaceInfo.Builder size(int, int);
739 method @NonNull @UiThread public GeckoDisplay.SurfaceInfo.Builder surfaceControl(@Nullable SurfaceControl);
742 @AnyThread public class GeckoResult<T> {
743 ctor public GeckoResult();
744 ctor public GeckoResult(Handler);
745 ctor public GeckoResult(GeckoResult<T>);
746 method @NonNull public GeckoResult<Void> accept(@Nullable GeckoResult.Consumer<T>);
747 method @NonNull public GeckoResult<Void> accept(@Nullable GeckoResult.Consumer<T>, @Nullable GeckoResult.Consumer<Throwable>);
748 method @NonNull @SafeVarargs public static <V> GeckoResult<List<V>> allOf(@NonNull GeckoResult<V>...);
749 method @NonNull public static <V> GeckoResult<List<V>> allOf(@Nullable List<GeckoResult<V>>);
750 method @AnyThread @NonNull public static GeckoResult<AllowOrDeny> allow();
751 method @NonNull public synchronized GeckoResult<Boolean> cancel();
752 method public synchronized void complete(@Nullable T);
753 method public synchronized void completeExceptionally(@NonNull Throwable);
754 method public void completeFrom(@Nullable GeckoResult<T>);
755 method @AnyThread @NonNull public static GeckoResult<AllowOrDeny> deny();
756 method @NonNull public <U> GeckoResult<U> exceptionally(@NonNull GeckoResult.OnExceptionListener<U>);
757 method @NonNull public GeckoResult<Void> finally_(@NonNull Runnable);
758 method @NonNull public static <T> GeckoResult<T> fromException(@NonNull Throwable);
759 method @NonNull public static <U> GeckoResult<U> fromValue(@Nullable U);
760 method @Nullable public Looper getLooper();
761 method @NonNull public <U> GeckoResult<U> map(@Nullable GeckoResult.OnValueMapper<T,U>);
762 method @NonNull public <U> GeckoResult<U> map(@Nullable GeckoResult.OnValueMapper<T,U>, @Nullable GeckoResult.OnExceptionMapper);
763 method @Nullable public synchronized T poll();
764 method @Nullable public synchronized T poll(long);
765 method public void setCancellationDelegate(@Nullable GeckoResult.CancellationDelegate);
766 method @NonNull public <U> GeckoResult<U> then(@NonNull GeckoResult.OnValueListener<T,U>);
767 method @NonNull public <U> GeckoResult<U> then(@Nullable GeckoResult.OnValueListener<T,U>, @Nullable GeckoResult.OnExceptionListener<U>);
768 method @NonNull public GeckoResult<T> withHandler(@Nullable Handler);
771 @AnyThread public static interface GeckoResult.CancellationDelegate {
772 method @NonNull default public GeckoResult<Boolean> cancel();
775 public static interface GeckoResult.Consumer<T> {
776 method @AnyThread public void accept(@Nullable T);
779 public static interface GeckoResult.OnExceptionListener<V> {
780 method @AnyThread @Nullable public GeckoResult<V> onException(@NonNull Throwable);
783 public static interface GeckoResult.OnExceptionMapper {
784 method @AnyThread @Nullable public Throwable onException(@NonNull Throwable);
787 public static interface GeckoResult.OnValueListener<T,U> {
788 method @AnyThread @Nullable public GeckoResult<U> onValue(@Nullable T);
791 public static interface GeckoResult.OnValueMapper<T,U> {
792 method @AnyThread @Nullable public U onValue(@Nullable T);
795 public static final class GeckoResult.UncaughtException extends RuntimeException {
796 ctor public UncaughtException(Throwable);
799 public final class GeckoRuntime implements Parcelable {
800 method @AnyThread public void appendAppNotesToCrashReport(@NonNull String);
801 method @UiThread public void attachTo(@NonNull Context);
802 method @UiThread public void configurationChanged(@NonNull Configuration);
803 method @NonNull @UiThread public static GeckoRuntime create(@NonNull Context);
804 method @NonNull @UiThread public static GeckoRuntime create(@NonNull Context, @NonNull GeckoRuntimeSettings);
805 method @Nullable @UiThread public GeckoRuntime.ActivityDelegate getActivityDelegate();
806 method @Nullable @UiThread public Autocomplete.StorageDelegate getAutocompleteStorageDelegate();
807 method @NonNull @UiThread public ContentBlockingController getContentBlockingController();
808 method @NonNull @UiThread public static synchronized GeckoRuntime getDefault(@NonNull Context);
809 method @Nullable @UiThread public GeckoRuntime.Delegate getDelegate();
810 method @NonNull @UiThread public OrientationController getOrientationController();
811 method @NonNull @UiThread public ProfilerController getProfilerController();
812 method @Nullable @UiThread public GeckoRuntime.ServiceWorkerDelegate getServiceWorkerDelegate();
813 method @AnyThread @NonNull public GeckoRuntimeSettings getSettings();
814 method @NonNull @UiThread public StorageController getStorageController();
815 method @NonNull @UiThread public WebExtensionController getWebExtensionController();
816 method @Nullable @UiThread public WebNotificationDelegate getWebNotificationDelegate();
817 method @NonNull @UiThread public WebPushController getWebPushController();
818 method @UiThread public void orientationChanged();
819 method @UiThread public void orientationChanged(int);
820 method @AnyThread public void readFromParcel(@NonNull Parcel);
821 method @UiThread public void setActivityDelegate(@Nullable GeckoRuntime.ActivityDelegate);
822 method @UiThread public void setAutocompleteStorageDelegate(@Nullable Autocomplete.StorageDelegate);
823 method @UiThread public void setDelegate(@Nullable GeckoRuntime.Delegate);
824 method @UiThread public void setServiceWorkerDelegate(@Nullable GeckoRuntime.ServiceWorkerDelegate);
825 method @UiThread public void setWebNotificationDelegate(@Nullable WebNotificationDelegate);
826 method @AnyThread public void shutdown();
827 field public static final String ACTION_CRASHED = "org.mozilla.gecko.ACTION_CRASHED";
828 field public static final String CRASHED_PROCESS_TYPE_BACKGROUND_CHILD = "BACKGROUND_CHILD";
829 field public static final String CRASHED_PROCESS_TYPE_FOREGROUND_CHILD = "FOREGROUND_CHILD";
830 field public static final String CRASHED_PROCESS_TYPE_MAIN = "MAIN";
831 field public static final Parcelable.Creator<GeckoRuntime> CREATOR;
832 field public static final String EXTRA_CRASH_PROCESS_TYPE = "processType";
833 field public static final String EXTRA_CRASH_REMOTE_TYPE = "remoteType";
834 field public static final String EXTRA_EXTRAS_PATH = "extrasPath";
835 field public static final String EXTRA_MINIDUMP_PATH = "minidumpPath";
838 public static interface GeckoRuntime.ActivityDelegate {
839 method @Nullable @UiThread public GeckoResult<Intent> onStartActivityForResult(@NonNull PendingIntent);
842 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoRuntime.CrashedProcessType {
845 public static interface GeckoRuntime.Delegate {
846 method @UiThread public void onShutdown();
849 @UiThread public static interface GeckoRuntime.ServiceWorkerDelegate {
850 method @NonNull @UiThread public GeckoResult<GeckoSession> onOpenWindow(@NonNull String);
853 @AnyThread public final class GeckoRuntimeSettings extends RuntimeSettings {
854 method public boolean getAboutConfigEnabled();
855 method public int getAllowInsecureConnections();
856 method @NonNull public String[] getArguments();
857 method public boolean getAutomaticFontSizeAdjustment();
858 method @Nullable public String getConfigFilePath();
859 method public boolean getConsoleOutputEnabled();
860 method @NonNull public ContentBlocking.Settings getContentBlocking();
861 method @Nullable public Class<? extends android.app.Service> getCrashHandler();
862 method @Nullable public Float getDisplayDensityOverride();
863 method @Nullable public Integer getDisplayDpiOverride();
864 method public boolean getDoubleTapZoomingEnabled();
865 method public boolean getEnterpriseRootsEnabled();
866 method @AnyThread @Nullable public ExperimentDelegate getExperimentDelegate();
867 method @Nullable public Integer getExtensionsProcessCrashThreshold();
868 method @Nullable public Long getExtensionsProcessCrashTimeframe();
869 method @Nullable public Boolean getExtensionsProcessEnabled();
870 method public boolean getExtensionsWebAPIEnabled();
871 method @NonNull public Bundle getExtras();
872 method public boolean getFontInflationEnabled();
873 method public float getFontSizeFactor();
874 method public boolean getForceEnableAccessibility();
875 method public boolean getForceUserScalableEnabled();
876 method public int getGlMsaaLevel();
877 method public boolean getGlobalPrivacyControl();
878 method public boolean getGlobalPrivacyControlPrivateMode();
879 method public boolean getInputAutoZoomEnabled();
880 method public boolean getJavaScriptEnabled();
881 method @NonNull public int getLargeKeepaliveFactor();
882 method @Nullable public String[] getLocales();
883 method public boolean getLoginAutofillEnabled();
884 method public boolean getPauseForDebuggerEnabled();
885 method public int getPreferredColorScheme();
886 method public boolean getRemoteDebuggingEnabled();
887 method @Nullable public GeckoRuntime getRuntime();
888 method @Nullable public Rect getScreenSizeOverride();
889 method @Nullable public RuntimeTelemetry.Delegate getTelemetryDelegate();
890 method public boolean getTranslationsOfferPopup();
891 method @NonNull public String getTrustedRecursiveResolverUri();
892 method public int getTrustedRecusiveResolverMode();
893 method public boolean getUseMaxScreenDepth();
894 method public boolean getWebFontsEnabled();
895 method public boolean getWebManifestEnabled();
896 method @NonNull public GeckoRuntimeSettings setAboutConfigEnabled(boolean);
897 method @NonNull public GeckoRuntimeSettings setAllowInsecureConnections(int);
898 method @NonNull public GeckoRuntimeSettings setAutomaticFontSizeAdjustment(boolean);
899 method @NonNull public GeckoRuntimeSettings setConsoleOutputEnabled(boolean);
900 method @NonNull public GeckoRuntimeSettings setDoubleTapZoomingEnabled(boolean);
901 method @NonNull public GeckoRuntimeSettings setEnterpriseRootsEnabled(boolean);
902 method @NonNull public GeckoRuntimeSettings setExtensionsProcessCrashThreshold(@NonNull Integer);
903 method @NonNull public GeckoRuntimeSettings setExtensionsProcessCrashTimeframe(@NonNull Long);
904 method @NonNull public GeckoRuntimeSettings setExtensionsProcessEnabled(boolean);
905 method @NonNull public GeckoRuntimeSettings setExtensionsWebAPIEnabled(boolean);
906 method @NonNull public GeckoRuntimeSettings setFontInflationEnabled(boolean);
907 method @NonNull public GeckoRuntimeSettings setFontSizeFactor(float);
908 method @NonNull public GeckoRuntimeSettings setForceEnableAccessibility(boolean);
909 method @NonNull public GeckoRuntimeSettings setForceUserScalableEnabled(boolean);
910 method @NonNull public GeckoRuntimeSettings setGlMsaaLevel(int);
911 method @NonNull public GeckoRuntimeSettings setGlobalPrivacyControl(boolean);
912 method @NonNull public GeckoRuntimeSettings setInputAutoZoomEnabled(boolean);
913 method @NonNull public GeckoRuntimeSettings setJavaScriptEnabled(boolean);
914 method @NonNull public GeckoRuntimeSettings setLargeKeepaliveFactor(int);
915 method public void setLocales(@Nullable String[]);
916 method @NonNull public GeckoRuntimeSettings setLoginAutofillEnabled(boolean);
917 method @NonNull public GeckoRuntimeSettings setPreferredColorScheme(int);
918 method @NonNull public GeckoRuntimeSettings setRemoteDebuggingEnabled(boolean);
919 method @NonNull public GeckoRuntimeSettings setTranslationsOfferPopup(boolean);
920 method @NonNull public GeckoRuntimeSettings setTrustedRecursiveResolverMode(int);
921 method @NonNull public GeckoRuntimeSettings setTrustedRecursiveResolverUri(@NonNull String);
922 method @NonNull public GeckoRuntimeSettings setWebFontsEnabled(boolean);
923 method @NonNull public GeckoRuntimeSettings setWebManifestEnabled(boolean);
924 field public static final int ALLOW_ALL = 0;
925 field public static final int COLOR_SCHEME_DARK = 1;
926 field public static final int COLOR_SCHEME_LIGHT = 0;
927 field public static final int COLOR_SCHEME_SYSTEM = -1;
928 field public static final Parcelable.Creator<GeckoRuntimeSettings> CREATOR;
929 field public static final int HTTPS_ONLY = 2;
930 field public static final int HTTPS_ONLY_PRIVATE = 1;
931 field public static final int TRR_MODE_DISABLED = 5;
932 field public static final int TRR_MODE_FIRST = 2;
933 field public static final int TRR_MODE_OFF = 0;
934 field public static final int TRR_MODE_ONLY = 3;
937 @AnyThread public static final class GeckoRuntimeSettings.Builder extends RuntimeSettings.Builder<GeckoRuntimeSettings> {
938 ctor public Builder();
939 method @NonNull public GeckoRuntimeSettings.Builder aboutConfigEnabled(boolean);
940 method @NonNull public GeckoRuntimeSettings.Builder allowInsecureConnections(int);
941 method @NonNull public GeckoRuntimeSettings.Builder arguments(@NonNull String[]);
942 method @NonNull public GeckoRuntimeSettings.Builder automaticFontSizeAdjustment(boolean);
943 method @NonNull public GeckoRuntimeSettings.Builder configFilePath(@Nullable String);
944 method @NonNull public GeckoRuntimeSettings.Builder consoleOutput(boolean);
945 method @NonNull public GeckoRuntimeSettings.Builder contentBlocking(@NonNull ContentBlocking.Settings);
946 method @NonNull public GeckoRuntimeSettings.Builder crashHandler(@Nullable Class<? extends android.app.Service>);
947 method @NonNull public GeckoRuntimeSettings.Builder debugLogging(boolean);
948 method @NonNull public GeckoRuntimeSettings.Builder displayDensityOverride(float);
949 method @NonNull public GeckoRuntimeSettings.Builder displayDpiOverride(int);
950 method @NonNull public GeckoRuntimeSettings.Builder doubleTapZoomingEnabled(boolean);
951 method @NonNull public GeckoRuntimeSettings.Builder enterpriseRootsEnabled(boolean);
952 method @AnyThread @NonNull public GeckoRuntimeSettings.Builder experimentDelegate(@Nullable ExperimentDelegate);
953 method @NonNull public GeckoRuntimeSettings.Builder extensionsProcessCrashThreshold(@NonNull Integer);
954 method @NonNull public GeckoRuntimeSettings.Builder extensionsProcessCrashTimeframe(@NonNull Long);
955 method @NonNull public GeckoRuntimeSettings.Builder extensionsProcessEnabled(boolean);
956 method @NonNull public GeckoRuntimeSettings.Builder extensionsWebAPIEnabled(boolean);
957 method @NonNull public GeckoRuntimeSettings.Builder extras(@NonNull Bundle);
958 method @NonNull public GeckoRuntimeSettings.Builder fontInflation(boolean);
959 method @NonNull public GeckoRuntimeSettings.Builder fontSizeFactor(float);
960 method @NonNull public GeckoRuntimeSettings.Builder forceUserScalableEnabled(boolean);
961 method @NonNull public GeckoRuntimeSettings.Builder glMsaaLevel(int);
962 method @NonNull public GeckoRuntimeSettings.Builder globalPrivacyControlEnabled(boolean);
963 method @NonNull public GeckoRuntimeSettings.Builder inputAutoZoomEnabled(boolean);
964 method @NonNull public GeckoRuntimeSettings.Builder javaScriptEnabled(boolean);
965 method @NonNull public GeckoRuntimeSettings.Builder largeKeepaliveFactor(int);
966 method @NonNull public GeckoRuntimeSettings.Builder locales(@Nullable String[]);
967 method @NonNull public GeckoRuntimeSettings.Builder loginAutofillEnabled(boolean);
968 method @NonNull public GeckoRuntimeSettings.Builder pauseForDebugger(boolean);
969 method @NonNull public GeckoRuntimeSettings.Builder preferredColorScheme(int);
970 method @NonNull public GeckoRuntimeSettings.Builder remoteDebuggingEnabled(boolean);
971 method @NonNull public GeckoRuntimeSettings.Builder screenSizeOverride(int, int);
972 method @Deprecated @DeprecationSchedule(id="geckoview-gvst",version=127) @NonNull public GeckoRuntimeSettings.Builder telemetryDelegate(@NonNull RuntimeTelemetry.Delegate);
973 method @NonNull public GeckoRuntimeSettings.Builder translationsOfferPopup(boolean);
974 method @NonNull public GeckoRuntimeSettings.Builder trustedRecursiveResolverMode(int);
975 method @NonNull public GeckoRuntimeSettings.Builder trustedRecursiveResolverUri(@NonNull String);
976 method @NonNull public GeckoRuntimeSettings.Builder useMaxScreenDepth(boolean);
977 method @NonNull public GeckoRuntimeSettings.Builder webFontsEnabled(boolean);
978 method @NonNull public GeckoRuntimeSettings.Builder webManifest(boolean);
979 method @NonNull protected GeckoRuntimeSettings newSettings(@Nullable GeckoRuntimeSettings);
982 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoRuntimeSettings.ColorScheme {
985 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoRuntimeSettings.HttpsOnlyMode {
988 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoRuntimeSettings.TrustedRecursiveResolverMode {
991 public class GeckoSession {
992 ctor public GeckoSession();
993 ctor public GeckoSession(@Nullable GeckoSessionSettings);
994 method @NonNull @UiThread public GeckoDisplay acquireDisplay();
995 method @UiThread public void close();
996 method @AnyThread @NonNull public GeckoResult<Boolean> containsFormData();
997 method @AnyThread @NonNull public GeckoResult<Boolean> didPrintPageContent();
998 method @AnyThread public void exitFullScreen();
999 method @NonNull @UiThread public SessionAccessibility getAccessibility();
1000 method @Nullable @UiThread public Autofill.Delegate getAutofillDelegate();
1001 method @NonNull @UiThread public Autofill.Session getAutofillSession();
1002 method @UiThread public void getClientBounds(@NonNull RectF);
1003 method @UiThread public void getClientToScreenMatrix(@NonNull Matrix);
1004 method @UiThread public void getClientToSurfaceMatrix(@NonNull Matrix);
1005 method @NonNull @UiThread public CompositorController getCompositorController();
1006 method @AnyThread @Nullable public ContentBlocking.Delegate getContentBlockingDelegate();
1007 method @Nullable @UiThread public GeckoSession.ContentDelegate getContentDelegate();
1008 method @AnyThread @NonNull public static String getDefaultUserAgent();
1009 method @AnyThread @Nullable public ExperimentDelegate getExperimentDelegate();
1010 method @AnyThread @NonNull public SessionFinder getFinder();
1011 method @AnyThread @Nullable public GeckoSession.HistoryDelegate getHistoryDelegate();
1012 method @AnyThread @Nullable public GeckoSession.MediaDelegate getMediaDelegate();
1013 method @AnyThread @Nullable public MediaSession.Delegate getMediaSessionDelegate();
1014 method @Nullable @UiThread public GeckoSession.NavigationDelegate getNavigationDelegate();
1015 method @NonNull @UiThread public OverscrollEdgeEffect getOverscrollEdgeEffect();
1016 method @UiThread public void getPageToScreenMatrix(@NonNull Matrix);
1017 method @UiThread public void getPageToSurfaceMatrix(@NonNull Matrix);
1018 method @NonNull @UiThread public PanZoomController getPanZoomController();
1019 method @AnyThread @NonNull public SessionPdfFileSaver getPdfFileSaver();
1020 method @Nullable @UiThread public GeckoSession.PermissionDelegate getPermissionDelegate();
1021 method @AnyThread @Nullable public GeckoSession.PrintDelegate getPrintDelegate();
1022 method @Nullable @UiThread public GeckoSession.ProgressDelegate getProgressDelegate();
1023 method @AnyThread @Nullable public GeckoSession.PromptDelegate getPromptDelegate();
1024 method @Nullable @UiThread public GeckoSession.ScrollDelegate getScrollDelegate();
1025 method @AnyThread @Nullable public GeckoSession.SelectionActionDelegate getSelectionActionDelegate();
1026 method @AnyThread @Nullable public TranslationsController.SessionTranslation getSessionTranslation();
1027 method @AnyThread @NonNull public GeckoSessionSettings getSettings();
1028 method @UiThread public void getSurfaceBounds(@NonNull Rect);
1029 method @AnyThread @NonNull public SessionTextInput getTextInput();
1030 method @AnyThread @Nullable public TranslationsController.SessionTranslation.Delegate getTranslationsSessionDelegate();
1031 method @AnyThread @NonNull public GeckoResult<String> getUserAgent();
1032 method @NonNull @UiThread public WebExtension.SessionController getWebExtensionController();
1033 method @AnyThread public void goBack();
1034 method @AnyThread public void goBack(boolean);
1035 method @AnyThread public void goForward();
1036 method @AnyThread public void goForward(boolean);
1037 method @AnyThread public void gotoHistoryIndex(int);
1038 method @AnyThread @NonNull public GeckoResult<Boolean> hasCookieBannerRuleForBrowsingContextTree();
1039 method @UiThread public boolean isOpen();
1040 method @AnyThread @NonNull public GeckoResult<Boolean> isPdfJs();
1041 method @AnyThread public void load(@NonNull GeckoSession.Loader);
1042 method @AnyThread public void loadUri(@NonNull String);
1043 method @UiThread public void open(@NonNull GeckoRuntime);
1044 method @AnyThread @NonNull public GeckoResult<String> pollForAnalysisCompleted(@NonNull String);
1045 method @AnyThread public void printPageContent();
1046 method @AnyThread public void purgeHistory();
1047 method @UiThread public void releaseDisplay(@NonNull GeckoDisplay);
1048 method @AnyThread public void reload();
1049 method @AnyThread public void reload(int);
1050 method @AnyThread @NonNull public GeckoResult<String> reportBackInStock(@NonNull String);
1051 method @AnyThread @NonNull public GeckoResult<GeckoSession.ReviewAnalysis> requestAnalysis(@NonNull String);
1052 method @AnyThread @NonNull public GeckoResult<GeckoSession.AnalysisStatusResponse> requestAnalysisStatus(@NonNull String);
1053 method @AnyThread @NonNull public GeckoResult<String> requestCreateAnalysis(@NonNull String);
1054 method @AnyThread @NonNull public GeckoResult<List<GeckoSession.Recommendation>> requestRecommendations(@NonNull String);
1055 method @AnyThread public void restoreState(@NonNull GeckoSession.SessionState);
1056 method @AnyThread @NonNull public GeckoResult<InputStream> saveAsPdf();
1057 method @AnyThread @NonNull public GeckoResult<Boolean> sendClickAttributionEvent(@NonNull String);
1058 method @AnyThread @NonNull public GeckoResult<Boolean> sendImpressionAttributionEvent(@NonNull String);
1059 method @AnyThread @NonNull public GeckoResult<Boolean> sendPlacementAttributionEvent(@NonNull String);
1060 method @AnyThread public void setActive(boolean);
1061 method @UiThread public void setAutofillDelegate(@Nullable Autofill.Delegate);
1062 method @AnyThread public void setContentBlockingDelegate(@Nullable ContentBlocking.Delegate);
1063 method @UiThread public void setContentDelegate(@Nullable GeckoSession.ContentDelegate);
1064 method @AnyThread public void setExperimentDelegate(@Nullable ExperimentDelegate);
1065 method @AnyThread public void setFocused(boolean);
1066 method @AnyThread public void setHistoryDelegate(@Nullable GeckoSession.HistoryDelegate);
1067 method @AnyThread public void setMediaDelegate(@Nullable GeckoSession.MediaDelegate);
1068 method @AnyThread public void setMediaSessionDelegate(@Nullable MediaSession.Delegate);
1069 method @UiThread public void setNavigationDelegate(@Nullable GeckoSession.NavigationDelegate);
1070 method @UiThread public void setPermissionDelegate(@Nullable GeckoSession.PermissionDelegate);
1071 method @AnyThread public void setPrintDelegate(@Nullable GeckoSession.PrintDelegate);
1072 method @AnyThread public void setPriorityHint(int);
1073 method @UiThread public void setProgressDelegate(@Nullable GeckoSession.ProgressDelegate);
1074 method @AnyThread public void setPromptDelegate(@Nullable GeckoSession.PromptDelegate);
1075 method @UiThread public void setScrollDelegate(@Nullable GeckoSession.ScrollDelegate);
1076 method @UiThread public void setSelectionActionDelegate(@Nullable GeckoSession.SelectionActionDelegate);
1077 method @AnyThread public void setTranslationsSessionDelegate(@Nullable TranslationsController.SessionTranslation.Delegate);
1078 method @AnyThread public void stop();
1079 method @UiThread protected void setShouldPinOnScreen(boolean);
1080 field public static final int FINDER_DISPLAY_DIM_PAGE = 2;
1081 field public static final int FINDER_DISPLAY_DRAW_LINK_OUTLINE = 4;
1082 field public static final int FINDER_DISPLAY_HIGHLIGHT_ALL = 1;
1083 field public static final int FINDER_FIND_BACKWARDS = 1;
1084 field public static final int FINDER_FIND_LINKS_ONLY = 8;
1085 field public static final int FINDER_FIND_MATCH_CASE = 2;
1086 field public static final int FINDER_FIND_WHOLE_WORD = 4;
1087 field public static final int HEADER_FILTER_CORS_SAFELISTED = 1;
1088 field public static final int HEADER_FILTER_UNRESTRICTED_UNSAFE = 2;
1089 field public static final int LOAD_FLAGS_ALLOW_POPUPS = 8;
1090 field public static final int LOAD_FLAGS_BYPASS_CACHE = 1;
1091 field public static final int LOAD_FLAGS_BYPASS_CLASSIFIER = 16;
1092 field public static final int LOAD_FLAGS_BYPASS_LOAD_URI_DELEGATE = 128;
1093 field public static final int LOAD_FLAGS_BYPASS_PROXY = 2;
1094 field public static final int LOAD_FLAGS_EXTERNAL = 4;
1095 field public static final int LOAD_FLAGS_FORCE_ALLOW_DATA_URI = 32;
1096 field public static final int LOAD_FLAGS_NONE = 0;
1097 field public static final int LOAD_FLAGS_REPLACE_HISTORY = 64;
1098 field public static final int PRIORITY_DEFAULT = 0;
1099 field public static final int PRIORITY_HIGH = 1;
1100 field @Nullable protected GeckoSession.Window mWindow;
1103 @AnyThread public static class GeckoSession.AnalysisStatusResponse {
1104 ctor protected AnalysisStatusResponse(@NonNull GeckoSession.AnalysisStatusResponse.Builder);
1105 field @NonNull public final Double progress;
1106 field @NonNull public final String status;
1109 public static class GeckoSession.AnalysisStatusResponse.Builder {
1110 ctor public Builder(@NonNull String);
1111 method @AnyThread @NonNull public GeckoSession.AnalysisStatusResponse build();
1112 method @AnyThread @NonNull public GeckoSession.AnalysisStatusResponse.Builder progress(@NonNull Double);
1113 method @AnyThread @NonNull public GeckoSession.AnalysisStatusResponse.Builder status(@NonNull String);
1116 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.ClipboardPermissionType {
1119 public static interface GeckoSession.ContentDelegate {
1120 method @UiThread default public void onCloseRequest(@NonNull GeckoSession);
1121 method @UiThread default public void onContextMenu(@NonNull GeckoSession, int, int, @NonNull GeckoSession.ContentDelegate.ContextElement);
1122 method @AnyThread default public void onCookieBannerDetected(@NonNull GeckoSession);
1123 method @AnyThread default public void onCookieBannerHandled(@NonNull GeckoSession);
1124 method @UiThread default public void onCrash(@NonNull GeckoSession);
1125 method @UiThread default public void onExternalResponse(@NonNull GeckoSession, @NonNull WebResponse);
1126 method @UiThread default public void onFirstComposite(@NonNull GeckoSession);
1127 method @UiThread default public void onFirstContentfulPaint(@NonNull GeckoSession);
1128 method @UiThread default public void onFocusRequest(@NonNull GeckoSession);
1129 method @UiThread default public void onFullScreen(@NonNull GeckoSession, boolean);
1130 method @UiThread default public void onKill(@NonNull GeckoSession);
1131 method @UiThread default public void onMetaViewportFitChange(@NonNull GeckoSession, @NonNull String);
1132 method @UiThread default public void onPaintStatusReset(@NonNull GeckoSession);
1133 method @UiThread default public void onPointerIconChange(@NonNull GeckoSession, @NonNull PointerIcon);
1134 method @UiThread default public void onPreviewImage(@NonNull GeckoSession, @NonNull String);
1135 method @UiThread default public void onProductUrl(@NonNull GeckoSession);
1136 method @UiThread default public void onShowDynamicToolbar(@NonNull GeckoSession);
1137 method @Nullable @UiThread default public GeckoResult<SlowScriptResponse> onSlowScript(@NonNull GeckoSession, @NonNull String);
1138 method @UiThread default public void onTitleChange(@NonNull GeckoSession, @Nullable String);
1139 method @UiThread default public void onWebAppManifest(@NonNull GeckoSession, @NonNull JSONObject);
1142 public static class GeckoSession.ContentDelegate.ContextElement {
1143 ctor protected ContextElement(@Nullable String, @Nullable String, @Nullable String, @Nullable String, @NonNull String, @Nullable String, @Nullable String);
1144 ctor protected ContextElement(@Nullable String, @Nullable String, @Nullable String, @Nullable String, @NonNull String, @Nullable String);
1145 field public static final int TYPE_AUDIO = 3;
1146 field public static final int TYPE_IMAGE = 1;
1147 field public static final int TYPE_NONE = 0;
1148 field public static final int TYPE_VIDEO = 2;
1149 field @Nullable public final String altText;
1150 field @Nullable public final String baseUri;
1151 field @Nullable public final String linkUri;
1152 field @Nullable public final String srcUri;
1153 field @Nullable public final String textContent;
1154 field @Nullable public final String title;
1155 field public final int type;
1158 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.ContentDelegate.ContextElement.Type {
1161 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.FinderDisplayFlags {
1164 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.FinderFindFlags {
1167 @AnyThread public static class GeckoSession.FinderResult {
1168 ctor protected FinderResult();
1169 field @Nullable public final RectF clientRect;
1170 field public final int current;
1171 field public final int flags;
1172 field public final boolean found;
1173 field @Nullable public final String linkUri;
1174 field @NonNull public final String searchString;
1175 field public final int total;
1176 field public final boolean wrapped;
1179 public static class GeckoSession.GeckoPrintException extends Exception {
1180 ctor protected GeckoPrintException();
1181 field public static final int ERROR_NO_ACTIVITY_CONTEXT = -5;
1182 field public static final int ERROR_NO_ACTIVITY_CONTEXT_DELEGATE = -4;
1183 field public static final int ERROR_NO_PRINT_DELEGATE = -6;
1184 field public static final int ERROR_PRINT_SETTINGS_SERVICE_NOT_AVAILABLE = -1;
1185 field public static final int ERROR_UNABLE_TO_CREATE_PRINT_SETTINGS = -2;
1186 field public static final int ERROR_UNABLE_TO_RETRIEVE_CANONICAL_BROWSING_CONTEXT = -3;
1187 field public final int code;
1190 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.GeckoPrintException.Codes {
1193 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.HeaderFilter {
1196 public static interface GeckoSession.HistoryDelegate {
1197 method @Nullable @UiThread default public GeckoResult<boolean[]> getVisited(@NonNull GeckoSession, @NonNull String[]);
1198 method @UiThread default public void onHistoryStateChange(@NonNull GeckoSession, @NonNull GeckoSession.HistoryDelegate.HistoryList);
1199 method @Nullable @UiThread default public GeckoResult<Boolean> onVisited(@NonNull GeckoSession, @NonNull String, @Nullable String, int);
1200 field public static final int VISIT_REDIRECT_PERMANENT = 4;
1201 field public static final int VISIT_REDIRECT_SOURCE = 8;
1202 field public static final int VISIT_REDIRECT_SOURCE_PERMANENT = 16;
1203 field public static final int VISIT_REDIRECT_TEMPORARY = 2;
1204 field public static final int VISIT_TOP_LEVEL = 1;
1205 field public static final int VISIT_UNRECOVERABLE_ERROR = 32;
1208 public static interface GeckoSession.HistoryDelegate.HistoryItem {
1209 method @AnyThread @NonNull default public String getTitle();
1210 method @AnyThread @NonNull default public String getUri();
1213 public static interface GeckoSession.HistoryDelegate.HistoryList implements List<GeckoSession.HistoryDelegate.HistoryItem> {
1214 method @AnyThread default public int getCurrentIndex();
1217 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.LoadFlags {
1220 @AnyThread public static class GeckoSession.Loader {
1221 ctor public Loader();
1222 method @NonNull public GeckoSession.Loader additionalHeaders(@NonNull Map<String,String>);
1223 method @NonNull public GeckoSession.Loader data(@NonNull byte[], @Nullable String);
1224 method @NonNull public GeckoSession.Loader data(@NonNull String, @Nullable String);
1225 method @NonNull public GeckoSession.Loader flags(int);
1226 method @NonNull public GeckoSession.Loader headerFilter(int);
1227 method @NonNull public GeckoSession.Loader referrer(@NonNull GeckoSession);
1228 method @NonNull public GeckoSession.Loader referrer(@NonNull Uri);
1229 method @NonNull public GeckoSession.Loader referrer(@NonNull String);
1230 method @NonNull public GeckoSession.Loader uri(@NonNull String);
1231 method @NonNull public GeckoSession.Loader uri(@NonNull Uri);
1234 public static interface GeckoSession.MediaDelegate {
1235 method @UiThread default public void onRecordingStatusChanged(@NonNull GeckoSession, @NonNull GeckoSession.MediaDelegate.RecordingDevice[]);
1238 public static class GeckoSession.MediaDelegate.RecordingDevice {
1239 ctor protected RecordingDevice();
1240 field public final long status;
1241 field public final long type;
1244 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.MediaDelegate.RecordingDevice.DeviceType {
1247 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.MediaDelegate.RecordingDevice.RecordingStatus {
1250 public static class GeckoSession.MediaDelegate.RecordingDevice.Status {
1251 ctor protected Status();
1252 field public static final long INACTIVE = 1L;
1253 field public static final long RECORDING = 0L;
1256 public static class GeckoSession.MediaDelegate.RecordingDevice.Type {
1257 ctor protected Type();
1258 field public static final long CAMERA = 0L;
1259 field public static final long MICROPHONE = 1L;
1262 public static interface GeckoSession.NavigationDelegate {
1263 method @UiThread default public void onCanGoBack(@NonNull GeckoSession, boolean);
1264 method @UiThread default public void onCanGoForward(@NonNull GeckoSession, boolean);
1265 method @Nullable @UiThread default public GeckoResult<String> onLoadError(@NonNull GeckoSession, @Nullable String, @NonNull WebRequestError);
1266 method @Nullable @UiThread default public GeckoResult<AllowOrDeny> onLoadRequest(@NonNull GeckoSession, @NonNull GeckoSession.NavigationDelegate.LoadRequest);
1267 method @Deprecated @DeprecationSchedule(id="geckoview-onlocationchange",version=127) @UiThread default public void onLocationChange(@NonNull GeckoSession, @Nullable String, @NonNull List<GeckoSession.PermissionDelegate.ContentPermission>);
1268 method @UiThread default public void onLocationChange(@NonNull GeckoSession, @Nullable String, @NonNull List<GeckoSession.PermissionDelegate.ContentPermission>, @NonNull Boolean);
1269 method @Nullable @UiThread default public GeckoResult<GeckoSession> onNewSession(@NonNull GeckoSession, @NonNull String);
1270 method @Nullable @UiThread default public GeckoResult<AllowOrDeny> onSubframeLoadRequest(@NonNull GeckoSession, @NonNull GeckoSession.NavigationDelegate.LoadRequest);
1271 field public static final int LOAD_REQUEST_IS_REDIRECT = 8388608;
1272 field public static final int TARGET_WINDOW_CURRENT = 1;
1273 field public static final int TARGET_WINDOW_NEW = 2;
1274 field public static final int TARGET_WINDOW_NONE = 0;
1277 public static class GeckoSession.NavigationDelegate.LoadRequest {
1278 ctor protected LoadRequest();
1279 field public final boolean hasUserGesture;
1280 field public final boolean isDirectNavigation;
1281 field public final boolean isRedirect;
1282 field public final int target;
1283 field @Nullable public final String triggerUri;
1284 field @NonNull public final String uri;
1287 @AnyThread public static class GeckoSession.PdfSaveResult {
1288 ctor protected PdfSaveResult();
1289 field @NonNull public final byte[] bytes;
1290 field @NonNull public final String filename;
1291 field public final boolean isPrivate;
1294 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.Permission {
1297 public static interface GeckoSession.PermissionDelegate {
1298 method @UiThread default public void onAndroidPermissionsRequest(@NonNull GeckoSession, @Nullable String[], @NonNull GeckoSession.PermissionDelegate.Callback);
1299 method @Nullable @UiThread default public GeckoResult<Integer> onContentPermissionRequest(@NonNull GeckoSession, @NonNull GeckoSession.PermissionDelegate.ContentPermission);
1300 method @UiThread default public void onMediaPermissionRequest(@NonNull GeckoSession, @NonNull String, @Nullable GeckoSession.PermissionDelegate.MediaSource[], @Nullable GeckoSession.PermissionDelegate.MediaSource[], @NonNull GeckoSession.PermissionDelegate.MediaCallback);
1301 field public static final int PERMISSION_AUTOPLAY_AUDIBLE = 5;
1302 field public static final int PERMISSION_AUTOPLAY_INAUDIBLE = 4;
1303 field public static final int PERMISSION_DESKTOP_NOTIFICATION = 1;
1304 field public static final int PERMISSION_GEOLOCATION = 0;
1305 field public static final int PERMISSION_MEDIA_KEY_SYSTEM_ACCESS = 6;
1306 field public static final int PERMISSION_PERSISTENT_STORAGE = 2;
1307 field public static final int PERMISSION_STORAGE_ACCESS = 8;
1308 field public static final int PERMISSION_TRACKING = 7;
1309 field public static final int PERMISSION_XR = 3;
1312 public static interface GeckoSession.PermissionDelegate.Callback {
1313 method @UiThread default public void grant();
1314 method @UiThread default public void reject();
1317 public static class GeckoSession.PermissionDelegate.ContentPermission {
1318 ctor protected ContentPermission();
1319 method @AnyThread @Nullable public static GeckoSession.PermissionDelegate.ContentPermission fromJson(@NonNull JSONObject);
1320 method @AnyThread @NonNull public JSONObject toJson();
1321 field public static final int VALUE_ALLOW = 1;
1322 field public static final int VALUE_DENY = 2;
1323 field public static final int VALUE_PROMPT = 3;
1324 field @Nullable public final String contextId;
1325 field public final int permission;
1326 field public final boolean privateMode;
1327 field @Nullable public final String thirdPartyOrigin;
1328 field @NonNull public final String uri;
1329 field public final int value;
1332 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PermissionDelegate.ContentPermission.Value {
1335 public static interface GeckoSession.PermissionDelegate.MediaCallback {
1336 method @UiThread default public void grant(@Nullable String, @Nullable String);
1337 method @UiThread default public void grant(@Nullable GeckoSession.PermissionDelegate.MediaSource, @Nullable GeckoSession.PermissionDelegate.MediaSource);
1338 method @UiThread default public void reject();
1341 public static class GeckoSession.PermissionDelegate.MediaSource {
1342 ctor protected MediaSource();
1343 field public static final int SOURCE_AUDIOCAPTURE = 3;
1344 field public static final int SOURCE_CAMERA = 0;
1345 field public static final int SOURCE_MICROPHONE = 2;
1346 field public static final int SOURCE_OTHER = 4;
1347 field public static final int SOURCE_SCREEN = 1;
1348 field public static final int TYPE_AUDIO = 1;
1349 field public static final int TYPE_VIDEO = 0;
1350 field @NonNull public final String id;
1351 field @Nullable public final String name;
1352 field public final int source;
1353 field public final int type;
1356 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PermissionDelegate.MediaSource.Source {
1359 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PermissionDelegate.MediaSource.Type {
1362 @AnyThread public static interface GeckoSession.PrintDelegate {
1363 method default public void onPrint(@NonNull GeckoSession);
1364 method default public void onPrint(@NonNull InputStream);
1365 method @Nullable default public GeckoResult<Boolean> onPrintWithStatus(@NonNull InputStream);
1368 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.Priority {
1371 public static interface GeckoSession.ProgressDelegate {
1372 method @UiThread default public void onPageStart(@NonNull GeckoSession, @NonNull String);
1373 method @UiThread default public void onPageStop(@NonNull GeckoSession, boolean);
1374 method @UiThread default public void onProgressChange(@NonNull GeckoSession, int);
1375 method @UiThread default public void onSecurityChange(@NonNull GeckoSession, @NonNull GeckoSession.ProgressDelegate.SecurityInformation);
1376 method @UiThread default public void onSessionStateChange(@NonNull GeckoSession, @NonNull GeckoSession.SessionState);
1379 public static class GeckoSession.ProgressDelegate.SecurityInformation {
1380 ctor protected SecurityInformation();
1381 field public static final int CONTENT_BLOCKED = 1;
1382 field public static final int CONTENT_LOADED = 2;
1383 field public static final int CONTENT_UNKNOWN = 0;
1384 field public static final int SECURITY_MODE_IDENTIFIED = 1;
1385 field public static final int SECURITY_MODE_UNKNOWN = 0;
1386 field public static final int SECURITY_MODE_VERIFIED = 2;
1387 field @Nullable public final X509Certificate certificate;
1388 field @NonNull public final String host;
1389 field public final boolean isException;
1390 field public final boolean isSecure;
1391 field public final int mixedModeActive;
1392 field public final int mixedModePassive;
1393 field @Nullable public final String origin;
1394 field public final int securityMode;
1397 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.ProgressDelegate.SecurityInformation.ContentType {
1400 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.ProgressDelegate.SecurityInformation.SecurityMode {
1403 public static interface GeckoSession.PromptDelegate {
1404 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onAddressSave(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.AutocompleteRequest<Autocomplete.AddressSaveOption>);
1405 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onAddressSelect(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.AutocompleteRequest<Autocomplete.AddressSelectOption>);
1406 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onAlertPrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.AlertPrompt);
1407 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onAuthPrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.AuthPrompt);
1408 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onBeforeUnloadPrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.BeforeUnloadPrompt);
1409 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onButtonPrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.ButtonPrompt);
1410 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onChoicePrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.ChoicePrompt);
1411 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onColorPrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.ColorPrompt);
1412 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onCreditCardSave(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.AutocompleteRequest<Autocomplete.CreditCardSaveOption>);
1413 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onCreditCardSelect(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.AutocompleteRequest<Autocomplete.CreditCardSelectOption>);
1414 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onDateTimePrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.DateTimePrompt);
1415 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onFilePrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.FilePrompt);
1416 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onLoginSave(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.AutocompleteRequest<Autocomplete.LoginSaveOption>);
1417 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onLoginSelect(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.AutocompleteRequest<Autocomplete.LoginSelectOption>);
1418 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onPopupPrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.PopupPrompt);
1419 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onRepostConfirmPrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.RepostConfirmPrompt);
1420 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onSelectIdentityCredentialAccount(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt);
1421 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onSelectIdentityCredentialProvider(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.IdentityCredential.ProviderSelectorPrompt);
1422 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onSharePrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.SharePrompt);
1423 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onShowPrivacyPolicyIdentityCredential(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.IdentityCredential.PrivacyPolicyPrompt);
1424 method @Nullable @UiThread default public GeckoResult<GeckoSession.PromptDelegate.PromptResponse> onTextPrompt(@NonNull GeckoSession, @NonNull GeckoSession.PromptDelegate.TextPrompt);
1427 public static class GeckoSession.PromptDelegate.AlertPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1428 ctor protected AlertPrompt(@NonNull String, @Nullable String, @Nullable String, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1429 field @Nullable public final String message;
1432 public static class GeckoSession.PromptDelegate.AuthPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1433 ctor protected AuthPrompt(@NonNull String, @Nullable String, @Nullable String, @NonNull GeckoSession.PromptDelegate.AuthPrompt.AuthOptions, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1434 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull String);
1435 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull String, @NonNull String);
1436 field @NonNull public final GeckoSession.PromptDelegate.AuthPrompt.AuthOptions authOptions;
1437 field @Nullable public final String message;
1440 public static class GeckoSession.PromptDelegate.AuthPrompt.AuthOptions {
1441 ctor protected AuthOptions();
1442 field public final int flags;
1443 field public final int level;
1444 field @Nullable public final String password;
1445 field @Nullable public final String uri;
1446 field @Nullable public final String username;
1449 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PromptDelegate.AuthPrompt.AuthOptions.AuthFlag {
1452 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PromptDelegate.AuthPrompt.AuthOptions.AuthLevel {
1455 public static class GeckoSession.PromptDelegate.AuthPrompt.AuthOptions.Flags {
1456 ctor protected Flags();
1457 field public static final int CROSS_ORIGIN_SUB_RESOURCE = 32;
1458 field public static final int HOST = 1;
1459 field public static final int ONLY_PASSWORD = 8;
1460 field public static final int PREVIOUS_FAILED = 16;
1461 field public static final int PROXY = 2;
1464 public static class GeckoSession.PromptDelegate.AuthPrompt.AuthOptions.Level {
1465 ctor protected Level();
1466 field public static final int NONE = 0;
1467 field public static final int PW_ENCRYPTED = 1;
1468 field public static final int SECURE = 2;
1471 public static class GeckoSession.PromptDelegate.AutocompleteRequest<T extends Autocomplete.Option<?>> extends GeckoSession.PromptDelegate.BasePrompt {
1472 ctor protected AutocompleteRequest(@NonNull String, @NonNull T[], GeckoSession.PromptDelegate.BasePrompt.Observer);
1473 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull Autocomplete.Option<?>);
1474 field @NonNull public final T[] options;
1477 public static class GeckoSession.PromptDelegate.BasePrompt {
1478 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse dismiss();
1479 method @Nullable @UiThread public GeckoSession.PromptDelegate.PromptInstanceDelegate getDelegate();
1480 method @UiThread public boolean isComplete();
1481 method @UiThread public void setDelegate(@Nullable GeckoSession.PromptDelegate.PromptInstanceDelegate);
1482 method @NonNull @UiThread protected GeckoSession.PromptDelegate.PromptResponse confirm();
1483 field @Nullable public final String title;
1486 protected static interface GeckoSession.PromptDelegate.BasePrompt.Observer {
1487 method @AnyThread default public void onPromptCompleted(@NonNull GeckoSession.PromptDelegate.BasePrompt);
1490 public static class GeckoSession.PromptDelegate.BeforeUnloadPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1491 ctor protected BeforeUnloadPrompt(@NonNull String, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1492 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@Nullable AllowOrDeny);
1495 public static class GeckoSession.PromptDelegate.ButtonPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1496 ctor protected ButtonPrompt(@NonNull String, @Nullable String, @Nullable String, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1497 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(int);
1498 field @Nullable public final String message;
1501 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PromptDelegate.ButtonPrompt.ButtonType {
1504 public static class GeckoSession.PromptDelegate.ButtonPrompt.Type {
1505 ctor protected Type();
1506 field public static final int NEGATIVE = 2;
1507 field public static final int POSITIVE = 0;
1510 public static class GeckoSession.PromptDelegate.ChoicePrompt extends GeckoSession.PromptDelegate.BasePrompt {
1511 ctor protected ChoicePrompt(@NonNull String, @Nullable String, @Nullable String, int, @NonNull GeckoSession.PromptDelegate.ChoicePrompt.Choice[], @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1512 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull String);
1513 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull String[]);
1514 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull GeckoSession.PromptDelegate.ChoicePrompt.Choice);
1515 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull GeckoSession.PromptDelegate.ChoicePrompt.Choice[]);
1516 field @NonNull public final GeckoSession.PromptDelegate.ChoicePrompt.Choice[] choices;
1517 field @Nullable public final String message;
1518 field public final int type;
1521 public static class GeckoSession.PromptDelegate.ChoicePrompt.Choice {
1522 ctor protected Choice();
1523 field public final boolean disabled;
1524 field @Nullable public final String icon;
1525 field @NonNull public final String id;
1526 field @Nullable public final GeckoSession.PromptDelegate.ChoicePrompt.Choice[] items;
1527 field @NonNull public final String label;
1528 field public final boolean selected;
1529 field public final boolean separator;
1532 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PromptDelegate.ChoicePrompt.ChoiceType {
1535 public static class GeckoSession.PromptDelegate.ChoicePrompt.Type {
1536 ctor protected Type();
1537 field public static final int MENU = 1;
1538 field public static final int MULTIPLE = 3;
1539 field public static final int SINGLE = 2;
1542 public static class GeckoSession.PromptDelegate.ColorPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1543 ctor protected ColorPrompt(@NonNull String, @Nullable String, @Nullable String, @Nullable String[], @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1544 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull String);
1545 field @Nullable public final String defaultValue;
1546 field @Nullable public final String[] predefinedValues;
1549 public static class GeckoSession.PromptDelegate.DateTimePrompt extends GeckoSession.PromptDelegate.BasePrompt {
1550 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull String);
1551 field @Nullable public final String defaultValue;
1552 field @Nullable public final String maxValue;
1553 field @Nullable public final String minValue;
1554 field @Nullable public final String stepValue;
1555 field public final int type;
1558 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PromptDelegate.DateTimePrompt.DatetimeType {
1561 public static class GeckoSession.PromptDelegate.DateTimePrompt.Type {
1562 ctor protected Type();
1563 field public static final int DATE = 1;
1564 field public static final int DATETIME_LOCAL = 5;
1565 field public static final int MONTH = 2;
1566 field public static final int TIME = 4;
1567 field public static final int WEEK = 3;
1570 public static class GeckoSession.PromptDelegate.FilePrompt extends GeckoSession.PromptDelegate.BasePrompt {
1571 ctor protected FilePrompt(@NonNull String, @Nullable String, int, int, @Nullable String[], @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1572 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull Context, @NonNull Uri);
1573 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull Context, @NonNull Uri[]);
1574 field public final int capture;
1575 field @Nullable public final String[] mimeTypes;
1576 field public final int type;
1579 public static class GeckoSession.PromptDelegate.FilePrompt.Capture {
1580 ctor protected Capture();
1581 field public static final int ANY = 1;
1582 field public static final int ENVIRONMENT = 3;
1583 field public static final int NONE = 0;
1584 field public static final int USER = 2;
1587 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PromptDelegate.FilePrompt.CaptureType {
1590 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PromptDelegate.FilePrompt.FileType {
1593 public static class GeckoSession.PromptDelegate.FilePrompt.Type {
1594 ctor protected Type();
1595 field public static final int MULTIPLE = 2;
1596 field public static final int SINGLE = 1;
1599 public static final class GeckoSession.PromptDelegate.IdentityCredential {
1600 ctor public IdentityCredential();
1603 public static class GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1604 ctor public AccountSelectorPrompt(@NonNull String, @NonNull GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Account[], @NonNull GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Provider, GeckoSession.PromptDelegate.BasePrompt.Observer);
1605 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull int);
1606 field @NonNull public final GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Account[] accounts;
1607 field @NonNull public final GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Provider provider;
1610 public static class GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Account {
1611 ctor public Account(int, @NonNull String, @NonNull String, @Nullable String);
1612 field @NonNull public final String email;
1613 field @Nullable public final String icon;
1614 field public final int id;
1615 field @NonNull public final String name;
1618 public static class GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Provider {
1619 ctor public Provider(@NonNull String, @NonNull String, @Nullable String);
1620 field @NonNull public final String domain;
1621 field @Nullable public final String icon;
1622 field @NonNull public final String name;
1625 public static class GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.ProviderAccounts {
1626 ctor public ProviderAccounts(int, @Nullable GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Provider, @NonNull GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Account[]);
1627 field @NonNull public final GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Account[] accounts;
1628 field public final int id;
1629 field @Nullable public final GeckoSession.PromptDelegate.IdentityCredential.AccountSelectorPrompt.Provider provider;
1632 public static class GeckoSession.PromptDelegate.IdentityCredential.PrivacyPolicyPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1633 ctor protected PrivacyPolicyPrompt(@NonNull String, @NonNull String, @NonNull String, @NonNull String, @NonNull String, @Nullable String, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1634 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(boolean);
1635 field @NonNull public final String host;
1636 field @Nullable public final String icon;
1637 field @NonNull public final String privacyPolicyUrl;
1638 field @NonNull public final String providerDomain;
1639 field @NonNull public final String termsOfServiceUrl;
1642 public static class GeckoSession.PromptDelegate.IdentityCredential.ProviderSelectorPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1643 ctor protected ProviderSelectorPrompt(@NonNull String, @NonNull GeckoSession.PromptDelegate.IdentityCredential.ProviderSelectorPrompt.Provider[], @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1644 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(int);
1645 field @NonNull public final GeckoSession.PromptDelegate.IdentityCredential.ProviderSelectorPrompt.Provider[] providers;
1648 public static class GeckoSession.PromptDelegate.IdentityCredential.ProviderSelectorPrompt.Provider {
1649 ctor public Provider(int, @NonNull String, @Nullable String, @NonNull String);
1650 field @NonNull public final String domain;
1651 field @Nullable public final String icon;
1652 field public final int id;
1653 field @NonNull public final String name;
1656 public static class GeckoSession.PromptDelegate.PopupPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1657 ctor protected PopupPrompt(@NonNull String, @Nullable String, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1658 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull AllowOrDeny);
1659 field @Nullable public final String targetUri;
1662 public static interface GeckoSession.PromptDelegate.PromptInstanceDelegate {
1663 method @UiThread default public void onPromptDismiss(@NonNull GeckoSession.PromptDelegate.BasePrompt);
1664 method @UiThread default public void onPromptUpdate(@NonNull GeckoSession.PromptDelegate.BasePrompt);
1667 public static class GeckoSession.PromptDelegate.PromptResponse {
1670 public static class GeckoSession.PromptDelegate.RepostConfirmPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1671 ctor protected RepostConfirmPrompt(@NonNull String, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1672 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@Nullable AllowOrDeny);
1675 public static class GeckoSession.PromptDelegate.SharePrompt extends GeckoSession.PromptDelegate.BasePrompt {
1676 ctor protected SharePrompt(@NonNull String, @Nullable String, @Nullable String, @Nullable String, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1677 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(int);
1678 field @Nullable public final String text;
1679 field @Nullable public final String uri;
1682 public static class GeckoSession.PromptDelegate.SharePrompt.Result {
1683 ctor protected Result();
1684 field public static final int ABORT = 2;
1685 field public static final int FAILURE = 1;
1686 field public static final int SUCCESS = 0;
1689 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.PromptDelegate.SharePrompt.ShareResult {
1692 public static class GeckoSession.PromptDelegate.TextPrompt extends GeckoSession.PromptDelegate.BasePrompt {
1693 ctor protected TextPrompt(@NonNull String, @Nullable String, @Nullable String, @Nullable String, @NonNull GeckoSession.PromptDelegate.BasePrompt.Observer);
1694 method @NonNull @UiThread public GeckoSession.PromptDelegate.PromptResponse confirm(@NonNull String);
1695 field @Nullable public final String defaultValue;
1696 field @Nullable public final String message;
1699 @AnyThread public static class GeckoSession.Recommendation {
1700 ctor protected Recommendation(@NonNull GeckoSession.Recommendation.Builder);
1701 field @NonNull public final Double adjustedRating;
1702 field @NonNull public final String aid;
1703 field @NonNull public final String analysisUrl;
1704 field @NonNull public final String currency;
1705 field @NonNull public final String grade;
1706 field @NonNull public final String imageUrl;
1707 field @NonNull public final String name;
1708 field @NonNull public final String price;
1709 field @NonNull public final Boolean sponsored;
1710 field @NonNull public final String url;
1713 public static class GeckoSession.Recommendation.Builder {
1714 ctor public Builder(@NonNull String);
1715 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder adjustedRating(@NonNull Double);
1716 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder aid(@NonNull String);
1717 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder analysisUrl(@NonNull String);
1718 method @AnyThread @NonNull public GeckoSession.Recommendation build();
1719 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder currency(@NonNull String);
1720 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder grade(@NonNull String);
1721 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder imageUrl(@NonNull String);
1722 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder name(@NonNull String);
1723 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder price(@NonNull String);
1724 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder sponsored(@NonNull Boolean);
1725 method @AnyThread @NonNull public GeckoSession.Recommendation.Builder url(@NonNull String);
1728 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.RestartReason {
1731 @AnyThread public static class GeckoSession.ReviewAnalysis {
1732 ctor protected ReviewAnalysis(@NonNull GeckoSession.ReviewAnalysis.Builder);
1733 field @Nullable public final Double adjustedRating;
1734 field @Nullable public final String analysisURL;
1735 field public final boolean deletedProduct;
1736 field public final boolean deletedProductReported;
1737 field @Nullable public final String grade;
1738 field @Nullable public final GeckoSession.ReviewAnalysis.Highlight highlights;
1739 field public final long lastAnalysisTime;
1740 field public final boolean needsAnalysis;
1741 field public final boolean notEnoughReviews;
1742 field public final boolean pageNotSupported;
1743 field @Nullable public final String productId;
1746 public static class GeckoSession.ReviewAnalysis.Builder {
1747 ctor public Builder(@Nullable String);
1748 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder adjustedRating(@NonNull Double);
1749 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder analysisUrl(@Nullable String);
1750 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis build();
1751 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder deletedProduct(@NonNull Boolean);
1752 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder deletedProductReported(@NonNull Boolean);
1753 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder grade(@Nullable String);
1754 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder highlights(@Nullable GeckoSession.ReviewAnalysis.Highlight);
1755 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder lastAnalysisTime(long);
1756 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder needsAnalysis(@NonNull Boolean);
1757 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder notEnoughReviews(@NonNull Boolean);
1758 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder pageNotSupported(@NonNull Boolean);
1759 method @AnyThread @NonNull public GeckoSession.ReviewAnalysis.Builder productId(@Nullable String);
1762 public static class GeckoSession.ReviewAnalysis.Highlight {
1763 ctor protected Highlight();
1764 field @Nullable public final String[] appearance;
1765 field @Nullable public final String[] competitiveness;
1766 field @Nullable public final String[] price;
1767 field @Nullable public final String[] quality;
1768 field @Nullable public final String[] shipping;
1771 public static interface GeckoSession.ScrollDelegate {
1772 method @UiThread default public void onScrollChanged(@NonNull GeckoSession, int, int);
1775 public static interface GeckoSession.SelectionActionDelegate {
1776 method @UiThread default public void onDismissClipboardPermissionRequest(@NonNull GeckoSession);
1777 method @UiThread default public void onHideAction(@NonNull GeckoSession, int);
1778 method @UiThread default public void onShowActionRequest(@NonNull GeckoSession, @NonNull GeckoSession.SelectionActionDelegate.Selection);
1779 method @Nullable @UiThread default public GeckoResult<AllowOrDeny> onShowClipboardPermissionRequest(@NonNull GeckoSession, @NonNull GeckoSession.SelectionActionDelegate.ClipboardPermission);
1780 field public static final String ACTION_COLLAPSE_TO_END = "org.mozilla.geckoview.COLLAPSE_TO_END";
1781 field public static final String ACTION_COLLAPSE_TO_START = "org.mozilla.geckoview.COLLAPSE_TO_START";
1782 field public static final String ACTION_COPY = "org.mozilla.geckoview.COPY";
1783 field public static final String ACTION_CUT = "org.mozilla.geckoview.CUT";
1784 field public static final String ACTION_DELETE = "org.mozilla.geckoview.DELETE";
1785 field public static final String ACTION_HIDE = "org.mozilla.geckoview.HIDE";
1786 field public static final String ACTION_PASTE = "org.mozilla.geckoview.PASTE";
1787 field public static final String ACTION_PASTE_AS_PLAIN_TEXT = "org.mozilla.geckoview.PASTE_AS_PLAIN_TEXT";
1788 field public static final String ACTION_SELECT_ALL = "org.mozilla.geckoview.SELECT_ALL";
1789 field public static final String ACTION_UNSELECT = "org.mozilla.geckoview.UNSELECT";
1790 field public static final int FLAG_IS_COLLAPSED = 1;
1791 field public static final int FLAG_IS_EDITABLE = 2;
1792 field public static final int FLAG_IS_PASSWORD = 4;
1793 field public static final int HIDE_REASON_ACTIVE_SCROLL = 3;
1794 field public static final int HIDE_REASON_ACTIVE_SELECTION = 2;
1795 field public static final int HIDE_REASON_INVISIBLE_SELECTION = 1;
1796 field public static final int HIDE_REASON_NO_SELECTION = 0;
1797 field public static final int PERMISSION_CLIPBOARD_READ = 1;
1800 public static class GeckoSession.SelectionActionDelegate.ClipboardPermission {
1801 ctor protected ClipboardPermission();
1802 field @Nullable public final Point screenPoint;
1803 field public final int type;
1804 field @NonNull public final String uri;
1807 public static class GeckoSession.SelectionActionDelegate.Selection {
1808 ctor protected Selection();
1809 method @AnyThread public void collapseToEnd();
1810 method @AnyThread public void collapseToStart();
1811 method @AnyThread public void copy();
1812 method @AnyThread public void cut();
1813 method @AnyThread public void delete();
1814 method @AnyThread public void execute(@NonNull String);
1815 method @AnyThread public void hide();
1816 method @AnyThread public boolean isActionAvailable(@NonNull String);
1817 method @AnyThread public void paste();
1818 method @AnyThread public void pasteAsPlainText();
1819 method @AnyThread public void selectAll();
1820 method @AnyThread public void unselect();
1821 field @NonNull public final Collection<String> availableActions;
1822 field public final int flags;
1823 field @Nullable public final RectF screenRect;
1824 field @NonNull public final String text;
1827 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.SelectionActionDelegateAction {
1830 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.SelectionActionDelegateFlag {
1833 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.SelectionActionDelegateHideReason {
1836 @AnyThread public static class GeckoSession.SessionState extends AbstractSequentialList<GeckoSession.HistoryDelegate.HistoryItem> implements Parcelable GeckoSession.HistoryDelegate.HistoryList {
1837 ctor public SessionState(@NonNull GeckoSession.SessionState);
1838 method @Nullable public static GeckoSession.SessionState fromString(@Nullable String);
1839 method public void readFromParcel(@NonNull Parcel);
1840 field public static final Parcelable.Creator<GeckoSession.SessionState> CREATOR;
1843 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.TargetWindow {
1846 public static interface GeckoSession.TextInputDelegate {
1847 method @UiThread default public void hideSoftInput(@NonNull GeckoSession);
1848 method @UiThread default public void restartInput(@NonNull GeckoSession, int);
1849 method @UiThread default public void showSoftInput(@NonNull GeckoSession);
1850 method @UiThread default public void updateCursorAnchorInfo(@NonNull GeckoSession, @NonNull CursorAnchorInfo);
1851 method @UiThread default public void updateExtractedText(@NonNull GeckoSession, @NonNull ExtractedTextRequest, @NonNull ExtractedText);
1852 method @UiThread default public void updateSelection(@NonNull GeckoSession, int, int, int, int);
1853 field public static final int RESTART_REASON_BLUR = 1;
1854 field public static final int RESTART_REASON_CONTENT_CHANGE = 2;
1855 field public static final int RESTART_REASON_FOCUS = 0;
1858 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSession.VisitFlags {
1861 @AnyThread public static class GeckoSession.WebResponseInfo {
1862 ctor protected WebResponseInfo();
1863 field @Nullable public final long contentLength;
1864 field @Nullable public final String contentType;
1865 field @Nullable public final String filename;
1866 field @NonNull public final String uri;
1869 @AnyThread public final class GeckoSessionSettings implements Parcelable {
1870 ctor public GeckoSessionSettings();
1871 ctor public GeckoSessionSettings(@NonNull GeckoSessionSettings);
1872 method public boolean getAllowJavascript();
1873 method @Nullable public String getChromeUri();
1874 method @Nullable public String getContextId();
1875 method public int getDisplayMode();
1876 method public boolean getFullAccessibilityTree();
1877 method public int getScreenId();
1878 method public boolean getSuspendMediaWhenInactive();
1879 method public boolean getUsePrivateMode();
1880 method public boolean getUseTrackingProtection();
1881 method public int getUserAgentMode();
1882 method @Nullable public String getUserAgentOverride();
1883 method public int getViewportMode();
1884 method public void readFromParcel(@NonNull Parcel);
1885 method public void setAllowJavascript(boolean);
1886 method public void setDisplayMode(int);
1887 method public void setFullAccessibilityTree(boolean);
1888 method public void setSuspendMediaWhenInactive(boolean);
1889 method public void setUseTrackingProtection(boolean);
1890 method public void setUserAgentMode(int);
1891 method public void setUserAgentOverride(@Nullable String);
1892 method public void setViewportMode(int);
1893 field public static final Parcelable.Creator<GeckoSessionSettings> CREATOR;
1894 field public static final int DISPLAY_MODE_BROWSER = 0;
1895 field public static final int DISPLAY_MODE_FULLSCREEN = 3;
1896 field public static final int DISPLAY_MODE_MINIMAL_UI = 1;
1897 field public static final int DISPLAY_MODE_STANDALONE = 2;
1898 field public static final int USER_AGENT_MODE_DESKTOP = 1;
1899 field public static final int USER_AGENT_MODE_MOBILE = 0;
1900 field public static final int USER_AGENT_MODE_VR = 2;
1901 field public static final int VIEWPORT_MODE_DESKTOP = 1;
1902 field public static final int VIEWPORT_MODE_MOBILE = 0;
1905 @AnyThread public static final class GeckoSessionSettings.Builder {
1906 ctor public Builder();
1907 ctor public Builder(GeckoSessionSettings);
1908 method @NonNull public GeckoSessionSettings.Builder allowJavascript(boolean);
1909 method @NonNull public GeckoSessionSettings build();
1910 method @NonNull public GeckoSessionSettings.Builder chromeUri(@NonNull String);
1911 method @NonNull public GeckoSessionSettings.Builder contextId(@Nullable String);
1912 method @NonNull public GeckoSessionSettings.Builder displayMode(int);
1913 method @NonNull public GeckoSessionSettings.Builder fullAccessibilityTree(boolean);
1914 method @NonNull public GeckoSessionSettings.Builder screenId(int);
1915 method @NonNull public GeckoSessionSettings.Builder suspendMediaWhenInactive(boolean);
1916 method @NonNull public GeckoSessionSettings.Builder usePrivateMode(boolean);
1917 method @NonNull public GeckoSessionSettings.Builder useTrackingProtection(boolean);
1918 method @NonNull public GeckoSessionSettings.Builder userAgentMode(int);
1919 method @NonNull public GeckoSessionSettings.Builder userAgentOverride(@NonNull String);
1920 method @NonNull public GeckoSessionSettings.Builder viewportMode(int);
1923 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSessionSettings.DisplayMode {
1926 public static class GeckoSessionSettings.Key<T> {
1929 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSessionSettings.UserAgentMode {
1932 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoSessionSettings.ViewportMode {
1935 public class GeckoVRManager {
1936 method @AnyThread public static synchronized void setExternalContext(long);
1939 @UiThread public class GeckoView extends FrameLayout implements GeckoDisplay.NewSurfaceProvider {
1940 ctor public GeckoView(Context);
1941 ctor public GeckoView(Context, AttributeSet);
1942 method @NonNull @UiThread public GeckoResult<Bitmap> capturePixels();
1943 method public void coverUntilFirstPaint(int);
1944 method public void dispatchDraw(@Nullable Canvas);
1945 method @Nullable public GeckoView.ActivityContextDelegate getActivityContextDelegate();
1946 method public boolean getAutofillEnabled();
1947 method @NonNull public PanZoomController getPanZoomController();
1948 method @Nullable public GeckoSession.PrintDelegate getPrintDelegate();
1949 method public void getPrintDelegate(@Nullable GeckoSession.PrintDelegate);
1950 method @AnyThread @Nullable public GeckoSession getSession();
1951 method public void onAttachedToWindow();
1952 method public void onDetachedFromWindow();
1953 method @NonNull public GeckoResult<PanZoomController.InputResultDetail> onTouchEventForDetailResult(@NonNull MotionEvent);
1954 method @Nullable @UiThread public GeckoSession releaseSession();
1955 method public void setActivityContextDelegate(@Nullable GeckoView.ActivityContextDelegate);
1956 method public void setAutofillEnabled(boolean);
1957 method public void setDynamicToolbarMaxHeight(int);
1958 method @UiThread public void setSession(@NonNull GeckoSession);
1959 method public void setVerticalClipping(int);
1960 method public void setViewBackend(int);
1961 method public boolean shouldPinOnScreen();
1962 field public static final int BACKEND_SURFACE_VIEW = 1;
1963 field public static final int BACKEND_TEXTURE_VIEW = 2;
1964 field @NonNull protected final GeckoView.Display mDisplay;
1965 field @Nullable protected GeckoSession mSession;
1968 @AnyThread public static interface GeckoView.ActivityContextDelegate {
1969 method @Nullable public Context getActivityContext();
1972 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoView.ViewBackend {
1975 public class GeckoViewPrintDocumentAdapter extends PrintDocumentAdapter {
1976 ctor public GeckoViewPrintDocumentAdapter(@NonNull InputStream, @NonNull Context);
1977 ctor public GeckoViewPrintDocumentAdapter(@NonNull InputStream, @NonNull Context, @Nullable GeckoResult<Boolean>);
1978 ctor public GeckoViewPrintDocumentAdapter(@NonNull File);
1979 method @AnyThread @Nullable public static File makeTempPdfFile(@NonNull InputStream, @NonNull Context);
1982 @AnyThread public class GeckoWebExecutor {
1983 ctor public GeckoWebExecutor(@NonNull GeckoRuntime);
1984 method @NonNull public GeckoResult<WebResponse> fetch(@NonNull WebRequest);
1985 method @NonNull public GeckoResult<WebResponse> fetch(@NonNull WebRequest, int);
1986 method @NonNull public GeckoResult<InetAddress[]> resolve(@NonNull String);
1987 method public void speculativeConnect(@NonNull String);
1988 field public static final int FETCH_FLAGS_ANONYMOUS = 1;
1989 field public static final int FETCH_FLAGS_NONE = 0;
1990 field public static final int FETCH_FLAGS_NO_REDIRECTS = 2;
1991 field public static final int FETCH_FLAGS_PRIVATE = 8;
1992 field public static final int FETCH_FLAGS_STREAM_FAILURE_TEST = 1024;
1995 @Retention(value=RetentionPolicy.SOURCE) public static interface GeckoWebExecutor.FetchFlags {
1998 @AnyThread public class Image {
1999 method @NonNull public GeckoResult<Bitmap> getBitmap(int);
2002 public static class Image.ImageProcessingException extends RuntimeException {
2003 ctor public ImageProcessingException(String);
2006 @UiThread public class MediaSession {
2007 ctor protected MediaSession(GeckoSession);
2008 method public boolean isActive();
2009 method public void muteAudio(boolean);
2010 method public void nextTrack();
2011 method public void pause();
2012 method public void play();
2013 method public void previousTrack();
2014 method public void seekBackward();
2015 method public void seekForward();
2016 method public void seekTo(double, boolean);
2017 method public void skipAd();
2018 method public void stop();
2021 @UiThread public static interface MediaSession.Delegate {
2022 method default public void onActivated(@NonNull GeckoSession, @NonNull MediaSession);
2023 method default public void onDeactivated(@NonNull GeckoSession, @NonNull MediaSession);
2024 method default public void onFeatures(@NonNull GeckoSession, @NonNull MediaSession, long);
2025 method default public void onFullscreen(@NonNull GeckoSession, @NonNull MediaSession, boolean, @Nullable MediaSession.ElementMetadata);
2026 method default public void onMetadata(@NonNull GeckoSession, @NonNull MediaSession, @NonNull MediaSession.Metadata);
2027 method default public void onPause(@NonNull GeckoSession, @NonNull MediaSession);
2028 method default public void onPlay(@NonNull GeckoSession, @NonNull MediaSession);
2029 method default public void onPositionState(@NonNull GeckoSession, @NonNull MediaSession, @NonNull MediaSession.PositionState);
2030 method default public void onStop(@NonNull GeckoSession, @NonNull MediaSession);
2033 public static class MediaSession.ElementMetadata {
2034 ctor public ElementMetadata(@Nullable String, double, long, long, int, int);
2035 field public final int audioTrackCount;
2036 field public final double duration;
2037 field public final long height;
2038 field @Nullable public final String source;
2039 field public final int videoTrackCount;
2040 field public final long width;
2043 public static class MediaSession.Feature {
2044 ctor public Feature();
2045 field public static final long FOCUS = 512L;
2046 field public static final long NEXT_TRACK = 128L;
2047 field public static final long NONE = 0L;
2048 field public static final long PAUSE = 2L;
2049 field public static final long PLAY = 1L;
2050 field public static final long PREVIOUS_TRACK = 256L;
2051 field public static final long SEEK_BACKWARD = 32L;
2052 field public static final long SEEK_FORWARD = 16L;
2053 field public static final long SEEK_TO = 8L;
2054 field public static final long SKIP_AD = 64L;
2055 field public static final long STOP = 4L;
2058 @Retention(value=RetentionPolicy.SOURCE) public static interface MediaSession.MSFeature {
2061 public static class MediaSession.Metadata {
2062 ctor protected Metadata(@Nullable String, @Nullable String, @Nullable String, @Nullable Image);
2063 field @Nullable public final String album;
2064 field @Nullable public final String artist;
2065 field @Nullable public final Image artwork;
2066 field @Nullable public final String title;
2069 public static class MediaSession.PositionState {
2070 ctor protected PositionState(double, double, double);
2071 field public final double duration;
2072 field public final double playbackRate;
2073 field public final double position;
2076 public class OrientationController {
2077 method @Nullable @UiThread public OrientationController.OrientationDelegate getDelegate();
2078 method @UiThread public void setDelegate(@Nullable OrientationController.OrientationDelegate);
2081 @UiThread public static interface OrientationController.OrientationDelegate {
2082 method @Nullable default public GeckoResult<AllowOrDeny> onOrientationLock(@NonNull int);
2083 method @Nullable default public void onOrientationUnlock();
2086 @UiThread public final class OverscrollEdgeEffect {
2087 method public void draw(@NonNull Canvas);
2088 method @Nullable public Runnable getInvalidationCallback();
2089 method public void setInvalidationCallback(@Nullable Runnable);
2090 method public void setTheme(@NonNull Context);
2093 @UiThread public class PanZoomController {
2094 ctor protected PanZoomController(GeckoSession);
2095 method public float getScrollFactor();
2096 method public boolean onDragEvent(@NonNull DragEvent);
2097 method public void onMotionEvent(@NonNull MotionEvent);
2098 method public void onMouseEvent(@NonNull MotionEvent);
2099 method public void onTouchEvent(@NonNull MotionEvent);
2100 method @NonNull public GeckoResult<PanZoomController.InputResultDetail> onTouchEventForDetailResult(@NonNull MotionEvent);
2101 method @UiThread public void scrollBy(@NonNull ScreenLength, @NonNull ScreenLength);
2102 method @UiThread public void scrollBy(@NonNull ScreenLength, @NonNull ScreenLength, int);
2103 method @UiThread public void scrollTo(@NonNull ScreenLength, @NonNull ScreenLength);
2104 method @UiThread public void scrollTo(@NonNull ScreenLength, @NonNull ScreenLength, int);
2105 method @UiThread public void scrollToBottom();
2106 method @UiThread public void scrollToTop();
2107 method public void setIsLongpressEnabled(boolean);
2108 method public void setScrollFactor(float);
2109 field public static final int INPUT_RESULT_HANDLED = 1;
2110 field public static final int INPUT_RESULT_HANDLED_CONTENT = 2;
2111 field public static final int INPUT_RESULT_IGNORED = 3;
2112 field public static final int INPUT_RESULT_UNHANDLED = 0;
2113 field public static final int OVERSCROLL_FLAG_HORIZONTAL = 1;
2114 field public static final int OVERSCROLL_FLAG_NONE = 0;
2115 field public static final int OVERSCROLL_FLAG_VERTICAL = 2;
2116 field public static final int SCROLLABLE_FLAG_BOTTOM = 4;
2117 field public static final int SCROLLABLE_FLAG_LEFT = 8;
2118 field public static final int SCROLLABLE_FLAG_NONE = 0;
2119 field public static final int SCROLLABLE_FLAG_RIGHT = 2;
2120 field public static final int SCROLLABLE_FLAG_TOP = 1;
2121 field public static final int SCROLL_BEHAVIOR_AUTO = 1;
2122 field public static final int SCROLL_BEHAVIOR_SMOOTH = 0;
2125 @Retention(value=RetentionPolicy.SOURCE) public static interface PanZoomController.InputResult {
2128 public static class PanZoomController.InputResultDetail {
2129 ctor protected InputResultDetail(int, int, int);
2130 method @AnyThread public int handledResult();
2131 method @AnyThread public int overscrollDirections();
2132 method @AnyThread public int scrollableDirections();
2135 @Retention(value=RetentionPolicy.SOURCE) public static interface PanZoomController.OverscrollDirections {
2138 @Retention(value=RetentionPolicy.SOURCE) public static interface PanZoomController.ScrollBehaviorType {
2141 @Retention(value=RetentionPolicy.SOURCE) public static interface PanZoomController.ScrollableDirections {
2144 @UiThread public class ProfilerController {
2145 ctor public ProfilerController();
2146 method public void addMarker(@NonNull String, @Nullable Double, @Nullable Double, @Nullable String);
2147 method public void addMarker(@NonNull String, @Nullable Double, @Nullable String);
2148 method public void addMarker(@NonNull String, @Nullable Double);
2149 method public void addMarker(@NonNull String, @Nullable String);
2150 method public void addMarker(@NonNull String);
2151 method @Nullable public Double getProfilerTime();
2152 method public boolean isProfilerActive();
2153 method public void startProfiler(@NonNull String[], @NonNull String[]);
2154 method @NonNull public GeckoResult<byte[]> stopProfiler();
2157 public abstract class RuntimeSettings implements Parcelable {
2158 ctor protected RuntimeSettings();
2159 ctor protected RuntimeSettings(@Nullable RuntimeSettings);
2160 method @AnyThread public void readFromParcel(@NonNull Parcel);
2161 method @AnyThread protected void updatePrefs(@NonNull RuntimeSettings);
2164 public abstract static class RuntimeSettings.Builder<Settings extends RuntimeSettings> {
2165 ctor public Builder();
2166 method @AnyThread @NonNull public Settings build();
2167 method @AnyThread @NonNull protected Settings getSettings();
2168 method @AnyThread @NonNull protected abstract Settings newSettings(@Nullable Settings);
2171 public final class RuntimeTelemetry {
2172 ctor protected RuntimeTelemetry();
2175 public static interface RuntimeTelemetry.Delegate {
2176 method @AnyThread default public void onBooleanScalar(@NonNull RuntimeTelemetry.Metric<Boolean>);
2177 method @AnyThread default public void onHistogram(@NonNull RuntimeTelemetry.Histogram);
2178 method @AnyThread default public void onLongScalar(@NonNull RuntimeTelemetry.Metric<Long>);
2179 method @AnyThread default public void onStringScalar(@NonNull RuntimeTelemetry.Metric<String>);
2182 public static class RuntimeTelemetry.Histogram extends RuntimeTelemetry.Metric<long[]> {
2183 ctor protected Histogram();
2184 field public final boolean isCategorical;
2187 public static class RuntimeTelemetry.Metric<T> {
2188 ctor protected Metric();
2189 field @NonNull public final String name;
2190 field @NonNull public final T value;
2193 public class ScreenLength {
2194 method @AnyThread @NonNull public static ScreenLength bottom();
2195 method @AnyThread @NonNull public static ScreenLength fromPixels(double);
2196 method @AnyThread @NonNull public static ScreenLength fromVisualViewportHeight(double);
2197 method @AnyThread @NonNull public static ScreenLength fromVisualViewportWidth(double);
2198 method @AnyThread public int getType();
2199 method @AnyThread public double getValue();
2200 method @AnyThread @NonNull public static ScreenLength top();
2201 method @AnyThread @NonNull public static ScreenLength zero();
2202 field public static final int DOCUMENT_HEIGHT = 4;
2203 field public static final int DOCUMENT_WIDTH = 3;
2204 field public static final int PIXEL = 0;
2205 field public static final int VISUAL_VIEWPORT_HEIGHT = 2;
2206 field public static final int VISUAL_VIEWPORT_WIDTH = 1;
2209 @Retention(value=RetentionPolicy.SOURCE) public static interface ScreenLength.ScreenLengthType {
2212 @UiThread public class SessionAccessibility {
2213 method @Nullable public View getView();
2214 method public boolean onMotionEvent(@NonNull MotionEvent);
2215 method @UiThread public void setView(@Nullable View);
2218 @AnyThread public final class SessionFinder {
2219 method public void clear();
2220 method @NonNull public GeckoResult<GeckoSession.FinderResult> find(@Nullable String, int);
2221 method public int getDisplayFlags();
2222 method public void setDisplayFlags(int);
2225 @AnyThread public final class SessionPdfFileSaver {
2226 method @Nullable public static GeckoResult<WebResponse> createResponse(@NonNull GeckoSession, @NonNull String, @NonNull String, @NonNull String, boolean, boolean);
2227 method @NonNull public GeckoResult<WebResponse> save();
2230 public final class SessionTextInput {
2231 method @NonNull @UiThread public GeckoSession.TextInputDelegate getDelegate();
2232 method @AnyThread @NonNull public synchronized Handler getHandler(@NonNull Handler);
2233 method @Nullable @UiThread public View getView();
2234 method @AnyThread @Nullable public synchronized InputConnection onCreateInputConnection(@NonNull EditorInfo);
2235 method @UiThread public boolean onKeyDown(int, @NonNull KeyEvent);
2236 method @UiThread public boolean onKeyLongPress(int, @NonNull KeyEvent);
2237 method @UiThread public boolean onKeyMultiple(int, int, @NonNull KeyEvent);
2238 method @UiThread public boolean onKeyPreIme(int, @NonNull KeyEvent);
2239 method @UiThread public boolean onKeyUp(int, @NonNull KeyEvent);
2240 method @UiThread public void setDelegate(@Nullable GeckoSession.TextInputDelegate);
2241 method @UiThread public synchronized void setView(@Nullable View);
2244 @AnyThread public final enum SlowScriptResponse {
2245 method public static SlowScriptResponse valueOf(String);
2246 method public static SlowScriptResponse[] values();
2247 enum_constant public static final SlowScriptResponse CONTINUE;
2248 enum_constant public static final SlowScriptResponse STOP;
2251 public final class StorageController {
2252 ctor public StorageController();
2253 method @AnyThread @NonNull public GeckoResult<Void> clearData(long);
2254 method @AnyThread public void clearDataForSessionContext(@NonNull String);
2255 method @AnyThread @NonNull public GeckoResult<Void> clearDataFromBaseDomain(@NonNull String, long);
2256 method @AnyThread @NonNull public GeckoResult<Void> clearDataFromHost(@NonNull String, long);
2257 method @AnyThread @NonNull public GeckoResult<List<GeckoSession.PermissionDelegate.ContentPermission>> getAllPermissions();
2258 method @AnyThread @NonNull public GeckoResult<Integer> getCookieBannerModeForDomain(@NonNull String, boolean);
2259 method @AnyThread @NonNull public GeckoResult<List<GeckoSession.PermissionDelegate.ContentPermission>> getPermissions(@NonNull String);
2260 method @AnyThread @NonNull public GeckoResult<List<GeckoSession.PermissionDelegate.ContentPermission>> getPermissions(@NonNull String, boolean);
2261 method @AnyThread @NonNull public GeckoResult<List<GeckoSession.PermissionDelegate.ContentPermission>> getPermissions(@NonNull String, @Nullable String, boolean);
2262 method @AnyThread @NonNull public GeckoResult<Void> removeCookieBannerModeForDomain(@NonNull String, boolean);
2263 method @AnyThread @NonNull public GeckoResult<Void> setCookieBannerModeAndPersistInPrivateBrowsingForDomain(@NonNull String, int);
2264 method @AnyThread @NonNull public GeckoResult<Void> setCookieBannerModeForDomain(@NonNull String, int, boolean);
2265 method @AnyThread public void setPermission(@NonNull GeckoSession.PermissionDelegate.ContentPermission, int);
2266 method @AnyThread public void setPrivateBrowsingPermanentPermission(@NonNull GeckoSession.PermissionDelegate.ContentPermission, int);
2269 public static class StorageController.ClearFlags {
2270 ctor public ClearFlags();
2271 field public static final long ALL = 512L;
2272 field public static final long ALL_CACHES = 6L;
2273 field public static final long AUTH_SESSIONS = 32L;
2274 field public static final long COOKIES = 1L;
2275 field public static final long DOM_STORAGES = 16L;
2276 field public static final long IMAGE_CACHE = 4L;
2277 field public static final long NETWORK_CACHE = 2L;
2278 field public static final long PERMISSIONS = 64L;
2279 field public static final long SITE_DATA = 471L;
2280 field public static final long SITE_SETTINGS = 192L;
2283 @Retention(value=RetentionPolicy.SOURCE) public static interface StorageController.StorageControllerClearFlags {
2286 public class TranslationsController {
2287 ctor public TranslationsController();
2290 public static class TranslationsController.Language implements Comparable<TranslationsController.Language> {
2291 ctor public Language(@NonNull String, @Nullable String);
2292 method @AnyThread public int compareTo(@Nullable TranslationsController.Language);
2293 field @NonNull public final String code;
2294 field @Nullable public final String localizedDisplayName;
2297 public static class TranslationsController.RuntimeTranslation {
2298 ctor public RuntimeTranslation();
2299 method @AnyThread @NonNull public static GeckoResult<Long> checkPairDownloadSize(@NonNull String, @NonNull String);
2300 method @AnyThread @NonNull public static GeckoResult<Long> checkPairDownloadSize(@NonNull TranslationsController.SessionTranslation.TranslationPair);
2301 method @AnyThread @NonNull public static GeckoResult<String> getLanguageSetting(@NonNull String);
2302 method @AnyThread @NonNull public static GeckoResult<Map<String,String>> getLanguageSettings();
2303 method @AnyThread @NonNull public static GeckoResult<List<String>> getNeverTranslateSiteList();
2304 method @AnyThread @NonNull public static GeckoResult<Boolean> isTranslationsEngineSupported();
2305 method @AnyThread @NonNull public static GeckoResult<List<TranslationsController.RuntimeTranslation.LanguageModel>> listModelDownloadStates();
2306 method @AnyThread @NonNull public static GeckoResult<TranslationsController.RuntimeTranslation.TranslationSupport> listSupportedLanguages();
2307 method @AnyThread @NonNull public static GeckoResult<Void> manageLanguageModel(@NonNull TranslationsController.RuntimeTranslation.ModelManagementOptions);
2308 method @AnyThread @NonNull public static GeckoResult<List<String>> preferredLanguages();
2309 method @AnyThread @NonNull public static GeckoResult<Void> setLanguageSettings(@NonNull String, @NonNull String);
2310 method @AnyThread @NonNull public static GeckoResult<Void> setNeverTranslateSpecifiedSite(@NonNull Boolean, @NonNull String);
2311 field public static final String ALL = "all";
2312 field public static final String ALWAYS = "always";
2313 field public static final String CACHE = "cache";
2314 field public static final String DELETE = "delete";
2315 field public static final String DOWNLOAD = "download";
2316 field public static final String LANGUAGE = "language";
2317 field public static final String NEVER = "never";
2318 field public static final String OFFER = "offer";
2321 public static class TranslationsController.RuntimeTranslation.LanguageModel {
2322 ctor public LanguageModel(@Nullable TranslationsController.Language, Boolean, long);
2323 field @NonNull public final Boolean isDownloaded;
2324 field @Nullable public final TranslationsController.Language language;
2325 field public final long size;
2328 @Retention(value=RetentionPolicy.SOURCE) public static interface TranslationsController.RuntimeTranslation.LanguageSetting {
2331 @AnyThread public static class TranslationsController.RuntimeTranslation.ModelManagementOptions {
2332 ctor protected ModelManagementOptions(@NonNull TranslationsController.RuntimeTranslation.ModelManagementOptions.Builder);
2333 field @Nullable public final String language;
2334 field @NonNull public final String operation;
2335 field @NonNull public final String operationLevel;
2338 @AnyThread public static class TranslationsController.RuntimeTranslation.ModelManagementOptions.Builder {
2339 ctor public Builder();
2340 method @AnyThread @NonNull public TranslationsController.RuntimeTranslation.ModelManagementOptions build();
2341 method @NonNull public TranslationsController.RuntimeTranslation.ModelManagementOptions.Builder languageToManage(@NonNull String);
2342 method @NonNull public TranslationsController.RuntimeTranslation.ModelManagementOptions.Builder operation(@NonNull String);
2343 method @NonNull public TranslationsController.RuntimeTranslation.ModelManagementOptions.Builder operationLevel(@NonNull String);
2346 @Retention(value=RetentionPolicy.SOURCE) public static interface TranslationsController.RuntimeTranslation.ModelOperation {
2349 @Retention(value=RetentionPolicy.SOURCE) public static interface TranslationsController.RuntimeTranslation.OperationLevel {
2352 public static class TranslationsController.RuntimeTranslation.TranslationSupport {
2353 ctor public TranslationSupport(@Nullable List<TranslationsController.Language>, @Nullable List<TranslationsController.Language>);
2354 field @Nullable public final List<TranslationsController.Language> fromLanguages;
2355 field @Nullable public final List<TranslationsController.Language> toLanguages;
2358 public static class TranslationsController.SessionTranslation {
2359 ctor public SessionTranslation(GeckoSession);
2360 method @AnyThread @NonNull public TranslationsController.SessionTranslation.Handler getHandler();
2361 method @AnyThread @NonNull public GeckoResult<Boolean> getNeverTranslateSiteSetting();
2362 method @AnyThread @NonNull public GeckoResult<Void> restoreOriginalPage();
2363 method @AnyThread @NonNull public GeckoResult<Void> setNeverTranslateSiteSetting(@NonNull Boolean);
2364 method @AnyThread @NonNull public GeckoResult<Void> translate(@NonNull String, @NonNull String, @Nullable TranslationsController.SessionTranslation.TranslationOptions);
2365 method @AnyThread @NonNull public GeckoResult<Void> translate(@NonNull TranslationsController.SessionTranslation.TranslationPair, @Nullable TranslationsController.SessionTranslation.TranslationOptions);
2368 @AnyThread public static interface TranslationsController.SessionTranslation.Delegate {
2369 method default public void onExpectedTranslate(@NonNull GeckoSession);
2370 method default public void onOfferTranslate(@NonNull GeckoSession);
2371 method default public void onTranslationStateChange(@NonNull GeckoSession, @Nullable TranslationsController.SessionTranslation.TranslationState);
2374 public static class TranslationsController.SessionTranslation.DetectedLanguages {
2375 ctor public DetectedLanguages(@Nullable String, @NonNull Boolean, @Nullable String);
2376 field @Nullable public final String docLangTag;
2377 field @NonNull public final Boolean isDocLangTagSupported;
2378 field @Nullable public final String userLangTag;
2381 @AnyThread public static class TranslationsController.SessionTranslation.TranslationOptions {
2382 ctor protected TranslationOptions(@NonNull TranslationsController.SessionTranslation.TranslationOptions.Builder);
2383 field @NonNull public final boolean downloadModel;
2386 @AnyThread public static class TranslationsController.SessionTranslation.TranslationOptions.Builder {
2387 ctor public Builder();
2388 method @AnyThread @NonNull public TranslationsController.SessionTranslation.TranslationOptions build();
2389 method @NonNull public TranslationsController.SessionTranslation.TranslationOptions.Builder downloadModel(@NonNull boolean);
2392 public static class TranslationsController.SessionTranslation.TranslationPair {
2393 ctor public TranslationPair(@Nullable String, @Nullable String);
2394 field @Nullable public final String fromLanguage;
2395 field @Nullable public final String toLanguage;
2398 public static class TranslationsController.SessionTranslation.TranslationState {
2399 ctor public TranslationState(@Nullable TranslationsController.SessionTranslation.TranslationPair, @Nullable String, @Nullable TranslationsController.SessionTranslation.DetectedLanguages, @NonNull Boolean);
2400 field @Nullable public final TranslationsController.SessionTranslation.DetectedLanguages detectedLanguages;
2401 field @Nullable public final String error;
2402 field @NonNull public final Boolean isEngineReady;
2403 field @Nullable public final TranslationsController.SessionTranslation.TranslationPair requestedTranslationPair;
2406 public static class TranslationsController.TranslationsException extends Exception {
2407 ctor public TranslationsException(int);
2408 field public static final int ERROR_COULD_NOT_LOAD_LANGUAGES = -5;
2409 field public static final int ERROR_COULD_NOT_RESTORE = -4;
2410 field public static final int ERROR_COULD_NOT_TRANSLATE = -3;
2411 field public static final int ERROR_ENGINE_NOT_SUPPORTED = -2;
2412 field public static final int ERROR_LANGUAGE_NOT_SUPPORTED = -6;
2413 field public static final int ERROR_MODEL_COULD_NOT_DELETE = -8;
2414 field public static final int ERROR_MODEL_COULD_NOT_DOWNLOAD = -9;
2415 field public static final int ERROR_MODEL_COULD_NOT_RETRIEVE = -7;
2416 field public static final int ERROR_MODEL_DOWNLOAD_REQUIRED = -11;
2417 field public static final int ERROR_MODEL_LANGUAGE_REQUIRED = -10;
2418 field public static final int ERROR_UNKNOWN = -1;
2419 field public final int code;
2422 @Retention(value=RetentionPolicy.SOURCE) public static interface TranslationsController.TranslationsException.Code {
2425 public class WebExtension {
2426 method @Nullable @UiThread public WebExtension.BrowsingDataDelegate getBrowsingDataDelegate();
2427 method @Nullable @UiThread public WebExtension.DownloadDelegate getDownloadDelegate();
2428 method @Nullable @UiThread public WebExtension.TabDelegate getTabDelegate();
2429 method @AnyThread public void setActionDelegate(@Nullable WebExtension.ActionDelegate);
2430 method @UiThread public void setBrowsingDataDelegate(@Nullable WebExtension.BrowsingDataDelegate);
2431 method @UiThread public void setDownloadDelegate(@Nullable WebExtension.DownloadDelegate);
2432 method @UiThread public void setMessageDelegate(@Nullable WebExtension.MessageDelegate, @NonNull String);
2433 method @UiThread public void setTabDelegate(@Nullable WebExtension.TabDelegate);
2434 field public final long flags;
2435 field @NonNull public final String id;
2436 field public final boolean isBuiltIn;
2437 field @NonNull public final String location;
2438 field @NonNull public final WebExtension.MetaData metaData;
2441 @AnyThread public static class WebExtension.Action {
2442 ctor protected Action();
2443 method @UiThread public void click();
2444 method @NonNull public WebExtension.Action withDefault(@NonNull WebExtension.Action);
2445 field @Nullable public final Integer badgeBackgroundColor;
2446 field @Nullable public final String badgeText;
2447 field @Nullable public final Integer badgeTextColor;
2448 field @Nullable public final Boolean enabled;
2449 field @Nullable public final Image icon;
2450 field @Nullable public final String title;
2453 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.Action.ActionType {
2456 public static interface WebExtension.ActionDelegate {
2457 method @UiThread default public void onBrowserAction(@NonNull WebExtension, @Nullable GeckoSession, @NonNull WebExtension.Action);
2458 method @Nullable @UiThread default public GeckoResult<GeckoSession> onOpenPopup(@NonNull WebExtension, @NonNull WebExtension.Action);
2459 method @UiThread default public void onPageAction(@NonNull WebExtension, @Nullable GeckoSession, @NonNull WebExtension.Action);
2460 method @Nullable @UiThread default public GeckoResult<GeckoSession> onTogglePopup(@NonNull WebExtension, @NonNull WebExtension.Action);
2463 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.BlocklistState {
2466 public static class WebExtension.BlocklistStateFlags {
2467 ctor public BlocklistStateFlags();
2468 field public static final int BLOCKED = 2;
2469 field public static final int NOT_BLOCKED = 0;
2470 field public static final int OUTDATED = 3;
2471 field public static final int SOFTBLOCKED = 1;
2472 field public static final int VULNERABLE_NO_UPDATE = 5;
2473 field public static final int VULNERABLE_UPDATE_AVAILABLE = 4;
2476 @UiThread public static interface WebExtension.BrowsingDataDelegate {
2477 method @Nullable default public GeckoResult<Void> onClearDownloads(long);
2478 method @Nullable default public GeckoResult<Void> onClearFormData(long);
2479 method @Nullable default public GeckoResult<Void> onClearHistory(long);
2480 method @Nullable default public GeckoResult<Void> onClearPasswords(long);
2481 method @Nullable default public GeckoResult<WebExtension.BrowsingDataDelegate.Settings> onGetSettings();
2484 @UiThread public static class WebExtension.BrowsingDataDelegate.Settings {
2485 ctor @UiThread public Settings(int, long, long);
2486 field public final long selectedTypes;
2487 field public final int sinceUnixTimestamp;
2488 field public final long toggleableTypes;
2491 public static class WebExtension.BrowsingDataDelegate.Type {
2492 ctor protected Type();
2493 field public static final long CACHE = 1L;
2494 field public static final long COOKIES = 2L;
2495 field public static final long DOWNLOADS = 4L;
2496 field public static final long FORM_DATA = 8L;
2497 field public static final long HISTORY = 16L;
2498 field public static final long LOCAL_STORAGE = 32L;
2499 field public static final long PASSWORDS = 64L;
2502 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.BrowsingDataTypes {
2505 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.ContextFlags {
2508 public static class WebExtension.CreateTabDetails {
2509 ctor protected CreateTabDetails();
2510 field @Nullable public final Boolean active;
2511 field @Nullable public final String cookieStoreId;
2512 field @Nullable public final Boolean discarded;
2513 field @Nullable public final Integer index;
2514 field @Nullable public final Boolean openInReaderMode;
2515 field @Nullable public final Boolean pinned;
2516 field @Nullable public final String url;
2519 public static class WebExtension.DisabledFlags {
2520 ctor public DisabledFlags();
2521 field public static final int APP = 8;
2522 field public static final int APP_VERSION = 32;
2523 field public static final int BLOCKLIST = 4;
2524 field public static final int SIGNATURE = 16;
2525 field public static final int USER = 2;
2528 public static class WebExtension.Download {
2529 ctor protected Download(int);
2530 method @Nullable @UiThread public GeckoResult<Void> update(@NonNull WebExtension.Download.Info);
2531 field public static final int INTERRUPT_REASON_CRASH = 24;
2532 field public static final int INTERRUPT_REASON_FILE_ACCESS_DENIED = 2;
2533 field public static final int INTERRUPT_REASON_FILE_BLOCKED = 8;
2534 field public static final int INTERRUPT_REASON_FILE_FAILED = 1;
2535 field public static final int INTERRUPT_REASON_FILE_NAME_TOO_LONG = 4;
2536 field public static final int INTERRUPT_REASON_FILE_NO_SPACE = 3;
2537 field public static final int INTERRUPT_REASON_FILE_SECURITY_CHECK_FAILED = 9;
2538 field public static final int INTERRUPT_REASON_FILE_TOO_LARGE = 5;
2539 field public static final int INTERRUPT_REASON_FILE_TOO_SHORT = 10;
2540 field public static final int INTERRUPT_REASON_FILE_TRANSIENT_ERROR = 7;
2541 field public static final int INTERRUPT_REASON_FILE_VIRUS_INFECTED = 6;
2542 field public static final int INTERRUPT_REASON_NETWORK_DISCONNECTED = 13;
2543 field public static final int INTERRUPT_REASON_NETWORK_FAILED = 11;
2544 field public static final int INTERRUPT_REASON_NETWORK_INVALID_REQUEST = 15;
2545 field public static final int INTERRUPT_REASON_NETWORK_SERVER_DOWN = 14;
2546 field public static final int INTERRUPT_REASON_NETWORK_TIMEOUT = 12;
2547 field public static final int INTERRUPT_REASON_NO_INTERRUPT = 0;
2548 field public static final int INTERRUPT_REASON_SERVER_BAD_CONTENT = 18;
2549 field public static final int INTERRUPT_REASON_SERVER_CERT_PROBLEM = 20;
2550 field public static final int INTERRUPT_REASON_SERVER_FAILED = 16;
2551 field public static final int INTERRUPT_REASON_SERVER_FORBIDDEN = 21;
2552 field public static final int INTERRUPT_REASON_SERVER_NO_RANGE = 17;
2553 field public static final int INTERRUPT_REASON_SERVER_UNAUTHORIZED = 19;
2554 field public static final int INTERRUPT_REASON_USER_CANCELED = 22;
2555 field public static final int INTERRUPT_REASON_USER_SHUTDOWN = 23;
2556 field public static final int STATE_COMPLETE = 2;
2557 field public static final int STATE_INTERRUPTED = 1;
2558 field public static final int STATE_IN_PROGRESS = 0;
2559 field public final int id;
2562 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.Download.DownloadInterruptReason {
2565 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.Download.DownloadState {
2568 public static interface WebExtension.Download.Info {
2569 method @UiThread default public long bytesReceived();
2570 method @UiThread default public boolean canResume();
2571 method @Nullable @UiThread default public Long endTime();
2572 method @Nullable @UiThread default public Integer error();
2573 method @Nullable @UiThread default public Long estimatedEndTime();
2574 method @UiThread default public boolean fileExists();
2575 method @UiThread default public long fileSize();
2576 method @NonNull @UiThread default public String filename();
2577 method @NonNull @UiThread default public String mime();
2578 method @UiThread default public boolean paused();
2579 method @NonNull @UiThread default public String referrer();
2580 method @UiThread default public long startTime();
2581 method @UiThread default public int state();
2582 method @UiThread default public long totalBytes();
2585 public static interface WebExtension.DownloadDelegate {
2586 method @AnyThread @Nullable default public GeckoResult<WebExtension.DownloadInitData> onDownload(@NonNull WebExtension, @NonNull WebExtension.DownloadRequest);
2589 public static class WebExtension.DownloadInitData {
2590 ctor public DownloadInitData(WebExtension.Download, WebExtension.Download.Info);
2591 field @NonNull public final WebExtension.Download download;
2592 field @NonNull public final WebExtension.Download.Info initData;
2595 public static class WebExtension.DownloadRequest {
2596 ctor protected DownloadRequest(WebExtension.DownloadRequest.Builder);
2597 field public static final int CONFLICT_ACTION_OVERWRITE = 1;
2598 field public static final int CONFLICT_ACTION_PROMPT = 2;
2599 field public static final int CONFLICT_ACTION_UNIQUIFY = 0;
2600 field public final boolean allowHttpErrors;
2601 field public final int conflictActionFlag;
2602 field public final int downloadFlags;
2603 field @Nullable public final String filename;
2604 field @NonNull public final WebRequest request;
2605 field public final boolean saveAs;
2608 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.DownloadRequest.ConflictActionFlags {
2611 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.EnabledFlags {
2614 public static class WebExtension.Flags {
2615 ctor protected Flags();
2616 field public static final long ALLOW_CONTENT_MESSAGING = 1L;
2617 field public static final long NONE = 0L;
2620 public static class WebExtension.InstallException extends Exception {
2621 ctor protected InstallException();
2622 field public final int code;
2623 field @Nullable public final String extensionName;
2626 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.InstallException.Codes {
2629 public static class WebExtension.InstallException.ErrorCodes {
2630 ctor protected ErrorCodes();
2631 field public static final int ERROR_BLOCKLISTED = -10;
2632 field public static final int ERROR_CORRUPT_FILE = -3;
2633 field public static final int ERROR_FILE_ACCESS = -4;
2634 field public static final int ERROR_INCOMPATIBLE = -11;
2635 field public static final int ERROR_INCORRECT_HASH = -2;
2636 field public static final int ERROR_INCORRECT_ID = -7;
2637 field public static final int ERROR_INVALID_DOMAIN = -8;
2638 field public static final int ERROR_NETWORK_FAILURE = -1;
2639 field public static final int ERROR_POSTPONED = -101;
2640 field public static final int ERROR_SIGNEDSTATE_REQUIRED = -5;
2641 field public static final int ERROR_UNEXPECTED_ADDON_TYPE = -6;
2642 field public static final int ERROR_UNEXPECTED_ADDON_VERSION = -9;
2643 field public static final int ERROR_UNSUPPORTED_ADDON_TYPE = -12;
2644 field public static final int ERROR_USER_CANCELED = -100;
2647 @UiThread public static interface WebExtension.MessageDelegate {
2648 method @Nullable default public void onConnect(@NonNull WebExtension.Port);
2649 method @Nullable default public GeckoResult<Object> onMessage(@NonNull String, @NonNull Object, @NonNull WebExtension.MessageSender);
2652 @UiThread public static class WebExtension.MessageSender {
2653 ctor protected MessageSender();
2654 method public boolean isTopLevel();
2655 field public static final int ENV_TYPE_CONTENT_SCRIPT = 2;
2656 field public static final int ENV_TYPE_EXTENSION = 1;
2657 field public final int environmentType;
2658 field @Nullable public final GeckoSession session;
2659 field @NonNull public final String url;
2660 field @NonNull public final WebExtension webExtension;
2663 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.MessageSender.EnvType {
2666 public class WebExtension.MetaData {
2667 ctor protected MetaData();
2668 field public final boolean allowedInPrivateBrowsing;
2669 field @Nullable public final String amoListingUrl;
2670 field public final double averageRating;
2671 field @NonNull public final String baseUrl;
2672 field public final int blocklistState;
2673 field @Nullable public final String creatorName;
2674 field @Nullable public final String creatorUrl;
2675 field @Nullable public final String description;
2676 field public final int disabledFlags;
2677 field @Nullable public final String downloadUrl;
2678 field public final boolean enabled;
2679 field @Nullable public final String fullDescription;
2680 field @NonNull public final String[] grantedOptionalOrigins;
2681 field @NonNull public final String[] grantedOptionalPermissions;
2682 field @Nullable public final String homepageUrl;
2683 field @NonNull public final Image icon;
2684 field @Nullable public final String incognito;
2685 field public final boolean isRecommended;
2686 field @Nullable public final String name;
2687 field public final boolean openOptionsPageInTab;
2688 field @NonNull public final String[] optionalOrigins;
2689 field @NonNull public final String[] optionalPermissions;
2690 field @Nullable public final String optionsPageUrl;
2691 field @NonNull public final String[] origins;
2692 field @NonNull public final String[] permissions;
2693 field public final int reviewCount;
2694 field @Nullable public final String reviewUrl;
2695 field public final int signedState;
2696 field public final boolean temporary;
2697 field @Nullable public final String updateDate;
2698 field @NonNull public final String version;
2701 @UiThread public static class WebExtension.Port {
2702 ctor protected Port();
2703 method public void disconnect();
2704 method public void postMessage(@NonNull JSONObject);
2705 method public void setDelegate(@Nullable WebExtension.PortDelegate);
2706 field @NonNull public final String name;
2707 field @NonNull public final WebExtension.MessageSender sender;
2710 @UiThread public static interface WebExtension.PortDelegate {
2711 method @NonNull default public void onDisconnect(@NonNull WebExtension.Port);
2712 method default public void onPortMessage(@NonNull Object, @NonNull WebExtension.Port);
2715 public static class WebExtension.SessionController {
2716 method @AnyThread @Nullable public WebExtension.ActionDelegate getActionDelegate(@NonNull WebExtension);
2717 method @AnyThread @Nullable public WebExtension.MessageDelegate getMessageDelegate(@NonNull WebExtension, @NonNull String);
2718 method @AnyThread @Nullable public WebExtension.SessionTabDelegate getTabDelegate(@NonNull WebExtension);
2719 method @AnyThread public void setActionDelegate(@NonNull WebExtension, @Nullable WebExtension.ActionDelegate);
2720 method @AnyThread public void setMessageDelegate(@NonNull WebExtension, @Nullable WebExtension.MessageDelegate, @NonNull String);
2721 method @AnyThread public void setTabDelegate(@NonNull WebExtension, @Nullable WebExtension.SessionTabDelegate);
2724 public static interface WebExtension.SessionTabDelegate {
2725 method @NonNull @UiThread default public GeckoResult<AllowOrDeny> onCloseTab(@Nullable WebExtension, @NonNull GeckoSession);
2726 method @NonNull @UiThread default public GeckoResult<AllowOrDeny> onUpdateTab(@NonNull WebExtension, @NonNull GeckoSession, @NonNull WebExtension.UpdateTabDetails);
2729 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.SignedState {
2732 public static class WebExtension.SignedStateFlags {
2733 ctor public SignedStateFlags();
2734 field public static final int MISSING = 0;
2735 field public static final int PRELIMINARY = 1;
2736 field public static final int PRIVILEGED = 4;
2737 field public static final int SIGNED = 2;
2738 field public static final int SYSTEM = 3;
2739 field public static final int UNKNOWN = -1;
2742 public static interface WebExtension.TabDelegate {
2743 method @Nullable @UiThread default public GeckoResult<GeckoSession> onNewTab(@NonNull WebExtension, @NonNull WebExtension.CreateTabDetails);
2744 method @UiThread default public void onOpenOptionsPage(@NonNull WebExtension);
2747 public static class WebExtension.UpdateTabDetails {
2748 ctor protected UpdateTabDetails();
2749 field @Nullable public final Boolean active;
2750 field @Nullable public final Boolean autoDiscardable;
2751 field @Nullable public final Boolean highlighted;
2752 field @Nullable public final Boolean muted;
2753 field @Nullable public final Boolean pinned;
2754 field @Nullable public final String url;
2757 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtension.WebExtensionFlags {
2760 public class WebExtensionController {
2761 method @Nullable @UiThread public WebExtension.Download createDownload(int);
2762 method @AnyThread @NonNull public GeckoResult<WebExtension> disable(@NonNull WebExtension, int);
2763 method @AnyThread public void disableExtensionProcessSpawning();
2764 method @AnyThread @NonNull public GeckoResult<WebExtension> enable(@NonNull WebExtension, int);
2765 method @AnyThread public void enableExtensionProcessSpawning();
2766 method @AnyThread @NonNull public GeckoResult<WebExtension> ensureBuiltIn(@NonNull String, @Nullable String);
2767 method @Nullable @UiThread public WebExtensionController.PromptDelegate getPromptDelegate();
2768 method @AnyThread @NonNull public GeckoResult<WebExtension> install(@NonNull String, @Nullable String);
2769 method @AnyThread @NonNull public GeckoResult<WebExtension> install(@NonNull String);
2770 method @AnyThread @NonNull public GeckoResult<WebExtension> installBuiltIn(@NonNull String);
2771 method @AnyThread @NonNull public GeckoResult<List<WebExtension>> list();
2772 method @UiThread public void setAddonManagerDelegate(@Nullable WebExtensionController.AddonManagerDelegate);
2773 method @AnyThread @NonNull public GeckoResult<WebExtension> setAllowedInPrivateBrowsing(@NonNull WebExtension, boolean);
2774 method @UiThread public void setDebuggerDelegate(@NonNull WebExtensionController.DebuggerDelegate);
2775 method @UiThread public void setExtensionProcessDelegate(@Nullable WebExtensionController.ExtensionProcessDelegate);
2776 method @UiThread public void setPromptDelegate(@Nullable WebExtensionController.PromptDelegate);
2777 method @AnyThread public void setTabActive(@NonNull GeckoSession, boolean);
2778 method @AnyThread @NonNull public GeckoResult<Void> uninstall(@NonNull WebExtension);
2779 method @AnyThread @NonNull public GeckoResult<WebExtension> update(@NonNull WebExtension);
2780 field public static final String INSTALLATION_METHOD_FROM_FILE = "install-from-file";
2781 field public static final String INSTALLATION_METHOD_MANAGER = "manager";
2784 public static interface WebExtensionController.AddonManagerDelegate {
2785 method @UiThread default public void onDisabled(@NonNull WebExtension);
2786 method @UiThread default public void onDisabling(@NonNull WebExtension);
2787 method @UiThread default public void onEnabled(@NonNull WebExtension);
2788 method @UiThread default public void onEnabling(@NonNull WebExtension);
2789 method @UiThread default public void onInstallationFailed(@Nullable WebExtension, @NonNull WebExtension.InstallException);
2790 method @UiThread default public void onInstalled(@NonNull WebExtension);
2791 method @UiThread default public void onInstalling(@NonNull WebExtension);
2792 method @UiThread default public void onReady(@NonNull WebExtension);
2793 method @UiThread default public void onUninstalled(@NonNull WebExtension);
2794 method @UiThread default public void onUninstalling(@NonNull WebExtension);
2797 public static interface WebExtensionController.DebuggerDelegate {
2798 method @UiThread default public void onExtensionListUpdated();
2801 public static class WebExtensionController.EnableSource {
2802 ctor public EnableSource();
2803 field public static final int APP = 2;
2804 field public static final int USER = 1;
2807 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtensionController.EnableSources {
2810 public static interface WebExtensionController.ExtensionProcessDelegate {
2811 method @UiThread default public void onDisabledProcessSpawning();
2814 @Retention(value=RetentionPolicy.SOURCE) public static interface WebExtensionController.InstallationMethod {
2817 @UiThread public static interface WebExtensionController.PromptDelegate {
2818 method @Nullable default public GeckoResult<AllowOrDeny> onInstallPrompt(@NonNull WebExtension);
2819 method @Nullable default public GeckoResult<AllowOrDeny> onOptionalPrompt(@NonNull WebExtension, @NonNull String[], @NonNull String[]);
2820 method @Nullable default public GeckoResult<AllowOrDeny> onUpdatePrompt(@NonNull WebExtension, @NonNull WebExtension, @NonNull String[], @NonNull String[]);
2823 @AnyThread public abstract class WebMessage {
2824 ctor protected WebMessage(@NonNull WebMessage.Builder);
2825 field @NonNull public final Map<String,String> headers;
2826 field @NonNull public final String uri;
2829 @AnyThread public abstract static class WebMessage.Builder {
2830 method @NonNull public WebMessage.Builder addHeader(@NonNull String, @NonNull String);
2831 method @NonNull public WebMessage.Builder header(@NonNull String, @NonNull String);
2832 method @NonNull public WebMessage.Builder uri(@NonNull String);
2835 public class WebNotification implements Parcelable {
2836 method @UiThread public void click();
2837 method @UiThread public void dismiss();
2838 field public static final Parcelable.Creator<WebNotification> CREATOR;
2839 field @Nullable public final String imageUrl;
2840 field @Nullable public final String lang;
2841 field public final boolean privateBrowsing;
2842 field @NonNull public final boolean requireInteraction;
2843 field public final boolean silent;
2844 field @Nullable public final String source;
2845 field @NonNull public final String tag;
2846 field @Nullable public final String text;
2847 field @Nullable public final String textDirection;
2848 field @Nullable public final String title;
2849 field @NonNull public final int[] vibrate;
2852 public interface WebNotificationDelegate {
2853 method @AnyThread default public void onCloseNotification(@NonNull WebNotification);
2854 method @AnyThread default public void onShowNotification(@NonNull WebNotification);
2857 public class WebPushController {
2858 method @Nullable @UiThread public WebPushDelegate getDelegate();
2859 method @UiThread public void onPushEvent(@NonNull String);
2860 method @UiThread public void onPushEvent(@NonNull String, @Nullable byte[]);
2861 method @UiThread public void onSubscriptionChanged(@NonNull String);
2862 method @UiThread public void setDelegate(@Nullable WebPushDelegate);
2865 public interface WebPushDelegate {
2866 method @Nullable @UiThread default public GeckoResult<WebPushSubscription> onGetSubscription(@NonNull String);
2867 method @Nullable @UiThread default public GeckoResult<WebPushSubscription> onSubscribe(@NonNull String, @Nullable byte[]);
2868 method @Nullable @UiThread default public GeckoResult<Void> onUnsubscribe(@NonNull String);
2871 public class WebPushSubscription implements Parcelable {
2872 ctor public WebPushSubscription(@NonNull String, @NonNull String, @Nullable byte[], @NonNull byte[], @NonNull byte[]);
2873 field public static final Parcelable.Creator<WebPushSubscription> CREATOR;
2874 field @Nullable public final byte[] appServerKey;
2875 field @NonNull public final byte[] authSecret;
2876 field @NonNull public final byte[] browserPublicKey;
2877 field @NonNull public final String endpoint;
2878 field @NonNull public final String scope;
2881 @AnyThread public class WebRequest extends WebMessage {
2882 ctor public WebRequest(@NonNull String);
2883 field public static final int CACHE_MODE_DEFAULT = 1;
2884 field public static final int CACHE_MODE_FORCE_CACHE = 5;
2885 field public static final int CACHE_MODE_NO_CACHE = 4;
2886 field public static final int CACHE_MODE_NO_STORE = 2;
2887 field public static final int CACHE_MODE_ONLY_IF_CACHED = 6;
2888 field public static final int CACHE_MODE_RELOAD = 3;
2889 field public final boolean beConservative;
2890 field @Nullable public final ByteBuffer body;
2891 field public final int cacheMode;
2892 field @NonNull public final String method;
2893 field @Nullable public final String referrer;
2896 @AnyThread public static class WebRequest.Builder extends WebMessage.Builder {
2897 ctor public Builder(@NonNull String);
2898 method @NonNull public WebRequest.Builder beConservative(boolean);
2899 method @NonNull public WebRequest.Builder body(@Nullable ByteBuffer);
2900 method @NonNull public WebRequest.Builder body(@Nullable String);
2901 method @NonNull public WebRequest build();
2902 method @NonNull public WebRequest.Builder cacheMode(int);
2903 method @NonNull public WebRequest.Builder method(@NonNull String);
2904 method @NonNull public WebRequest.Builder referrer(@Nullable String);
2907 @Retention(value=RetentionPolicy.SOURCE) public static interface WebRequest.CacheMode {
2910 @AnyThread public class WebRequestError extends Exception {
2911 ctor public WebRequestError(int, int);
2912 ctor public WebRequestError(int, int, X509Certificate);
2913 field public static final int ERROR_BAD_HSTS_CERT = 179;
2914 field public static final int ERROR_CATEGORY_CONTENT = 4;
2915 field public static final int ERROR_CATEGORY_NETWORK = 3;
2916 field public static final int ERROR_CATEGORY_PROXY = 6;
2917 field public static final int ERROR_CATEGORY_SAFEBROWSING = 7;
2918 field public static final int ERROR_CATEGORY_SECURITY = 2;
2919 field public static final int ERROR_CATEGORY_UNKNOWN = 1;
2920 field public static final int ERROR_CATEGORY_URI = 5;
2921 field public static final int ERROR_CONNECTION_REFUSED = 67;
2922 field public static final int ERROR_CONTENT_CRASHED = 68;
2923 field public static final int ERROR_CORRUPTED_CONTENT = 52;
2924 field public static final int ERROR_DATA_URI_TOO_LONG = 117;
2925 field public static final int ERROR_FILE_ACCESS_DENIED = 101;
2926 field public static final int ERROR_FILE_NOT_FOUND = 85;
2927 field public static final int ERROR_HTTPS_ONLY = 163;
2928 field public static final int ERROR_INVALID_CONTENT_ENCODING = 84;
2929 field public static final int ERROR_MALFORMED_URI = 53;
2930 field public static final int ERROR_NET_INTERRUPT = 35;
2931 field public static final int ERROR_NET_RESET = 147;
2932 field public static final int ERROR_NET_TIMEOUT = 51;
2933 field public static final int ERROR_OFFLINE = 115;
2934 field public static final int ERROR_PORT_BLOCKED = 131;
2935 field public static final int ERROR_PROXY_CONNECTION_REFUSED = 38;
2936 field public static final int ERROR_REDIRECT_LOOP = 99;
2937 field public static final int ERROR_SAFEBROWSING_HARMFUL_URI = 71;
2938 field public static final int ERROR_SAFEBROWSING_MALWARE_URI = 39;
2939 field public static final int ERROR_SAFEBROWSING_PHISHING_URI = 87;
2940 field public static final int ERROR_SAFEBROWSING_UNWANTED_URI = 55;
2941 field public static final int ERROR_SECURITY_BAD_CERT = 50;
2942 field public static final int ERROR_SECURITY_SSL = 34;
2943 field public static final int ERROR_UNKNOWN = 17;
2944 field public static final int ERROR_UNKNOWN_HOST = 37;
2945 field public static final int ERROR_UNKNOWN_PROTOCOL = 69;
2946 field public static final int ERROR_UNKNOWN_PROXY_HOST = 54;
2947 field public static final int ERROR_UNKNOWN_SOCKET_TYPE = 83;
2948 field public static final int ERROR_UNSAFE_CONTENT_TYPE = 36;
2949 field public final int category;
2950 field @Nullable public final X509Certificate certificate;
2951 field public final int code;
2954 @Retention(value=RetentionPolicy.SOURCE) public static interface WebRequestError.Error {
2957 @Retention(value=RetentionPolicy.SOURCE) public static interface WebRequestError.ErrorCategory {
2960 @AnyThread public class WebResponse extends WebMessage {
2961 ctor protected WebResponse(@NonNull WebResponse.Builder);
2962 method public void setReadTimeoutMillis(long);
2963 field public static final long DEFAULT_READ_TIMEOUT_MS = 30000L;
2964 field @Nullable public final InputStream body;
2965 field @Nullable public final X509Certificate certificate;
2966 field public final boolean isSecure;
2967 field public final boolean redirected;
2968 field @Nullable public final boolean requestExternalApp;
2969 field @Nullable public final boolean skipConfirmation;
2970 field public final int statusCode;
2973 @AnyThread public static class WebResponse.Builder extends WebMessage.Builder {
2974 ctor public Builder(@NonNull String);
2975 method @NonNull public WebResponse.Builder body(@NonNull InputStream);
2976 method @NonNull public WebResponse build();
2977 method @NonNull public WebResponse.Builder certificate(@NonNull X509Certificate);
2978 method @NonNull public WebResponse.Builder isSecure(boolean);
2979 method @NonNull public WebResponse.Builder redirected(boolean);
2980 method @NonNull public WebResponse.Builder requestExternalApp(boolean);
2981 method @NonNull public WebResponse.Builder skipConfirmation(boolean);
2982 method @NonNull public WebResponse.Builder statusCode(int);