From 75424755210bb586e90d68d14af7ef144c752f98 Mon Sep 17 00:00:00 2001 From: Steven Moreland Date: Wed, 5 Aug 2020 19:42:15 +0000 Subject: [PATCH] Parcelable getStability SystemApi MODULE_LIBRARIES This method is intentionally overridden by subclasses. The infrastructure doesn't detect that this is happening, but we should still annotate this as part of the API. As requested by API review council. Bug: 162811168 Test: build only Change-Id: I27714a93b71108cc0cc62fc858c260e2a6920ba9 --- api/module-lib-current.txt | 1 + core/java/android/os/Parcelable.java | 1 + non-updatable-api/module-lib-current.txt | 1 + 3 files changed, 3 insertions(+) diff --git a/api/module-lib-current.txt b/api/module-lib-current.txt index cacc950aca051..5bc10ece4db56 100644 --- a/api/module-lib-current.txt +++ b/api/module-lib-current.txt @@ -56,6 +56,7 @@ package android.os { } public interface Parcelable { + method public default int getStability(); field public static final int PARCELABLE_STABILITY_LOCAL = 0; // 0x0 field public static final int PARCELABLE_STABILITY_VINTF = 1; // 0x1 } diff --git a/core/java/android/os/Parcelable.java b/core/java/android/os/Parcelable.java index 3d3759e695e0d..f14f66b07630d 100644 --- a/core/java/android/os/Parcelable.java +++ b/core/java/android/os/Parcelable.java @@ -161,6 +161,7 @@ public interface Parcelable { * @return true if this parcelable is stable. * @hide */ + @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) default @Stability int getStability() { return PARCELABLE_STABILITY_LOCAL; } diff --git a/non-updatable-api/module-lib-current.txt b/non-updatable-api/module-lib-current.txt index 02827139f0c95..df45c9ec1dee3 100644 --- a/non-updatable-api/module-lib-current.txt +++ b/non-updatable-api/module-lib-current.txt @@ -16,6 +16,7 @@ package android.os { } public interface Parcelable { + method public default int getStability(); field public static final int PARCELABLE_STABILITY_LOCAL = 0; // 0x0 field public static final int PARCELABLE_STABILITY_VINTF = 1; // 0x1 }