(Optional) The application should register and implement a listener interface to receive native or payload push notifications.
The IODPPushNotificationListener interface should be implemented by the application to receive the BES native push notifications on BlackBerry devices. The onPushNotification method is called when a new BES push notification is received. For more information on configuring BES native notifications on SAP Control Center, see BES Native Notification Properties in SAP Control Center for SAP Mobile Platform.
The following code illustrates how to register listeners for native push notifications.
Public class Mylistener implements IODPPushNotifciationListner { Public int onPushNotifcation(Hashtable ht) { If(getpayload == true) Return 0; Else Return 1; } }