Class MqttHeaderAccessor
java.lang.Object
org.springframework.integration.mqtt.support.MqttHeaderAccessor
public final class MqttHeaderAccessor
extends java.lang.Object
Helper for typed access to incoming MQTT message headers.
- Since:
- 5.3
-
Method Summary
Modifier and Type Method Description static java.lang.Booleanduplicate(org.springframework.messaging.Message<?> message)Return the duplicate header.static java.lang.Integerid(org.springframework.messaging.Message<?> message)Return the MQTT message id.static java.lang.IntegerreceivedQos(org.springframework.messaging.Message<?> message)Return the received QOS header.static java.lang.BooleanreceivedRetained(org.springframework.messaging.Message<?> message)Return the received retained header.static java.lang.StringreceivedTopic(org.springframework.messaging.Message<?> message)Return the received topic header.
-
Method Details
-
receivedTopic
@Nullable public static java.lang.String receivedTopic(org.springframework.messaging.Message<?> message)Return the received topic header.- Parameters:
message- the message.- Returns:
- the header.
-
id
@Nullable public static java.lang.Integer id(org.springframework.messaging.Message<?> message)Return the MQTT message id.- Parameters:
message- the message.- Returns:
- the header.
-
receivedQos
@Nullable public static java.lang.Integer receivedQos(org.springframework.messaging.Message<?> message)Return the received QOS header.- Parameters:
message- the message.- Returns:
- the header.
-
receivedRetained
@Nullable public static java.lang.Boolean receivedRetained(org.springframework.messaging.Message<?> message)Return the received retained header.- Parameters:
message- the message.- Returns:
- the header.
-
duplicate
@Nullable public static java.lang.Boolean duplicate(org.springframework.messaging.Message<?> message)Return the duplicate header.- Parameters:
message- the message.- Returns:
- the header.
-