solana_sdk::account

Trait ReadableAccount

source
pub trait ReadableAccount: Sized {
    // Required methods
    fn lamports(&self) -> u64;
    fn data(&self) -> &[u8] ;
    fn owner(&self) -> &Pubkey;
    fn executable(&self) -> bool;
    fn rent_epoch(&self) -> Epoch;

    // Provided method
    fn to_account_shared_data(&self) -> AccountSharedData { ... }
}

Required Methods§

source

fn lamports(&self) -> u64

source

fn data(&self) -> &[u8]

source

fn owner(&self) -> &Pubkey

source

fn executable(&self) -> bool

source

fn rent_epoch(&self) -> Epoch

Provided Methods§

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl ReadableAccount for Ref<'_, Account>

source§

fn lamports(&self) -> u64

source§

fn data(&self) -> &[u8]

source§

fn owner(&self) -> &Pubkey

source§

fn executable(&self) -> bool

source§

fn rent_epoch(&self) -> Epoch

source§

impl ReadableAccount for Ref<'_, AccountSharedData>

Implementors§