Skip to content

Commit

Permalink
[TIMOB-24504] Add documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
Gary Mathews committed Jun 14, 2017
1 parent 5aa2567 commit 3d18732
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions apidoc/Titanium/Android/Notification.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,33 @@ examples:
// Send the notification.
Titanium.Android.NotificationManager.notify(1, notification);
- title: Bundled Notifications Example
example: |
The following example shows how to create bundled notifications.
var id = 100,
groupKey = 'group_key';
for (var i = 3; i > 0; i--) {
Ti.Android.NotificationManager.notify(id++,
Ti.Android.createNotification({
icon: Ti.Android.R.drawable.ic_dialog_info,
contentTitle: 'NOTIFICATION #' + i,
contentText : 'Lorem ipsum dolor sit amet, facer eruditi omittantur cu pri, nibh nonumy putant eam eu.'
group: groupKey
})
);
}
Ti.Android.NotificationManager.notify(id++,
Ti.Android.createNotification({
icon: Ti.Android.R.drawable.ic_dialog_info,
contentTitle: 'NOTIFICATIONS',
contentText : 'You have 3 notifications.',
group: group,
groupSummary: true
})
);
extends: Titanium.Proxy
since: "1.5"
platforms: [android]
Expand Down Expand Up @@ -197,6 +224,18 @@ properties:
Titanium.Android.FLAG_ONLY_ALERT_ONCE, Titanium.Android.FLAG_SHOW_LIGHTS ]
default: <Titanium.Android.FLAG_AUTO_CANCEL>

- name: group
summary: The group key that the notification will belong to.
type: String
since: "6.2.0"
osver: {android: {min: "7.0"}}

- name: groupSummary
summary: Specifies if this is a group summary notification.
type: Boolean
since: "6.2.0"
osver: {android: {min: "7.0"}}

- name: icon
summary:
Notification icon, specified as an Android resource ID, or a local URL to a
Expand Down

0 comments on commit 3d18732

Please sign in to comment.