mwkirk / javapns

Test import of svn javapns repo from Google Code
3 stars 0 forks source link

How to use PushNotificationManager without a Device? #123

Closed mwkirk closed 11 years ago

mwkirk commented 11 years ago

Original author: mlilback (May 17, 2012 19:27:32)

All the documentation and example show passing an object that implements Device to the sendNotification methods on PushNotificationManager. But all the Device stuff is deprecated.

How are you suppose to send notifications without a device?

Original issue: http://code.google.com/p/javapns/issues/detail?id=123

mwkirk commented 11 years ago

From sype...@gmail.com on May 17, 2012 20:47:12 I'm not sure where you looked at in the documentation to determine that only Device objects are accepted, but both the javadoc and the Basic Push Notification wiki page state that devices can be provided in a variety of ways, including simple Strings. The Push class handles all the details of converting your device tokens into Device objects. There is even a Devices utility class that can convert your lists if you absolutely cannot use the preferred Push class for some reason.

Also, the Device interface in question is not deprecated at all, and the javadoc reflects that fact...