org.eclipse.paho.client.mqttv3.internal.wire
Class MqttConnack
java.lang.Object
org.eclipse.paho.client.mqttv3.internal.wire.MqttWireMessage
org.eclipse.paho.client.mqttv3.internal.wire.MqttAck
org.eclipse.paho.client.mqttv3.internal.wire.MqttConnack
public class MqttConnack
- extends MqttAck
An on-the-wire representation of an MQTT CONNACK.
Fields inherited from class org.eclipse.paho.client.mqttv3.internal.wire.MqttWireMessage |
duplicate, MESSAGE_TYPE_CONNACK, MESSAGE_TYPE_CONNECT, MESSAGE_TYPE_DISCONNECT, MESSAGE_TYPE_PINGREQ, MESSAGE_TYPE_PINGRESP, MESSAGE_TYPE_PUBACK, MESSAGE_TYPE_PUBCOMP, MESSAGE_TYPE_PUBLISH, MESSAGE_TYPE_PUBREC, MESSAGE_TYPE_PUBREL, MESSAGE_TYPE_SUBACK, MESSAGE_TYPE_SUBSCRIBE, MESSAGE_TYPE_UNSUBACK, MESSAGE_TYPE_UNSUBSCRIBE, msgId, STRING_ENCODING |
Constructor Summary |
MqttConnack(byte info,
byte[] variableHeader)
|
Methods inherited from class org.eclipse.paho.client.mqttv3.internal.wire.MqttWireMessage |
createWireMessage, createWireMessage, decodeUTF8, encodeMBI, encodeMessageId, encodeUTF8, getHeader, getMessageId, getPayload, getType, isRetryable, readMBI, setDuplicate, setMessageId |
MqttConnack
public MqttConnack(byte info,
byte[] variableHeader)
throws IOException
- Throws:
IOException
getReturnCode
public int getReturnCode()
getVariableHeader
protected byte[] getVariableHeader()
throws MqttException
- Specified by:
getVariableHeader
in class MqttWireMessage
- Throws:
MqttException
isMessageIdRequired
public boolean isMessageIdRequired()
- Returns whether or not this message needs to include a message ID.
- Overrides:
isMessageIdRequired
in class MqttWireMessage
getKey
public String getKey()
- Description copied from class:
MqttWireMessage
- Returns a key associated with the message. For most message types
this will be unique. For connect, disconnect and ping only one
message of this type is allowed so a fixed key will be returned
- Overrides:
getKey
in class MqttWireMessage
- Returns:
- key a key associated with the message
toString
public String toString()
- Overrides:
toString
in class MqttAck
- Returns:
- String representation of the wire message
Copyright © 2013. All Rights Reserved.