diff options
| author | 2020-12-10 08:47:13 +0000 | |
|---|---|---|
| committer | 2020-12-10 08:47:13 +0000 | |
| commit | 52dceb804b59425f110ea2936fcde7c526810d16 (patch) | |
| tree | 5704535c11317be7a4d9e4f79672f4775d212099 | |
| parent | cc8c3ba4a93cba8b93e56822635a4a67f7a874aa (diff) | |
| parent | 5675ee40c39979d20788126968ac18b10c2969e4 (diff) | |
Merge "Nullable annoation for Location#setExtras."
| -rw-r--r-- | core/api/current.txt | 2 | ||||
| -rw-r--r-- | location/java/android/location/Location.java | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/core/api/current.txt b/core/api/current.txt index cb5aea77004a..423b523a1027 100644 --- a/core/api/current.txt +++ b/core/api/current.txt @@ -24036,7 +24036,7 @@ package android.location { method public void setBearingAccuracyDegrees(float); method public void setElapsedRealtimeNanos(long); method public void setElapsedRealtimeUncertaintyNanos(double); - method @Deprecated public void setExtras(android.os.Bundle); + method @Deprecated public void setExtras(@Nullable android.os.Bundle); method public void setLatitude(double); method public void setLongitude(double); method public void setProvider(String); diff --git a/location/java/android/location/Location.java b/location/java/android/location/Location.java index b4392b1d29b4..47ecbd80a07f 100644 --- a/location/java/android/location/Location.java +++ b/location/java/android/location/Location.java @@ -19,6 +19,7 @@ package android.location; import static java.util.concurrent.TimeUnit.NANOSECONDS; import android.annotation.NonNull; +import android.annotation.Nullable; import android.annotation.SystemApi; import android.compat.annotation.UnsupportedAppUsage; import android.os.Build; @@ -1066,7 +1067,7 @@ public class Location implements Parcelable { * @deprecated Do not use. */ @Deprecated - public void setExtras(Bundle extras) { + public void setExtras(@Nullable Bundle extras) { mExtras = (extras == null) ? null : new Bundle(extras); } |