Struct ic_utils::canister::AsyncCallBuilder
source · pub struct AsyncCallBuilder<'agent, 'canister> { /* private fields */ }
Expand description
A builder for an asynchronous call (ie. update) to the Internet Computer.
See AsyncCaller for a description of this structure.
Implementations§
source§impl<'agent: 'canister, 'canister> AsyncCallBuilder<'agent, 'canister>
impl<'agent: 'canister, 'canister> AsyncCallBuilder<'agent, 'canister>
sourcepub fn with_arg<Argument>(self, arg: Argument) -> Self
pub fn with_arg<Argument>(self, arg: Argument) -> Self
Set the argument with Candid argument. Can be called at most once.
sourcepub fn with_args(self, tuple: impl ArgumentEncoder) -> Self
pub fn with_args(self, tuple: impl ArgumentEncoder) -> Self
Set the argument with multiple arguments as tuple. Can be called at most once.
sourcepub fn with_arg_raw(self, arg: Vec<u8>) -> Self
pub fn with_arg_raw(self, arg: Vec<u8>) -> Self
Set the argument with raw argument bytes. Can be called at most once.
sourcepub fn with_effective_canister_id(self, canister_id: Principal) -> Self
pub fn with_effective_canister_id(self, canister_id: Principal) -> Self
Sets the effective canister ID of the destination.
sourcepub fn build<Output>(self) -> AsyncCaller<'agent, Output>
pub fn build<Output>(self) -> AsyncCaller<'agent, Output>
Builds an AsyncCaller from this builder’s state.
Trait Implementations§
Auto Trait Implementations§
impl<'agent, 'canister> Freeze for AsyncCallBuilder<'agent, 'canister>
impl<'agent, 'canister> !RefUnwindSafe for AsyncCallBuilder<'agent, 'canister>
impl<'agent, 'canister> Send for AsyncCallBuilder<'agent, 'canister>
impl<'agent, 'canister> Sync for AsyncCallBuilder<'agent, 'canister>
impl<'agent, 'canister> Unpin for AsyncCallBuilder<'agent, 'canister>
impl<'agent, 'canister> !UnwindSafe for AsyncCallBuilder<'agent, 'canister>
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