pub struct NearSigner { /* private fields */ }Implementations§
Source§impl NearSigner
impl NearSigner
pub fn new( network: &NetworkConfig, account_id: &str, private_key: &str, ) -> Result<Self>
pub async fn call_contract( &self, method_name: &str, args: Value, gas: u64, deposit: u128, ) -> Result<FinalExecutionOutcomeView>
Sourcepub async fn get_tx_context(&self) -> Result<(u64, CryptoHash)>
pub async fn get_tx_context(&self) -> Result<(u64, CryptoHash)>
Get current access key nonce and latest block hash for building transactions.
Sourcepub async fn send_function_call_async(
&self,
receiver_id: &AccountId,
method_name: &str,
args: Vec<u8>,
gas: u64,
deposit: u128,
nonce: u64,
block_hash: CryptoHash,
) -> Result<CryptoHash>
pub async fn send_function_call_async( &self, receiver_id: &AccountId, method_name: &str, args: Vec<u8>, gas: u64, deposit: u128, nonce: u64, block_hash: CryptoHash, ) -> Result<CryptoHash>
Send a raw function call to an arbitrary receiver (broadcast async, does not wait). Returns the transaction hash.
Auto Trait Implementations§
impl Freeze for NearSigner
impl !RefUnwindSafe for NearSigner
impl Send for NearSigner
impl Sync for NearSigner
impl Unpin for NearSigner
impl UnsafeUnpin for NearSigner
impl !UnwindSafe for NearSigner
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> 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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more