pub struct VmError {
pub category: VmErrorCategory,
pub status: String,
pub abort_code: Option<u64>,
pub location: Option<String>,
}Expand description
Detailed VM error information.
Fields§
§category: VmErrorCategoryError category.
status: StringThe raw VM status string.
abort_code: Option<u64>Abort code (if applicable).
location: Option<String>Location of the error (module::function).
Implementations§
Source§impl VmError
impl VmError
Sourcepub fn is_insufficient_balance(&self) -> bool
pub fn is_insufficient_balance(&self) -> bool
Returns true if this is an insufficient balance error.
Sourcepub fn is_sequence_number_error(&self) -> bool
pub fn is_sequence_number_error(&self) -> bool
Returns true if this is a sequence number error.
Sourcepub fn is_out_of_gas(&self) -> bool
pub fn is_out_of_gas(&self) -> bool
Returns true if this is an out of gas error.
Sourcepub fn user_message(&self) -> String
pub fn user_message(&self) -> String
Returns a user-friendly error message.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for VmError
impl<'de> Deserialize<'de> for VmError
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for VmError
impl RefUnwindSafe for VmError
impl Send for VmError
impl Sync for VmError
impl Unpin for VmError
impl UnwindSafe for VmError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoMoveArg for Twhere
T: Serialize,
impl<T> IntoMoveArg for Twhere
T: Serialize,
Source§fn into_move_arg(self) -> Result<Vec<u8>, AptosError>
fn into_move_arg(self) -> Result<Vec<u8>, AptosError>
Converts this value into BCS-encoded bytes. Read more