public enum PacketType extends java.lang.Enum<PacketType>
| Enum Constant and Description |
|---|
BadPacket |
Disconnect |
Error |
KeepAlive |
LoginAccepted |
LoginDenied |
LoginRequest |
Message |
PingAnswer |
PingRequest |
| Modifier and Type | Field and Description |
|---|---|
int |
packetID |
| Modifier and Type | Method and Description |
|---|---|
static PacketType |
getPacket(int packetID) |
int |
getPacketID() |
static PacketType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static PacketType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PacketType BadPacket
public static final PacketType KeepAlive
public static final PacketType Disconnect
public static final PacketType Error
public static final PacketType LoginDenied
public static final PacketType LoginRequest
public static final PacketType LoginAccepted
public static final PacketType PingRequest
public static final PacketType PingAnswer
public static final PacketType Message
public static PacketType[] values()
for (PacketType c : PacketType.values()) System.out.println(c);
public static PacketType valueOf(java.lang.String name)
name - the name of the enum constant to be returned.java.lang.IllegalArgumentException - if this enum type has no constant
with the specified namejava.lang.NullPointerException - if the argument is nullpublic int getPacketID()
public static PacketType getPacket(int packetID)