public static enum RosterPacket.ItemType extends Enum<RosterPacket.ItemType>
Enum Constant and Description |
---|
both
The user and the contact have subscriptions to each other's presence (also called a
"mutual subscription").
|
from
The contact has a subscription to the user's presence, but the user does not have a
subscription to the contact's presence.
|
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".
|
remove
The user wishes to stop receiving presence updates from the subscriber.
|
to
The user has a subscription to the contact's presence, but the contact does not have a
subscription to the user's presence.
|
Modifier and Type | Method and Description |
---|---|
String |
asSymbol()
Get a String containing symbols representing the item type.
|
static RosterPacket.ItemType |
fromString(String string) |
static RosterPacket.ItemType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static RosterPacket.ItemType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final RosterPacket.ItemType none
public static final RosterPacket.ItemType to
public static final RosterPacket.ItemType from
public static final RosterPacket.ItemType both
public static final RosterPacket.ItemType remove
public static RosterPacket.ItemType[] values()
for (RosterPacket.ItemType c : RosterPacket.ItemType.values()) System.out.println(c);
public static RosterPacket.ItemType valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static RosterPacket.ItemType fromString(String string)
public String asSymbol()