Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/logging/NotifEvent.java +8 −30 Original line number Diff line number Diff line Loading @@ -27,12 +27,11 @@ import java.lang.annotation.RetentionPolicy; /** * An event related to notifications. {@link NotifLog} stores and prints these events for debugging * and triaging purposes. * and triaging purposes. We do not store a copy of the status bar notification nor ranking * here to mitigate memory usage. */ public class NotifEvent extends RichEvent { public static final int TOTAL_EVENT_TYPES = 11; private final StatusBarNotification mSbn; private final Ranking mRanking; /** * Creates a NotifEvent with an event type that matches with an index in the array Loading @@ -44,34 +43,20 @@ public class NotifEvent extends RichEvent { public NotifEvent(int logLevel, int type, String reason, StatusBarNotification sbn, Ranking ranking) { super(logLevel, type, reason); if (sbn != null) { mSbn = sbn.cloneLight(); } else { mSbn = null; } if (ranking != null) { mRanking = new Ranking(); mRanking.populate(ranking); } else { mRanking = null; } mMessage += getExtraInfo(); mMessage += getExtraInfo(sbn, ranking); } private String getExtraInfo() { private String getExtraInfo(StatusBarNotification sbn, Ranking ranking) { StringBuilder extraInfo = new StringBuilder(); if (mSbn != null) { if (sbn != null) { extraInfo.append(" Sbn="); extraInfo.append(mSbn); extraInfo.append(sbn); } if (mRanking != null) { if (ranking != null) { extraInfo.append(" Ranking="); extraInfo.append(mRanking); extraInfo.append(ranking); } return extraInfo.toString(); Loading Loading @@ -106,13 +91,6 @@ public class NotifEvent extends RichEvent { return events; } /** * @return a copy of the status bar notification that changed with this event */ public StatusBarNotification getSbn() { return mSbn; } /** * Builds a NotifEvent. */ Loading Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/logging/NotifEvent.java +8 −30 Original line number Diff line number Diff line Loading @@ -27,12 +27,11 @@ import java.lang.annotation.RetentionPolicy; /** * An event related to notifications. {@link NotifLog} stores and prints these events for debugging * and triaging purposes. * and triaging purposes. We do not store a copy of the status bar notification nor ranking * here to mitigate memory usage. */ public class NotifEvent extends RichEvent { public static final int TOTAL_EVENT_TYPES = 11; private final StatusBarNotification mSbn; private final Ranking mRanking; /** * Creates a NotifEvent with an event type that matches with an index in the array Loading @@ -44,34 +43,20 @@ public class NotifEvent extends RichEvent { public NotifEvent(int logLevel, int type, String reason, StatusBarNotification sbn, Ranking ranking) { super(logLevel, type, reason); if (sbn != null) { mSbn = sbn.cloneLight(); } else { mSbn = null; } if (ranking != null) { mRanking = new Ranking(); mRanking.populate(ranking); } else { mRanking = null; } mMessage += getExtraInfo(); mMessage += getExtraInfo(sbn, ranking); } private String getExtraInfo() { private String getExtraInfo(StatusBarNotification sbn, Ranking ranking) { StringBuilder extraInfo = new StringBuilder(); if (mSbn != null) { if (sbn != null) { extraInfo.append(" Sbn="); extraInfo.append(mSbn); extraInfo.append(sbn); } if (mRanking != null) { if (ranking != null) { extraInfo.append(" Ranking="); extraInfo.append(mRanking); extraInfo.append(ranking); } return extraInfo.toString(); Loading Loading @@ -106,13 +91,6 @@ public class NotifEvent extends RichEvent { return events; } /** * @return a copy of the status bar notification that changed with this event */ public StatusBarNotification getSbn() { return mSbn; } /** * Builds a NotifEvent. */ Loading