新聞中心
INotificationSubscriber

創(chuàng)新互聯是一家集網站建設,奉節(jié)企業(yè)網站建設,奉節(jié)品牌網站建設,網站定制,奉節(jié)網站建設報價,網絡營銷,網絡優(yōu)化,奉節(jié)網站推廣為一體的創(chuàng)新建站企業(yè),幫助傳統(tǒng)企業(yè)提升企業(yè)形象加強企業(yè)競爭力??沙浞譂M足這一群體相比中小企業(yè)更為豐富、高端、多元的互聯網需求。同時我們時刻保持專業(yè)、時尚、前沿,時刻以成就客戶成長自我,堅持不斷學習、思考、沉淀、凈化自己,讓我們?yōu)楦嗟钠髽I(yè)打造出實用型網站。
@Deprecatedpublic interface INotificationSubscriberextends IRemoteBroker已棄用。 此更改從 API 版本 5 開始生效。此 API 僅在高級通知系統(tǒng)中使用,不對外部系統(tǒng)開放。
Since:
1
字段摘要
| 修飾符和類型 | 字段 | 描述 |
|---|---|---|
| static String | DESCRIPTOR | 已棄用。 |
| static int | NOTIFICATION_CONNECTED | 已棄用。 |
| static int | NOTIFICATION_DISCONNECT | 已棄用。 |
| static int | NOTIFICATION_DISTURB_MODE_CHANGE | 已棄用。 |
| static int | NOTIFICATION_POSTED | 已棄用。 |
| static int | NOTIFICATION_REMOVED | 已棄用。 |
| static int | NOTIFICATION_UPDATE | 已棄用。 |
方法總結
| 修飾符和類型 | 方法 | 描述 |
|---|---|---|
| void | onDisturbModeChange(int disturbMode) | 已棄用。 |
| void | onNotificationPosted(NotificationRequest info) | 已棄用。 |
| void | onNotificationPosted(NotificationRequest info, NotificationSortingMap sortingMap) | 已棄用。 |
| void | onNotificationRankingUpdate(NotificationSortingMap sortingMap) | 已棄用。 |
| void | onNotificationRemoved(NotificationRequest info) | 已棄用。 |
| void | onNotificationRemoved(NotificationRequest info, NotificationSortingMap sortingMap, int deleteReason) | 已棄用。 |
| void | onSubscribeConnected() | 已棄用。 |
| void | onSubscribeDisConnected() | 已棄用。 |
| 從接口 ohos.rpc.IRemoteBroker 繼承的方法 |
|---|
| asObject |
字段詳細信息
DESCRIPTOR
@Deprecated static final String DESCRIPTOR
已棄用。
唯一標識遠程過程調用 (RPC) 對象。
Since:
1
NOTIFICATION_CONNECTED
@Deprecated static final int NOTIFICATION_CONNECTED
已棄用。
表示訂閱者已連接到 ANS。 此常量用于調用 onSubscribeConnected() 方法。
Since:
1
NOTIFICATION_DISCONNECT
@Deprecated static final int NOTIFICATION_DISCONNECT
已棄用。
表示訂閱者與 ANS 斷開連接。 此常量用于調用 onSubscribeDisConnected() 方法。
Since:
1
NOTIFICATION_DISTURB_MODE_CHANGE
@Deprecated static final int NOTIFICATION_DISTURB_MODE_CHANGE
已棄用。
表示請勿打擾模式類型更改。 此常量用于調用 onDisturbModeChange(int) 方法。
Since:
4
NOTIFICATION_POSTED
@Deprecated static final int NOTIFICATION_POSTED
已棄用。
表示訂閱者成功接收到通知。 該常量用于調用 onNotificationPosted(ohos.event.notification.NotificationRequest) 方法。
Since:
1
NOTIFICATION_REMOVED
@Deprecated static final int NOTIFICATION_REMOVED
已棄用。
表示訂閱者收到的通知被移除。 該常量用于調用 onNotificationRemoved(ohos.event.notification.NotificationRequest) 方法。
Since:
1
NOTIFICATION_UPDATE
@Deprecated static final int NOTIFICATION_UPDATE
已棄用。
表示通知的排名信息發(fā)生變化。 該常量用于調用 onNotificationRankingUpdate(ohos.event.notification.NotificationSortingMap) 方法。
Since:
1
方法詳情
onNotificationPosted
@Deprecated void onNotificationPosted(NotificationRequest info) throws RemoteException
已棄用。
當訂閱者收到新通知時回調。
參數:
| 參數名稱 | 參數描述 |
|---|---|
| info | 表示接收到的 NotificationRequest 對象。 |
Throws:
| Throw名稱 | Throw描述 |
|---|---|
| RemoteException | 如果發(fā)生 IPC 異常,則拋出此異常。 |
Since:
1
onNotificationPosted
@Deprecated void onNotificationPosted(NotificationRequest info, NotificationSortingMap sortingMap) throws RemoteException
已棄用。
當訂閱者收到新通知時回調。
參數:
| 參數名稱 | 參數描述 |
|---|---|
| info | 表示接收到的 NotificationRequest 對象。 |
| sortingMap | 表示當前訂閱者獲取通知排名信息所使用的排序圖。 |
Throws:
| Throw名稱 | Throw描述 |
|---|---|
| RemoteException | 如果發(fā)生 IPC 異常,則拋出此異常。 |
Since:
2
onNotificationRemoved
@Deprecated void onNotificationRemoved(NotificationRequest info) throws RemoteException
已棄用。
刪除通知時回調。
參數:
| 參數名稱 | 參數描述 |
|---|---|
| info | 表示已移除的 NotificationRequest 對象。 |
Throws:
| Throw名稱 | Throw描述 |
|---|---|
| RemoteException | 如果發(fā)生 IPC 異常,則拋出此異常。 |
Since:
1
onNotificationRemoved
@Deprecated void onNotificationRemoved(NotificationRequest info, NotificationSortingMap sortingMap, int deleteReason) throws RemoteException
已棄用。
刪除通知時回調。
參數:
| 參數名稱 | 參數描述 |
|---|---|
| info | 表示已移除的 NotificationRequest 對象。 |
| sortingMap | 表示當前訂閱者獲取通知排名信息所使用的排序圖。 |
| deleteReason | 表示刪除的原因。 |
Throws:
| Throw名稱 | Throw描述 |
|---|---|
| RemoteException | 如果發(fā)生 IPC 異常,則拋出此異常。 |
Since:
2
onNotificationRankingUpdate
@Deprecated void onNotificationRankingUpdate(NotificationSortingMap sortingMap) throws RemoteException
已棄用。
當前通知的排名信息發(fā)生變化時回調。
參數:
| 參數名稱 | 參數描述 |
|---|---|
| sortingMap | 表示用于獲取通知排名信息的排序圖。 |
Throws:
| Throw名稱 | Throw描述 |
|---|---|
| RemoteException | 如果發(fā)生 IPC 異常,則拋出此異常。 |
Since:
1
onSubscribeConnected
@Deprecated void onSubscribeConnected() throws RemoteException
已棄用。
當訂閱者連接到高級通知服務 (ANS) 時回調。
Throws:
| Throw名稱 | Throw描述 |
|---|---|
| RemoteException | 如果發(fā)生 IPC 異常,則拋出此異常。 |
Since:
1
onSubscribeDisConnected
@Deprecated void onSubscribeDisConnected() throws RemoteException
已棄用。
當訂閱者與 ANS 斷開連接時回調。
Throws:
| Throw名稱 | Throw描述 |
|---|---|
| RemoteException | 如果發(fā)生 IPC 異常,則拋出此異常。 |
Since:
1
onDisturbModeChange
@Deprecated void onDisturbModeChange(int disturbMode) throws RemoteException
已棄用。
當請勿打擾模式類型更改時調用。
參數:
| 參數名稱 | 參數描述 |
|---|---|
| disturbMode | 指示當前的請勿打擾模式類型。 |
Throws:
| Throw名稱 | Throw描述 |
|---|---|
| RemoteException | 如果發(fā)生 IPC 異常,則拋出此異常。 |
Since:
4
當前題目:創(chuàng)新互聯鴻蒙OS教程:鴻蒙OSINotificationSubscriber
網站地址:http://fisionsoft.com.cn/article/coghiis.html


咨詢
建站咨詢
