Bug 1448095 - 2. Fix javadoc warnings; r=me
authorJim Chen <nchen@mozilla.com>
Tue, 24 Apr 2018 00:43:51 -0400
changeset 471307 6da32c5c109ddffc9d520e98a67de26afb21dc72
parent 471306 ef55a35aa35e9469ed04e87668e31446d6dc4cb3
child 471308 305addd57798647a6673b7fbacc7f4a712cb0f59
push id1728
push userjlund@mozilla.com
push dateMon, 18 Jun 2018 21:12:27 +0000
treeherdermozilla-release@c296fde26f5f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersme
bugs1448095
milestone61.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1448095 - 2. Fix javadoc warnings; r=me
mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntime.java
mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntimeSettings.java
mobile/android/geckoview/src/main/java/org/mozilla/geckoview/SessionAccessibility.java
--- a/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntime.java
+++ b/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntime.java
@@ -29,16 +29,17 @@ public final class GeckoRuntime implemen
 
     /**
      * Get the default runtime for the given context.
      * This will create and initialize the runtime with the default settings.
      *
      * Note: Only use this for session-less apps.
      *       For regular apps, use create() and createSession() instead.
      *
+     * @param context An application context for the default runtime.
      * @return The (static) default runtime for the context.
      */
     public static synchronized @NonNull GeckoRuntime getDefault(
             final @NonNull Context context) {
         Log.d(LOGTAG, "getDefault");
         if (sDefaultRuntime == null) {
             sDefaultRuntime = new GeckoRuntime();
             sDefaultRuntime.attachTo(context);
--- a/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntimeSettings.java
+++ b/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntimeSettings.java
@@ -35,72 +35,78 @@ public final class GeckoRuntimeSettings 
         public @NonNull GeckoRuntimeSettings build() {
             return new GeckoRuntimeSettings(mSettings);
         }
 
         /**
          * Set the content process hint flag.
          *
          * @param use If true, this will reload the content process for future use.
+         * @return This Builder instance.
          */
         public @NonNull Builder useContentProcessHint(final boolean use) {
             mSettings.mUseContentProcess = use;
             return this;
         }
 
         /**
          * Set the custom Gecko process arguments.
          *
          * @param args The Gecko process arguments.
+         * @return This Builder instance.
          */
         public @NonNull Builder arguments(final @NonNull String[] args) {
             if (args == null) {
                 throw new IllegalArgumentException("Arguments must not  be null");
             }
             mSettings.mArgs = args;
             return this;
         }
 
         /**
          * Set the custom Gecko intent extras.
          *
          * @param extras The Gecko intent extras.
+         * @return This Builder instance.
          */
         public @NonNull Builder extras(final @NonNull Bundle extras) {
             if (extras == null) {
                 throw new IllegalArgumentException("Extras must not  be null");
             }
             mSettings.mExtras = extras;
             return this;
         }
 
         /**
          * Set whether JavaScript support should be enabled.
          *
          * @param flag A flag determining whether JavaScript should be enabled.
+         * @return This Builder instance.
          */
         public @NonNull Builder javaScriptEnabled(final boolean flag) {
             mSettings.mJavaScript.set(flag);
             return this;
         }
 
         /**
          * Set whether remote debugging support should be enabled.
          *
          * @param enabled True if remote debugging should be enabled.
+         * @return This Builder instance.
          */
         public @NonNull Builder remoteDebuggingEnabled(final boolean enabled) {
             mSettings.mRemoteDebugging.set(enabled);
             return this;
         }
 
         /**
          * Set whether support for web fonts should be enabled.
          *
          * @param flag A flag determining whether web fonts should be enabled.
+         * @return This Builder instance.
          */
         public @NonNull Builder webFontsEnabled(final boolean flag) {
             mSettings.mWebFonts.set(flag);
             return this;
         }
     }
 
     /* package */ GeckoRuntime runtime;
@@ -217,16 +223,17 @@ public final class GeckoRuntimeSettings 
     public boolean getJavaScriptEnabled() {
         return mJavaScript.get();
     }
 
     /**
      * Set whether JavaScript support should be enabled.
      *
      * @param flag A flag determining whether JavaScript should be enabled.
+     * @return This GeckoRuntimeSettings instance.
      */
     public @NonNull GeckoRuntimeSettings setJavaScriptEnabled(final boolean flag) {
         mJavaScript.set(flag);
         return this;
     }
 
     /**
      * Get whether remote debugging support is enabled.
@@ -236,16 +243,17 @@ public final class GeckoRuntimeSettings 
     public boolean getRemoteDebuggingEnabled() {
         return mRemoteDebugging.get();
     }
 
     /**
      * Set whether remote debugging support should be enabled.
      *
      * @param enabled True if remote debugging should be enabled.
+     * @return This GeckoRuntimeSettings instance.
      */
     public @NonNull GeckoRuntimeSettings setRemoteDebuggingEnabled(final boolean enabled) {
         mRemoteDebugging.set(enabled);
         return this;
     }
 
     /**
      * Get whether web fonts support is enabled.
@@ -255,16 +263,17 @@ public final class GeckoRuntimeSettings 
     public boolean getWebFontsEnabled() {
         return mWebFonts.get();
     }
 
     /**
      * Set whether support for web fonts should be enabled.
      *
      * @param flag A flag determining whether web fonts should be enabled.
+     * @return This GeckoRuntimeSettings instance.
      */
     public @NonNull GeckoRuntimeSettings setWebFontsEnabled(final boolean flag) {
         mWebFonts.set(flag);
         return this;
     }
 
     @Override // Parcelable
     public int describeContents() {
--- a/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/SessionAccessibility.java
+++ b/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/SessionAccessibility.java
@@ -55,26 +55,28 @@ public class SessionAccessibility {
             public void handleMessage(final String event, final GeckoBundle message,
                                       final EventCallback callback) {
                 sendAccessibilityEvent(message);
             }
         }, "GeckoView:AccessibilityEvent", null);
     }
 
     /**
-      * Get the GeckoView instance that delegates accessibility to this session.
+      * Get the View instance that delegates accessibility to this session.
       *
-      * @return GeckoView instance.
+      * @return View instance.
       */
     public View getView() {
         return mView;
     }
 
     /**
-      * Set the GeckoView instance that should delegate accessibility to this session.
+      * Set the View instance that should delegate accessibility to this session.
+      *
+      * @param view View instance.
       */
     public void setView(final View view) {
         if (mView != null) {
             mView.setAccessibilityDelegate(null);
         }
 
         mView = view;
         mLastItem = false;