I am trying to generate framework for iOS. In that need to handle the push notifications in static library project.
Is it possible to handle push notifications in static library project ? If it is possible ,How ?
Thanks.
I am trying to generate framework for iOS. In that need to handle the push notifications in static library project.
Is it possible to handle push notifications in static library project ? If it is possible ,How ?
Thanks.
As David Berry commented, you really need to receive all Push Notifications delegate methods in AppDelegate.
What you can do in your static lib is to provide an API to be called by the app in its AppDelegate. An app that uses your lib must therefore call these methods in order to take advantage from it.
Example (in AppDelegate):
- (void) application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo
{
[[PNLib sharedSingleton] appDidReceiveRemoteNotification:userInfo];
}