org.jboss.aerogear.android.impl.unifiedpush
Class AeroGearGCMPushRegistrar
java.lang.Object
org.jboss.aerogear.android.impl.unifiedpush.AeroGearGCMPushRegistrar
- All Implemented Interfaces:
- PushRegistrar
public class AeroGearGCMPushRegistrar
- extends Object
- implements PushRegistrar
|
Method Summary |
protected String |
getRegistrationId(android.content.Context context)
Gets the current registration id for application on GCM service. |
void |
register(android.content.Context context,
Callback<Void> callback)
Registers a device to a push network and any 3rd party application servers. |
void |
unregister(android.content.Context context,
Callback<Void> callback)
Unregisters a device a push network and any party application servers. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PROPERTY_REG_ID
public static final String PROPERTY_REG_ID
- See Also:
- Constant Field Values
REGISTRATION_EXPIRY_TIME_MS
public static final long REGISTRATION_EXPIRY_TIME_MS
- Default lifespan (7 days) of a reservation until it is considered
expired.
- See Also:
- Constant Field Values
AeroGearGCMPushRegistrar
public AeroGearGCMPushRegistrar(PushConfig config)
register
public void register(android.content.Context context,
Callback<Void> callback)
- Description copied from interface:
PushRegistrar
- Registers a device to a push network and any 3rd party application servers.
- Specified by:
register in interface PushRegistrar
- Parameters:
context - Android application contextcallback - a callback.
unregister
public void unregister(android.content.Context context,
Callback<Void> callback)
- Description copied from interface:
PushRegistrar
- Unregisters a device a push network and any party application servers.
- Specified by:
unregister in interface PushRegistrar
- Parameters:
context - Android application contextcallback - a callback.
getRegistrationId
protected String getRegistrationId(android.content.Context context)
- Gets the current registration id for application on GCM service.
If result is empty, the registration has failed.
- Returns:
- registration id, or empty string if the registration is not
complete.
Copyright © 2013 JBoss by Red Hat. All Rights Reserved.