js-apis-reminderAgent.md 17.9 KB
Newer Older
E
ester.zhou 已提交
1
# Reminder Agent
Z
zengyawen 已提交
2

E
ester.zhou 已提交
3 4
> ![icon-note.gif](public_sys-resources/icon-note.gif) **NOTE**
> The initial APIs of this module are supported since API version 7. Newly added APIs will be marked with a superscript to indicate their earliest API version.
Z
zengyawen 已提交
5 6


E
ester.zhou 已提交
7
## Modules to Import
Z
zengyawen 已提交
8 9

```
E
ester.zhou 已提交
10
import reminderAgent from'@ohos.reminderAgent';
Z
zengyawen 已提交
11 12
```

E
ester.zhou 已提交
13 14 15 16 17 18 19

## reminderAgent.publishReminder

publishReminder(reminderReq: ReminderRequest, callback: AsyncCallback<number>): void

Publishes an agent-powered reminder. This API uses an asynchronous callback to return the result.

E
ester.zhou 已提交
20
**Required permissions**: ohos.permission.PUBLISH_AGENT_REMINDER
E
ester.zhou 已提交
21

E
ester.zhou 已提交
22 23 24
**System capability**: SystemCapability.Notification.ReminderAgent

**Parameters**
E
ester.zhou 已提交
25 26 27 28 29 30

  | Name| Type| Mandatory| Description|
  | -------- | -------- | -------- | -------- |
  | reminderReq | [ReminderRequest](#reminderrequest) | Yes| Reminder to be published.|
  | callback | AsyncCallback<number> | Yes| Asynchronous callback used to return the published reminder's ID.|

E
ester.zhou 已提交
31
**Example**
E
ester.zhou 已提交
32
  ```
E
ester.zhou 已提交
33 34 35
  export default {
      data: {
          timer: {
E
ester.zhou 已提交
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53
              reminderType: reminderAgent.ReminderType.REMINDER_TYPE_TIMER,
              triggerTimeInSeconds: 3
          }
      },
      startTimer() {
          reminderAgent.publishReminder(timer, (err, reminderId) => {    console.log("reminderId = " + reminderId);
          });
      }
  }
  ```


## reminderAgent.publishReminder

publishReminder(reminderReq: ReminderRequest): Promise<number>

Publishes an agent-powered reminder. This API uses a promise callback to return the result.

E
ester.zhou 已提交
54
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
55

E
ester.zhou 已提交
56
**Parameters**
E
ester.zhou 已提交
57 58 59 60
  | Name| Type| Mandatory| Description|
  | -------- | -------- | -------- | -------- |
  | reminderReq | [ReminderRequest](#reminderrequest) | Yes| Reminder to be published.|

E
ester.zhou 已提交
61
**Return value**
E
ester.zhou 已提交
62 63 64 65
  | Type| Description|
  | -------- | -------- |
  | Promise<number> | Promise used to return the published reminder's ID.|

E
ester.zhou 已提交
66
**Example**
E
ester.zhou 已提交
67
  ```
E
ester.zhou 已提交
68 69 70
  export default {
      data:
          {timer: {
E
ester.zhou 已提交
71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89
              reminderType: reminderAgent.ReminderType.REMINDER_TYPE_TIMER,
              triggerTimeInSeconds: 3
          }
      },
      startTimer() {
          reminderAgent.publishReminder(this.timer).then((reminderId) => {
              console.log("reminderId = " + reminderId);
          });
      }
  }
  ```


## reminderAgent.cancelReminder

cancelReminder(reminderId: number, callback: AsyncCallback<void>): void

Cancels the reminder with the specified ID. This API uses an asynchronous callback to return the cancellation result.

E
ester.zhou 已提交
90
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
91

E
ester.zhou 已提交
92
**Parameters**
E
ester.zhou 已提交
93 94 95 96 97 98

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| reminderId | number | Yes| ID of the reminder to cancel.|
| callback | AsyncCallback<void> | Yes| Asynchronous callback used to return the result.|

E
ester.zhou 已提交
99
**Example**
Z
zengyawen 已提交
100 101 102

```
export default {
E
ester.zhou 已提交
103 104
    cancel() {
        reminderAgent.cancelReminder(1, (err, data) => {
Z
zengyawen 已提交
105 106 107 108 109 110
            console.log("do next");
        });
    }
}
```

E
ester.zhou 已提交
111 112 113 114 115 116 117

## reminderAgent.cancelReminder

cancelReminder(reminderId: number): Promise<void>

Cancels the reminder with the specified ID. This API uses a promise to return the cancellation result.

E
ester.zhou 已提交
118
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
119

E
ester.zhou 已提交
120
**Parameters**
E
ester.zhou 已提交
121 122 123 124 125

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| reminderId | number | Yes| ID of the reminder to cancel.|

E
ester.zhou 已提交
126
**Return value**
E
ester.zhou 已提交
127 128 129 130 131

| Type| Description|
| -------- | -------- |
| Promise<void> | Promise used to return the result.|

E
ester.zhou 已提交
132
**Example**
Z
zengyawen 已提交
133 134 135 136 137 138 139 140 141 142 143

```
export default {
    cancel() {
        reminderAgent.cancelReminder(1).then(() => {
            console.log("do next");
        });
    }
}
```

E
ester.zhou 已提交
144 145 146 147 148 149 150

## reminderAgent.getValidReminders

getValidReminders(callback: AsyncCallback<Array<ReminderRequest>>): void

Obtains all valid (not yet expired) reminders set by the current application. This API uses an asynchronous callback to return the reminders.

E
ester.zhou 已提交
151
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
152

E
ester.zhou 已提交
153
**Parameters**
E
ester.zhou 已提交
154 155 156 157 158

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| callback | AsyncCallback<Array<[ReminderRequest](#reminderrequest)>> | Yes| Asynchronous callback used to return an array of all valid reminders set by the current application.|

E
ester.zhou 已提交
159
**Example**
Z
zengyawen 已提交
160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187

```
reminderAgent.getValidReminders((err, reminders) => {
    for (let i = 0; i < reminders.length; i++) {
        console.log("getValidReminders = " + reminders[i]);
        console.log("getValidReminders, reminderType = " + reminders[i].reminderType);
        for (let j = 0; j < reminders[i].actionButton.length; j++) {
            console.log("getValidReminders, actionButton.title = " + reminders[i].actionButton[j].title);
            console.log("getValidReminders, actionButton.type = " + reminders[i].actionButton[j].type);
        }
        console.log("getValidReminders, wantAgent.pkgName = " + reminders[i].wantAgent.pkgName);
        console.log("getValidReminders, wantAgent.abilityName = " + reminders[i].wantAgent.abilityName);
        console.log("getValidReminders, maxScreenWantAgent.pkgName = " + reminders[i].maxScreenWantAgent.pkgName);
        console.log("getValidReminders, maxScreenWantAgent.abilityName = " + reminders[i].maxScreenWantAgent.abilityName);
        console.log("getValidReminders, ringDuration = " + reminders[i].ringDuration);
        console.log("getValidReminders, snoozeTimes = " + reminders[i].snoozeTimes);
        console.log("getValidReminders, timeInterval = " + reminders[i].timeInterval);
        console.log("getValidReminders, title = " + reminders[i].title);
        console.log("getValidReminders, content = " + reminders[i].content);
        console.log("getValidReminders, expiredContent = " + reminders[i].expiredContent);
        console.log("getValidReminders, snoozeContent = " + reminders[i].snoozeContent);
        console.log("getValidReminders, notificationId = " + reminders[i].notificationId);
        console.log("getValidReminders, slotType = " + reminders[i].slotType);
    }
})
```


E
ester.zhou 已提交
188 189 190 191 192
## reminderAgent.getValidReminders

getValidReminders(): Promise&lt;Array&lt;ReminderRequest&gt;&gt;

Obtains all valid (not yet expired) reminders set by the current application. This API uses a promise to return the reminders.
Z
zengyawen 已提交
193

E
ester.zhou 已提交
194
**System capability**: SystemCapability.Notification.ReminderAgent
Z
zengyawen 已提交
195

E
ester.zhou 已提交
196
**Return value**
Z
zengyawen 已提交
197

E
ester.zhou 已提交
198 199 200 201
| Type| Description|
| -------- | -------- |
| Promise&lt;Array&lt;[ReminderRequest](#reminderrequest)&gt;&gt; | Promise used to return an array of all valid reminders set by the current application.|

E
ester.zhou 已提交
202
**Example**
Z
zengyawen 已提交
203 204

```
E
ester.zhou 已提交
205
reminderAgent.getValidReminders().then((reminders) => {
Z
zengyawen 已提交
206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229
    for (let i = 0; i < reminders.length; i++) {
        console.log("getValidReminders = " + reminders[i]);
        console.log("getValidReminders, reminderType = " + reminders[i].reminderType);
        for (let j = 0; j < reminders[i].actionButton.length; j++) {
            console.log("getValidReminders, actionButton.title = " + reminders[i].actionButton[j].title);
            console.log("getValidReminders, actionButton.type = " + reminders[i].actionButton[j].type);
        }
        console.log("getValidReminders, wantAgent.pkgName = " + reminders[i].wantAgent.pkgName);
        console.log("getValidReminders, wantAgent.abilityName = " + reminders[i].wantAgent.abilityName);
        console.log("getValidReminders, maxScreenWantAgent.pkgName = " + reminders[i].maxScreenWantAgent.pkgName);
        console.log("getValidReminders, maxScreenWantAgent.abilityName = " + reminders[i].maxScreenWantAgent.abilityName);
        console.log("getValidReminders, ringDuration = " + reminders[i].ringDuration);
        console.log("getValidReminders, snoozeTimes = " + reminders[i].snoozeTimes);
        console.log("getValidReminders, timeInterval = " + reminders[i].timeInterval);
        console.log("getValidReminders, title = " + reminders[i].title);
        console.log("getValidReminders, content = " + reminders[i].content);
        console.log("getValidReminders, expiredContent = " + reminders[i].expiredContent);
        console.log("getValidReminders, snoozeContent = " + reminders[i].snoozeContent);
        console.log("getValidReminders, notificationId = " + reminders[i].notificationId);
        console.log("getValidReminders, slotType = " + reminders[i].slotType);
    }
})
```

E
ester.zhou 已提交
230 231 232 233 234 235 236

## reminderAgent.cancelAllReminders

cancelAllReminders(callback: AsyncCallback&lt;void&gt;): void

Cancels all reminders set by the current application. This API uses an asynchronous callback to return the cancellation result.

E
ester.zhou 已提交
237
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
238

E
ester.zhou 已提交
239
**Parameters**
E
ester.zhou 已提交
240 241 242 243 244

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| callback | AsyncCallback&lt;void&gt; | Yes| Asynchronous callback used to return the result.|

E
ester.zhou 已提交
245
**Example**
Z
zengyawen 已提交
246 247

```
E
ester.zhou 已提交
248
reminderAgent.cancelAllReminders((err, data) =>{
E
ester.zhou 已提交
249
    console.log("do next")})
Z
zengyawen 已提交
250 251 252
```


E
ester.zhou 已提交
253
## reminderAgent.cancelAllReminders
Z
zengyawen 已提交
254

E
ester.zhou 已提交
255
cancelAllReminders(): Promise&lt;void&gt;
Z
zengyawen 已提交
256

E
ester.zhou 已提交
257
Cancels all reminders set by the current application. This API uses a promise to return the cancellation result.
Z
zengyawen 已提交
258

E
ester.zhou 已提交
259
**System capability**: SystemCapability.Notification.ReminderAgent
Z
zengyawen 已提交
260

E
ester.zhou 已提交
261
**Return value**
E
ester.zhou 已提交
262 263 264 265 266

| Type| Description|
| -------- | -------- |
| Promise&lt;void&gt; | Promise used to return the result.|

E
ester.zhou 已提交
267
**Example**
Z
zengyawen 已提交
268 269 270

```
reminderAgent.cancelAllReminders().then(() => {
E
ester.zhou 已提交
271
    console.log("do next")})
Z
zengyawen 已提交
272 273
```

E
ester.zhou 已提交
274 275 276 277 278 279 280

## reminderAgent.addNotificationSlot

addNotificationSlot(slot: NotificationSlot, callback: AsyncCallback&lt;void&gt;): void

Adds a reminder notification slot. This API uses an asynchronous callback to return the result.

E
ester.zhou 已提交
281
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
282

E
ester.zhou 已提交
283
**Parameters**
E
ester.zhou 已提交
284 285 286 287 288 289

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| slot | [NotificationSlot](js-apis-notification.md#notificationslot) | Yes| Reminder notification slot to add.|
| callback | AsyncCallback&lt;void&gt; | Yes| Asynchronous callback used to return the result.|

E
ester.zhou 已提交
290
**Example**
Z
zengyawen 已提交
291 292

```
E
ester.zhou 已提交
293
export default {    data: {        mySlot: {
Z
zengyawen 已提交
294 295
            type: 3,
            sound: "/sdcard/music2.mp3"
E
ester.zhou 已提交
296
        }    },
Z
zengyawen 已提交
297 298 299 300 301 302 303 304
    addSlot() {
        reminderAgent.addNotificationSlot(this.mySlot, (err, data) => {
            console.log("do next");
        });
    }
}
```

E
ester.zhou 已提交
305 306 307 308 309 310 311

## reminderAgent.addNotificationSlot

addNotificationSlot(slot: NotificationSlot): Promise&lt;void&gt;

Adds a reminder notification slot. This API uses a promise to return the result.

E
ester.zhou 已提交
312
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
313

E
ester.zhou 已提交
314
**Parameters**
E
ester.zhou 已提交
315 316 317 318 319

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| slot | [NotificationSlot](js-apis-notification.md#notificationslot) | Yes| Reminder notification slot to add.|

E
ester.zhou 已提交
320
**Return value**
E
ester.zhou 已提交
321 322 323 324 325

| Type| Description|
| -------- | -------- |
| Promise&lt;void&gt; | Promise used to return the result.|

E
ester.zhou 已提交
326
**Example**
Z
zengyawen 已提交
327 328

```
E
ester.zhou 已提交
329
export default {    data: {        mySlot: {
Z
zengyawen 已提交
330 331
            type: 3,
            sound: "/sdcard/music2.mp3"
E
ester.zhou 已提交
332
        }    },
Z
zengyawen 已提交
333 334
    addSlot() {
        reminderAgent.addNotificationSlot(this.mySlot).then(() => {
E
ester.zhou 已提交
335
   console.log("do next");
Z
zengyawen 已提交
336 337 338 339 340
        });
    }
}
```

E
ester.zhou 已提交
341 342 343 344 345 346 347

## reminderAgent.removeNotificationSlot

removeNotificationSlot(slotType: notification.SlotType, callback: AsyncCallback&lt;void&gt;): void

Removes a notification slot of a specified type. This API uses an asynchronous callback to return the result.

E
ester.zhou 已提交
348
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
349

E
ester.zhou 已提交
350
**Parameters**
E
ester.zhou 已提交
351 352 353 354 355 356

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| slotType | [notification.SlotType](js-apis-notification.md#slottype) | Yes| Type of the reminder notification slot to remove.|
| callback | AsyncCallback&lt;void&gt; | Yes| Asynchronous callback used to return the result.|

E
ester.zhou 已提交
357
**Example**
Z
zengyawen 已提交
358 359 360

```
export default {
E
ester.zhou 已提交
361
    removeSlot() {reminderAgent.removeNotificationSlot(notification.SlotType.CONTENT_INFORMATION, (err, data) => {
Z
zengyawen 已提交
362
            console.log("do next");
E
ester.zhou 已提交
363
});
Z
zengyawen 已提交
364 365 366 367
    }
}
```

E
ester.zhou 已提交
368 369 370 371 372 373 374

## reminderAgent.removeNotificationSlot

removeNotificationSlot(slotType: notification.SlotType): Promise&lt;void&gt;

Removes a notification slot of a specified type. This API uses a promise to return the result.

E
ester.zhou 已提交
375
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
376

E
ester.zhou 已提交
377
**Parameters**
E
ester.zhou 已提交
378 379 380 381 382

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| slotType | [notification.SlotType](js-apis-notification.md#slottype) | Yes| Type of the reminder notification slot to remove.|

E
ester.zhou 已提交
383
**Return value**
E
ester.zhou 已提交
384 385 386 387 388

| Type| Description|
| -------- | -------- |
| Promise&lt;void&gt; | Promise used to return the result.|

E
ester.zhou 已提交
389
**Example**
Z
zengyawen 已提交
390 391 392

```
export default {
E
ester.zhou 已提交
393
    removeSlot() {        reminderAgent.removeNotificationSlot(notification.SlotType.CONTENT_INFORMATION).then(() => {
Z
zengyawen 已提交
394 395 396 397 398 399
            console.log("do next");
        });
    }
}
```

E
ester.zhou 已提交
400 401

## ActionButtonType
Z
zengyawen 已提交
402 403 404

Enumerates button types.

E
ester.zhou 已提交
405
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
406 407 408 409 410 411 412 413

| Name| Default Value| Description|
| -------- | -------- | -------- |
| ACTION_BUTTON_TYPE_CLOSE | 0 | Button for closing the reminder.|
| ACTION_BUTTON_TYPE_SNOOZE | 1 | Button for snoozing the reminder.|


## ReminderType
Z
zengyawen 已提交
414 415 416

Enumerates reminder types.

E
ester.zhou 已提交
417
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
418 419 420 421 422 423 424 425 426

| Name| Default Value| Description|
| -------- | -------- | -------- |
| REMINDER_TYPE_TIMER | 0 | Countdown reminder.|
| REMINDER_TYPE_CALENDAR | 1 | Calendar reminder.|
| REMINDER_TYPE_ALARM | 2 | Alarm reminder.|


## ActionButton
Z
zengyawen 已提交
427 428 429

Defines a button displayed in the reminder notification.

E
ester.zhou 已提交
430
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
431 432 433 434 435 436 437 438

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| title | string | Yes| Text on the button.|
| type | [ActionButtonType](#actionbuttontype) | Yes| Button type.|


## WantAgent
Z
zengyawen 已提交
439 440 441

Sets the package and ability that are redirected to when the reminder notification is clicked.

E
ester.zhou 已提交
442
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
443 444 445 446 447 448 449 450

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| pkgName | string | Yes| Name of the package that is redirected to when the reminder notification is clicked.|
| abilityName | string | Yes| Name of the ability that is redirected to when the reminder notification is clicked.|


## MaxScreenWantAgent
Z
zengyawen 已提交
451 452 453

Sets the name of the target package and ability to start automatically when the reminder arrives and the device is not in use. If the device is in use, a notification will be displayed.

E
ester.zhou 已提交
454
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
455 456 457 458 459 460 461 462

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| pkgName | string | Yes| Name of the package that is automatically started when the reminder arrives and the device is not in use.|
| abilityName | string | Yes| Name of the ability that is automatically started when the reminder arrives and the device is not in use.|


## ReminderRequest
Z
zengyawen 已提交
463 464 465

Defines the reminder to publish.

E
ester.zhou 已提交
466
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| reminderType | ReminderType | Yes| Type of the reminder.|
| actionButton | [ActionButton?,&nbsp;ActionButton?] | No| Action button displayed in the reminder notification. (The parameter is optional. Up to two buttons are supported.)|
| wantAgent | WantAgent | No| Information about the ability that is redirected to when the notification is clicked.|
| maxScreenWantAgent | MaxScreenWantAgent | No| Information about the ability that is automatically started when the reminder arrives. If the device is in use, a notification will be displayed.|
| ringDuration | number | No| Ringing duration.|
| snoozeTimes | number | No| Number of reminder snooze times.|
| timeInterval | number | No| Reminder snooze interval.|
| title | string | No| Reminder title.|
| content | string | No| Reminder content.|
| expiredContent | string | No| Content to be displayed after the reminder expires.|
| snoozeContent | string | No| Content to be displayed when the reminder is snoozing.|
| notificationId | number | No| Notification ID used by the reminder. If there are reminders with the same notification ID, the later one will overwrite the earlier one.|
| slotType | [notification.SlotType](js-apis-notification.md#slottype) | No| Type of the slot used by the reminder.|


## ReminderRequestCalendar
Z
zengyawen 已提交
486 487 488 489 490

ReminderRequestCalendar extends ReminderRequest

Defines a reminder for a calendar event.

E
ester.zhou 已提交
491
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
492 493 494 495 496 497 498 499 500

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| dateTime | [LocalDateTime](#localdatetime) | Yes| Reminder time.|
| repeatMonths | Array&lt;number&gt; | No| Month in which the reminder repeats.|
| repeatDays | Array&lt;number&gt; | No| Date on which the reminder repeats.|


## ReminderRequestAlarm
Z
zengyawen 已提交
501 502 503

ReminderRequestAlarm extends ReminderRequest

E
ester.zhou 已提交
504 505
Defines a reminder for an alarm.

E
ester.zhou 已提交
506
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
507

E
ester.zhou 已提交
508
| Name| Type| Mandatory| Description|
E
ester.zhou 已提交
509 510 511 512 513 514 515 516 517
| -------- | -------- | -------- | -------- |
| hour | number | Yes| Hour portion of the reminder time.|
| minute | number | Yes| Minute portion of the reminder time.|
| daysOfWeek | Array&lt;number&gt; | No| Days of a week when the reminder repeats.|


## ReminderRequestTimer

ReminderRequestTimer extends ReminderRequest
Z
zengyawen 已提交
518 519 520

Defines a reminder for a scheduled timer.

E
ester.zhou 已提交
521
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
522 523 524 525 526 527 528

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| triggerTimeInSeconds | number | Yes| Number of seconds in the countdown timer.|


## LocalDateTime
Z
zengyawen 已提交
529 530 531

Sets the time information for a calendar reminder.

E
ester.zhou 已提交
532
**System capability**: SystemCapability.Notification.ReminderAgent
E
ester.zhou 已提交
533 534 535 536 537 538 539 540 541

| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| year | number | Yes| Year.|
| month | number | Yes| Month.|
| day | number | Yes| Date.|
| hour | number | Yes| Hour.|
| minute | number | Yes| Minute.|
| second | number | No| Second.|