Loading...
Searching...
No Matches
<NCNotificationListener> Protocol Reference

Class provides a callback to be invoked when NotificationManager detects local notification events. More...

#include <com/navigine/idl/objc/NCNotificationListener.h>

Inherits <NSObject>.

Instance Methods

(void) - onNotificationLoaded:
 Called when iBeacon signal mathed all parameters in notification.
 
(void) - onNotificationFailed:
 Called if unable to calculate notification or network errors.
 

Detailed Description

Class provides a callback to be invoked when NotificationManager detects local notification events.

Referenced from NotificationManager.

Note
The callback is invoked in the UI thread.

Definition at line 20 of file NCNotificationListener.h.

Method Documentation

◆ onNotificationFailed:

- (void) onNotificationFailed: (nullable NSError *) error

Called if unable to calculate notification or network errors.

Parameters
errorhandled error.

Swift code snippet:

func onNotificationFailed(_ error: Error) {
print("Notification failed")
example?.demonstrateErrorHandling(error)
}

Objective C code snippet:

- (void)onNotificationFailed:(NSError *)error {
NSLog(@"Notification failed");
[self.example demonstrateErrorHandling:error];
}

◆ onNotificationLoaded:

- (void) onNotificationLoaded: (nullable NCNotification *) notification

Called when iBeacon signal mathed all parameters in notification.

Parameters
notificationnotification instance created in CMS Notification.

Swift code snippet:

func onNotificationLoaded(_ notification: Notification) {
print("Notification loaded")
example?.demonstrateNotificationUsage(notification)
}

Objective C code snippet:

- (void)onNotificationLoaded:(NCNotification *)notification {
NSLog(@"Notification loaded");
[self.example demonstrateNotificationUsage:notification];
}

The documentation for this protocol was generated from the following file: