Class PlccomMqttLastWill


  • public final class PlccomMqttLastWill
    extends Object
    Immutable MQTT Last Will configuration for a client CONNECT packet.
    • Method Detail

      • getTopic

        public String getTopic()
        Returns the Last Will topic.
        Returns:
        MQTT topic name used by the broker when it publishes the Will
      • getLastWillPayload

        public byte[] getLastWillPayload()
        Returns a defensive copy of the Last Will payload.
        Returns:
        Last Will payload bytes, never null
      • getQualityOfService

        public PlccomMqttQualityOfService getQualityOfService()
        Returns the requested Last Will QoS.
        Returns:
        QoS level used by the broker for the Last Will publication
      • isRetain

        public boolean isRetain()
        Returns whether the broker should retain the Last Will publication.
        Returns:
        true when the MQTT Will Retain flag is set
      • getPayloadFormatUtf8

        public Boolean getPayloadFormatUtf8()
        Returns the MQTT 5 Will Payload Format Indicator property.
        Returns:
        Boolean.TRUE for UTF-8 character data, Boolean.FALSE for unspecified binary data, or null when the property is omitted
      • getMessageExpiryIntervalSeconds

        public Long getMessageExpiryIntervalSeconds()
        Returns the MQTT 5 Will Message Expiry Interval property.
        Returns:
        expiry interval in seconds, or null when omitted
      • getWillDelayIntervalSeconds

        public Long getWillDelayIntervalSeconds()
        Returns the MQTT 5 Will Delay Interval property.
        Returns:
        delay interval in seconds, or null when omitted
      • getContentType

        public String getContentType()
        Returns the MQTT 5 Will Content Type property.
        Returns:
        content type, or null when omitted
      • getResponseTopic

        public String getResponseTopic()
        Returns the MQTT 5 Will Response Topic property.
        Returns:
        response topic, or null when omitted
      • getCorrelationData

        public byte[] getCorrelationData()
        Returns a defensive copy of the MQTT 5 Will Correlation Data property.
        Returns:
        correlation data bytes, or null when omitted
      • getUserProperties

        public List<PlccomMqttUserProperty> getUserProperties()
        Returns the MQTT 5 Will User Properties.
        Returns:
        immutable user-property list, never null