Interface UnsubackPacket
- All Known Subinterfaces:
ModifiableUnsubackPacket
@Immutable @DoNotImplement public interface UnsubackPacket
Represents an UNSUBACK packet.
Contains all values of an MQTT 5 UNSUBACK, but will also be used to represent MQTT 3 UNSUBACK messages.
- Since:
- 4.3.0, CE 2020.1
-
Method Summary
Modifier and Type Method Description intgetPacketIdentifier()The packet identifier of the UNSUBACK packet.@Immutable @NotNull List<@NotNull UnsubackReasonCode>getReasonCodes()Represents the return codes for the QoS levels of the different Topics contained in the corresponding UNSUBSCRIBE message as well as potential failure codes.@NotNull Optional<String>getReasonString()The reason string of the UNSUBACK packet.@Immutable @NotNull UserPropertiesgetUserProperties()The user properties from the UNSUBACK packet.
-
Method Details
-
getPacketIdentifier
int getPacketIdentifier()The packet identifier of the UNSUBACK packet.- Returns:
- The packet identifier.
- Since:
- 4.3.0, CE 2020.1
-
getReasonCodes
Represents the return codes for the QoS levels of the different Topics contained in the corresponding UNSUBSCRIBE message as well as potential failure codes.For an MQTT 3 client this
Listfor the MQTT 5 property will always be empty (if not modified by a previousUnsubackOutboundInterceptor).- Returns:
- The reason codes for the unsubscribed topics.
- Since:
- 4.3.0, CE 2020.1
-
getReasonString
The reason string of the UNSUBACK packet.For an MQTT 3 client this
Optionalfor the MQTT 5 property will always be empty (if not modified by a previousUnsubackOutboundInterceptor).- Returns:
- An
Optionalcontaining the unsuback reason string if present. - Since:
- 4.3.0, CE 2020.1
-
getUserProperties
The user properties from the UNSUBACK packet.For an MQTT 3 client this MQTT 5 property will always be empty (if not modified by a previous
UnsubackOutboundInterceptor).- Returns:
- The
UserPropertiesof the UNSUBACK packet. - Since:
- 4.3.0, CE 2020.1
-