“5e78954a8d34d4441f1c5326ee81b6947a6841fd”上不存在“...apis/js-apis-inner-application-abilityRunningInfo.md”
提交 2173f599 编写于 作者: F fangJinliang1

fix docs

Signed-off-by: NfangJinliang1 <fangjinliang1@huawei.com>
Change-Id: I67907475203100088df4fa53c8df0ed138d324e0
Signed-off-by: NfangJinliang1 <fangjinliang1@huawei.com>
上级 955b6253
...@@ -16,7 +16,7 @@ import WantAgent from '@ohos.app.ability.wantAgent'; ...@@ -16,7 +16,7 @@ import WantAgent from '@ohos.app.ability.wantAgent';
getWantAgent(info: WantAgentInfo, callback: AsyncCallback\<WantAgent\>): void getWantAgent(info: WantAgentInfo, callback: AsyncCallback\<WantAgent\>): void
创建WantAgent(callback形式)。 创建WantAgent(callback形式)。 创建失败返回的WantAgent为空值。
**系统能力**:SystemCapability.Ability.AbilityRuntime.Core **系统能力**:SystemCapability.Ability.AbilityRuntime.Core
...@@ -77,7 +77,7 @@ try { ...@@ -77,7 +77,7 @@ try {
getWantAgent(info: WantAgentInfo): Promise\<WantAgent\> getWantAgent(info: WantAgentInfo): Promise\<WantAgent\>
创建WantAgent(Promise形式)。 创建WantAgent(Promise形式)。 创建失败返回的WantAgent为空值。
**系统能力**:SystemCapability.Ability.AbilityRuntime.Core **系统能力**:SystemCapability.Ability.AbilityRuntime.Core
......
...@@ -29,6 +29,8 @@ publish(request: NotificationRequest, callback: AsyncCallback\<void\>): void ...@@ -29,6 +29,8 @@ publish(request: NotificationRequest, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------------- | | -------- | ----------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -82,6 +84,8 @@ publish(request: NotificationRequest): Promise\<void\> ...@@ -82,6 +84,8 @@ publish(request: NotificationRequest): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------------- | | -------- | ----------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -134,6 +138,8 @@ publish(request: NotificationRequest, userId: number, callback: AsyncCallback\<v ...@@ -134,6 +138,8 @@ publish(request: NotificationRequest, userId: number, callback: AsyncCallback\<v
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------------- | | -------- | ----------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -193,6 +199,8 @@ publish(request: NotificationRequest, userId: number): Promise\<void\> ...@@ -193,6 +199,8 @@ publish(request: NotificationRequest, userId: number): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------------- | | -------- | ----------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -244,6 +252,8 @@ cancel(id: number, label: string, callback: AsyncCallback\<void\>): void ...@@ -244,6 +252,8 @@ cancel(id: number, label: string, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -284,6 +294,8 @@ cancel(id: number, label?: string): Promise\<void\> ...@@ -284,6 +294,8 @@ cancel(id: number, label?: string): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -318,6 +330,8 @@ cancel(id: number, callback: AsyncCallback\<void\>): void ...@@ -318,6 +330,8 @@ cancel(id: number, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -351,6 +365,8 @@ cancelAll(callback: AsyncCallback\<void\>): void ...@@ -351,6 +365,8 @@ cancelAll(callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -389,6 +405,8 @@ cancelAll(): Promise\<void\> ...@@ -389,6 +405,8 @@ cancelAll(): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -426,6 +444,8 @@ addSlot(slot: NotificationSlot, callback: AsyncCallback\<void\>): void ...@@ -426,6 +444,8 @@ addSlot(slot: NotificationSlot, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -472,6 +492,8 @@ addSlot(slot: NotificationSlot): Promise\<void\> ...@@ -472,6 +492,8 @@ addSlot(slot: NotificationSlot): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -509,6 +531,8 @@ addSlot(type: SlotType, callback: AsyncCallback\<void\>): void ...@@ -509,6 +531,8 @@ addSlot(type: SlotType, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -547,6 +571,8 @@ addSlot(type: SlotType): Promise\<void\> ...@@ -547,6 +571,8 @@ addSlot(type: SlotType): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -584,6 +610,8 @@ addSlots(slots: Array\<NotificationSlot\>, callback: AsyncCallback\<void\>): voi ...@@ -584,6 +610,8 @@ addSlots(slots: Array\<NotificationSlot\>, callback: AsyncCallback\<void\>): voi
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -634,6 +662,8 @@ addSlots(slots: Array\<NotificationSlot\>): Promise\<void\> ...@@ -634,6 +662,8 @@ addSlots(slots: Array\<NotificationSlot\>): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -675,6 +705,8 @@ getSlot(slotType: SlotType, callback: AsyncCallback\<NotificationSlot\>): void ...@@ -675,6 +705,8 @@ getSlot(slotType: SlotType, callback: AsyncCallback\<NotificationSlot\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -720,6 +752,8 @@ getSlot(slotType: SlotType): Promise\<NotificationSlot\> ...@@ -720,6 +752,8 @@ getSlot(slotType: SlotType): Promise\<NotificationSlot\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -753,6 +787,8 @@ getSlots(callback: AsyncCallback<Array\<NotificationSlot\>>): void ...@@ -753,6 +787,8 @@ getSlots(callback: AsyncCallback<Array\<NotificationSlot\>>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -791,6 +827,8 @@ getSlots(): Promise\<Array\<NotificationSlot\>> ...@@ -791,6 +827,8 @@ getSlots(): Promise\<Array\<NotificationSlot\>>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -824,6 +862,8 @@ removeSlot(slotType: SlotType, callback: AsyncCallback\<void\>): void ...@@ -824,6 +862,8 @@ removeSlot(slotType: SlotType, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -863,6 +903,8 @@ removeSlot(slotType: SlotType): Promise\<void\> ...@@ -863,6 +903,8 @@ removeSlot(slotType: SlotType): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -896,6 +938,8 @@ removeAllSlots(callback: AsyncCallback\<void\>): void ...@@ -896,6 +938,8 @@ removeAllSlots(callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -927,6 +971,8 @@ removeAllSlots(): Promise\<void\> ...@@ -927,6 +971,8 @@ removeAllSlots(): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -965,6 +1011,8 @@ setNotificationEnable(bundle: BundleOption, enable: boolean, callback: AsyncCall ...@@ -965,6 +1011,8 @@ setNotificationEnable(bundle: BundleOption, enable: boolean, callback: AsyncCall
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1011,6 +1059,8 @@ setNotificationEnable(bundle: BundleOption, enable: boolean): Promise\<void\> ...@@ -1011,6 +1059,8 @@ setNotificationEnable(bundle: BundleOption, enable: boolean): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1052,6 +1102,8 @@ isNotificationEnabled(bundle: BundleOption, callback: AsyncCallback\<boolean\>): ...@@ -1052,6 +1102,8 @@ isNotificationEnabled(bundle: BundleOption, callback: AsyncCallback\<boolean\>):
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1103,6 +1155,8 @@ isNotificationEnabled(bundle: BundleOption): Promise\<boolean\> ...@@ -1103,6 +1155,8 @@ isNotificationEnabled(bundle: BundleOption): Promise\<boolean\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1143,6 +1197,8 @@ isNotificationEnabled(callback: AsyncCallback\<boolean\>): void ...@@ -1143,6 +1197,8 @@ isNotificationEnabled(callback: AsyncCallback\<boolean\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1191,6 +1247,8 @@ isNotificationEnabled(): Promise\<boolean\> ...@@ -1191,6 +1247,8 @@ isNotificationEnabled(): Promise\<boolean\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1230,6 +1288,8 @@ displayBadge(bundle: BundleOption, enable: boolean, callback: AsyncCallback\<voi ...@@ -1230,6 +1288,8 @@ displayBadge(bundle: BundleOption, enable: boolean, callback: AsyncCallback\<voi
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1276,6 +1336,8 @@ displayBadge(bundle: BundleOption, enable: boolean): Promise\<void\> ...@@ -1276,6 +1336,8 @@ displayBadge(bundle: BundleOption, enable: boolean): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1317,6 +1379,8 @@ isBadgeDisplayed(bundle: BundleOption, callback: AsyncCallback\<boolean\>): void ...@@ -1317,6 +1379,8 @@ isBadgeDisplayed(bundle: BundleOption, callback: AsyncCallback\<boolean\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1368,6 +1432,8 @@ isBadgeDisplayed(bundle: BundleOption): Promise\<boolean\> ...@@ -1368,6 +1432,8 @@ isBadgeDisplayed(bundle: BundleOption): Promise\<boolean\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1410,6 +1476,8 @@ setSlotByBundle(bundle: BundleOption, slot: NotificationSlot, callback: AsyncCal ...@@ -1410,6 +1476,8 @@ setSlotByBundle(bundle: BundleOption, slot: NotificationSlot, callback: AsyncCal
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1461,6 +1529,8 @@ setSlotByBundle(bundle: BundleOption, slot: NotificationSlot): Promise\<void\> ...@@ -1461,6 +1529,8 @@ setSlotByBundle(bundle: BundleOption, slot: NotificationSlot): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1505,6 +1575,8 @@ getSlotsByBundle(bundle: BundleOption, callback: AsyncCallback<Array\<Notificati ...@@ -1505,6 +1575,8 @@ getSlotsByBundle(bundle: BundleOption, callback: AsyncCallback<Array\<Notificati
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1556,6 +1628,8 @@ getSlotsByBundle(bundle: BundleOption): Promise<Array\<NotificationSlot\>> ...@@ -1556,6 +1628,8 @@ getSlotsByBundle(bundle: BundleOption): Promise<Array\<NotificationSlot\>>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1597,6 +1671,8 @@ getSlotNumByBundle(bundle: BundleOption, callback: AsyncCallback\<number\>): voi ...@@ -1597,6 +1671,8 @@ getSlotNumByBundle(bundle: BundleOption, callback: AsyncCallback\<number\>): voi
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1648,6 +1724,8 @@ getSlotNumByBundle(bundle: BundleOption): Promise\<number\> ...@@ -1648,6 +1724,8 @@ getSlotNumByBundle(bundle: BundleOption): Promise\<number\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1689,6 +1767,8 @@ getAllActiveNotifications(callback: AsyncCallback<Array\<NotificationRequest\>>) ...@@ -1689,6 +1767,8 @@ getAllActiveNotifications(callback: AsyncCallback<Array\<NotificationRequest\>>)
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1731,6 +1811,8 @@ getAllActiveNotifications(): Promise\<Array\<[NotificationRequest](#notification ...@@ -1731,6 +1811,8 @@ getAllActiveNotifications(): Promise\<Array\<[NotificationRequest](#notification
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1763,6 +1845,8 @@ getActiveNotificationCount(callback: AsyncCallback\<number\>): void ...@@ -1763,6 +1845,8 @@ getActiveNotificationCount(callback: AsyncCallback\<number\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1801,6 +1885,8 @@ getActiveNotificationCount(): Promise\<number\> ...@@ -1801,6 +1885,8 @@ getActiveNotificationCount(): Promise\<number\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1833,6 +1919,8 @@ getActiveNotifications(callback: AsyncCallback<Array\<NotificationRequest\>>): v ...@@ -1833,6 +1919,8 @@ getActiveNotifications(callback: AsyncCallback<Array\<NotificationRequest\>>): v
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1871,6 +1959,8 @@ getActiveNotifications(): Promise\<Array\<[NotificationRequest](#notificationreq ...@@ -1871,6 +1959,8 @@ getActiveNotifications(): Promise\<Array\<[NotificationRequest](#notificationreq
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1904,6 +1994,8 @@ cancelGroup(groupName: string, callback: AsyncCallback\<void\>): void ...@@ -1904,6 +1994,8 @@ cancelGroup(groupName: string, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1944,6 +2036,8 @@ cancelGroup(groupName: string): Promise\<void\> ...@@ -1944,6 +2036,8 @@ cancelGroup(groupName: string): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -1983,6 +2077,8 @@ removeGroupByBundle(bundle: BundleOption, groupName: string, callback: AsyncCall ...@@ -1983,6 +2077,8 @@ removeGroupByBundle(bundle: BundleOption, groupName: string, callback: AsyncCall
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2030,6 +2126,8 @@ removeGroupByBundle(bundle: BundleOption, groupName: string): Promise\<void\> ...@@ -2030,6 +2126,8 @@ removeGroupByBundle(bundle: BundleOption, groupName: string): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2070,6 +2168,8 @@ setDoNotDisturbDate(date: DoNotDisturbDate, callback: AsyncCallback\<void\>): vo ...@@ -2070,6 +2168,8 @@ setDoNotDisturbDate(date: DoNotDisturbDate, callback: AsyncCallback\<void\>): vo
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2118,6 +2218,8 @@ setDoNotDisturbDate(date: DoNotDisturbDate): Promise\<void\> ...@@ -2118,6 +2218,8 @@ setDoNotDisturbDate(date: DoNotDisturbDate): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2160,6 +2262,8 @@ setDoNotDisturbDate(date: DoNotDisturbDate, userId: number, callback: AsyncCallb ...@@ -2160,6 +2262,8 @@ setDoNotDisturbDate(date: DoNotDisturbDate, userId: number, callback: AsyncCallb
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2212,6 +2316,8 @@ setDoNotDisturbDate(date: DoNotDisturbDate, userId: number): Promise\<void\> ...@@ -2212,6 +2316,8 @@ setDoNotDisturbDate(date: DoNotDisturbDate, userId: number): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2256,6 +2362,8 @@ getDoNotDisturbDate(callback: AsyncCallback\<DoNotDisturbDate\>): void ...@@ -2256,6 +2362,8 @@ getDoNotDisturbDate(callback: AsyncCallback\<DoNotDisturbDate\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2298,6 +2406,8 @@ getDoNotDisturbDate(): Promise\<DoNotDisturbDate\> ...@@ -2298,6 +2406,8 @@ getDoNotDisturbDate(): Promise\<DoNotDisturbDate\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2334,6 +2444,8 @@ getDoNotDisturbDate(userId: number, callback: AsyncCallback\<DoNotDisturbDate\>) ...@@ -2334,6 +2444,8 @@ getDoNotDisturbDate(userId: number, callback: AsyncCallback\<DoNotDisturbDate\>)
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2385,6 +2497,8 @@ getDoNotDisturbDate(userId: number): Promise\<DoNotDisturbDate\> ...@@ -2385,6 +2497,8 @@ getDoNotDisturbDate(userId: number): Promise\<DoNotDisturbDate\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2403,9 +2517,9 @@ Notification.getDoNotDisturbDate(userId).then((data) => { ...@@ -2403,9 +2517,9 @@ Notification.getDoNotDisturbDate(userId).then((data) => {
``` ```
## Notification.supportDoNotDisturbMode ## Notification.isSupportDoNotDisturbMode
supportDoNotDisturbMode(callback: AsyncCallback\<boolean\>): void isSupportDoNotDisturbMode(callback: AsyncCallback\<boolean\>): void
查询是否支持免打扰功能(Callback形式)。 查询是否支持免打扰功能(Callback形式)。
...@@ -2423,6 +2537,8 @@ supportDoNotDisturbMode(callback: AsyncCallback\<boolean\>): void ...@@ -2423,6 +2537,8 @@ supportDoNotDisturbMode(callback: AsyncCallback\<boolean\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2432,22 +2548,22 @@ supportDoNotDisturbMode(callback: AsyncCallback\<boolean\>): void ...@@ -2432,22 +2548,22 @@ supportDoNotDisturbMode(callback: AsyncCallback\<boolean\>): void
**示例:** **示例:**
```js ```js
function supportDoNotDisturbModeCallback(err,data) { function isSupportDoNotDisturbModeCallback(err,data) {
if (err) { if (err) {
console.info("supportDoNotDisturbMode failed " + JSON.stringify(err)); console.info("isSupportDoNotDisturbMode failed " + JSON.stringify(err));
} else { } else {
console.info("supportDoNotDisturbMode success"); console.info("isSupportDoNotDisturbMode success");
} }
} }
Notification.supportDoNotDisturbMode(supportDoNotDisturbModeCallback); Notification.isSupportDoNotDisturbMode(supportDoNotDisturbModeCallback);
``` ```
## Notification.supportDoNotDisturbMode ## Notification.isSupportDoNotDisturbMode
supportDoNotDisturbMode(): Promise\<boolean\> isSupportDoNotDisturbMode(): Promise\<boolean\>
查询是否支持勿扰模式功能(Promise形式)。 查询是否支持勿扰模式功能(Promise形式)。
...@@ -2465,6 +2581,8 @@ supportDoNotDisturbMode(): Promise\<boolean\> ...@@ -2465,6 +2581,8 @@ supportDoNotDisturbMode(): Promise\<boolean\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2474,8 +2592,8 @@ supportDoNotDisturbMode(): Promise\<boolean\> ...@@ -2474,8 +2592,8 @@ supportDoNotDisturbMode(): Promise\<boolean\>
**示例:** **示例:**
```js ```js
Notification.supportDoNotDisturbMode().then((data) => { Notification.isSupportDoNotDisturbMode().then((data) => {
console.info("supportDoNotDisturbMode success, data: " + JSON.stringify(data)); console.info("isSupportDoNotDisturbMode success, data: " + JSON.stringify(data));
}); });
``` ```
...@@ -2498,6 +2616,8 @@ isSupportTemplate(templateName: string, callback: AsyncCallback\<boolean\>): voi ...@@ -2498,6 +2616,8 @@ isSupportTemplate(templateName: string, callback: AsyncCallback\<boolean\>): voi
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2544,6 +2664,8 @@ isSupportTemplate(templateName: string): Promise\<boolean\> ...@@ -2544,6 +2664,8 @@ isSupportTemplate(templateName: string): Promise\<boolean\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2579,6 +2701,8 @@ requestEnableNotification(callback: AsyncCallback\<void\>): void ...@@ -2579,6 +2701,8 @@ requestEnableNotification(callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2611,6 +2735,8 @@ requestEnableNotification(): Promise\<void\> ...@@ -2611,6 +2735,8 @@ requestEnableNotification(): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2648,6 +2774,8 @@ setDistributedEnable(enable: boolean, callback: AsyncCallback\<void\>): void ...@@ -2648,6 +2774,8 @@ setDistributedEnable(enable: boolean, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2693,6 +2821,8 @@ setDistributedEnable(enable: boolean): Promise\<void> ...@@ -2693,6 +2821,8 @@ setDistributedEnable(enable: boolean): Promise\<void>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2727,6 +2857,8 @@ isDistributedEnabled(callback: AsyncCallback\<boolean>): void ...@@ -2727,6 +2857,8 @@ isDistributedEnabled(callback: AsyncCallback\<boolean>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2766,6 +2898,8 @@ isDistributedEnabled(): Promise\<boolean> ...@@ -2766,6 +2898,8 @@ isDistributedEnabled(): Promise\<boolean>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2805,6 +2939,8 @@ setDistributedEnableByBundle(bundle: BundleOption, enable: boolean, callback: As ...@@ -2805,6 +2939,8 @@ setDistributedEnableByBundle(bundle: BundleOption, enable: boolean, callback: As
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2856,6 +2992,8 @@ setDistributedEnableByBundle(bundle: BundleOption, enable: boolean): Promise\<vo ...@@ -2856,6 +2992,8 @@ setDistributedEnableByBundle(bundle: BundleOption, enable: boolean): Promise\<vo
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2899,6 +3037,8 @@ isDistributedEnabledByBundle(bundle: BundleOption, callback: AsyncCallback\<bool ...@@ -2899,6 +3037,8 @@ isDistributedEnabledByBundle(bundle: BundleOption, callback: AsyncCallback\<bool
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2953,6 +3093,8 @@ isDistributedEnabledByBundle(bundle: BundleOption): Promise\<boolean> ...@@ -2953,6 +3093,8 @@ isDistributedEnabledByBundle(bundle: BundleOption): Promise\<boolean>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -2994,6 +3136,8 @@ getDeviceRemindType(callback: AsyncCallback\<DeviceRemindType\>): void ...@@ -2994,6 +3136,8 @@ getDeviceRemindType(callback: AsyncCallback\<DeviceRemindType\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3036,6 +3180,8 @@ getDeviceRemindType(): Promise\<DeviceRemindType\> ...@@ -3036,6 +3180,8 @@ getDeviceRemindType(): Promise\<DeviceRemindType\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3074,6 +3220,8 @@ publishAsBundle(request: NotificationRequest, representativeBundle: string, user ...@@ -3074,6 +3220,8 @@ publishAsBundle(request: NotificationRequest, representativeBundle: string, user
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------------- | | -------- | ----------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3138,6 +3286,8 @@ publishAsBundle(request: NotificationRequest, representativeBundle: string, user ...@@ -3138,6 +3286,8 @@ publishAsBundle(request: NotificationRequest, representativeBundle: string, user
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------------- | | -------- | ----------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3198,6 +3348,8 @@ cancelAsBundle(id: number, representativeBundle: string, userId: number, callbac ...@@ -3198,6 +3348,8 @@ cancelAsBundle(id: number, representativeBundle: string, userId: number, callbac
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3249,6 +3401,8 @@ cancelAsBundle(id: number, representativeBundle: string, userId: number): Promis ...@@ -3249,6 +3401,8 @@ cancelAsBundle(id: number, representativeBundle: string, userId: number): Promis
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3293,6 +3447,8 @@ setNotificationEnableSlot(bundle: BundleOption, type: SlotType, enable: boolean, ...@@ -3293,6 +3447,8 @@ setNotificationEnableSlot(bundle: BundleOption, type: SlotType, enable: boolean,
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3341,6 +3497,8 @@ setNotificationEnableSlot(bundle: BundleOption, type: SlotType, enable: boolean) ...@@ -3341,6 +3497,8 @@ setNotificationEnableSlot(bundle: BundleOption, type: SlotType, enable: boolean)
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3382,6 +3540,8 @@ isNotificationSlotEnabled(bundle: BundleOption, type: SlotType, callback: AsyncC ...@@ -3382,6 +3540,8 @@ isNotificationSlotEnabled(bundle: BundleOption, type: SlotType, callback: AsyncC
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3434,6 +3594,8 @@ isNotificationSlotEnabled(bundle: BundleOption, type: SlotType): Promise\<boolea ...@@ -3434,6 +3594,8 @@ isNotificationSlotEnabled(bundle: BundleOption, type: SlotType): Promise\<boolea
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3474,6 +3636,8 @@ setSyncNotificationEnabledWithoutApp(userId: number, enable: boolean, callback: ...@@ -3474,6 +3636,8 @@ setSyncNotificationEnabledWithoutApp(userId: number, enable: boolean, callback:
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3526,6 +3690,8 @@ setSyncNotificationEnabledWithoutApp(userId: number, enable: boolean): Promise\< ...@@ -3526,6 +3690,8 @@ setSyncNotificationEnabledWithoutApp(userId: number, enable: boolean): Promise\<
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3568,6 +3734,8 @@ getSyncNotificationEnabledWithoutApp(userId: number, callback: AsyncCallback\<bo ...@@ -3568,6 +3734,8 @@ getSyncNotificationEnabledWithoutApp(userId: number, callback: AsyncCallback\<bo
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3618,6 +3786,8 @@ getSyncNotificationEnabledWithoutApp(userId: number): Promise\<boolean> ...@@ -3618,6 +3786,8 @@ getSyncNotificationEnabledWithoutApp(userId: number): Promise\<boolean>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -3862,7 +4032,7 @@ Notification.getSyncNotificationEnabledWithoutApp(userId).then((data) => { ...@@ -3862,7 +4032,7 @@ Notification.getSyncNotificationEnabledWithoutApp(userId).then((data) => {
| label | string | 是 | 是 | 通知标签。 | | label | string | 是 | 是 | 通知标签。 |
| badgeIconStyle | number | 是 | 是 | 通知角标类型。 | | badgeIconStyle | number | 是 | 是 | 通知角标类型。 |
| showDeliveryTime | boolean | 是 | 是 | 是否显示分发时间。 | | showDeliveryTime | boolean | 是 | 是 | 是否显示分发时间。 |
| actionButtons | Array\<[NotificationActionButton](#notificationactionbutton)\> | 是 | 是 | 通知按钮,最多两个按钮。 | | actionButtons | Array\<[NotificationActionButton](#notificationactionbutton)\> | 是 | 是 | 通知按钮,最多三个按钮。 |
| smallIcon | [image.PixelMap](js-apis-image.md#pixelmap7) | 是 | 是 | 通知小图标。可选字段,大小不超过30KB。 | | smallIcon | [image.PixelMap](js-apis-image.md#pixelmap7) | 是 | 是 | 通知小图标。可选字段,大小不超过30KB。 |
| largeIcon | [image.PixelMap](js-apis-image.md#pixelmap7) | 是 | 是 | 通知大图标。可选字段,大小不超过30KB。 | | largeIcon | [image.PixelMap](js-apis-image.md#pixelmap7) | 是 | 是 | 通知大图标。可选字段,大小不超过30KB。 |
| creatorBundleName | string | 是 | 否 | 创建通知的包名。 | | creatorBundleName | string | 是 | 否 | 创建通知的包名。 |
......
...@@ -36,6 +36,8 @@ subscribe(subscriber: NotificationSubscriber, info: NotificationSubscribeInfo, c ...@@ -36,6 +36,8 @@ subscribe(subscriber: NotificationSubscriber, info: NotificationSubscribeInfo, c
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -88,6 +90,8 @@ subscribe(subscriber: NotificationSubscriber, callback: AsyncCallback\<void\>): ...@@ -88,6 +90,8 @@ subscribe(subscriber: NotificationSubscriber, callback: AsyncCallback\<void\>):
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -136,6 +140,8 @@ subscribe(subscriber: NotificationSubscriber, info?: NotificationSubscribeInfo): ...@@ -136,6 +140,8 @@ subscribe(subscriber: NotificationSubscriber, info?: NotificationSubscribeInfo):
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -179,6 +185,8 @@ unsubscribe(subscriber: NotificationSubscriber, callback: AsyncCallback\<void\>) ...@@ -179,6 +185,8 @@ unsubscribe(subscriber: NotificationSubscriber, callback: AsyncCallback\<void\>)
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -226,6 +234,8 @@ unsubscribe(subscriber: NotificationSubscriber): Promise\<void\> ...@@ -226,6 +234,8 @@ unsubscribe(subscriber: NotificationSubscriber): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -271,6 +281,8 @@ remove(bundle: BundleOption, notificationKey: NotificationKey, reason: RemoveRea ...@@ -271,6 +281,8 @@ remove(bundle: BundleOption, notificationKey: NotificationKey, reason: RemoveRea
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -324,6 +336,8 @@ remove(bundle: BundleOption, notificationKey: NotificationKey, reason: RemoveRea ...@@ -324,6 +336,8 @@ remove(bundle: BundleOption, notificationKey: NotificationKey, reason: RemoveRea
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -372,6 +386,8 @@ remove(hashCode: string, reason: RemoveReason, callback: AsyncCallback\<void\>): ...@@ -372,6 +386,8 @@ remove(hashCode: string, reason: RemoveReason, callback: AsyncCallback\<void\>):
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -418,6 +434,8 @@ remove(hashCode: string, reason: RemoveReason): Promise\<void\> ...@@ -418,6 +434,8 @@ remove(hashCode: string, reason: RemoveReason): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -458,6 +476,8 @@ removeAll(bundle: BundleOption, callback: AsyncCallback\<void\>): void ...@@ -458,6 +476,8 @@ removeAll(bundle: BundleOption, callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -503,6 +523,8 @@ removeAll(callback: AsyncCallback\<void\>): void ...@@ -503,6 +523,8 @@ removeAll(callback: AsyncCallback\<void\>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -545,6 +567,8 @@ removeAll(bundle?: BundleOption): Promise\<void\> ...@@ -545,6 +567,8 @@ removeAll(bundle?: BundleOption): Promise\<void\>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ---------------------------------------- | | -------- | ---------------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -582,6 +606,8 @@ removeAll(userId: number, callback: AsyncCallback\<void>): void ...@@ -582,6 +606,8 @@ removeAll(userId: number, callback: AsyncCallback\<void>): void
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
...@@ -625,6 +651,8 @@ removeAll(userId: number): Promise\<void> ...@@ -625,6 +651,8 @@ removeAll(userId: number): Promise\<void>
**错误码:** **错误码:**
错误码详细介绍请参考[errcode-notification](../errorcodes/errorcode-notification.md)
| 错误码ID | 错误信息 | | 错误码ID | 错误信息 |
| -------- | ----------------------------------- | | -------- | ----------------------------------- |
| 1600001 | Internal error. | | 1600001 | Internal error. |
......
...@@ -16,7 +16,7 @@ import WantAgent from '@ohos.wantAgent'; ...@@ -16,7 +16,7 @@ import WantAgent from '@ohos.wantAgent';
getWantAgent(info: WantAgentInfo, callback: AsyncCallback\<WantAgent\>): void getWantAgent(info: WantAgentInfo, callback: AsyncCallback\<WantAgent\>): void
创建WantAgent(callback形式)。 创建WantAgent(callback形式)。 创建失败返回的WantAgent为空值。
**系统能力**:SystemCapability.Ability.AbilityRuntime.Core **系统能力**:SystemCapability.Ability.AbilityRuntime.Core
...@@ -75,7 +75,7 @@ WantAgent.getWantAgent(wantAgentInfo, getWantAgentCallback); ...@@ -75,7 +75,7 @@ WantAgent.getWantAgent(wantAgentInfo, getWantAgentCallback);
getWantAgent(info: WantAgentInfo): Promise\<WantAgent\> getWantAgent(info: WantAgentInfo): Promise\<WantAgent\>
创建WantAgent(Promise形式)。 创建WantAgent(Promise形式)。 创建失败返回的WantAgent为空值。
**系统能力**:SystemCapability.Ability.AbilityRuntime.Core **系统能力**:SystemCapability.Ability.AbilityRuntime.Core
......
# 元能力子系统错误码
## 1600001 内部错误
**错误信息**
Internal error.
**错误描述**
多线程处理异常、内部指针校验错误等内部处理错误时,方法将返回该错误码。
**可能原因**
多线程处理、内部处理异常等内核通用错误。
**处理步骤**
确认系统资源是否足够。
## 1600002 序列化或反序列化错误
**错误信息**
marshalling or unmarshalling error.
**错误描述**
数据传输前,进行序列化或反序列化错误,方法将返回该错误码。
**可能原因**
应用与通知服务字段未匹配。
**处理步骤**
检查应用sdk版本与系统版本是否匹配。
## 1600003 连接通知服务失败
**错误信息**
Failed to connect service.
**错误描述**
应用连接通知服务失败,方法将返回该错误码。
**可能原因**
通知服务繁忙或异常。
**处理步骤**
重启系统。
## 1600004 通知开关关闭
**错误信息**
Notification is not enabled.
**错误描述**
当通知开关为关闭状态时,方法将返回该错误码。
**可能原因**
应用的通知开关为关闭状态。
**处理步骤**
通知设置里开启应用通知开关。
## 1600005 通知渠道关闭
**错误信息**
Notification slot is not enabled.
**错误描述**
当通知渠道关闭时,方法将返回该错误码。
**可能原因**
通知渠道关闭状态,或未添加该类型渠道。
**处理步骤**
1、通知设置里查看应用是否有该类型渠道,没有需要新增。
2、通知设置里查看应用该类型渠道状态,要保持开启状态。
## 1600006 通知删除失败
**错误信息**
Notification is not allowed to remove.
**错误描述**
通知设置了禁止删除属性,方法将返回该错误码。
**可能原因**
通知设置了禁止删除属性。
**处理步骤**
参考[NotificationRequest](../apis/js-apis-notificationManager.md#notificationrequest)通知禁止删除属性。
## 1600007 通知不存在
**错误信息**
The notification is not exist.
**错误描述**
通知服务未找到该通知,方法将返回该错误码。
**可能原因**
通知已被取消或删除。
**处理步骤**
## 1600008 用户不存在
**错误信息**
The user is not exist.
**错误描述**
传入的用户信息系统里未查询到,方法将返回该错误码。
**可能原因**
传入用户信息有误。
**处理步骤**
检查传入的用户信息。
## 1600009 通知发布频度超过限制
**错误信息**
Over max number notifications per second.
**错误描述**
通知发送频率超过限制,方法将返回该错误码。
**可能原因**
通知发送频率超过每秒10个。
**处理步骤**
降低通知发送频率。
## 16000010 分布式操作失败
**错误信息**
Distributed operation failed.
**错误描述**
分布式数据库操作异常或分布式接口调用异常,方法将返回该错误码。
**可能原因**
分布式数据库操作异常或分布式接口调用异常。
**处理步骤**
检查分布式连接是否正常。
## 16000011 读模板配置文件错误
**错误信息**
Read template config failed.
**错误描述**
模板配置文件读取异常,方法将返回该错误码。
**可能原因**
系统中模板配置文件丢失。
**处理步骤**
请检查系统中模板配置文件是否存在,配置文件路径:/system/etc/notification_template/external.json。
## 16000012 内存空间不够
**错误信息**
No memory space.
**错误描述**
内存申请出现错误,方法将返回该错误码。
**可能原因**
内存申请出现错误。
**处理步骤**
确认系统内存是否足够。
# ANS通知子系统ChangeLog
## cl.notificationManager.1 接口名变更
基于此前接口名定义不够规范,与其他功能类型的接口命名不一致,对此接口名进行变更。
**变更影响**
底层仍支持原接口功能,不影响4.0.2.3版本调用该接口的应用。
**关键接口/组件变更**
| 包名 | 旧接口 | 新接口 |
| --------------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| ohos.notificationManager.d.ts | **function** supportDoNotDisturbMode(callback: AsyncCallback<boolean>): **void**; | **function** isSupportDoNotDisturbMode(callback: AsyncCallback<boolean>): **void**; |
| ohos.notificationManager.d.ts | **function** supportDoNotDisturbMode(): Promise<boolean>; | **function** isSupportDoNotDisturbMode(): Promise<boolean>; |
**适配指导**
按新的接口isSupportDoNotDisturbMode调用。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册