Enum Class Mqtt5UnsubAckReasonCode
java.lang.Object
java.lang.Enum<Mqtt5UnsubAckReasonCode>
com.hivemq.client.mqtt.mqtt5.message.unsubscribe.unsuback.Mqtt5UnsubAckReasonCode
- All Implemented Interfaces:
Mqtt5ReasonCode,Serializable,Comparable<Mqtt5UnsubAckReasonCode>,Constable
public enum Mqtt5UnsubAckReasonCode
extends Enum<Mqtt5UnsubAckReasonCode>
implements Mqtt5ReasonCode
Reason Code of an
MQTT 5 UnsubAck message.- Since:
- 1.0
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe UNSUBSCRIBE packet is valid but is not accepted by the server.No matching topic filter is being used by the client.The client is not authorized to unsubscribe.The specified packet identifier is already in use.The subscription is deleted.The topic filter is formed correctly but is not accepted by the server (for this client).The server either does not want to reveal the reason for the failure or none of the other reason codes apply. -
Method Summary
Modifier and TypeMethodDescriptionstatic @Nullable Mqtt5UnsubAckReasonCodefromCode(int code) Returns the UnsubAck Reason Code belonging to the given byte code.intgetCode()static Mqtt5UnsubAckReasonCodeReturns the enum constant of this class with the specified name.static Mqtt5UnsubAckReasonCode[]values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOfMethods inherited from interface com.hivemq.client.mqtt.mqtt5.message.Mqtt5ReasonCode
canBeSentByClient, canBeSentByServer, canBeSetByUser, isError
-
Enum Constant Details
-
SUCCESS
The subscription is deleted. -
NO_SUBSCRIPTIONS_EXISTED
No matching topic filter is being used by the client. -
UNSPECIFIED_ERROR
The server either does not want to reveal the reason for the failure or none of the other reason codes apply. -
IMPLEMENTATION_SPECIFIC_ERROR
The UNSUBSCRIBE packet is valid but is not accepted by the server. -
NOT_AUTHORIZED
The client is not authorized to unsubscribe. -
TOPIC_FILTER_INVALID
The topic filter is formed correctly but is not accepted by the server (for this client). -
PACKET_IDENTIFIER_IN_USE
The specified packet identifier is already in use.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- if the argument is null
-
getCode
public int getCode()- Specified by:
getCodein interfaceMqtt5ReasonCode- Returns:
- the byte code of this Reason Code.
-
fromCode
Returns the UnsubAck Reason Code belonging to the given byte code.- Parameters:
code- the byte code.- Returns:
- the UnsubAck Reason Code belonging to the given byte code or
nullif the byte code is not a valid UnsubAck Reason Code code.
-