Class SdkException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.sportradar.mbs.sdk.exceptions.SdkException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
AuthTokenFailureException,ProtocolInvalidRequestException,ProtocolInvalidResponseException,ProtocolMessageTooBigException,ProtocolSendBufferFullException,ProtocolSendFailedException,ProtocolTimeoutException,SdkNotConnectedException,ServerErrorResponseException,WebSocketConnectionException
The base class for all SDK exceptions.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionSdkException(int code, String message, Throwable cause) Constructs a new SdkException with the specified code, message, and cause. -
Method Summary
Modifier and TypeMethodDescriptionintgetCode()Get the error code associated with the exception.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
SdkException
Constructs a new SdkException with the specified code, message, and cause.- Parameters:
code- the error code associated with the exceptionmessage- the detail messagecause- the cause (which is saved for later retrieval by the getCause() method)
-
-
Method Details
-
getCode
public int getCode()Get the error code associated with the exception.- Returns:
- The error code.
-