See: Description
Exception | Description |
---|---|
AccountNotFoundException |
Exception thrown when trying to load an account that doesn't exist on the Stellar network.
|
AccountRequiresMemoException |
AccountRequiresMemoException is thrown when a transaction is trying to submit an operation to an
account which requires a memo.
|
BadRequestException |
Exception thrown when a bad request is made to the server.
|
BadResponseException |
Exception thrown when a bad response is received from the server.
|
ConnectionErrorException |
Connection error when trying to connect to the server.
|
InvalidSep10ChallengeException |
If the SEP-0010 validation fails, the exception will be thrown.
|
NetworkException |
Represents an exception that occurs during network operations in the Stellar SDK.
|
PrepareTransactionException |
Exception thrown when preparing a transaction failed.
|
RequestTimeoutException |
Exception thrown when a request times out.
|
SdkException |
Base class for all exceptions thrown by the SDK.
|
SorobanRpcException |
Throws when Soroban-RPC instance responds with error.
|
TooManyRequestsException |
Exception thrown when too many requests were sent to the Horizon server.
|
UnexpectedException |
This exception is thrown to indicate that an unexpected condition has occurred which
theoretically should never happen during the normal execution of the program.
|
UnknownResponseException |
The base exception class is SdkException
, which extends
RuntimeException
. All custom exceptions defined in the SDK extend SdkException
. The SDK may also throw standard Java runtime exceptions
such as IllegalArgumentException
where appropriate.
The exception hierarchy is as follows:
SdkException
The Stellar SDK uses unchecked exceptions (extending RuntimeException
) for the
following reasons:
While the SDK uses unchecked exceptions, developers are still encouraged to catch and handle these exceptions appropriately in their code. The specific exception classes thrown by the SDK provide useful information about the nature of the error that occurred.
SdkException
,
RuntimeException