Enum Class Mqtt5SubAckReasonCode

java.lang.Object
java.lang.Enum<Mqtt5SubAckReasonCode>
com.hivemq.client.mqtt.mqtt5.message.subscribe.suback.Mqtt5SubAckReasonCode
All Implemented Interfaces:
Mqtt5ReasonCode, Serializable, Comparable<Mqtt5SubAckReasonCode>, Constable

public enum Mqtt5SubAckReasonCode extends Enum<Mqtt5SubAckReasonCode> implements Mqtt5ReasonCode
Reason Code of an MQTT 5 SubAck message.
Since:
1.0
  • Enum Constant Details

    • GRANTED_QOS_0

      public static final Mqtt5SubAckReasonCode GRANTED_QOS_0
      The subscription is accepted and the maximum QoS sent will be QoS 0 (this might be a lower QoS than was requested).
    • GRANTED_QOS_1

      public static final Mqtt5SubAckReasonCode GRANTED_QOS_1
      The subscription is accepted and the maximum QoS sent will be QoS 1 (this might be a lower QoS than was requested).
    • GRANTED_QOS_2

      public static final Mqtt5SubAckReasonCode GRANTED_QOS_2
      The subscription is accepted and the maximum QoS sent will be QoS 2.
    • UNSPECIFIED_ERROR

      public static final Mqtt5SubAckReasonCode 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

      public static final Mqtt5SubAckReasonCode IMPLEMENTATION_SPECIFIC_ERROR
      The SUBSCRIBE packet is valid but is not accepted by the server.
    • NOT_AUTHORIZED

      public static final Mqtt5SubAckReasonCode NOT_AUTHORIZED
      The client is not authorized to make the subscription.
    • TOPIC_FILTER_INVALID

      public static final Mqtt5SubAckReasonCode TOPIC_FILTER_INVALID
      The topic filter is formed correctly but is not accepted by the server (for this client).
    • PACKET_IDENTIFIER_IN_USE

      public static final Mqtt5SubAckReasonCode PACKET_IDENTIFIER_IN_USE
      The specified packet identifier is already in use.
    • QUOTA_EXCEEDED

      public static final Mqtt5SubAckReasonCode QUOTA_EXCEEDED
      An implementation or administrative imposed limit has been exceeded.
    • SHARED_SUBSCRIPTIONS_NOT_SUPPORTED

      public static final Mqtt5SubAckReasonCode SHARED_SUBSCRIPTIONS_NOT_SUPPORTED
      The server does not support shared subscriptions (for this client).
    • SUBSCRIPTION_IDENTIFIERS_NOT_SUPPORTED

      public static final Mqtt5SubAckReasonCode SUBSCRIPTION_IDENTIFIERS_NOT_SUPPORTED
      The server does not support subscription identifiers (for this client).
    • WILDCARD_SUBSCRIPTIONS_NOT_SUPPORTED

      public static final Mqtt5SubAckReasonCode WILDCARD_SUBSCRIPTIONS_NOT_SUPPORTED
      The server does not support wildcard subscriptions (for this client).
  • Method Details

    • values

      public static Mqtt5SubAckReasonCode[] 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

      public static Mqtt5SubAckReasonCode valueOf(String name)
      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 name
      NullPointerException - if the argument is null
    • getCode

      public int getCode()
      Specified by:
      getCode in interface Mqtt5ReasonCode
      Returns:
      the byte code of this Reason Code.
    • fromCode

      @Nullable public static @Nullable Mqtt5SubAckReasonCode fromCode(int code)
      Returns the SubAck Reason Code belonging to the given byte code.
      Parameters:
      code - the byte code.
      Returns:
      the SubAck Reason Code belonging to the given byte code or null if the byte code is not a valid SubAck Reason Code.