remove debug
This commit is contained in:
parent
71512c08e6
commit
0982c30f7a
3 changed files with 23 additions and 23 deletions
|
@ -9,18 +9,18 @@ use crate::data_source::{DataSource, Stat};
|
|||
use crate::ChampInfo;
|
||||
use crate::Champion;
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct BuildResponse {
|
||||
lol: Lol,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct Lol {
|
||||
#[serde(rename = "championsReport")]
|
||||
champions_report: Vec<ChampionReport>,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct ChampionReport {
|
||||
champion_id: u32,
|
||||
role: String,
|
||||
|
@ -28,7 +28,7 @@ struct ChampionReport {
|
|||
stats: Stats,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct Stats {
|
||||
starting_items: Build,
|
||||
core_builds: Build,
|
||||
|
@ -45,7 +45,7 @@ struct Stats {
|
|||
assists: u32,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct Build {
|
||||
build: Vec<u32>,
|
||||
win_rate: f64,
|
||||
|
|
|
@ -12,31 +12,31 @@ pub struct KBDataSource {
|
|||
token: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct ChampionResponse {
|
||||
patches: Vec<Patch>,
|
||||
//patches: Vec<Patch>,
|
||||
champions: Vec<Champion>,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct Patch {
|
||||
enabled: bool,
|
||||
//enabled: bool,
|
||||
#[serde(rename = "patchVersion")]
|
||||
patch_version: String,
|
||||
patchid: u32,
|
||||
start: String,
|
||||
//patchid: u32,
|
||||
//start: String,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct Champion {
|
||||
id: u32,
|
||||
name: String,
|
||||
#[serde(rename = "className")]
|
||||
classname: String,
|
||||
//name: String,
|
||||
//#[serde(rename = "className")]
|
||||
//classname: String,
|
||||
builds: Option<Position>,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct Position {
|
||||
bot: u16,
|
||||
jungle: u16,
|
||||
|
@ -45,12 +45,12 @@ struct Position {
|
|||
top: u16,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct BuildResponse {
|
||||
builds2: Vec<KBBuild>,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct KBBuild {
|
||||
position: String,
|
||||
item0: KBItem,
|
||||
|
@ -80,14 +80,14 @@ struct KBBuild {
|
|||
patch: Patch,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct KBItem {
|
||||
#[serde(rename = "itemId")]
|
||||
item_id: u32,
|
||||
name: String,
|
||||
//name: String,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct Summoner {
|
||||
name: String,
|
||||
}
|
||||
|
|
|
@ -8,12 +8,12 @@ use crate::Champion as ChampionLoL;
|
|||
|
||||
pub struct PBDataSource;
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct ChampionResponse {
|
||||
champions: Vec<Champion>,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Debug)]
|
||||
#[derive(Deserialize)]
|
||||
struct Champion {
|
||||
key: Option<String>,
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue