Struct pyth_sdk_solana::state::ProductAccount
source · [−]#[repr(C)]pub struct ProductAccount {
pub magic: u32,
pub ver: u32,
pub atype: u32,
pub size: u32,
pub px_acc: Pubkey,
pub attr: [u8; 464],
}
Expand description
Product accounts contain metadata for a single product, such as its symbol (“Crypto.BTC/USD”) and its base/quote currencies.
Fields
magic: u32
pyth magic number
ver: u32
program version
atype: u32
account type
size: u32
price account size
px_acc: Pubkey
first price account in list
attr: [u8; 464]
key/value pairs of reference attr.
Implementations
sourceimpl ProductAccount
impl ProductAccount
pub fn iter(&self) -> AttributeIter<'_>ⓘNotable traits for AttributeIter<'a>impl<'a> Iterator for AttributeIter<'a> type Item = (&'a str, &'a str);
Trait Implementations
sourceimpl Clone for ProductAccount
impl Clone for ProductAccount
sourcefn clone(&self) -> ProductAccount
fn clone(&self) -> ProductAccount
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for ProductAccount
impl Debug for ProductAccount
sourceimpl PartialEq<ProductAccount> for ProductAccount
impl PartialEq<ProductAccount> for ProductAccount
sourcefn eq(&self, other: &ProductAccount) -> bool
fn eq(&self, other: &ProductAccount) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
impl Copy for ProductAccount
impl Eq for ProductAccount
impl Pod for ProductAccount
impl StructuralEq for ProductAccount
impl StructuralPartialEq for ProductAccount
Auto Trait Implementations
impl RefUnwindSafe for ProductAccount
impl Send for ProductAccount
impl Sync for ProductAccount
impl Unpin for ProductAccount
impl UnwindSafe for ProductAccount
Blanket Implementations
impl<T> AbiExample for T
impl<T> AbiExample for T
default fn example() -> T
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> CheckedBitPattern for T where
T: AnyBitPattern,
impl<T> CheckedBitPattern for T where
T: AnyBitPattern,
type Bits = T
type Bits = T
Self
must have the same layout as the specified Bits
except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern
. Read more
sourcefn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret bits
as &Self
. Read more