pub enum WasmResult {
Reply(Vec<u8>),
Reject(String),
}Expand description
This struct describes the different types that executing a Wasm function in a canister can produce
Variants§
Reply(Vec<u8>)
Raw response, returned in a “happy” case
Reject(String)
Returned with an error message when the canister decides to reject the message
Trait Implementations§
Source§impl Clone for WasmResult
impl Clone for WasmResult
Source§fn clone(&self) -> WasmResult
fn clone(&self) -> WasmResult
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for WasmResult
impl Debug for WasmResult
Source§impl<'de> Deserialize<'de> for WasmResult
impl<'de> Deserialize<'de> for WasmResult
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
Source§impl Hash for WasmResult
impl Hash for WasmResult
Source§impl PartialEq for WasmResult
impl PartialEq for WasmResult
Source§impl Serialize for WasmResult
impl Serialize for WasmResult
impl Eq for WasmResult
impl StructuralPartialEq for WasmResult
Auto Trait Implementations§
impl Freeze for WasmResult
impl RefUnwindSafe for WasmResult
impl Send for WasmResult
impl Sync for WasmResult
impl Unpin for WasmResult
impl UnwindSafe for WasmResult
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