net.rim.pushsdk.acknowledgement
Enum ListenerType

java.lang.Object
  extended by java.lang.Enum<ListenerType>
      extended by net.rim.pushsdk.acknowledgement.ListenerType
All Implemented Interfaces:
Serializable, Comparable<ListenerType>

public enum ListenerType
extends Enum<ListenerType>

Type of a notification listener: success, failure, any, last.

Author:
dstrelbytsky

Enum Constant Summary
ANY
          Listeners of this type are invoked on any notification message.
FAILURE
          Listeners of this type are invoked on notification of a failed delivery of a push message to a particular address.
LAST
          Listeners of this type are invoked on the last notification for a push request.
SUCCESS
          Listeners of this type are invoked on notification of a successful delivery of a push message to a particular address.
 
Method Summary
static ListenerType valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ListenerType[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

SUCCESS

public static final ListenerType SUCCESS
Listeners of this type are invoked on notification of a successful delivery of a push message to a particular address.


FAILURE

public static final ListenerType FAILURE
Listeners of this type are invoked on notification of a failed delivery of a push message to a particular address.


ANY

public static final ListenerType ANY
Listeners of this type are invoked on any notification message.


LAST

public static final ListenerType LAST
Listeners of this type are invoked on the last notification for a push request. This functionality must be enabled in the corresponding push application by setting the 'lastNotificationEnabled' flag to true. Keep in mind enabling last notification does incur a performance penalty.

Method Detail

values

public static ListenerType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (ListenerType c : ListenerType.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static ListenerType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null


Copyright © 2011 Research In Motion. All Rights Reserved.