diff options
| author | 2018-04-06 22:06:04 +0000 | |
|---|---|---|
| committer | 2018-04-06 22:06:04 +0000 | |
| commit | 66b90a035f13d3ad0f7399cd8978c890a38ec935 (patch) | |
| tree | d29f5d81db089e64aa097607ea2b2feb455004d6 | |
| parent | 7f03f1a20c1b6190003b9b5baf0f14dfc25785b5 (diff) | |
| parent | eb53c228f062a895dd90a00b6f2d7e7dda3d8ca1 (diff) | |
Merge "Added nullability annotations to API" into pi-dev
| -rw-r--r-- | core/java/android/app/Notification.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/java/android/app/Notification.java b/core/java/android/app/Notification.java index 87198756a602..4ab6724262ce 100644 --- a/core/java/android/app/Notification.java +++ b/core/java/android/app/Notification.java @@ -6431,6 +6431,7 @@ public class Notification implements Parcelable /** * @return the user to be displayed for any replies sent by the user */ + @NonNull public Person getUser() { return mUser; } @@ -6505,7 +6506,8 @@ public class Notification implements Parcelable * * @return this object for method chaining */ - public MessagingStyle addMessage(CharSequence text, long timestamp, Person sender) { + public MessagingStyle addMessage(@NonNull CharSequence text, long timestamp, + @Nullable Person sender) { return addMessage(new Message(text, timestamp, sender)); } @@ -6935,7 +6937,7 @@ public class Notification implements Parcelable * to differentiate between the different users. * </p> */ - public Message(CharSequence text, long timestamp, @Nullable Person sender){ + public Message(@NonNull CharSequence text, long timestamp, @Nullable Person sender) { mText = text; mTimestamp = timestamp; mSender = sender; |