Package com.zb.mom.ww.mxgateway.client
Class MxGatewayCommandException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.zb.mom.ww.mxgateway.client.MxGatewayException
com.zb.mom.ww.mxgateway.client.MxGatewayCommandException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
MxAccessException
Thrown when the gateway accepts an MXAccess command but the command itself
fails at the protocol layer. Carries the original
MxCommandReply and
ProtocolStatus so callers can inspect the failure detail.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionMxGatewayCommandException(String operation, MxaccessGateway.ProtocolStatus protocolStatus, MxaccessGateway.MxCommandReply reply) Creates a new command exception. -
Method Summary
Modifier and TypeMethodDescriptionReturns the gateway protocol status that triggered this exception.reply()Returns the raw command reply associated with the failure.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
MxGatewayCommandException
public MxGatewayCommandException(String operation, MxaccessGateway.ProtocolStatus protocolStatus, MxaccessGateway.MxCommandReply reply) Creates a new command exception.- Parameters:
operation- human-readable name of the failing operationprotocolStatus- protocol status returned by the gatewayreply- raw command reply, ornullwhen the call failed before a reply was produced
-
-
Method Details
-
protocolStatus
Returns the gateway protocol status that triggered this exception.- Returns:
- the protocol status, or
nullif none was supplied
-
reply
Returns the raw command reply associated with the failure.- Returns:
- the command reply, or
nullif no reply was available
-