pub struct MatchInfo {Show 13 fields
pub id: MatchId,
pub kind: MatchType,
pub season: Season,
pub category: Option<MatchCategory>,
pub date: DateTime<Utc>,
pub players: Box<[UserProfile]>,
pub spectators: Box<[UserProfile]>,
pub seed: Option<MatchSeedInfo>,
pub result: MatchOutcome,
pub forfeited: bool,
pub decayed: bool,
pub rank: MatchRank,
pub elo_updates: Box<[MatchEloUpdate]>,
}Expand description
Match info
Fields§
§id: MatchId§kind: MatchType§season: Season§category: Option<MatchCategory>§date: DateTime<Utc>§players: Box<[UserProfile]>§spectators: Box<[UserProfile]>§seed: Option<MatchSeedInfo>§result: MatchOutcome§forfeited: bool§decayed: bool§rank: MatchRank§elo_updates: Box<[MatchEloUpdate]>Implementations§
Source§impl MatchInfo
impl MatchInfo
Sourcepub async fn get_recent(
params: Option<&GetRecentMatchesParams<'_>>,
) -> Result<Box<[Self]>>
pub async fn get_recent( params: Option<&GetRecentMatchesParams<'_>>, ) -> Result<Box<[Self]>>
GET recent matches given params
Source§impl MatchInfo
impl MatchInfo
Sourcepub fn players(&self) -> &[UserProfile]
pub fn players(&self) -> &[UserProfile]
Users participating in the match
Sourcepub fn spectators(&self) -> &[UserProfile]
pub fn spectators(&self) -> &[UserProfile]
Users spectating the match
pub fn elo_updates(&self) -> &[MatchEloUpdate]
Trait Implementations§
Source§impl<'de> Deserialize<'de> for MatchInfo
impl<'de> Deserialize<'de> for MatchInfo
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
impl Eq for MatchInfo
impl StructuralPartialEq for MatchInfo
Auto Trait Implementations§
impl Freeze for MatchInfo
impl RefUnwindSafe for MatchInfo
impl Send for MatchInfo
impl Sync for MatchInfo
impl Unpin for MatchInfo
impl UnwindSafe for MatchInfo
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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.