public enum Mqtt5UnsubAckReasonCode extends Enum<Mqtt5UnsubAckReasonCode> implements Mqtt5ReasonCode
MQTT 5 UnsubAck message
.Enum Constant and Description |
---|
IMPLEMENTATION_SPECIFIC_ERROR
The UNSUBSCRIBE packet is valid but is not accepted by the server.
|
NO_SUBSCRIPTIONS_EXISTED
No matching topic filter is being used by the client.
|
NOT_AUTHORIZED
The client is not authorized to unsubscribe.
|
PACKET_IDENTIFIER_IN_USE
The specified packet identifier is already in use.
|
SUCCESS
The subscription is deleted.
|
TOPIC_FILTER_INVALID
The topic filter is formed correctly but is not accepted by the server (for this client).
|
UNSPECIFIED_ERROR
The server either does not want to reveal the reason for the failure or none of the other reason codes apply.
|
Modifier and Type | Method and Description |
---|---|
static @Nullable Mqtt5UnsubAckReasonCode |
fromCode(int code)
Returns the UnsubAck Reason Code belonging to the given byte code.
|
int |
getCode() |
static Mqtt5UnsubAckReasonCode |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Mqtt5UnsubAckReasonCode[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
canBeSentByClient, canBeSentByServer, canBeSetByUser, isError
public static final Mqtt5UnsubAckReasonCode SUCCESS
public static final Mqtt5UnsubAckReasonCode NO_SUBSCRIPTIONS_EXISTED
public static final Mqtt5UnsubAckReasonCode UNSPECIFIED_ERROR
public static final Mqtt5UnsubAckReasonCode IMPLEMENTATION_SPECIFIC_ERROR
public static final Mqtt5UnsubAckReasonCode NOT_AUTHORIZED
public static final Mqtt5UnsubAckReasonCode TOPIC_FILTER_INVALID
public static final Mqtt5UnsubAckReasonCode PACKET_IDENTIFIER_IN_USE
public static Mqtt5UnsubAckReasonCode[] values()
for (Mqtt5UnsubAckReasonCode c : Mqtt5UnsubAckReasonCode.values()) System.out.println(c);
public static Mqtt5UnsubAckReasonCode 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()
getCode
in interface Mqtt5ReasonCode
@Nullable public static @Nullable Mqtt5UnsubAckReasonCode fromCode(int code)
code
- the byte code.null
if the byte code is not a
valid UnsubAck Reason Code code.