summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Bernardo Rufino <brufino@google.com> 2022-03-14 10:01:55 +0000
committer Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2022-03-14 10:01:55 +0000
commit91dfda1f28b2693d33cc1f4483f908c63f281572 (patch)
tree0d6884ff96c4f541b00a4fc9afeb6e1e7759610c
parent9675d3b8770ab86453567341f349e1831e829443 (diff)
parent5e90e84fe64432b607578eb0f8af6324aab57ea6 (diff)
Merge "Document when types are checked in Bundle" am: 05f2831e1c am: 9e3ee7afc6 am: 5e90e84fe6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2018615 Change-Id: I4d7f75c708922cf6889fe7125f6be537426e7c06
-rw-r--r--core/java/android/os/Bundle.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/core/java/android/os/Bundle.java b/core/java/android/os/Bundle.java
index a19b51b7811b..cf28c1639fac 100644
--- a/core/java/android/os/Bundle.java
+++ b/core/java/android/os/Bundle.java
@@ -989,7 +989,7 @@ public final class Bundle extends BaseBundle implements Cloneable, Parcelable {
* Otherwise, this method might throw an exception or return {@code null}.
*
* @param key a String, or {@code null}
- * @param clazz The type of the items inside the array
+ * @param clazz The type of the items inside the array. This is only verified when unparceling.
* @return a Parcelable[] value, or {@code null}
*/
@SuppressLint({"ArrayReturn", "NullableCollection"})
@@ -1053,7 +1053,8 @@ public final class Bundle extends BaseBundle implements Cloneable, Parcelable {
* Otherwise, this method might throw an exception or return {@code null}.
*
* @param key a String, or {@code null}
- * @param clazz The type of the items inside the array list
+ * @param clazz The type of the items inside the array list. This is only verified when
+ * unparceling.
* @return an ArrayList<T> value, or {@code null}
*/
@SuppressLint("NullableCollection")
@@ -1103,6 +1104,8 @@ public final class Bundle extends BaseBundle implements Cloneable, Parcelable {
* </ul>
*
* @param key a String, or null
+ * @param clazz The type of the items inside the sparse array. This is only verified when
+ * unparceling.
* @return a SparseArray of T values, or null
*/
@SuppressWarnings("unchecked")