pub struct TieredReadableAccount<'accounts_file, M: TieredAccountMeta> {
pub meta: &'accounts_file M,
pub address: &'accounts_file Pubkey,
pub owner: &'accounts_file Pubkey,
pub index: usize,
pub account_block: &'accounts_file [u8],
}
Expand description
The struct that offers read APIs for accessing a TieredAccount.
Fields§
§meta: &'accounts_file M
TieredAccountMeta
address: &'accounts_file Pubkey
The address of the account
owner: &'accounts_file Pubkey
The address of the account owner
index: usize
The index for accessing the account inside its belonging AccountsFile
account_block: &'accounts_file [u8]
The account block that contains this account. Note that this account block may be shared with other accounts.
Implementations§
source§impl<'accounts_file, M: TieredAccountMeta> TieredReadableAccount<'accounts_file, M>
impl<'accounts_file, M: TieredAccountMeta> TieredReadableAccount<'accounts_file, M>
sourcepub fn hash(&self) -> Option<&'accounts_file AccountHash>
pub fn hash(&self) -> Option<&'accounts_file AccountHash>
Returns the hash of this account.
Trait Implementations§
source§impl<'accounts_file, M: Debug + TieredAccountMeta> Debug for TieredReadableAccount<'accounts_file, M>
impl<'accounts_file, M: Debug + TieredAccountMeta> Debug for TieredReadableAccount<'accounts_file, M>
source§impl<'accounts_file, M: PartialEq + TieredAccountMeta> PartialEq for TieredReadableAccount<'accounts_file, M>
impl<'accounts_file, M: PartialEq + TieredAccountMeta> PartialEq for TieredReadableAccount<'accounts_file, M>
source§fn eq(&self, other: &TieredReadableAccount<'accounts_file, M>) -> bool
fn eq(&self, other: &TieredReadableAccount<'accounts_file, M>) -> bool
Tests for
self
and other
values to be equal, and is used by ==
.source§impl<'accounts_file, M: TieredAccountMeta> ReadableAccount for TieredReadableAccount<'accounts_file, M>
impl<'accounts_file, M: TieredAccountMeta> ReadableAccount for TieredReadableAccount<'accounts_file, M>
source§fn executable(&self) -> bool
fn executable(&self) -> bool
Returns true if the data associated to this account is executable.
Temporarily unimplemented!() as program runtime v2 will use a different API for executable.
source§fn rent_epoch(&self) -> Epoch
fn rent_epoch(&self) -> Epoch
Returns the epoch that this account will next owe rent by parsing the specified account block. Epoch::MAX will be returned if the account is rent-exempt.
impl<'accounts_file, M: Eq + TieredAccountMeta> Eq for TieredReadableAccount<'accounts_file, M>
impl<'accounts_file, M: TieredAccountMeta> StructuralPartialEq for TieredReadableAccount<'accounts_file, M>
Auto Trait Implementations§
impl<'accounts_file, M> Freeze for TieredReadableAccount<'accounts_file, M>
impl<'accounts_file, M> RefUnwindSafe for TieredReadableAccount<'accounts_file, M>where
M: RefUnwindSafe,
impl<'accounts_file, M> Send for TieredReadableAccount<'accounts_file, M>where
M: Sync,
impl<'accounts_file, M> Sync for TieredReadableAccount<'accounts_file, M>where
M: Sync,
impl<'accounts_file, M> Unpin for TieredReadableAccount<'accounts_file, M>
impl<'accounts_file, M> UnwindSafe for TieredReadableAccount<'accounts_file, M>where
M: RefUnwindSafe,
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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