Struct ethcontract::errors::MethodError
source · pub struct MethodError {
pub signature: String,
pub inner: ExecutionError,
}Expand description
Error that can occur while executing a contract call or transaction.
Fields§
§signature: StringThe signature of the failed method.
inner: ExecutionErrorThe inner execution error that for the method transaction that failed.
Implementations§
source§impl MethodError
impl MethodError
sourcepub fn new<I: Into<ExecutionError>>(function: &Function, inner: I) -> Self
pub fn new<I: Into<ExecutionError>>(function: &Function, inner: I) -> Self
Create a new MethodError from an ABI function specification and an
inner ExecutionError.
sourcepub fn from_parts(signature: String, inner: ExecutionError) -> Self
pub fn from_parts(signature: String, inner: ExecutionError) -> Self
Create a MethodError from its signature and inner ExecutionError.
Trait Implementations§
source§impl Debug for MethodError
impl Debug for MethodError
source§impl Display for MethodError
impl Display for MethodError
source§impl Error for MethodError
impl Error for MethodError
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()
Auto Trait Implementations§
impl Freeze for MethodError
impl !RefUnwindSafe for MethodError
impl Send for MethodError
impl Sync for MethodError
impl Unpin for MethodError
impl !UnwindSafe for MethodError
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