diff --git a/api/@ohos.commonEvent.d.ts b/api/@ohos.commonEvent.d.ts index 36840ef8cdac683b537e0adb9f146f69ee2baab0..f6f530ac6146527e3d33515dcc3c097d8d8108da 100644 --- a/api/@ohos.commonEvent.d.ts +++ b/api/@ohos.commonEvent.d.ts @@ -22,6 +22,7 @@ import { CommonEventPublishData } from './commonEvent/commonEventPublishData'; * the defination for commonevent * @name commonEvent * @since 7 + * @sysCap SystemCapability.Notification.CommonEvent * @permission N/A */ declare namespace commonEvent { @@ -29,7 +30,7 @@ declare namespace commonEvent { * Publishes an ordered, sticky, or standard common event. * * @since 7 - * @param data Indicate the CommonEventPublishData containing the common event content and attributes. + * @param event name of the common event. * @param callback Specified callback method. * @return - */ @@ -39,7 +40,8 @@ declare namespace commonEvent { * Publishes an ordered, sticky, or standard common event. * * @since 7 - * @param data Indicate the CommonEventPublishData containing the common event content and attributes. + * @param event name of the common event. + * @param options Indicate the CommonEventPublishData containing the common event content and attributes. * @param callback Specified callback method. * @return - */ @@ -60,8 +62,7 @@ declare namespace commonEvent { * * @since 7 * @param subscribeInfo Indicate the information of the subscriber. - * @param callback Specified callback method. - * @return - + * @return Returns common event subscriber object */ function createSubscriber(subscribeInfo: CommonEventSubscribeInfo): Promise; diff --git a/api/@ohos.events.emitter.d.ts b/api/@ohos.events.emitter.d.ts index ac359eb225ed036a1157492a9bf0a6cc95af0664..3305e9060861188c8e20da330487eef2b7fd5077 100644 --- a/api/@ohos.events.emitter.d.ts +++ b/api/@ohos.events.emitter.d.ts @@ -19,6 +19,7 @@ import { Callback } from './basic'; * Provides methods for sending and processing in-process events. * * @since 7 + * @sysCap SystemCapability.Notification.Emitter * @import import events_emitter from '@ohos.emitter'; * @permission N/A */ diff --git a/api/@ohos.notification.d.ts b/api/@ohos.notification.d.ts index c24a7a258edb2b7d88ac7454abbe095270b6d098..bfeaf5a46e42156c55c799c2507bc7360cde635a 100644 --- a/api/@ohos.notification.d.ts +++ b/api/@ohos.notification.d.ts @@ -32,8 +32,7 @@ import { NotificationRequest } from './notification/notificationRequest'; * * @name notification * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @import import notification from '@ohos.notification'; * @permission N/A */ @@ -44,7 +43,8 @@ declare namespace notification { *

If a notification with the same ID has been published by the current application and has not been deleted, * this method will update the notification. * - * @param Publishes a notification. + * @param request notification request + * @param callback callback function */ function publish(request: NotificationRequest, callback: AsyncCallback): void; function publish(request: NotificationRequest): Promise; @@ -52,15 +52,17 @@ declare namespace notification { /** * Cancels a notification with the specified ID. * - * @param ID of the notification to cancel, which must be unique in the application. + * @param id of the notification to cancel, which must be unique in the application. + * @param callback callback function */ function cancel(id: number, callback: AsyncCallback): void; /** * Cancels a notification with the specified label and ID. * - * @param ID of the notification to cancel, which must be unique in the application. - * @param Label of the notification to cancel. + * @param id ID of the notification to cancel, which must be unique in the application. + * @param label Label of the notification to cancel. + * @param callback callback function */ function cancel(id: number, label: string, callback: AsyncCallback): void; function cancel(id: number, label?: string): Promise; @@ -76,7 +78,7 @@ declare namespace notification { * * @param slot Indicates the notification slot to be created, which is set by {@link NotificationSlot}. * This parameter must be specified. - * + * @param callback callback function * @systemapi Hide this for inner system use. */ function addSlot(slot: NotificationSlot, callback: AsyncCallback): void; @@ -94,7 +96,8 @@ declare namespace notification { /** * Adds a slot type. * - * @param Slot type to add. + * @param type Slot type to add. + * @param callback callback function */ function addSlot(type: SlotType, callback: AsyncCallback): void; function addSlot(type: SlotType): Promise; @@ -104,7 +107,7 @@ declare namespace notification { * * @param slots Indicates the notification slots to be created, which is set by {@link NotificationSlot}. * This parameter must be specified. - * + * @param callback callback function * @systemapi Hide this for inner system use. */ function addSlots(slots: Array, callback: AsyncCallback): void; @@ -122,8 +125,8 @@ declare namespace notification { /** * Obtains a notification slot of the specified slot type. * - * @param Type of the notification slot to obtain. - * + * @param slotType Type of the notification slot to obtain. + * @param callback callback function * @return Returns the created {@link NotificationSlot}. */ function getSlot(slotType: SlotType, callback: AsyncCallback): void; @@ -140,7 +143,8 @@ declare namespace notification { /** * Removes a NotificationSlot of the specified SlotType created by the current application. * - * @param Type of the NotificationSlot to remove. + * @param slotType Type of the NotificationSlot to remove. + * @param callback callback function */ function removeSlot(slotType: SlotType, callback: AsyncCallback): void; function removeSlot(slotType: SlotType): Promise; @@ -186,8 +190,7 @@ declare namespace notification { * * @name ContentType * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A */ export enum ContentType { diff --git a/api/commonEvent/commonEventData.d.ts b/api/commonEvent/commonEventData.d.ts index 6e985c7156e1344d918407c3b9b2b91e074dcd43..abc558a6a32a95c65fef391c7a28affc2e378fb3 100644 --- a/api/commonEvent/commonEventData.d.ts +++ b/api/commonEvent/commonEventData.d.ts @@ -16,6 +16,7 @@ /** * the data of the commonEvent * @name CommonEventData + * @sysCap SystemCapability.Notification.commonEvent * @since 7 * @permission N/A */ diff --git a/api/commonEvent/commonEventPublishData.d.ts b/api/commonEvent/commonEventPublishData.d.ts index 4c1dd0b5dd291b9d5062bb8984d183fa496cfbe3..0db7c31981bb08ea6e0387feb85db22f93dc9d4f 100644 --- a/api/commonEvent/commonEventPublishData.d.ts +++ b/api/commonEvent/commonEventPublishData.d.ts @@ -17,6 +17,7 @@ * containing the common event content and attributes * @name CommonEventPublishData * @since 7 + * @sysCap SystemCapability.Notification.commonEvent * @permission N/A */ export interface CommonEventPublishData { diff --git a/api/commonEvent/commonEventSubscribeInfo.d.ts b/api/commonEvent/commonEventSubscribeInfo.d.ts index cf648cf60827180ec800b4b63035cb44a1d4ad7e..6b54ef9d672e093fc870e27418d11938ff7865fb 100644 --- a/api/commonEvent/commonEventSubscribeInfo.d.ts +++ b/api/commonEvent/commonEventSubscribeInfo.d.ts @@ -17,6 +17,7 @@ * the information of the subscriber * @name CommonEventSubscribeInfo * @since 7 + * @sysCap SystemCapability.Notification.commonEvent * @permission N/A */ export interface CommonEventSubscribeInfo { diff --git a/api/commonEvent/commonEventSubscriber.d.ts b/api/commonEvent/commonEventSubscriber.d.ts index 65e5aba3537b2b8ea2080f0f63e701c46cae7435..24c23bc02b28b7d5c294cce280d001700ad75919 100644 --- a/api/commonEvent/commonEventSubscriber.d.ts +++ b/api/commonEvent/commonEventSubscriber.d.ts @@ -19,6 +19,7 @@ import { CommonEventSubscribeInfo } from './commonEventSubscribeInfo'; * the subscriber of common event * @name CommonEventSubscriber * @since 7 + * @sysCap SystemCapability.Notification.commonEvent * @permission N/A */ export interface CommonEventSubscriber { @@ -26,7 +27,7 @@ export interface CommonEventSubscriber { * Obtains the result code of the current ordered common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ getCode(callback: AsyncCallback): void; @@ -35,8 +36,7 @@ export interface CommonEventSubscriber { * Obtains the result code of the current ordered common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. - * @return - + * @return Returns code of this common event */ getCode(): Promise; @@ -45,7 +45,7 @@ export interface CommonEventSubscriber { * * @since 7 * @param code Indicates the custom result code to set. You can set it to any value. - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ setCode(code: number, callback: AsyncCallback): void; @@ -55,7 +55,6 @@ export interface CommonEventSubscriber { * * @since 7 * @param code Indicates the custom result code to set. You can set it to any value. - * @param callback Indicate the callback funtion to receive the common event. * @return - */ setCode(code: number): Promise; @@ -64,7 +63,7 @@ export interface CommonEventSubscriber { * Obtains the result data of the current ordered common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ getData(callback: AsyncCallback): void; @@ -73,8 +72,8 @@ export interface CommonEventSubscriber { * Obtains the result data of the current ordered common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. - * @return - + * @return + * @return Returns data of this common event */ getData(): Promise; @@ -83,7 +82,7 @@ export interface CommonEventSubscriber { * * @since 7 * @param data Indicates the custom result data to set. You can set it to any character string. - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ setData(data: string, callback: AsyncCallback): void; @@ -93,7 +92,6 @@ export interface CommonEventSubscriber { * * @since 7 * @param data Indicates the custom result data to set. You can set it to any character string. - * @param callback Indicate the callback funtion to receive the common event. * @return - */ setData(data: string): Promise; @@ -104,7 +102,7 @@ export interface CommonEventSubscriber { * @since 7 * @param code Indicates the custom result code to set. You can set it to any value. * @param data Indicates the custom result data to set. You can set it to any character string. - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ setCodeAndData(code: number, data: string, callback: AsyncCallback): void; @@ -115,7 +113,6 @@ export interface CommonEventSubscriber { * @since 7 * @param code Indicates the custom result code to set. You can set it to any value. * @param data Indicates the custom result data to set. You can set it to any character string. - * @param callback Indicate the callback funtion to receive the common event. * @return - */ setCodeAndData(code: number, data: string): Promise; @@ -124,7 +121,7 @@ export interface CommonEventSubscriber { * Checks whether the current common event is an ordered common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ isOrderedCommonEvent(callback: AsyncCallback): void; @@ -133,8 +130,7 @@ export interface CommonEventSubscriber { * Checks whether the current common event is an ordered common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. - * @return - + * @return Returns true if this common event is ordered, false otherwise */ isOrderedCommonEvent(): Promise; @@ -142,7 +138,7 @@ export interface CommonEventSubscriber { * Checks whether the current common event is a sticky common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ isStickyCommonEvent(callback: AsyncCallback): void; @@ -151,8 +147,7 @@ export interface CommonEventSubscriber { * Checks whether the current common event is a sticky common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. - * @return - + * @return Returns true if this common event is sticky, false otherwise */ isStickyCommonEvent(): Promise; @@ -160,7 +155,7 @@ export interface CommonEventSubscriber { * Aborts the current ordered common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ abortCommonEvent(callback: AsyncCallback): void; @@ -169,7 +164,6 @@ export interface CommonEventSubscriber { * Aborts the current ordered common event. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. * @return - */ abortCommonEvent(): Promise; @@ -178,7 +172,7 @@ export interface CommonEventSubscriber { * Clears the abort state of the current ordered common event * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ clearAbortCommonEvent(callback: AsyncCallback): void; @@ -187,7 +181,6 @@ export interface CommonEventSubscriber { * Clears the abort state of the current ordered common event * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. * @return - */ clearAbortCommonEvent(): Promise; @@ -196,7 +189,7 @@ export interface CommonEventSubscriber { * Checks whether the current ordered common event should be aborted. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ getAbortCommonEvent(callback: AsyncCallback): void; @@ -205,8 +198,7 @@ export interface CommonEventSubscriber { * Checks whether the current ordered common event should be aborted. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. - * @return - + * @return Returns true if this common event is aborted, false otherwise */ getAbortCommonEvent(): Promise; @@ -214,7 +206,7 @@ export interface CommonEventSubscriber { * get the CommonEventSubscribeInfo of this CommonEventSubscriber. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. + * @param callback Indicate the callback function to receive the common event. * @return - */ getSubscribeInfo(callback: AsyncCallback): void; @@ -223,8 +215,7 @@ export interface CommonEventSubscriber { * get the CommonEventSubscribeInfo of this CommonEventSubscriber. * * @since 7 - * @param callback Indicate the callback funtion to receive the common event. - * @return - + * @return Returns the commonEvent subscribe information */ getSubscribeInfo(): Promise; } diff --git a/api/notification/notificationActionButton.d.ts b/api/notification/notificationActionButton.d.ts index d67934492a3091a57fbe745664cf5797e37a138d..8ca3fae07b0865a60ef8462239145cb8553a6a43 100644 --- a/api/notification/notificationActionButton.d.ts +++ b/api/notification/notificationActionButton.d.ts @@ -20,9 +20,8 @@ import { WantAgent } from '../@ohos.wantAgent'; * Describes an action button displayed in a notification. * @name NotificationActionButton * @since 7 - * @devices phone, tablet, tv, wearable, car * @permission N/A - * @sysCap SystemCapability.Notification.ANS + * @sysCap SystemCapability.Notification.Notification */ export interface NotificationActionButton { /** diff --git a/api/notification/notificationContent.d.ts b/api/notification/notificationContent.d.ts index d2cc36ebdc6e98670dfc6dc78c3071da0564e4f5..fd62adb6044a0adfda383c0919130dd8c1d9b83a 100644 --- a/api/notification/notificationContent.d.ts +++ b/api/notification/notificationContent.d.ts @@ -20,8 +20,7 @@ import image from './@ohos.multimedia.image'; * * @name NotificationBasicContent * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A */ export interface NotificationBasicContent { @@ -46,8 +45,7 @@ export interface NotificationBasicContent { * * @name NotificationLongTextContent * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A */ export interface NotificationLongTextContent extends NotificationBasicContent { @@ -72,8 +70,7 @@ export interface NotificationLongTextContent extends NotificationBasicContent { * * @name NotificationMultiLineContent * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A */ export interface NotificationMultiLineContent extends NotificationBasicContent { @@ -98,8 +95,7 @@ export interface NotificationMultiLineContent extends NotificationBasicContent { * * @name NotificationPictureContent * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A */ export interface NotificationPictureContent extends NotificationBasicContent { @@ -124,8 +120,7 @@ export interface NotificationPictureContent extends NotificationBasicContent { * * @name NotificationContent * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A */ export interface NotificationContent { diff --git a/api/notification/notificationRequest.d.ts b/api/notification/notificationRequest.d.ts index 669a492e34c68711c4299849667f51a044b3c8ae..a8514b224ee158f2ea3733d0d5398409ba2662d4 100644 --- a/api/notification/notificationRequest.d.ts +++ b/api/notification/notificationRequest.d.ts @@ -25,8 +25,7 @@ import { NotificationTemplate } from './notificationTemplate'; * * @name NotificationRequest * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A */ export interface NotificationRequest { diff --git a/api/notification/notificationSlot.d.ts b/api/notification/notificationSlot.d.ts index 82ff360f74f57ce33f6749c346ba2e29f15019eb..e31044fe30e540b6bfc4cb768af7bc9ed22b1d9a 100644 --- a/api/notification/notificationSlot.d.ts +++ b/api/notification/notificationSlot.d.ts @@ -20,9 +20,8 @@ import notification from '../@ohos.notification'; * * @name NotificationSlot * @since 7 - * @devices phone, tablet, tv, wearable, car * @permission N/A - * @sysCap SystemCapability.Notification.ANS + * @sysCap SystemCapability.Notification.Notification */ export interface NotificationSlot { /** diff --git a/api/notification/notificationSorting.d.ts b/api/notification/notificationSorting.d.ts index a4d917145141ce36f5f9f2ca5e153cc738ccd152..e6a82290456d571c75b137d0eb5db6104e26e224 100644 --- a/api/notification/notificationSorting.d.ts +++ b/api/notification/notificationSorting.d.ts @@ -19,8 +19,7 @@ import { NotificationSlot } from './notificationSlot'; * Provides sorting information about an active notification. * * @name NotificationSorting - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A * @systemapi Hide this for inner system use. * @since 7 diff --git a/api/notification/notificationSortingMap.d.ts b/api/notification/notificationSortingMap.d.ts index 2b2a73b4e4daf6f7bd9f1eaf407bf1346e6081b3..8a791653b878c06a5d8ec251133618f39909c639 100644 --- a/api/notification/notificationSortingMap.d.ts +++ b/api/notification/notificationSortingMap.d.ts @@ -20,8 +20,7 @@ import { NotificationSorting } from './notificationSorting'; * * @name NotificationSortingMap * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A * @systemapi Hide this for inner system use. */ diff --git a/api/notification/notificationSubscribeInfo.d.ts b/api/notification/notificationSubscribeInfo.d.ts index d7ee89bd9a53c526aec7dfcdbff571c80d199996..b1b7be4bd30c5b0a05203839bad9b4057a5f3d44 100644 --- a/api/notification/notificationSubscribeInfo.d.ts +++ b/api/notification/notificationSubscribeInfo.d.ts @@ -18,8 +18,7 @@ * * @name NotificationSubscribeInfo * @since 7 - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A * @systemapi Hide this for inner system use. */ diff --git a/api/notification/notificationSubscriber.d.ts b/api/notification/notificationSubscriber.d.ts index d8e2277bc72c82461cf7efc540cdf00be1cf9e19..e47c205d92b81663f9099722e2b11f47b7756dbe 100644 --- a/api/notification/notificationSubscriber.d.ts +++ b/api/notification/notificationSubscriber.d.ts @@ -22,8 +22,7 @@ import notification from '../@ohos.notification'; * a notification is canceled. * * @name NotificationSubscriber - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A * @systemapi Hide this for inner system use. * @since 7 @@ -50,8 +49,7 @@ export interface NotificationSubscriber { * a notification is canceled. * * @name SubscribeCallbackData - * @sysCap SystemCapability.Notification.ANS - * @devices phone, tablet, tv, wearable, car + * @sysCap SystemCapability.Notification.Notification * @permission N/A * @systemapi Hide this for inner system use. * @since 7 diff --git a/api/notification/notificationTemplate.d.ts b/api/notification/notificationTemplate.d.ts index d131ed5cb2afa784543246f7ed70d20651717b60..84a9d86ced4a082edd4f96cb35c0d410ec2188fd 100644 --- a/api/notification/notificationTemplate.d.ts +++ b/api/notification/notificationTemplate.d.ts @@ -18,9 +18,8 @@ * * @name NotificationTemplate * @since 8 - * @devices phone, tablet, tv, wearable, car * @permission N/A - * @sysCap SystemCapability.Notification.ANS + * @sysCap SystemCapability.Notification.Notification */ export interface NotificationTemplate { /** diff --git a/api/notification/notificationUserInput.d.ts b/api/notification/notificationUserInput.d.ts index 63f0229887675cb5071c4a9e686bdf8e0714cf55..9584561bf18d416ed2a098454befcf92d06ba170 100644 --- a/api/notification/notificationUserInput.d.ts +++ b/api/notification/notificationUserInput.d.ts @@ -18,9 +18,8 @@ * * @name NotificationUserInput * @since 8 - * @devices phone, tablet, tv, wearable, car * @permission N/A - * @sysCap SystemCapability.Notification.ANS + * @sysCap SystemCapability.Notification.Notification */ export interface NotificationUserInput { /**