Package io.netty.handler.codec.mqtt
Class MqttProperties
- java.lang.Object
-
- io.netty.handler.codec.mqtt.MqttProperties
-
public final class MqttProperties extends Object
MQTT Properties container
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classMqttProperties.BinaryPropertystatic classMqttProperties.IntegerPropertystatic classMqttProperties.MqttProperty<T>MQTT property base classstatic classMqttProperties.MqttPropertyTypeDeprecated.static classMqttProperties.StringPairstatic classMqttProperties.StringPropertystatic classMqttProperties.UserPropertiesstatic classMqttProperties.UserProperty
-
Field Summary
Fields Modifier and Type Field Description static intASSIGNED_CLIENT_IDENTIFIERstatic intAUTHENTICATION_DATAstatic intAUTHENTICATION_METHODstatic intCONTENT_TYPEstatic intCORRELATION_DATAstatic intMAXIMUM_PACKET_SIZEstatic intMAXIMUM_QOSstatic MqttPropertiesNO_PROPERTIESstatic intPAYLOAD_FORMAT_INDICATORstatic intPUBLICATION_EXPIRY_INTERVALstatic intREASON_STRINGstatic intRECEIVE_MAXIMUMstatic intREQUEST_PROBLEM_INFORMATIONstatic intREQUEST_RESPONSE_INFORMATIONstatic intRESPONSE_INFORMATIONstatic intRESPONSE_TOPICstatic intRETAIN_AVAILABLEstatic intSERVER_KEEP_ALIVEstatic intSERVER_REFERENCEstatic intSESSION_EXPIRY_INTERVALstatic intSHARED_SUBSCRIPTION_AVAILABLEstatic intSUBSCRIPTION_IDENTIFIERstatic intSUBSCRIPTION_IDENTIFIER_AVAILABLEstatic intTOPIC_ALIASstatic intTOPIC_ALIAS_MAXIMUMstatic intUSER_PROPERTYstatic intWILDCARD_SUBSCRIPTION_AVAILABLEstatic intWILL_DELAY_INTERVAL
-
Constructor Summary
Constructors Constructor Description MqttProperties()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(MqttProperties.MqttProperty property)List<? extends MqttProperties.MqttProperty>getProperties(int propertyId)Get properties by ID.MqttProperties.MqttPropertygetProperty(int propertyId)Get property by ID.booleanisEmpty()Collection<? extends MqttProperties.MqttProperty>listAll()
-
-
-
Field Detail
-
PAYLOAD_FORMAT_INDICATOR
public static final int PAYLOAD_FORMAT_INDICATOR
- See Also:
- Constant Field Values
-
REQUEST_PROBLEM_INFORMATION
public static final int REQUEST_PROBLEM_INFORMATION
- See Also:
- Constant Field Values
-
REQUEST_RESPONSE_INFORMATION
public static final int REQUEST_RESPONSE_INFORMATION
- See Also:
- Constant Field Values
-
MAXIMUM_QOS
public static final int MAXIMUM_QOS
- See Also:
- Constant Field Values
-
RETAIN_AVAILABLE
public static final int RETAIN_AVAILABLE
- See Also:
- Constant Field Values
-
WILDCARD_SUBSCRIPTION_AVAILABLE
public static final int WILDCARD_SUBSCRIPTION_AVAILABLE
- See Also:
- Constant Field Values
-
SUBSCRIPTION_IDENTIFIER_AVAILABLE
public static final int SUBSCRIPTION_IDENTIFIER_AVAILABLE
- See Also:
- Constant Field Values
-
SHARED_SUBSCRIPTION_AVAILABLE
public static final int SHARED_SUBSCRIPTION_AVAILABLE
- See Also:
- Constant Field Values
-
SERVER_KEEP_ALIVE
public static final int SERVER_KEEP_ALIVE
- See Also:
- Constant Field Values
-
RECEIVE_MAXIMUM
public static final int RECEIVE_MAXIMUM
- See Also:
- Constant Field Values
-
TOPIC_ALIAS_MAXIMUM
public static final int TOPIC_ALIAS_MAXIMUM
- See Also:
- Constant Field Values
-
TOPIC_ALIAS
public static final int TOPIC_ALIAS
- See Also:
- Constant Field Values
-
PUBLICATION_EXPIRY_INTERVAL
public static final int PUBLICATION_EXPIRY_INTERVAL
- See Also:
- Constant Field Values
-
SESSION_EXPIRY_INTERVAL
public static final int SESSION_EXPIRY_INTERVAL
- See Also:
- Constant Field Values
-
WILL_DELAY_INTERVAL
public static final int WILL_DELAY_INTERVAL
- See Also:
- Constant Field Values
-
MAXIMUM_PACKET_SIZE
public static final int MAXIMUM_PACKET_SIZE
- See Also:
- Constant Field Values
-
SUBSCRIPTION_IDENTIFIER
public static final int SUBSCRIPTION_IDENTIFIER
- See Also:
- Constant Field Values
-
CONTENT_TYPE
public static final int CONTENT_TYPE
- See Also:
- Constant Field Values
-
RESPONSE_TOPIC
public static final int RESPONSE_TOPIC
- See Also:
- Constant Field Values
-
ASSIGNED_CLIENT_IDENTIFIER
public static final int ASSIGNED_CLIENT_IDENTIFIER
- See Also:
- Constant Field Values
-
AUTHENTICATION_METHOD
public static final int AUTHENTICATION_METHOD
- See Also:
- Constant Field Values
-
RESPONSE_INFORMATION
public static final int RESPONSE_INFORMATION
- See Also:
- Constant Field Values
-
SERVER_REFERENCE
public static final int SERVER_REFERENCE
- See Also:
- Constant Field Values
-
REASON_STRING
public static final int REASON_STRING
- See Also:
- Constant Field Values
-
USER_PROPERTY
public static final int USER_PROPERTY
- See Also:
- Constant Field Values
-
CORRELATION_DATA
public static final int CORRELATION_DATA
- See Also:
- Constant Field Values
-
AUTHENTICATION_DATA
public static final int AUTHENTICATION_DATA
- See Also:
- Constant Field Values
-
NO_PROPERTIES
public static final MqttProperties NO_PROPERTIES
-
-
Method Detail
-
add
public void add(MqttProperties.MqttProperty property)
-
listAll
public Collection<? extends MqttProperties.MqttProperty> listAll()
-
isEmpty
public boolean isEmpty()
-
getProperty
public MqttProperties.MqttProperty getProperty(int propertyId)
Get property by ID. If there are multiple properties of this type (can be with Subscription ID) then return the first one.- Parameters:
propertyId- ID of the property- Returns:
- a property if it is set, null otherwise
-
getProperties
public List<? extends MqttProperties.MqttProperty> getProperties(int propertyId)
Get properties by ID. Some properties (Subscription ID and User Properties) may occur multiple times, this method returns all their values in order.- Parameters:
propertyId- ID of the property- Returns:
- all properties having specified ID
-
-