pub struct Snapshot { /* private fields */ }Implementations§
Source§impl Snapshot
impl Snapshot
Sourcepub fn stats_available(&self, slate_id: &SlateId) -> bool
pub fn stats_available(&self, slate_id: &SlateId) -> bool
Player and team stats cover both sides of every slate game in this publication. This does not guarantee that the games are final.
Sourcepub fn slates(&self) -> impl Iterator<Item = &Slate> + '_
pub fn slates(&self) -> impl Iterator<Item = &Slate> + '_
All slates with salaried players in ascending order
Sourcepub fn current_week_slates(&self) -> impl Iterator<Item = &Slate> + '_
pub fn current_week_slates(&self) -> impl Iterator<Item = &Slate> + '_
Latest populated week’s slates in ID order. Only these carry injuries.
Sourcepub fn current_slate(&self) -> Option<&Slate>
pub fn current_slate(&self) -> Option<&Slate>
Current slate, fixed at build time.
Sourcepub fn slate(&self, id: &SlateId) -> Option<&Slate>
pub fn slate(&self, id: &SlateId) -> Option<&Slate>
The slate with this id, or None when it has no salaried players.
Sourcepub fn games_for_slate(&self, slate_id: &SlateId) -> &[Game]
pub fn games_for_slate(&self, slate_id: &SlateId) -> &[Game]
The stored slate’s games as captured at build time, independent of
whether the slate resolves to salaried players: known kickoffs
ascending, unknown kickoffs last, game id breaking ties. None for the
slate itself does not make this empty. Unknown ids and slates with no
membership yield an empty slice.
Sourcepub fn players_for_slate(
&self,
slate_id: &SlateId,
) -> Option<&HashMap<NflPlayerId, SalariedPlayer>>
pub fn players_for_slate( &self, slate_id: &SlateId, ) -> Option<&HashMap<NflPlayerId, SalariedPlayer>>
Player-only index for slate_id; None when unpopulated.
All positions, no flex duplicates, no defenses.
Sourcepub fn player(
&self,
slate_id: &SlateId,
id: &NflPlayerId,
) -> Option<&SalariedPlayer>
pub fn player( &self, slate_id: &SlateId, id: &NflPlayerId, ) -> Option<&SalariedPlayer>
The player with this gsis id on slate_id, or None when the slate
has no such player.
Sourcepub fn defense(
&self,
slate_id: &SlateId,
team: &TeamAbbr,
) -> Option<&SalariedPlayer>
pub fn defense( &self, slate_id: &SlateId, team: &TeamAbbr, ) -> Option<&SalariedPlayer>
The defense with this team on slate_id, or None when the slate has
no such defense.
Sourcepub fn salaried_player(
&self,
slate_id: &SlateId,
value: &PlayerOrDefenseId,
) -> Option<&SalariedPlayer>
pub fn salaried_player( &self, slate_id: &SlateId, value: &PlayerOrDefenseId, ) -> Option<&SalariedPlayer>
The salaried row for a player or a defense, whichever the id names.
pub fn salaried_players_for_position( &self, slate_id: &SlateId, pos: &DfsPositionSlotType, ) -> &[SalariedPlayer]
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Snapshot
impl RefUnwindSafe for Snapshot
impl Send for Snapshot
impl Sync for Snapshot
impl Unpin for Snapshot
impl UnsafeUnpin for Snapshot
impl UnwindSafe for Snapshot
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
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
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> ⓘ
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> ⓘ
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