Enum DeliveryPriority

java.lang.Object
java.lang.Enum<DeliveryPriority>
com.eatthepath.pushy.apns.DeliveryPriority
All Implemented Interfaces:
Serializable, Comparable<DeliveryPriority>, java.lang.constant.Constable

public enum DeliveryPriority extends Enum<DeliveryPriority>
An enumeration of delivery priorities for APNs push notifications. Note that this priority affects when the notification may be delivered to the receiving device by the APNs gateway and does not affect when the notification will be sent to the gateway itself.
Since:
0.4
Author:
Jon Chambers
See Also:
  • Enum Constant Details

    • IMMEDIATE

      public static final DeliveryPriority IMMEDIATE

      Indicates that the APNs server should attempt to deliver a notification immediately. Additionally, according to Apple's documentation:

      The push notification must trigger an alert, sound, or badge on the device. It is an error to use this priority for a push that contains only the content-available key.

    • CONSERVE_POWER

      public static final DeliveryPriority CONSERVE_POWER

      Indicates that the APNs server should attempt to deliver a notification "at a time that conserves power on the device receiving it."

  • Method Details

    • values

      public static DeliveryPriority[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static DeliveryPriority 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
    • getCode

      public int getCode()
    • getFromCode

      public static DeliveryPriority getFromCode(int code)