Struct solana_runtime::bank_client::BankClient[][src]

pub struct BankClient { /* fields omitted */ }

Implementations

impl BankClient[src]

pub fn new_shared(bank: &Arc<Bank>) -> Self[src]

pub fn new(bank: Bank) -> Self[src]

Trait Implementations

impl AsyncClient for BankClient[src]

fn async_transfer(
    &self,
    lamports: u64,
    keypair: &Keypair,
    pubkey: &Pubkey,
    recent_blockhash: Hash
) -> Result<Signature>
[src]

Transfer lamports from keypair to pubkey

fn async_send_transaction(&self, transaction: Transaction) -> Result<Signature>[src]

Send a signed transaction, but don’t wait to see if the server accepted it.

fn async_send_message<T: Signers>(
    &self,
    keypairs: &T,
    message: Message,
    recent_blockhash: Hash
) -> Result<Signature>
[src]

Create a transaction from the given message, and send it to the server, but don’t wait for to see if the server accepted it. Read more

fn async_send_instruction(
    &self,
    keypair: &Keypair,
    instruction: Instruction,
    recent_blockhash: Hash
) -> Result<Signature>
[src]

Create a transaction from a single instruction that only requires a single signer. Then send it to the server, but don’t wait for a reply. Read more

impl Client for BankClient[src]

fn tpu_addr(&self) -> String[src]

impl SyncClient for BankClient[src]

fn send_and_confirm_instruction(
    &self,
    keypair: &Keypair,
    instruction: Instruction
) -> Result<Signature>
[src]

Create and process a transaction from a single instruction.

fn transfer_and_confirm(
    &self,
    lamports: u64,
    keypair: &Keypair,
    pubkey: &Pubkey
) -> Result<Signature>
[src]

Transfer lamports from keypair to pubkey

fn send_and_confirm_message<T: Signers>(
    &self,
    keypairs: &T,
    message: Message
) -> Result<Signature>
[src]

Create a transaction from the given message, and send it to the server, retrying as-needed. Read more

fn get_account_data(&self, pubkey: &Pubkey) -> Result<Option<Vec<u8>>>[src]

Get an account or None if not found.

fn get_account(&self, pubkey: &Pubkey) -> Result<Option<Account>>[src]

Get an account or None if not found.

fn get_account_with_commitment(
    &self,
    pubkey: &Pubkey,
    _commitment_config: CommitmentConfig
) -> Result<Option<Account>>
[src]

Get an account or None if not found. Uses explicit commitment configuration.

fn get_balance(&self, pubkey: &Pubkey) -> Result<u64>[src]

Get account balance or 0 if not found.

fn get_balance_with_commitment(
    &self,
    pubkey: &Pubkey,
    _commitment_config: CommitmentConfig
) -> Result<u64>
[src]

Get account balance or 0 if not found. Uses explicit commitment configuration.

fn get_minimum_balance_for_rent_exemption(&self, data_len: usize) -> Result<u64>[src]

fn get_recent_blockhash(&self) -> Result<(Hash, FeeCalculator)>[src]

Get recent blockhash

fn get_recent_blockhash_with_commitment(
    &self,
    _commitment_config: CommitmentConfig
) -> Result<(Hash, FeeCalculator, u64)>
[src]

Get recent blockhash. Uses explicit commitment configuration.

fn get_fee_calculator_for_blockhash(
    &self,
    blockhash: &Hash
) -> Result<Option<FeeCalculator>>
[src]

Get Some(FeeCalculator) associated with blockhash if it is still in the BlockhashQueue, otherwise None` Read more

fn get_fee_rate_governor(&self) -> Result<FeeRateGovernor>[src]

Get recent fee rate governor

fn get_signature_status(
    &self,
    signature: &Signature
) -> Result<Option<Result<()>>>
[src]

Get signature status.

fn get_signature_status_with_commitment(
    &self,
    signature: &Signature,
    _commitment_config: CommitmentConfig
) -> Result<Option<Result<()>>>
[src]

Get signature status. Uses explicit commitment configuration.

fn get_slot(&self) -> Result<u64>[src]

Get last known slot

fn get_slot_with_commitment(
    &self,
    _commitment_config: CommitmentConfig
) -> Result<u64>
[src]

Get last known slot. Uses explicit commitment configuration.

fn get_transaction_count(&self) -> Result<u64>[src]

Get transaction count

fn get_transaction_count_with_commitment(
    &self,
    _commitment_config: CommitmentConfig
) -> Result<u64>
[src]

Get transaction count. Uses explicit commitment configuration.

fn poll_for_signature_confirmation(
    &self,
    signature: &Signature,
    min_confirmed_blocks: usize
) -> Result<usize>
[src]

Poll until the signature has been confirmed by at least min_confirmed_blocks

fn poll_for_signature(&self, signature: &Signature) -> Result<()>[src]

Poll to confirm a transaction.

fn get_new_blockhash(&self, blockhash: &Hash) -> Result<(Hash, FeeCalculator)>[src]

fn get_epoch_info(&self) -> Result<EpochInfo>[src]

Auto Trait Implementations

Blanket Implementations

impl<T> AbiExample for T[src]

pub default fn example() -> T[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T> Instrument for T[src]

fn instrument(self, span: Span) -> Instrumented<Self>[src]

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

fn in_current_span(self) -> Instrumented<Self>[src]

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> Pointable for T

pub const ALIGN: usize

The alignment of pointer.

type Init = T

The type for initializers.

pub unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more

pub unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more

pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more

pub unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

pub fn vzip(self) -> V