pub struct InstrumentMeta<Num> { /* private fields */ }Expand description
Instrument Meta.
Implementations§
Source§impl<Num> InstrumentMeta<Num>
impl<Num> InstrumentMeta<Num>
Sourcepub fn new(
name: impl AsRef<str>,
symbol: ExcSymbol,
attrs: Attributes<Num>,
) -> Self
pub fn new( name: impl AsRef<str>, symbol: ExcSymbol, attrs: Attributes<Num>, ) -> Self
Create a new InstrumentMeta.
Sourcepub fn instrument(&self) -> &Instrument
pub fn instrument(&self) -> &Instrument
Get instrument.
Sourcepub fn attrs(&self) -> &Attributes<Num>
pub fn attrs(&self) -> &Attributes<Num>
Get attributes.
Sourcepub fn expire(&self) -> Option<&OffsetDateTime>
pub fn expire(&self) -> Option<&OffsetDateTime>
Get the expire time.
Sourcepub fn with_expire(self, expire: impl Into<Option<OffsetDateTime>>) -> Self
pub fn with_expire(self, expire: impl Into<Option<OffsetDateTime>>) -> Self
Set the expire time.
Trait Implementations§
Source§impl<Num: Clone> Clone for InstrumentMeta<Num>
impl<Num: Clone> Clone for InstrumentMeta<Num>
Source§fn clone(&self) -> InstrumentMeta<Num>
fn clone(&self) -> InstrumentMeta<Num>
Returns a duplicate 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<Num: Debug> Debug for InstrumentMeta<Num>
impl<Num: Debug> Debug for InstrumentMeta<Num>
Source§impl<'de, Num> Deserialize<'de> for InstrumentMeta<Num>
impl<'de, Num> Deserialize<'de> for InstrumentMeta<Num>
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<Num> Display for InstrumentMeta<Num>where
Num: Display,
impl<Num> Display for InstrumentMeta<Num>where
Num: Display,
Source§impl<Num: PartialEq> PartialEq for InstrumentMeta<Num>
impl<Num: PartialEq> PartialEq for InstrumentMeta<Num>
Source§impl<Num> Serialize for InstrumentMeta<Num>
impl<Num> Serialize for InstrumentMeta<Num>
impl<Num: Eq> Eq for InstrumentMeta<Num>
impl<Num> StructuralPartialEq for InstrumentMeta<Num>
Auto Trait Implementations§
impl<Num> Freeze for InstrumentMeta<Num>where
Num: Freeze,
impl<Num> RefUnwindSafe for InstrumentMeta<Num>where
Num: RefUnwindSafe,
impl<Num> Send for InstrumentMeta<Num>where
Num: Send,
impl<Num> Sync for InstrumentMeta<Num>where
Num: Sync,
impl<Num> Unpin for InstrumentMeta<Num>where
Num: Unpin,
impl<Num> UnwindSafe for InstrumentMeta<Num>where
Num: UnwindSafe,
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