pub struct MoversUpdate {
pub actives: Vec<MarketMover>,
pub gainers: Vec<MarketMover>,
pub losers: Vec<MarketMover>,
pub timestamp: DateTime<Utc>,
}Expand description
Market movers update containing actives, gainers, and losers.
Fields§
§actives: Vec<MarketMover>Most active stocks
gainers: Vec<MarketMover>Top gaining stocks
losers: Vec<MarketMover>Top losing stocks
timestamp: DateTime<Utc>Timestamp of the update
Implementations§
Source§impl MoversUpdate
impl MoversUpdate
Sourcepub fn new(
actives: Vec<MarketMover>,
gainers: Vec<MarketMover>,
losers: Vec<MarketMover>,
) -> Self
pub fn new( actives: Vec<MarketMover>, gainers: Vec<MarketMover>, losers: Vec<MarketMover>, ) -> Self
Create a new MoversUpdate with current timestamp.
Sourcepub fn with_timestamp(
actives: Vec<MarketMover>,
gainers: Vec<MarketMover>,
losers: Vec<MarketMover>,
timestamp: DateTime<Utc>,
) -> Self
pub fn with_timestamp( actives: Vec<MarketMover>, gainers: Vec<MarketMover>, losers: Vec<MarketMover>, timestamp: DateTime<Utc>, ) -> Self
Create a new MoversUpdate with a specific timestamp.
Trait Implementations§
Source§impl Clone for MoversUpdate
impl Clone for MoversUpdate
Source§fn clone(&self) -> MoversUpdate
fn clone(&self) -> MoversUpdate
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 moreSource§impl Debug for MoversUpdate
impl Debug for MoversUpdate
Source§impl<'de> Deserialize<'de> for MoversUpdate
impl<'de> Deserialize<'de> for MoversUpdate
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
Auto Trait Implementations§
impl Freeze for MoversUpdate
impl RefUnwindSafe for MoversUpdate
impl Send for MoversUpdate
impl Sync for MoversUpdate
impl Unpin for MoversUpdate
impl UnsafeUnpin for MoversUpdate
impl UnwindSafe for MoversUpdate
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