mirror of
https://gitee.com/openharmony/interface_sdk-js
synced 2024-10-07 14:13:45 +00:00
新增批量删除接口
Signed-off-by: XKK <huyingsong@huawei.com>
This commit is contained in:
parent
85d5b97f5f
commit
a911672bd1
39
api/@ohos.notificationSubscribe.d.ts
vendored
39
api/@ohos.notificationSubscribe.d.ts
vendored
@ -253,6 +253,26 @@ declare namespace notificationSubscribe {
|
||||
*/
|
||||
function remove(hashCode: string, reason: RemoveReason, callback: AsyncCallback<void>): void;
|
||||
|
||||
|
||||
/**
|
||||
* Remove notifications.
|
||||
*
|
||||
* @permission ohos.permission.NOTIFICATION_CONTROLLER
|
||||
* @param { Array<String> } hashCodes - The hashCode array.
|
||||
* @param { RemoveReason } reason - The remove reason.
|
||||
* @param { AsyncCallback<void> } callback - The callback of remove.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Not system application to call the interface.
|
||||
* @throws { BusinessError } 401 - The parameter check failed.
|
||||
* @throws { BusinessError } 1600001 - Internal error.
|
||||
* @throws { BusinessError } 1600002 - Marshalling or unmarshalling error.
|
||||
* @throws { BusinessError } 1600003 - Failed to connect service.
|
||||
* @syscap SystemCapability.Notification.Notification
|
||||
* @systemapi
|
||||
* @since 10
|
||||
*/
|
||||
function remove(hashCodes: Array<String>, reason: RemoveReason, callback: AsyncCallback<void>): void;
|
||||
|
||||
/**
|
||||
* Remove notification.
|
||||
*
|
||||
@ -273,6 +293,25 @@ declare namespace notificationSubscribe {
|
||||
*/
|
||||
function remove(hashCode: string, reason: RemoveReason): Promise<void>;
|
||||
|
||||
/**
|
||||
* Remove notifications.
|
||||
*
|
||||
* @permission ohos.permission.NOTIFICATION_CONTROLLER
|
||||
* @param { Array<String> } hashCodes - The hashCode array.
|
||||
* @param { RemoveReason } reason - The remove reason.
|
||||
* @returns { Promise<void> } The promise returned by the function.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Not system application to call the interface.
|
||||
* @throws { BusinessError } 401 - The parameter check failed.
|
||||
* @throws { BusinessError } 1600001 - Internal error.
|
||||
* @throws { BusinessError } 1600002 - Marshalling or unmarshalling error.
|
||||
* @throws { BusinessError } 1600003 - Failed to connect service.
|
||||
* @syscap SystemCapability.Notification.Notification
|
||||
* @systemapi
|
||||
* @since 10
|
||||
*/
|
||||
function remove(hashCodes: Array<String>, reason: RemoveReason): Promise<void>;
|
||||
|
||||
/**
|
||||
* RemoveAll all notifications.
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user