#[repr(C)]pub struct TradePrices {
pub index: TradePrice,
pub long: TradePrice,
pub short: TradePrice,
}
Expand description
Prices.
Fields§
§index: TradePrice
Index token price.
long: TradePrice
Long token price.
short: TradePrice
Short token price.
Trait Implementations§
Source§impl BorshDeserialize for TradePriceswhere
TradePrice: BorshDeserialize,
impl BorshDeserialize for TradePriceswhere
TradePrice: BorshDeserialize,
fn deserialize_reader<R: Read>(reader: &mut R) -> Result<Self, Error>
§fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
Deserializes this instance from a given slice of bytes.
Updates the buffer to point at the remaining bytes.
§fn try_from_slice(v: &[u8]) -> Result<Self, Error>
fn try_from_slice(v: &[u8]) -> Result<Self, Error>
Deserialize this instance from a slice of bytes.
fn try_from_reader<R>(reader: &mut R) -> Result<Self, Error>where
R: Read,
Source§impl BorshSerialize for TradePriceswhere
TradePrice: BorshSerialize,
impl BorshSerialize for TradePriceswhere
TradePrice: BorshSerialize,
Source§impl Clone for TradePrices
impl Clone for TradePrices
Source§fn clone(&self) -> TradePrices
fn clone(&self) -> TradePrices
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for TradePrices
impl Debug for TradePrices
Source§impl<'de> Deserialize<'de> for TradePrices
impl<'de> Deserialize<'de> for TradePrices
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for TradePrices
impl Serialize for TradePrices
Source§impl Space for TradePrices
impl Space for TradePrices
const INIT_SPACE: usize = 96usize
impl Copy for TradePrices
impl Pod for TradePrices
Auto Trait Implementations§
impl Freeze for TradePrices
impl RefUnwindSafe for TradePrices
impl Send for TradePrices
impl Sync for TradePrices
impl Unpin for TradePrices
impl UnwindSafe for TradePrices
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
§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
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
.§fn 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
.Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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