Enum RosterPacket.ItemType

java.lang.Object
java.lang.Enum<RosterPacket.ItemType>
org.jivesoftware.smack.roster.packet.RosterPacket.ItemType
All Implemented Interfaces:
Serializable, Comparable<RosterPacket.ItemType>
Enclosing class:
RosterPacket

  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    The user and the contact have subscriptions to each other's presence (also called a "mutual subscription").
    The contact has a subscription to the user's presence, but the user does not have a subscription to the contact's presence.
    The user does not have a subscription to the contact's presence, and the contact does not have a subscription to the user's presence; this is the default value, so if the subscription attribute is not included then the state is to be understood as "none".
    The user wishes to stop receiving presence updates from the subscriber.
    The user has a subscription to the contact's presence, but the contact does not have a subscription to the user's presence.
  • Method Summary

    Modifier and Type
    Method
    Description
    Get a String containing symbols representing the item type.
     
    Returns the enum constant of this type with the specified name.
    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 Details

    • none

      public static final RosterPacket.ItemType none
      The user does not have a subscription to the contact's presence, and the contact does not have a subscription to the user's presence; this is the default value, so if the subscription attribute is not included then the state is to be understood as "none".
    • to

      public static final RosterPacket.ItemType to
      The user has a subscription to the contact's presence, but the contact does not have a subscription to the user's presence.
    • from

      public static final RosterPacket.ItemType from
      The contact has a subscription to the user's presence, but the user does not have a subscription to the contact's presence.
    • both

      public static final RosterPacket.ItemType both
      The user and the contact have subscriptions to each other's presence (also called a "mutual subscription").
    • remove

      public static final RosterPacket.ItemType remove
      The user wishes to stop receiving presence updates from the subscriber.
  • Method Details

    • values

      public static RosterPacket.ItemType[] 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 RosterPacket.ItemType 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
    • fromString

      public static RosterPacket.ItemType fromString(String string)
    • asSymbol

      public String asSymbol()
      Get a String containing symbols representing the item type. The first symbol in the string is a big dot, representing the local entity. The second symbol represents the established subscription relation and is typically an arrow. The head(s) of the arrow point in the direction presence messages are sent. For example, if there is only a head pointing to the big dot, then the local user will receive presence information from the remote entity.
      Returns:
      the symbolic representation of this item type.