pub struct GGData {Show 13 fields
pub current_user: Option<Box<GGUser>>,
pub entrant: Option<Box<GGEntrant>>,
pub event: Option<Box<GGEvent>>,
pub participant: Option<Box<GGParticipant>>,
pub phase: Option<Box<GGPhase>>,
pub phase_group: Option<Box<GGPhaseGroup>>,
pub player: Option<Box<GGPlayer>>,
pub set: Option<Box<GGSet>>,
pub tournament: Option<Box<GGTournament>>,
pub tournaments: Option<Box<GGTournamentConnection>>,
pub user: Option<Box<GGUser>>,
pub videogame: Option<Box<GGVideogame>>,
pub videogames: Option<Box<GGVideogameConnection>>,
}
Expand description
Equivalent for start.gg Query.
Each element in the structure is optional, allowing a user to only query values they want. Given each is an option and not a requirement, a method is included for each element with the same name. These methods will unwrap and return the proper value without any unwrapping or references needed. Certain methods (see tournaments()) will return a vector of the data type instead of a connection to a vector, done to simplify the API and make the start.gg api easier to work with.
Fields§
§current_user: Option<Box<GGUser>>
§entrant: Option<Box<GGEntrant>>
§event: Option<Box<GGEvent>>
§participant: Option<Box<GGParticipant>>
§phase: Option<Box<GGPhase>>
§phase_group: Option<Box<GGPhaseGroup>>
§player: Option<Box<GGPlayer>>
§set: Option<Box<GGSet>>
§tournament: Option<Box<GGTournament>>
§tournaments: Option<Box<GGTournamentConnection>>
§user: Option<Box<GGUser>>
§videogame: Option<Box<GGVideogame>>
§videogames: Option<Box<GGVideogameConnection>>
Implementations§
Source§impl GGData
impl GGData
Sourcepub fn current_user(&self) -> GGUser
pub fn current_user(&self) -> GGUser
Returns the current user.
Returns an empty user if not set or wasn’t queried.
Sourcepub fn entrant(&self) -> GGEntrant
pub fn entrant(&self) -> GGEntrant
Returns the entrant.
Returns an empty entrant if not set or wasn’t queried.
Sourcepub fn event(&self) -> GGEvent
pub fn event(&self) -> GGEvent
Returns the event.
Returns an empty event if not set or wasn’t queried.
Sourcepub fn participant(&self) -> GGParticipant
pub fn participant(&self) -> GGParticipant
Returns the participant.
Returns an empty participant if not set or wasn’t queried.
Sourcepub fn phase(&self) -> GGPhase
pub fn phase(&self) -> GGPhase
Returns the phase.
Returns an empty phase if not set or wasn’t queried.
Sourcepub fn phase_group(&self) -> GGPhaseGroup
pub fn phase_group(&self) -> GGPhaseGroup
Returns the phase group.
Returns an empty phase group if not set or wasn’t queried.
Sourcepub fn player(&self) -> GGPlayer
pub fn player(&self) -> GGPlayer
Returns the player.
Returns an empty player if not set or wasn’t queried.
Sourcepub fn tournament(&self) -> GGTournament
pub fn tournament(&self) -> GGTournament
Returns the tournament.
Returns an empty tournament if not set or wasn’t queried.
Sourcepub fn tournaments(&self) -> Vec<GGTournament>
pub fn tournaments(&self) -> Vec<GGTournament>
Returns a vector of tournaments.
Returns an empty vector if not set or wasn’t queried.
Sourcepub fn user(&self) -> GGUser
pub fn user(&self) -> GGUser
Returns the user.
Returns an empty user if not set or wasn’t queried.
Sourcepub fn videogame(&self) -> GGVideogame
pub fn videogame(&self) -> GGVideogame
Returns the videogame.
Returns an empty videogame if not set or wasn’t queried.
Sourcepub fn videogames(&self) -> Vec<GGVideogame>
pub fn videogames(&self) -> Vec<GGVideogame>
Returns a vector of videogames.
Returns an empty vector if not set or wasn’t queried.