pub struct Keyed<Key, Value> {
pub key: Key,
pub value: Value,
}Expand description
A keyed value.
eg/ Keyed<InstrumentIndex, Instrument>
Fields§
§key: Key§value: ValueImplementations§
Trait Implementations§
Source§impl<'de, Key, Value> Deserialize<'de> for Keyed<Key, Value>where
Key: Deserialize<'de>,
Value: Deserialize<'de>,
impl<'de, Key, Value> Deserialize<'de> for Keyed<Key, Value>where
Key: Deserialize<'de>,
Value: Deserialize<'de>,
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<Ass, Asset, T> From<(ExchangeId, Ass, T)> for Keyed<ExchangeAsset<Asset>, T>where
Ass: Into<Asset>,
impl<Ass, Asset, T> From<(ExchangeId, Ass, T)> for Keyed<ExchangeAsset<Asset>, T>where
Ass: Into<Asset>,
Source§fn from((exchange, asset, value): (ExchangeId, Ass, T)) -> Self
fn from((exchange, asset, value): (ExchangeId, Ass, T)) -> Self
Converts to this type from the input type.
Source§impl<Key: Ord, Value: Ord> Ord for Keyed<Key, Value>
impl<Key: Ord, Value: Ord> Ord for Keyed<Key, Value>
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<Key: PartialOrd, Value: PartialOrd> PartialOrd for Keyed<Key, Value>
impl<Key: PartialOrd, Value: PartialOrd> PartialOrd for Keyed<Key, Value>
impl<Key: Copy, Value: Copy> Copy for Keyed<Key, Value>
impl<Key: Eq, Value: Eq> Eq for Keyed<Key, Value>
impl<Key, Value> StructuralPartialEq for Keyed<Key, Value>
Auto Trait Implementations§
impl<Key, Value> Freeze for Keyed<Key, Value>
impl<Key, Value> RefUnwindSafe for Keyed<Key, Value>where
Key: RefUnwindSafe,
Value: RefUnwindSafe,
impl<Key, Value> Send for Keyed<Key, Value>
impl<Key, Value> Sync for Keyed<Key, Value>
impl<Key, Value> Unpin for Keyed<Key, Value>
impl<Key, Value> UnwindSafe for Keyed<Key, Value>where
Key: UnwindSafe,
Value: 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