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
All Methods Instance Methods Abstract Methods Modifier and Type Method Description int
getPacketIdentifier()
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 UserProperties
getUserProperties()
The user properties from the UNSUBACK packet.
-
-
-
Method Detail
-
getPacketIdentifier
int getPacketIdentifier()
The packet identifier of the UNSUBACK packet.- Returns:
- The packet identifier.
- Since:
- 4.3.0, CE 2020.1
-
getReasonCodes
@Immutable @NotNull @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.For an MQTT 3 client this
List
for 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
@NotNull Optional<String> getReasonString()
The reason string of the UNSUBACK packet.For an MQTT 3 client this
Optional
for the MQTT 5 property will always be empty (if not modified by a previousUnsubackOutboundInterceptor
).- Returns:
- An
Optional
containing the unsuback reason string if present. - Since:
- 4.3.0, CE 2020.1
-
getUserProperties
@Immutable @NotNull @Immutable @NotNull UserProperties 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
UserProperties
of the UNSUBACK packet. - Since:
- 4.3.0, CE 2020.1
-
-