Package com.plccom.mqtt.client
Class PlccomMqttConnectException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- com.plccom.mqtt.client.PlccomMqttException
-
- com.plccom.mqtt.client.PlccomMqttConnectException
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
PlccomMqttAuthenticationException
public class PlccomMqttConnectException extends PlccomMqttException
MQTT connection or CONNACK failure.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PlccomMqttConnectException(String message)Creates a connection exception with a diagnostic message.PlccomMqttConnectException(String message, Throwable cause)Creates a connection exception with a diagnostic message and root cause.PlccomMqttConnectException(String message, Throwable cause, boolean protocolVersionRejected)Creates a connection exception and records whether protocol fallback is allowed.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisProtocolVersionRejected()Returns whether the broker explicitly rejected the MQTT protocol version.-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
PlccomMqttConnectException
public PlccomMqttConnectException(String message)
Creates a connection exception with a diagnostic message.- Parameters:
message- human-readable connection failure description
-
PlccomMqttConnectException
public PlccomMqttConnectException(String message, Throwable cause)
Creates a connection exception with a diagnostic message and root cause.- Parameters:
message- human-readable connection failure descriptioncause- underlying failure, ornullwhen the broker supplied only an MQTT reason code
-
PlccomMqttConnectException
public PlccomMqttConnectException(String message, Throwable cause, boolean protocolVersionRejected)
Creates a connection exception and records whether protocol fallback is allowed.- Parameters:
message- human-readable connection failure descriptioncause- underlying failure, ornullwhen no lower-level cause is availableprotocolVersionRejected-truewhen the broker explicitly rejected the MQTT protocol version
-
-