#[repr(C)]pub struct MarkPriceUpdate {
pub instrument_id: InstrumentId,
pub value: Price,
pub ts_event: UnixNanos,
pub ts_init: UnixNanos,
}Expand description
Represents a mark price update.
Fields§
§instrument_id: InstrumentIdThe instrument ID for the mark price.
value: PriceThe mark price.
ts_event: UnixNanosUNIX timestamp (nanoseconds) when the price event occurred.
ts_init: UnixNanosUNIX timestamp (nanoseconds) when the instance was created.
Implementations§
Source§impl MarkPriceUpdate
impl MarkPriceUpdate
Sourcepub fn new(
instrument_id: InstrumentId,
value: Price,
ts_event: UnixNanos,
ts_init: UnixNanos,
) -> Self
pub fn new( instrument_id: InstrumentId, value: Price, ts_event: UnixNanos, ts_init: UnixNanos, ) -> Self
Creates a new MarkPriceUpdate instance.
Sourcepub fn get_metadata(
instrument_id: &InstrumentId,
price_precision: u8,
) -> HashMap<String, String>
pub fn get_metadata( instrument_id: &InstrumentId, price_precision: u8, ) -> HashMap<String, String>
Returns the metadata for the type, for use with serialization formats.
Sourcepub fn get_fields() -> IndexMap<String, String>
pub fn get_fields() -> IndexMap<String, String>
Returns the field map for the type, for use with Arrow schemas.
Trait Implementations§
Source§impl CatalogPathPrefix for MarkPriceUpdate
impl CatalogPathPrefix for MarkPriceUpdate
Source§fn path_prefix() -> &'static str
fn path_prefix() -> &'static str
Returns the path prefix (directory name) for this data type.
Source§impl Clone for MarkPriceUpdate
impl Clone for MarkPriceUpdate
Source§fn clone(&self) -> MarkPriceUpdate
fn clone(&self) -> MarkPriceUpdate
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 MarkPriceUpdate
Source§impl Debug for MarkPriceUpdate
impl Debug for MarkPriceUpdate
Source§impl<'de> Deserialize<'de> for MarkPriceUpdate
impl<'de> Deserialize<'de> for MarkPriceUpdate
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 Display for MarkPriceUpdate
impl Display for MarkPriceUpdate
impl Eq for MarkPriceUpdate
Source§impl From<MarkPriceUpdate> for Data
impl From<MarkPriceUpdate> for Data
Source§fn from(value: MarkPriceUpdate) -> Self
fn from(value: MarkPriceUpdate) -> Self
Converts to this type from the input type.
Source§impl HasTsInit for MarkPriceUpdate
impl HasTsInit for MarkPriceUpdate
Source§impl Hash for MarkPriceUpdate
impl Hash for MarkPriceUpdate
Source§impl PartialEq for MarkPriceUpdate
impl PartialEq for MarkPriceUpdate
Source§fn eq(&self, other: &MarkPriceUpdate) -> bool
fn eq(&self, other: &MarkPriceUpdate) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serializable for MarkPriceUpdate
impl Serializable for MarkPriceUpdate
Source§impl Serialize for MarkPriceUpdate
impl Serialize for MarkPriceUpdate
impl StructuralPartialEq for MarkPriceUpdate
Auto Trait Implementations§
impl Freeze for MarkPriceUpdate
impl RefUnwindSafe for MarkPriceUpdate
impl Send for MarkPriceUpdate
impl Sync for MarkPriceUpdate
impl Unpin for MarkPriceUpdate
impl UnsafeUnpin for MarkPriceUpdate
impl UnwindSafe for MarkPriceUpdate
Blanket Implementations§
impl<T> Allocation for T
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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.