public enum Mqtt5MessageType extends Enum<Mqtt5MessageType>
Enum Constant and Description |
---|
AUTH |
CONNACK |
CONNECT |
DISCONNECT |
PINGREQ |
PINGRESP |
PUBACK |
PUBCOMP |
PUBLISH |
PUBREC |
PUBREL |
SUBACK |
SUBSCRIBE |
UNSUBACK |
UNSUBSCRIBE |
Modifier and Type | Method and Description |
---|---|
static @Nullable Mqtt5MessageType |
fromCode(int code)
Returns the MQTT message type belonging to the given byte code.
|
int |
getCode() |
static Mqtt5MessageType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Mqtt5MessageType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Mqtt5MessageType CONNECT
public static final Mqtt5MessageType CONNACK
public static final Mqtt5MessageType PUBLISH
public static final Mqtt5MessageType PUBACK
public static final Mqtt5MessageType PUBREC
public static final Mqtt5MessageType PUBREL
public static final Mqtt5MessageType PUBCOMP
public static final Mqtt5MessageType SUBSCRIBE
public static final Mqtt5MessageType SUBACK
public static final Mqtt5MessageType UNSUBSCRIBE
public static final Mqtt5MessageType UNSUBACK
public static final Mqtt5MessageType PINGREQ
public static final Mqtt5MessageType PINGRESP
public static final Mqtt5MessageType DISCONNECT
public static final Mqtt5MessageType AUTH
public static Mqtt5MessageType[] values()
for (Mqtt5MessageType c : Mqtt5MessageType.values()) System.out.println(c);
public static Mqtt5MessageType 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 int getCode()
@Nullable public static @Nullable Mqtt5MessageType fromCode(int code)
code
- the byte code.null
if the byte code is not a
valid MQTT message type.