• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: state of apns?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: state of apns?


  • Subject: Re: state of apns?
  • From: Amedeo Mantica <email@hidden>
  • Date: Tue, 28 Jun 2011 16:44:06 +0200

Hello

Is 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

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: state of apns?
      • From: Jesse Tayler <email@hidden>
References: 
 >state of apns? (From: Jesse Tayler <email@hidden>)

  • Prev by Date: Community Talk on WebEx
  • Next by Date: Re: state of apns?
  • Previous by thread: state of apns?
  • Next by thread: Re: state of apns?
  • Index(es):
    • Date
    • Thread