Enum vortex_common::error::ContractError
source · pub enum ContractError {
Show 28 variants
Std(StdError),
Unauthorized {},
SemVer(String),
InsufficientFundsSend {},
UnexpectedError {},
InsufficientCollateral {},
PrematureLiquidation {},
DuplicatedLiquidation {},
FailedLiquidation {},
FailedToSerialize {
err_msg: String,
},
FailedToBinary {
err_msg: String,
},
FailedToGetEquityAndTotalMarketValue {
err_msg: String,
},
FailedToGetInsuranceFund {},
FailedToGetOrder {
order_id: String,
},
FailedToFetchBalances {
err_msg: String,
},
InsufficientBalance {},
InsufficientBalanceForFundingPayment {},
InvalidCoinType {},
InvalidPositionEffect {},
InvalidPositionDirection {},
Invalidcw20token {},
InvalidOrderData {},
InsufficientOpenPositionToClose {
intended_close_amount: Decimal,
can_be_closed: Decimal,
},
InvalidDenom {
unsupported_denom: String,
},
TwapNotExist {},
OrderNotFound {},
UnwhitelistedUser {},
InsufficientLiquidity {},
}Variants§
Std(StdError)
Fields
SemVer(String)
InsufficientFundsSend
Fields
UnexpectedError
Fields
InsufficientCollateral
Fields
PrematureLiquidation
Fields
DuplicatedLiquidation
Fields
FailedLiquidation
Fields
FailedToSerialize
FailedToBinary
FailedToGetEquityAndTotalMarketValue
FailedToGetInsuranceFund
Fields
FailedToGetOrder
FailedToFetchBalances
InsufficientBalance
Fields
InsufficientBalanceForFundingPayment
Fields
InvalidCoinType
Fields
InvalidPositionEffect
Fields
InvalidPositionDirection
Fields
Invalidcw20token
Fields
InvalidOrderData
Fields
InsufficientOpenPositionToClose
InvalidDenom
TwapNotExist
Fields
OrderNotFound
Fields
UnwhitelistedUser
Fields
InsufficientLiquidity
Fields
Trait Implementations§
source§impl Debug for ContractError
impl Debug for ContractError
source§impl Display for ContractError
impl Display for ContractError
source§impl Error for ContractError
impl Error for ContractError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
source§impl From<Error> for ContractError
impl From<Error> for ContractError
source§impl From<StdError> for ContractError
impl From<StdError> for ContractError
source§impl PartialEq<ContractError> for ContractError
impl PartialEq<ContractError> for ContractError
source§fn eq(&self, other: &ContractError) -> bool
fn eq(&self, other: &ContractError) -> bool
This method tests for
self and other values to be equal, and is used
by ==.