Re: state of apns?
Re: state of apns?
- Subject: Re: state of apns?
- From: Amedeo Mantica <email@hidden>
- Date: Tue, 28 Jun 2011 16:44:06 +0200
HelloIs very easy to use, I made a really tiny wrapper for it (just basic notifications), see attachment
I needed to just know when my app start
so I had in my app constructor
try { INAPNSSender.initializeAPNS( this.resourceManager().pathURLForResourceNamed("YOU CERTIFICATE FOR APNS.p12", "app", null).getPath() , "1234 < CERTIFICATE KEY");
INAPNSSender.addDevice("Amedeo", "PUT PHONE UUID HERE"); INAPNSSender.addDevice("Phone1", "PUT PHONE UUID HERE"); INAPNSSender.addDevice("Phone2", "PUT PHONE UUID HERE"); INAPNSSender.addDevice("Phone3", "PUT PHONE UUID HERE");
INAPNSSender.send("Amedeo", "Confindustria WebSite started", 1, "Purr.aiff"); <---- this sends the notification to the named device, the badge number and the sound
} catch (Exception e) { //e.printStackTrace(); }
All methods are static, you could use everywhere Regards Amedeo
|
Attachment:
INAPNSSender.java
Description: Binary data
---------------------------------
Amedeo Mantica
WOWODC 2011 : July 1-2-3, Montreal.
wowodc.com