pub struct BankClient { /* private fields */ }This crate has been marked for formal inclusion in the Agave Unstable API. From v4.0.0 onward, the agave-unstable-api crate feature must be specified to acknowledge use of an interface that may break without warning.
Implementationsยง
Sourceยงimpl BankClient
impl BankClient
This crate has been marked for formal inclusion in the Agave Unstable API. From v4.0.0 onward, the agave-unstable-api crate feature must be specified to acknowledge use of an interface that may break without warning.
pub fn new(bank: Bank) -> Self
This crate has been marked for formal inclusion in the Agave Unstable API. From v4.0.0 onward, the agave-unstable-api crate feature must be specified to acknowledge use of an interface that may break without warning.
pub fn set_sysvar_for_tests<T: SysvarSerialize>(&self, sysvar: &T)
This crate has been marked for formal inclusion in the Agave Unstable API. From v4.0.0 onward, the agave-unstable-api crate feature must be specified to acknowledge use of an interface that may break without warning.
Trait Implementationsยง
Sourceยงimpl AsyncClient for BankClient
impl AsyncClient for BankClient
Sourceยงfn async_send_versioned_transaction(
&self,
transaction: VersionedTransaction,
) -> Result<Signature>
fn async_send_versioned_transaction( &self, transaction: VersionedTransaction, ) -> Result<Signature>
Sourceยงfn async_send_transaction(
&self,
transaction: Transaction,
) -> Result<Signature, TransportError>
fn async_send_transaction( &self, transaction: Transaction, ) -> Result<Signature, TransportError>
Sourceยงfn async_send_batch(
&self,
transactions: Vec<Transaction>,
) -> Result<(), TransportError>
fn async_send_batch( &self, transactions: Vec<Transaction>, ) -> Result<(), TransportError>
Sourceยงfn async_send_versioned_transaction_batch(
&self,
transactions: Vec<VersionedTransaction>,
) -> Result<(), TransportError>
fn async_send_versioned_transaction_batch( &self, transactions: Vec<VersionedTransaction>, ) -> Result<(), TransportError>
Sourceยงfn async_send_message<T>(
&self,
keypairs: &T,
message: Message,
recent_blockhash: Hash,
) -> Result<Signature, TransportError>
fn async_send_message<T>( &self, keypairs: &T, message: Message, recent_blockhash: Hash, ) -> Result<Signature, TransportError>
Sourceยงfn async_send_instruction(
&self,
keypair: &Keypair,
instruction: Instruction,
recent_blockhash: Hash,
) -> Result<Signature, TransportError>
fn async_send_instruction( &self, keypair: &Keypair, instruction: Instruction, recent_blockhash: Hash, ) -> Result<Signature, TransportError>
Sourceยงfn async_transfer(
&self,
lamports: u64,
keypair: &Keypair,
pubkey: &Address,
recent_blockhash: Hash,
) -> Result<Signature, TransportError>
fn async_transfer( &self, lamports: u64, keypair: &Keypair, pubkey: &Address, recent_blockhash: Hash, ) -> Result<Signature, TransportError>
keypair to pubkey, but donโt wait to confirm.Sourceยงimpl SyncClient for BankClient
impl SyncClient for BankClient
Sourceยงfn send_and_confirm_instruction(
&self,
keypair: &Keypair,
instruction: Instruction,
) -> Result<Signature>
fn send_and_confirm_instruction( &self, keypair: &Keypair, instruction: Instruction, ) -> Result<Signature>
Create and process a transaction from a single instruction.
Sourceยงfn transfer_and_confirm(
&self,
lamports: u64,
keypair: &Keypair,
pubkey: &Pubkey,
) -> Result<Signature>
fn transfer_and_confirm( &self, lamports: u64, keypair: &Keypair, pubkey: &Pubkey, ) -> Result<Signature>
Transfer lamports from keypair to pubkey
Sourceยงfn send_and_confirm_message<T: Signers + ?Sized>(
&self,
keypairs: &T,
message: Message,
) -> Result<Signature>
fn send_and_confirm_message<T: Signers + ?Sized>( &self, keypairs: &T, message: Message, ) -> Result<Signature>
Sourceยงfn get_account_data(&self, pubkey: &Pubkey) -> Result<Option<Vec<u8>>>
fn get_account_data(&self, pubkey: &Pubkey) -> Result<Option<Vec<u8>>>
Sourceยงfn get_account(&self, pubkey: &Pubkey) -> Result<Option<Account>>
fn get_account(&self, pubkey: &Pubkey) -> Result<Option<Account>>
Sourceยงfn get_account_with_commitment(
&self,
pubkey: &Pubkey,
_commitment_config: CommitmentConfig,
) -> Result<Option<Account>>
fn get_account_with_commitment( &self, pubkey: &Pubkey, _commitment_config: CommitmentConfig, ) -> Result<Option<Account>>
Sourceยงfn get_balance_with_commitment(
&self,
pubkey: &Pubkey,
_commitment_config: CommitmentConfig,
) -> Result<u64>
fn get_balance_with_commitment( &self, pubkey: &Pubkey, _commitment_config: CommitmentConfig, ) -> Result<u64>
fn get_minimum_balance_for_rent_exemption(&self, data_len: usize) -> Result<u64>
Sourceยงfn get_signature_status(
&self,
signature: &Signature,
) -> Result<Option<Result<()>>>
fn get_signature_status( &self, signature: &Signature, ) -> Result<Option<Result<()>>>
Sourceยงfn get_signature_status_with_commitment(
&self,
signature: &Signature,
_commitment_config: CommitmentConfig,
) -> Result<Option<Result<()>>>
fn get_signature_status_with_commitment( &self, signature: &Signature, _commitment_config: CommitmentConfig, ) -> Result<Option<Result<()>>>
Sourceยงfn get_slot_with_commitment(
&self,
_commitment_config: CommitmentConfig,
) -> Result<u64>
fn get_slot_with_commitment( &self, _commitment_config: CommitmentConfig, ) -> Result<u64>
Sourceยงfn get_transaction_count(&self) -> Result<u64>
fn get_transaction_count(&self) -> Result<u64>
Sourceยงfn get_transaction_count_with_commitment(
&self,
_commitment_config: CommitmentConfig,
) -> Result<u64>
fn get_transaction_count_with_commitment( &self, _commitment_config: CommitmentConfig, ) -> Result<u64>
Sourceยงfn poll_for_signature_confirmation(
&self,
signature: &Signature,
min_confirmed_blocks: usize,
) -> Result<usize>
fn poll_for_signature_confirmation( &self, signature: &Signature, min_confirmed_blocks: usize, ) -> Result<usize>
min_confirmed_blocksSourceยงfn poll_for_signature(&self, signature: &Signature) -> Result<()>
fn poll_for_signature(&self, signature: &Signature) -> Result<()>
fn get_epoch_info(&self) -> Result<EpochInfo>
Sourceยงfn get_latest_blockhash(&self) -> Result<Hash>
fn get_latest_blockhash(&self) -> Result<Hash>
Sourceยงfn get_latest_blockhash_with_commitment(
&self,
_commitment_config: CommitmentConfig,
) -> Result<(Hash, u64)>
fn get_latest_blockhash_with_commitment( &self, _commitment_config: CommitmentConfig, ) -> Result<(Hash, u64)>
Sourceยงfn is_blockhash_valid(
&self,
blockhash: &Hash,
_commitment_config: CommitmentConfig,
) -> Result<bool>
fn is_blockhash_valid( &self, blockhash: &Hash, _commitment_config: CommitmentConfig, ) -> Result<bool>
Auto Trait Implementationsยง
impl Freeze for BankClient
impl !RefUnwindSafe for BankClient
impl Send for BankClient
impl Sync for BankClient
impl Unpin for BankClient
impl UnsafeUnpin for BankClient
impl !UnwindSafe for BankClient
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
Sourceยงimpl<T> FmtForward for T
impl<T> FmtForward for T
Sourceยงfn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
self to use its Binary implementation when Debug-formatted.Sourceยงfn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
self to use its Display implementation when
Debug-formatted.Sourceยงfn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
self to use its LowerExp implementation when
Debug-formatted.Sourceยงfn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
self to use its LowerHex implementation when
Debug-formatted.Sourceยงfn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
self to use its Octal implementation when Debug-formatted.Sourceยงfn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
self to use its Pointer implementation when
Debug-formatted.Sourceยงfn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
self to use its UpperExp implementation when
Debug-formatted.Sourceยงfn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
self to use its UpperHex implementation when
Debug-formatted.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>
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>
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 moreSourceยงimpl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
Sourceยงfn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
Sourceยงfn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
self and passes that borrow into the pipe function. Read moreSourceยงfn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
self and passes that borrow into the pipe function. Read moreSourceยงfn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
Sourceยงfn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
Sourceยงfn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
self, then passes self.as_ref() into the pipe function.Sourceยงfn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
self, then passes self.as_mut() into the pipe
function.Sourceยงfn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
self, then passes self.deref() into the pipe function.Sourceยงimpl<T> Pointable for T
impl<T> Pointable for T
Sourceยงimpl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Sourceยงimpl<T> Tap for T
impl<T> Tap for T
Sourceยงfn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Borrow<B> of a value. Read moreSourceยงfn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
BorrowMut<B> of a value. Read moreSourceยงfn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
AsRef<R> view of a value. Read moreSourceยงfn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
AsMut<R> view of a value. Read moreSourceยงfn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Deref::Target of a value. Read moreSourceยงfn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Deref::Target of a value. Read moreSourceยงfn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
.tap() only in debug builds, and is erased in release builds.Sourceยงfn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
.tap_mut() only in debug builds, and is erased in release
builds.Sourceยงfn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
.tap_borrow() only in debug builds, and is erased in release
builds.Sourceยงfn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
.tap_borrow_mut() only in debug builds, and is erased in release
builds.Sourceยงfn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
.tap_ref() only in debug builds, and is erased in release
builds.Sourceยงfn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
.tap_ref_mut() only in debug builds, and is erased in release
builds.Sourceยงfn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
.tap_deref() only in debug builds, and is erased in release
builds.