summaryrefslogtreecommitdiff
path: root/core/java
diff options
context:
space:
mode:
authorTom Natan <tomnatan@google.com>2021-04-28 10:26:25 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2021-04-28 10:26:25 +0000
commitba2767ef4a32986be5863d1d0aa50b20a039bced (patch)
tree56893ab5fc3ad6cab57b1bf69b75fb1f5b463f6b /core/java
parente8c9b223f527d5e3fc1a6e0f43d46e189b5d9ea1 (diff)
parentbfc894c34f8ee05b4b91dbe9879f3f8979b3513f (diff)
Merge "Document version codes in CompatChanges API" am: d4691f8a31 am: de7b72d03e am: bfc894c34f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1688067 Change-Id: I6bc5d31fa7fc02194fd7e638658f7120f1b68500
Diffstat (limited to 'core/java')
-rw-r--r--core/java/android/app/compat/PackageOverride.java21
1 files changed, 17 insertions, 4 deletions
diff --git a/core/java/android/app/compat/PackageOverride.java b/core/java/android/app/compat/PackageOverride.java
index 59b355523a30..fad6cd311021 100644
--- a/core/java/android/app/compat/PackageOverride.java
+++ b/core/java/android/app/compat/PackageOverride.java
@@ -19,6 +19,7 @@ package android.app.compat;
import android.annotation.IntDef;
import android.annotation.NonNull;
import android.annotation.SystemApi;
+import android.content.pm.PackageInfo;
import android.os.Parcel;
import java.lang.annotation.Retention;
@@ -101,12 +102,20 @@ public final class PackageOverride {
return VALUE_UNDEFINED;
}
- /** Returns the minimum version code the override applies to. */
+ /**
+ * Returns the minimum APK version code the override applies to.
+ *
+ * @see PackageInfo#getLongVersionCode()
+ */
public long getMinVersionCode() {
return mMinVersionCode;
}
- /** Returns the minimum version code the override applies from. */
+ /**
+ * Returns the maximum APK version code the override applies from.
+ *
+ * @see PackageInfo#getLongVersionCode()
+ */
public long getMaxVersionCode() {
return mMaxVersionCode;
}
@@ -146,9 +155,11 @@ public final class PackageOverride {
private boolean mEnabled;
/**
- * Sets the minimum version code the override should apply from.
+ * Sets the minimum APK version code the override should apply from.
*
* default value: {@code Long.MIN_VALUE}.
+ *
+ * @see PackageInfo#getLongVersionCode()
*/
@NonNull
public Builder setMinVersionCode(long minVersionCode) {
@@ -157,9 +168,11 @@ public final class PackageOverride {
}
/**
- * Sets the maximum version code the override should apply to.
+ * Sets the maximum APK version code the override should apply to.
*
* default value: {@code Long.MAX_VALUE}.
+ *
+ * @see PackageInfo#getLongVersionCode()
*/
@NonNull
public Builder setMaxVersionCode(long maxVersionCode) {