pub struct OraclePrice {
pub value: u128,
pub decimals: u8,
}Expand description
A fixed-point oracle price: value / 10^decimals quote units per one
whole token of the priced asset (standard market convention).
Fields§
§value: u128§decimals: u8Implementations§
Source§impl OraclePrice
impl OraclePrice
Trait Implementations§
Source§impl Clone for OraclePrice
impl Clone for OraclePrice
Source§fn clone(&self) -> OraclePrice
fn clone(&self) -> OraclePrice
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for OraclePrice
Source§impl Debug for OraclePrice
impl Debug for OraclePrice
impl Eq for OraclePrice
Source§impl PartialEq for OraclePrice
impl PartialEq for OraclePrice
Source§fn eq(&self, other: &OraclePrice) -> bool
fn eq(&self, other: &OraclePrice) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for OraclePrice
Auto Trait Implementations§
impl Freeze for OraclePrice
impl RefUnwindSafe for OraclePrice
impl Send for OraclePrice
impl Sync for OraclePrice
impl Unpin for OraclePrice
impl UnsafeUnpin for OraclePrice
impl UnwindSafe for OraclePrice
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