public class ApnsDelegateAdapter extends Object implements ApnsDelegate
EMPTY
Constructor and Description |
---|
ApnsDelegateAdapter() |
Modifier and Type | Method and Description |
---|---|
void |
cacheLengthExceeded(int newCacheLength)
The resend cache needed a bigger size (while resending messages)
|
void |
connectionClosed(DeliveryError e,
int messageIdentifier)
The connection was closed and/or an error packet was received while
monitoring was turned on.
|
void |
messageSendFailed(ApnsNotification message,
Throwable e)
Called when the delivery of the message failed for any reason
If message is null, then your notification has been rejected by Apple but
it has been removed from the cache so it is not possible to identify
which notification caused the error.
|
void |
messageSent(ApnsNotification message,
boolean resent)
Called when message was successfully sent to the Apple servers
|
void |
notificationsResent(int resendCount)
A number of notifications has been queued for resending due to a error-response
packet being received.
|
public void messageSent(ApnsNotification message, boolean resent)
ApnsDelegate
messageSent
in interface ApnsDelegate
message
- the notification that was sentresent
- whether the notification was resent after an errorpublic void messageSendFailed(ApnsNotification message, Throwable e)
ApnsDelegate
messageSendFailed
in interface ApnsDelegate
message
- the notification that was attempted to be sente
- the cause and description of the failurepublic void connectionClosed(DeliveryError e, int messageIdentifier)
ApnsDelegate
connectionClosed
in interface ApnsDelegate
e
- the delivery errormessageIdentifier
- id of the message that failedpublic void cacheLengthExceeded(int newCacheLength)
ApnsDelegate
cacheLengthExceeded
in interface ApnsDelegate
newCacheLength
- new size of the resend cache.public void notificationsResent(int resendCount)
ApnsDelegate
notificationsResent
in interface ApnsDelegate
resendCount
- the number of messages being queued for resendCopyright © 2015. All rights reserved.