We are building an SDK providing a particular service, and which will be integrated into iOS applications. The question is very generic and wanted suggestions how to actually go forward with it. The SDK listens to different OS notifications and events, and for certain events require the user to react to it. E.g., the SDK is performing some operation in the background, but in between it requires the user to launch the client and enter certain missing information. How to pass this information from SDK to the iOS application, so that the app developers react to it and show the information in their customised way to the end-user, ( say when in background so a local notification and when in foreground some customised alert ) but the UI notif's should not be triggered from SDK and which is actually the requirement. Will creating delegates suffice or is their any other cleaner way to go forward it.
I suggest you to use delegate instead of NSNotification :
You probably want only 1 response to your call, so if you need NSNotification, nothing prevent the client app to answer it several times.
If the user need notification, he can implement it himself inside your delegates methods.
Delegates provide instant response, NSNotification is asynchronous. If you need information from client, you should ask for a sync response.
Cheers