forked from mirror/Riven
parent
a9fdd84236
commit
1950f7ec98
|
@ -1,6 +1,6 @@
|
|||
[package]
|
||||
name = "riven"
|
||||
version = "0.0.3"
|
||||
version = "0.0.4"
|
||||
authors = ["Mingwei Samuel <mingwei.samuel@gmail.com>"]
|
||||
repository = "https://github.com/MingweiSamuel/Riven"
|
||||
description = "Riot API Library (WIP)"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
|
||||
// This file is automatically generated.
|
||||
// Do not directly edit.
|
||||
// Generated on 2019-10-22T05:40:37.599Z
|
||||
// Generated on 2019-10-22T06:59:44.522Z
|
||||
|
||||
use std::fmt;
|
||||
use num_derive;
|
||||
|
|
106
src/dto.rs
106
src/dto.rs
|
@ -1,7 +1,7 @@
|
|||
|
||||
// This file is automatically generated.
|
||||
// Do not directly edit.
|
||||
// Generated on 2019-10-22T05:40:37.680Z
|
||||
// Generated on 2019-10-22T06:59:44.590Z
|
||||
|
||||
// http://www.mingweisamuel.com/riotapi-schema/tool/
|
||||
// Version 0c74167e0eaaeb6de1c7e8219fecaabcf8386d1f
|
||||
|
@ -9,7 +9,7 @@
|
|||
// champion-mastery-v4
|
||||
#[allow(dead_code)]
|
||||
pub mod champion_mastery_v4 {
|
||||
/// ChampionMastery data object. This class is automatically generated.
|
||||
/// ChampionMastery data object. This struct is automatically generated.
|
||||
/// # Description
|
||||
/// This object contains single Champion Mastery information for player and champion combination.
|
||||
#[derive(Debug)]
|
||||
|
@ -48,7 +48,7 @@ pub mod champion_mastery_v4 {
|
|||
// champion-v3
|
||||
#[allow(dead_code)]
|
||||
pub mod champion_v3 {
|
||||
/// ChampionInfo data object. This class is automatically generated.
|
||||
/// ChampionInfo data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct ChampionInfo {
|
||||
|
@ -64,7 +64,7 @@ pub mod champion_v3 {
|
|||
// league-exp-v4
|
||||
#[allow(dead_code)]
|
||||
pub mod league_exp_v4 {
|
||||
/// LeagueEntry data object. This class is automatically generated.
|
||||
/// LeagueEntry data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct LeagueEntry {
|
||||
|
@ -100,7 +100,7 @@ pub mod league_exp_v4 {
|
|||
#[serde(rename = "leaguePoints")]
|
||||
pub league_points: i32,
|
||||
}
|
||||
/// MiniSeries data object. This class is automatically generated.
|
||||
/// MiniSeries data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct MiniSeries {
|
||||
|
@ -118,7 +118,7 @@ pub mod league_exp_v4 {
|
|||
// league-v4
|
||||
#[allow(dead_code)]
|
||||
pub mod league_v4 {
|
||||
/// LeagueList data object. This class is automatically generated.
|
||||
/// LeagueList data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct LeagueList {
|
||||
|
@ -133,7 +133,7 @@ pub mod league_v4 {
|
|||
#[serde(rename = "name")]
|
||||
pub name: String,
|
||||
}
|
||||
/// LeagueItem data object. This class is automatically generated.
|
||||
/// LeagueItem data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct LeagueItem {
|
||||
|
@ -163,7 +163,7 @@ pub mod league_v4 {
|
|||
#[serde(rename = "leaguePoints")]
|
||||
pub league_points: i32,
|
||||
}
|
||||
/// MiniSeries data object. This class is automatically generated.
|
||||
/// MiniSeries data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct MiniSeries {
|
||||
|
@ -176,7 +176,7 @@ pub mod league_v4 {
|
|||
#[serde(rename = "wins")]
|
||||
pub wins: i32,
|
||||
}
|
||||
/// LeagueEntry data object. This class is automatically generated.
|
||||
/// LeagueEntry data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct LeagueEntry {
|
||||
|
@ -217,7 +217,7 @@ pub mod league_v4 {
|
|||
// lol-status-v3
|
||||
#[allow(dead_code)]
|
||||
pub mod lol_status_v3 {
|
||||
/// ShardStatus data object. This class is automatically generated.
|
||||
/// ShardStatus data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct ShardStatus {
|
||||
|
@ -234,7 +234,7 @@ pub mod lol_status_v3 {
|
|||
#[serde(rename = "locales")]
|
||||
pub locales: std::vec::Vec<String>,
|
||||
}
|
||||
/// Service data object. This class is automatically generated.
|
||||
/// Service data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Service {
|
||||
|
@ -247,7 +247,7 @@ pub mod lol_status_v3 {
|
|||
#[serde(rename = "slug")]
|
||||
pub slug: String,
|
||||
}
|
||||
/// Incident data object. This class is automatically generated.
|
||||
/// Incident data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Incident {
|
||||
|
@ -260,7 +260,7 @@ pub mod lol_status_v3 {
|
|||
#[serde(rename = "updates")]
|
||||
pub updates: std::vec::Vec<Message>,
|
||||
}
|
||||
/// Message data object. This class is automatically generated.
|
||||
/// Message data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Message {
|
||||
|
@ -279,7 +279,7 @@ pub mod lol_status_v3 {
|
|||
#[serde(rename = "id")]
|
||||
pub id: String,
|
||||
}
|
||||
/// Translation data object. This class is automatically generated.
|
||||
/// Translation data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Translation {
|
||||
|
@ -295,7 +295,7 @@ pub mod lol_status_v3 {
|
|||
// match-v4
|
||||
#[allow(dead_code)]
|
||||
pub mod match_v4 {
|
||||
/// Match data object. This class is automatically generated.
|
||||
/// Match data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Match {
|
||||
|
@ -338,7 +338,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "gameCreation")]
|
||||
pub game_creation: i64,
|
||||
}
|
||||
/// ParticipantIdentity data object. This class is automatically generated.
|
||||
/// ParticipantIdentity data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct ParticipantIdentity {
|
||||
|
@ -348,7 +348,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "participantId")]
|
||||
pub participant_id: i32,
|
||||
}
|
||||
/// Player data object. This class is automatically generated.
|
||||
/// Player data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Player {
|
||||
|
@ -373,7 +373,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "accountId")]
|
||||
pub account_id: String,
|
||||
}
|
||||
/// TeamStats data object. This class is automatically generated.
|
||||
/// TeamStats data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct TeamStats {
|
||||
|
@ -427,7 +427,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "dragonKills")]
|
||||
pub dragon_kills: i32,
|
||||
}
|
||||
/// TeamBans data object. This class is automatically generated.
|
||||
/// TeamBans data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct TeamBans {
|
||||
|
@ -438,7 +438,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "championId")]
|
||||
pub champion_id: i32,
|
||||
}
|
||||
/// Participant data object. This class is automatically generated.
|
||||
/// Participant data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Participant {
|
||||
|
@ -472,7 +472,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "championId")]
|
||||
pub champion_id: i32,
|
||||
}
|
||||
/// ParticipantStats data object. This class is automatically generated.
|
||||
/// ParticipantStats data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct ParticipantStats {
|
||||
|
@ -719,7 +719,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "timeCCingOthers")]
|
||||
pub time_c_cing_others: i64,
|
||||
}
|
||||
/// Rune data object. This class is automatically generated.
|
||||
/// Rune data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Rune {
|
||||
|
@ -728,7 +728,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "rank")]
|
||||
pub rank: i32,
|
||||
}
|
||||
/// ParticipantTimeline data object. This class is automatically generated.
|
||||
/// ParticipantTimeline data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct ParticipantTimeline {
|
||||
|
@ -764,7 +764,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "damageTakenPerMinDeltas")]
|
||||
pub damage_taken_per_min_deltas: std::collections::HashMap<String, f64>,
|
||||
}
|
||||
/// Mastery data object. This class is automatically generated.
|
||||
/// Mastery data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Mastery {
|
||||
|
@ -773,7 +773,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "rank")]
|
||||
pub rank: i32,
|
||||
}
|
||||
/// Matchlist data object. This class is automatically generated.
|
||||
/// Matchlist data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Matchlist {
|
||||
|
@ -786,7 +786,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "endIndex")]
|
||||
pub end_index: i32,
|
||||
}
|
||||
/// MatchReference data object. This class is automatically generated.
|
||||
/// MatchReference data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct MatchReference {
|
||||
|
@ -807,7 +807,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "timestamp")]
|
||||
pub timestamp: i64,
|
||||
}
|
||||
/// MatchTimeline data object. This class is automatically generated.
|
||||
/// MatchTimeline data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct MatchTimeline {
|
||||
|
@ -816,7 +816,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "frameInterval")]
|
||||
pub frame_interval: i64,
|
||||
}
|
||||
/// MatchFrame data object. This class is automatically generated.
|
||||
/// MatchFrame data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct MatchFrame {
|
||||
|
@ -827,7 +827,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "events")]
|
||||
pub events: std::vec::Vec<MatchEvent>,
|
||||
}
|
||||
/// MatchParticipantFrame data object. This class is automatically generated.
|
||||
/// MatchParticipantFrame data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct MatchParticipantFrame {
|
||||
|
@ -852,7 +852,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "jungleMinionsKilled")]
|
||||
pub jungle_minions_killed: i32,
|
||||
}
|
||||
/// MatchPosition data object. This class is automatically generated.
|
||||
/// MatchPosition data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct MatchPosition {
|
||||
|
@ -861,7 +861,7 @@ pub mod match_v4 {
|
|||
#[serde(rename = "x")]
|
||||
pub x: i32,
|
||||
}
|
||||
/// MatchEvent data object. This class is automatically generated.
|
||||
/// MatchEvent data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct MatchEvent {
|
||||
|
@ -918,7 +918,7 @@ pub mod match_v4 {
|
|||
// spectator-v4
|
||||
#[allow(dead_code)]
|
||||
pub mod spectator_v4 {
|
||||
/// CurrentGameInfo data object. This class is automatically generated.
|
||||
/// CurrentGameInfo data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct CurrentGameInfo {
|
||||
|
@ -956,7 +956,7 @@ pub mod spectator_v4 {
|
|||
#[serde(rename = "gameQueueConfigId")]
|
||||
pub game_queue_config_id: i64,
|
||||
}
|
||||
/// BannedChampion data object. This class is automatically generated.
|
||||
/// BannedChampion data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct BannedChampion {
|
||||
|
@ -970,7 +970,7 @@ pub mod spectator_v4 {
|
|||
#[serde(rename = "teamId")]
|
||||
pub team_id: i64,
|
||||
}
|
||||
/// Observer data object. This class is automatically generated.
|
||||
/// Observer data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Observer {
|
||||
|
@ -978,7 +978,7 @@ pub mod spectator_v4 {
|
|||
#[serde(rename = "encryptionKey")]
|
||||
pub encryption_key: String,
|
||||
}
|
||||
/// CurrentGameParticipant data object. This class is automatically generated.
|
||||
/// CurrentGameParticipant data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct CurrentGameParticipant {
|
||||
|
@ -1013,7 +1013,7 @@ pub mod spectator_v4 {
|
|||
#[serde(rename = "summonerId")]
|
||||
pub summoner_id: String,
|
||||
}
|
||||
/// GameCustomizationObject data object. This class is automatically generated.
|
||||
/// GameCustomizationObject data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct GameCustomizationObject {
|
||||
|
@ -1024,7 +1024,7 @@ pub mod spectator_v4 {
|
|||
#[serde(rename = "content")]
|
||||
pub content: String,
|
||||
}
|
||||
/// Perks data object. This class is automatically generated.
|
||||
/// Perks data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Perks {
|
||||
|
@ -1038,7 +1038,7 @@ pub mod spectator_v4 {
|
|||
#[serde(rename = "perkSubStyle")]
|
||||
pub perk_sub_style: i64,
|
||||
}
|
||||
/// FeaturedGames data object. This class is automatically generated.
|
||||
/// FeaturedGames data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct FeaturedGames {
|
||||
|
@ -1049,7 +1049,7 @@ pub mod spectator_v4 {
|
|||
#[serde(rename = "gameList")]
|
||||
pub game_list: std::vec::Vec<FeaturedGameInfo>,
|
||||
}
|
||||
/// FeaturedGameInfo data object. This class is automatically generated.
|
||||
/// FeaturedGameInfo data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct FeaturedGameInfo {
|
||||
|
@ -1089,7 +1089,7 @@ pub mod spectator_v4 {
|
|||
#[serde(rename = "gameQueueConfigId")]
|
||||
pub game_queue_config_id: i64,
|
||||
}
|
||||
/// Participant data object. This class is automatically generated.
|
||||
/// Participant data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct Participant {
|
||||
|
@ -1120,7 +1120,7 @@ pub mod spectator_v4 {
|
|||
// summoner-v4
|
||||
#[allow(dead_code)]
|
||||
pub mod summoner_v4 {
|
||||
/// Summoner data object. This class is automatically generated.
|
||||
/// Summoner data object. This struct is automatically generated.
|
||||
/// # Description
|
||||
/// represents a summoner
|
||||
#[derive(Debug)]
|
||||
|
@ -1153,7 +1153,7 @@ pub mod summoner_v4 {
|
|||
// tournament-stub-v4
|
||||
#[allow(dead_code)]
|
||||
pub mod tournament_stub_v4 {
|
||||
/// TournamentCodeParameters data object. This class is automatically generated.
|
||||
/// TournamentCodeParameters data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct TournamentCodeParameters {
|
||||
|
@ -1179,14 +1179,14 @@ pub mod tournament_stub_v4 {
|
|||
#[serde(rename = "metadata")]
|
||||
pub metadata: String,
|
||||
}
|
||||
/// LobbyEventWrapper data object. This class is automatically generated.
|
||||
/// LobbyEventWrapper data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct LobbyEventWrapper {
|
||||
#[serde(rename = "eventList")]
|
||||
pub event_list: std::vec::Vec<LobbyEvent>,
|
||||
}
|
||||
/// LobbyEvent data object. This class is automatically generated.
|
||||
/// LobbyEvent data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct LobbyEvent {
|
||||
|
@ -1200,7 +1200,7 @@ pub mod tournament_stub_v4 {
|
|||
#[serde(rename = "timestamp")]
|
||||
pub timestamp: String,
|
||||
}
|
||||
/// ProviderRegistrationParameters data object. This class is automatically generated.
|
||||
/// ProviderRegistrationParameters data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct ProviderRegistrationParameters {
|
||||
|
@ -1212,7 +1212,7 @@ pub mod tournament_stub_v4 {
|
|||
#[serde(rename = "region")]
|
||||
pub region: String,
|
||||
}
|
||||
/// TournamentRegistrationParameters data object. This class is automatically generated.
|
||||
/// TournamentRegistrationParameters data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct TournamentRegistrationParameters {
|
||||
|
@ -1228,7 +1228,7 @@ pub mod tournament_stub_v4 {
|
|||
// tournament-v4
|
||||
#[allow(dead_code)]
|
||||
pub mod tournament_v4 {
|
||||
/// TournamentCodeParameters data object. This class is automatically generated.
|
||||
/// TournamentCodeParameters data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct TournamentCodeParameters {
|
||||
|
@ -1254,7 +1254,7 @@ pub mod tournament_v4 {
|
|||
#[serde(rename = "metadata")]
|
||||
pub metadata: String,
|
||||
}
|
||||
/// TournamentCode data object. This class is automatically generated.
|
||||
/// TournamentCode data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct TournamentCode {
|
||||
|
@ -1299,7 +1299,7 @@ pub mod tournament_v4 {
|
|||
#[serde(rename = "metaData")]
|
||||
pub meta_data: String,
|
||||
}
|
||||
/// TournamentCodeUpdateParameters data object. This class is automatically generated.
|
||||
/// TournamentCodeUpdateParameters data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct TournamentCodeUpdateParameters {
|
||||
|
@ -1319,14 +1319,14 @@ pub mod tournament_v4 {
|
|||
#[serde(rename = "mapType")]
|
||||
pub map_type: String,
|
||||
}
|
||||
/// LobbyEventWrapper data object. This class is automatically generated.
|
||||
/// LobbyEventWrapper data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct LobbyEventWrapper {
|
||||
#[serde(rename = "eventList")]
|
||||
pub event_list: std::vec::Vec<LobbyEvent>,
|
||||
}
|
||||
/// LobbyEvent data object. This class is automatically generated.
|
||||
/// LobbyEvent data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct LobbyEvent {
|
||||
|
@ -1340,7 +1340,7 @@ pub mod tournament_v4 {
|
|||
#[serde(rename = "eventType")]
|
||||
pub event_type: String,
|
||||
}
|
||||
/// ProviderRegistrationParameters data object. This class is automatically generated.
|
||||
/// ProviderRegistrationParameters data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct ProviderRegistrationParameters {
|
||||
|
@ -1352,7 +1352,7 @@ pub mod tournament_v4 {
|
|||
#[serde(rename = "region")]
|
||||
pub region: String,
|
||||
}
|
||||
/// TournamentRegistrationParameters data object. This class is automatically generated.
|
||||
/// TournamentRegistrationParameters data object. This struct is automatically generated.
|
||||
#[derive(Debug)]
|
||||
#[derive(serde::Serialize, serde::Deserialize)]
|
||||
pub struct TournamentRegistrationParameters {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
|
||||
// This file is automatically generated.
|
||||
// Do not directly edit.
|
||||
// Generated on 2019-10-22T05:40:37.693Z
|
||||
// Generated on 2019-10-22T06:59:44.598Z
|
||||
|
||||
// http://www.mingweisamuel.com/riotapi-schema/tool/
|
||||
// Version 0c74167e0eaaeb6de1c7e8219fecaabcf8386d1f
|
||||
|
@ -16,44 +16,88 @@ use crate::consts::Region;
|
|||
use crate::riot_api::RiotApi;
|
||||
|
||||
impl RiotApi {
|
||||
/// Handle for ChampionMasteryV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#champion-mastery-v4">https://developer.riotgames.com/api-methods/#champion-mastery-v4</a>
|
||||
#[inline]
|
||||
pub fn champion_mastery_v4(&self) -> ChampionMasteryV4 {
|
||||
ChampionMasteryV4 { base: self }
|
||||
}
|
||||
/// Handle for ChampionV3 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#champion-v3">https://developer.riotgames.com/api-methods/#champion-v3</a>
|
||||
#[inline]
|
||||
pub fn champion_v3(&self) -> ChampionV3 {
|
||||
ChampionV3 { base: self }
|
||||
}
|
||||
/// Handle for LeagueExpV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#league-exp-v4">https://developer.riotgames.com/api-methods/#league-exp-v4</a>
|
||||
#[inline]
|
||||
pub fn league_exp_v4(&self) -> LeagueExpV4 {
|
||||
LeagueExpV4 { base: self }
|
||||
}
|
||||
/// Handle for LeagueV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#league-v4">https://developer.riotgames.com/api-methods/#league-v4</a>
|
||||
#[inline]
|
||||
pub fn league_v4(&self) -> LeagueV4 {
|
||||
LeagueV4 { base: self }
|
||||
}
|
||||
/// Handle for LolStatusV3 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#lol-status-v3">https://developer.riotgames.com/api-methods/#lol-status-v3</a>
|
||||
#[inline]
|
||||
pub fn lol_status_v3(&self) -> LolStatusV3 {
|
||||
LolStatusV3 { base: self }
|
||||
}
|
||||
/// Handle for MatchV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#match-v4">https://developer.riotgames.com/api-methods/#match-v4</a>
|
||||
#[inline]
|
||||
pub fn match_v4(&self) -> MatchV4 {
|
||||
MatchV4 { base: self }
|
||||
}
|
||||
/// Handle for SpectatorV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#spectator-v4">https://developer.riotgames.com/api-methods/#spectator-v4</a>
|
||||
#[inline]
|
||||
pub fn spectator_v4(&self) -> SpectatorV4 {
|
||||
SpectatorV4 { base: self }
|
||||
}
|
||||
/// Handle for SummonerV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#summoner-v4">https://developer.riotgames.com/api-methods/#summoner-v4</a>
|
||||
#[inline]
|
||||
pub fn summoner_v4(&self) -> SummonerV4 {
|
||||
SummonerV4 { base: self }
|
||||
}
|
||||
/// Handle for ThirdPartyCodeV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#third-party-code-v4">https://developer.riotgames.com/api-methods/#third-party-code-v4</a>
|
||||
#[inline]
|
||||
pub fn third_party_code_v4(&self) -> ThirdPartyCodeV4 {
|
||||
ThirdPartyCodeV4 { base: self }
|
||||
}
|
||||
/// Handle for TournamentStubV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#tournament-stub-v4">https://developer.riotgames.com/api-methods/#tournament-stub-v4</a>
|
||||
#[inline]
|
||||
pub fn tournament_stub_v4(&self) -> TournamentStubV4 {
|
||||
TournamentStubV4 { base: self }
|
||||
}
|
||||
/// Handle for TournamentV4 endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#tournament-v4">https://developer.riotgames.com/api-methods/#tournament-v4</a>
|
||||
#[inline]
|
||||
pub fn tournament_v4(&self) -> TournamentV4 {
|
||||
TournamentV4 { base: self }
|
||||
}
|
||||
}
|
||||
|
||||
/// ChampionMasteryV4 endpoints. This class is automatically generated.<para />
|
||||
/// ChampionMasteryV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#champion-mastery-v4">https://developer.riotgames.com/api-methods/#champion-mastery-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#champion-mastery-v4">https://developer.riotgames.com/api-methods/#champion-mastery-v4</a>
|
||||
pub struct ChampionMasteryV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -100,9 +144,9 @@ impl<'a> ChampionMasteryV4<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// ChampionV3 endpoints. This class is automatically generated.<para />
|
||||
/// ChampionV3 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#champion-v3">https://developer.riotgames.com/api-methods/#champion-v3</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#champion-v3">https://developer.riotgames.com/api-methods/#champion-v3</a>
|
||||
pub struct ChampionV3<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -121,9 +165,9 @@ impl<'a> ChampionV3<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// LeagueExpV4 endpoints. This class is automatically generated.<para />
|
||||
/// LeagueExpV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#league-exp-v4">https://developer.riotgames.com/api-methods/#league-exp-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#league-exp-v4">https://developer.riotgames.com/api-methods/#league-exp-v4</a>
|
||||
pub struct LeagueExpV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -149,9 +193,9 @@ impl<'a> LeagueExpV4<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// LeagueV4 endpoints. This class is automatically generated.<para />
|
||||
/// LeagueV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#league-v4">https://developer.riotgames.com/api-methods/#league-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#league-v4">https://developer.riotgames.com/api-methods/#league-v4</a>
|
||||
pub struct LeagueV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -242,9 +286,9 @@ impl<'a> LeagueV4<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// LolStatusV3 endpoints. This class is automatically generated.<para />
|
||||
/// LolStatusV3 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#lol-status-v3">https://developer.riotgames.com/api-methods/#lol-status-v3</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#lol-status-v3">https://developer.riotgames.com/api-methods/#lol-status-v3</a>
|
||||
pub struct LolStatusV3<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -265,9 +309,9 @@ impl<'a> LolStatusV3<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// MatchV4 endpoints. This class is automatically generated.<para />
|
||||
/// MatchV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#match-v4">https://developer.riotgames.com/api-methods/#match-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#match-v4">https://developer.riotgames.com/api-methods/#match-v4</a>
|
||||
pub struct MatchV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -364,9 +408,9 @@ impl<'a> MatchV4<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// SpectatorV4 endpoints. This class is automatically generated.<para />
|
||||
/// SpectatorV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#spectator-v4">https://developer.riotgames.com/api-methods/#spectator-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#spectator-v4">https://developer.riotgames.com/api-methods/#spectator-v4</a>
|
||||
pub struct SpectatorV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -398,9 +442,9 @@ impl<'a> SpectatorV4<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// SummonerV4 endpoints. This class is automatically generated.<para />
|
||||
/// SummonerV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#summoner-v4">https://developer.riotgames.com/api-methods/#summoner-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#summoner-v4">https://developer.riotgames.com/api-methods/#summoner-v4</a>
|
||||
pub struct SummonerV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -459,9 +503,9 @@ impl<'a> SummonerV4<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// ThirdPartyCodeV4 endpoints. This class is automatically generated.<para />
|
||||
/// ThirdPartyCodeV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#third-party-code-v4">https://developer.riotgames.com/api-methods/#third-party-code-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#third-party-code-v4">https://developer.riotgames.com/api-methods/#third-party-code-v4</a>
|
||||
pub struct ThirdPartyCodeV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -481,9 +525,9 @@ impl<'a> ThirdPartyCodeV4<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// TournamentStubV4 endpoints. This class is automatically generated.<para />
|
||||
/// TournamentStubV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#tournament-stub-v4">https://developer.riotgames.com/api-methods/#tournament-stub-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#tournament-stub-v4">https://developer.riotgames.com/api-methods/#tournament-stub-v4</a>
|
||||
pub struct TournamentStubV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
@ -503,9 +547,9 @@ impl<'a> TournamentStubV4<'a> {
|
|||
|
||||
}
|
||||
|
||||
/// TournamentV4 endpoints. This class is automatically generated.<para />
|
||||
/// TournamentV4 endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#tournament-v4">https://developer.riotgames.com/api-methods/#tournament-v4</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#tournament-v4">https://developer.riotgames.com/api-methods/#tournament-v4</a>
|
||||
pub struct TournamentV4<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
|
|
@ -4,6 +4,8 @@ pub use dto::*;
|
|||
pub mod consts;
|
||||
|
||||
mod endpoints;
|
||||
pub use endpoints::*;
|
||||
|
||||
mod riot_api_config;
|
||||
pub use riot_api_config::*;
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ pub mod {{= dotUtils.changeCase.snakeCase(endpoint) }} {
|
|||
let schema = schemas[schemaKey];
|
||||
let props = schema.properties;
|
||||
}}
|
||||
/// {{= schemaName }} data object. This class is automatically generated.
|
||||
/// {{= schemaName }} data object. This struct is automatically generated.
|
||||
{{? schema.description }}
|
||||
/// # Description
|
||||
/// {{= schema.description }}
|
||||
|
|
|
@ -32,6 +32,10 @@ impl RiotApi {
|
|||
const method = dotUtils.changeCase.snakeCase(endpointName);
|
||||
const type = dotUtils.changeCase.pascalCase(endpointName);
|
||||
}}
|
||||
/// Handle for {{= type }} endpoints. This method is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#{{= endpointName }}">https://developer.riotgames.com/api-methods/#{{= endpointName }}</a>
|
||||
#[inline]
|
||||
pub fn {{= method }}(&self) -> {{= type }} {
|
||||
{{= type }} { base: self }
|
||||
}
|
||||
|
@ -44,9 +48,9 @@ impl RiotApi {
|
|||
let endpoint = dotUtils.changeCase.pascalCase(endpointName);
|
||||
}}
|
||||
|
||||
/// {{= endpoint }} endpoints. This class is automatically generated.<para />
|
||||
/// {{= endpoint }} endpoints. This struct is automatically generated.
|
||||
/// # Official API Reference
|
||||
/// a href="https://developer.riotgames.com/api-methods/#{{= endpointName }}">https://developer.riotgames.com/api-methods/#{{= endpointName }}</a>
|
||||
/// <a href="https://developer.riotgames.com/api-methods/#{{= endpointName }}">https://developer.riotgames.com/api-methods/#{{= endpointName }}</a>
|
||||
pub struct {{= endpoint }}<'a> {
|
||||
base: &'a RiotApi,
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue