From 3785605a441451398fa5e51f86069286665fee19 Mon Sep 17 00:00:00 2001 From: Julia Reynolds Date: Fri, 11 Nov 2016 09:20:07 -0500 Subject: [PATCH] Make getter & setting names consistent. Test: runtest systemui-notification Change-Id: Iff746f0ae149d1b09792e240503db9d008fe267c --- api/current.txt | 2 +- api/system-current.txt | 2 +- api/test-current.txt | 2 +- core/java/android/app/Notification.java | 2 +- .../android/server/notification/NotificationManagerService.java | 2 +- .../com/android/server/notification/NotificationRecord.java | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/api/current.txt b/api/current.txt index a267ae5afd215..5642a8ada4f62 100644 --- a/api/current.txt +++ b/api/current.txt @@ -4954,9 +4954,9 @@ package android.app { ctor public Notification(android.os.Parcel); method public android.app.Notification clone(); method public int describeContents(); + method public java.lang.String getChannel(); method public java.lang.String getGroup(); method public android.graphics.drawable.Icon getLargeIcon(); - method public java.lang.String getNotificationChannel(); method public android.graphics.drawable.Icon getSmallIcon(); method public java.lang.String getSortKey(); method public void writeToParcel(android.os.Parcel, int); diff --git a/api/system-current.txt b/api/system-current.txt index 4f58ed0a17397..75d12587bf850 100644 --- a/api/system-current.txt +++ b/api/system-current.txt @@ -5107,9 +5107,9 @@ package android.app { ctor public Notification(android.os.Parcel); method public android.app.Notification clone(); method public int describeContents(); + method public java.lang.String getChannel(); method public java.lang.String getGroup(); method public android.graphics.drawable.Icon getLargeIcon(); - method public java.lang.String getNotificationChannel(); method public android.graphics.drawable.Icon getSmallIcon(); method public java.lang.String getSortKey(); method public void writeToParcel(android.os.Parcel, int); diff --git a/api/test-current.txt b/api/test-current.txt index ad56e8f4b056b..7440d368d43c2 100644 --- a/api/test-current.txt +++ b/api/test-current.txt @@ -4964,9 +4964,9 @@ package android.app { ctor public Notification(android.os.Parcel); method public android.app.Notification clone(); method public int describeContents(); + method public java.lang.String getChannel(); method public java.lang.String getGroup(); method public android.graphics.drawable.Icon getLargeIcon(); - method public java.lang.String getNotificationChannel(); method public android.graphics.drawable.Icon getSmallIcon(); method public java.lang.String getSortKey(); method public void writeToParcel(android.os.Parcel, int); diff --git a/core/java/android/app/Notification.java b/core/java/android/app/Notification.java index bdb26855c2416..261fde2883d31 100644 --- a/core/java/android/app/Notification.java +++ b/core/java/android/app/Notification.java @@ -2239,7 +2239,7 @@ public class Notification implements Parcelable /** * Returns the id of the channel this notification posts to. */ - public String getNotificationChannel() { + public String getChannel() { return mChannelId; } diff --git a/services/core/java/com/android/server/notification/NotificationManagerService.java b/services/core/java/com/android/server/notification/NotificationManagerService.java index c7f4d6b5e203a..90ede6ff2f031 100644 --- a/services/core/java/com/android/server/notification/NotificationManagerService.java +++ b/services/core/java/com/android/server/notification/NotificationManagerService.java @@ -2722,7 +2722,7 @@ public class NotificationManagerService extends SystemService { + " id=" + id + " notification=" + notification); } final NotificationChannel channel = mRankingHelper.getNotificationChannelWithFallback(pkg, - callingUid, notification.getNotificationChannel()); + callingUid, notification.getChannel()); final StatusBarNotification n = new StatusBarNotification( pkg, opPkg, channel, id, tag, callingUid, callingPid, notification, user, null, System.currentTimeMillis()); diff --git a/services/core/java/com/android/server/notification/NotificationRecord.java b/services/core/java/com/android/server/notification/NotificationRecord.java index 965257c873e9c..5eacba668398f 100644 --- a/services/core/java/com/android/server/notification/NotificationRecord.java +++ b/services/core/java/com/android/server/notification/NotificationRecord.java @@ -283,7 +283,7 @@ public final class NotificationRecord { pw.println(prefix + " mVisibleSinceMs=" + mVisibleSinceMs); pw.println(prefix + " mUpdateTimeMs=" + mUpdateTimeMs); pw.println(prefix + " mSuppressedVisualEffects= " + mSuppressedVisualEffects); - pw.println(prefix + " notificationChannel= " + notification.getNotificationChannel()); + pw.println(prefix + " notificationChannel= " + notification.getChannel()); }