Mobile PushFrom Libzter
Mobile Push
[edit] OverviewMobile Push is an open source API that provides push notifications to Android applications. Notifications are sent through SMS or HTTP, and can be used for various applications that needs to receive a data stream without polling. [edit] TechnologyMobile Push requires Android OS 1.6 or later. There is a requirement to sign up for a developer key at Ericsson labs. [edit] Example and usageThere are some steps needed to be taken in XML configuration before the application is ready to use push. That is well described at the library site. When done, only a handler is used to capture the notifications. Like this: public class MyPushReceiver extends PushReceiver { @Override public void onPushMessageReceived(Context context, String msg) { Log.i("Mobile Push", "Received: " + msg); foobar(msg, context); // do whatever } @Override public void onPushFailed(Context context, Exception e) { // error handling } } [edit] ResourcesUser comments on this article (Mobile Push) |
||