Method | Description | |
---|---|---|
__construct ( $title, $body ) | ||
jsonSerialize ( ) | ||
setBadge ( integer $badge ) : |
iOS only: will add smal red bubbles indicating the number of notifications to your apps icon | |
setBody ( string $body ) : |
android/ios: the body text is the main content of the notification | |
setClickAction ( string $actionName ) : |
android/ios: what should happen upon notification click. when empty on android the default activity will be launched passing any payload to an intent. | |
setColor ( string $color ) : |
android only: background color of the notification icon when showing details on notifications | |
setIcon ( string $icon ) : |
android only: set the name of your drawable resource as string | |
setSound ( string $sound ) : |
android/ios: can be default or a filename of a sound resource bundled in the app. | |
setTag ( string $tag ) : |
android only: when set notification will replace prior notifications from the same app with the same tag. | |
setTitle ( string $title ) : |
android only: notification title (also works for ios watches) |
public setClickAction ( string $actionName ) : |
||
$actionName | string | on android: intent name, on ios: category in apns payload |
return |