move dtos to 'models' module

pull/5/head
Mingwei Samuel 2019-11-03 10:48:45 -08:00
parent f2e70246bf
commit de8cd21e94
8 changed files with 13 additions and 9 deletions

View File

@ -9,10 +9,9 @@
// http://www.mingweisamuel.com/riotapi-schema/tool/ // http://www.mingweisamuel.com/riotapi-schema/tool/
// Version 3bd5ca30e5a7aa15963ca4366e3b6be89defe567 // Version 3bd5ca30e5a7aa15963ca4366e3b6be89defe567
//! Automatically generated endpoint handles and data transfer structs. //! Automatically generated endpoint handles.
mod dto; use crate::models::*;
pub use dto::*;
use std::future::Future; use std::future::Future;
use std::vec::Vec; use std::vec::Vec;

View File

@ -11,6 +11,8 @@ pub mod endpoints;
mod error; mod error;
pub use error::*; pub use error::*;
pub mod models;
mod req; mod req;
mod riot_api; mod riot_api;

View File

@ -9,6 +9,8 @@
// http://www.mingweisamuel.com/riotapi-schema/tool/ // http://www.mingweisamuel.com/riotapi-schema/tool/
// Version 3bd5ca30e5a7aa15963ca4366e3b6be89defe567 // Version 3bd5ca30e5a7aa15963ca4366e3b6be89defe567
//! Automatically generated data transfer structs.
/// ChampionMasteryV4 data objects. This module is automatically generated. /// ChampionMasteryV4 data objects. This module is automatically generated.
#[allow(dead_code)] #[allow(dead_code)]
pub mod champion_mastery_v4 { pub mod champion_mastery_v4 {

View File

@ -6,10 +6,9 @@
// http://www.mingweisamuel.com/riotapi-schema/tool/ // http://www.mingweisamuel.com/riotapi-schema/tool/
// Version {{= spec.info.version }} // Version {{= spec.info.version }}
//! Automatically generated endpoint handles and data transfer structs. //! Automatically generated endpoint handles.
mod dto; use crate::models::*;
pub use dto::*;
use std::future::Future; use std::future::Future;
use std::vec::Vec; use std::vec::Vec;

View File

@ -6,6 +6,8 @@
// http://www.mingweisamuel.com/riotapi-schema/tool/ // http://www.mingweisamuel.com/riotapi-schema/tool/
// Version {{= spec.info.version }} // Version {{= spec.info.version }}
//! Automatically generated data transfer structs.
{{ {{
let schemas = spec.components.schemas; let schemas = spec.components.schemas;
let schemaKeyByEndpoint = Object.keys(schemas) let schemaKeyByEndpoint = Object.keys(schemas)

View File

@ -10,7 +10,7 @@ use futures_util::future;
use colored::*; use colored::*;
use riven::consts::*; use riven::consts::*;
use riven::endpoints::summoner_v4::Summoner; use riven::models::summoner_v4::Summoner;
const REGION: Region = Region::KR; const REGION: Region = Region::KR;

View File

@ -8,7 +8,7 @@ use testutils::*;
use colored::*; use colored::*;
use riven::consts::*; use riven::consts::*;
use riven::endpoints::summoner_v4::*; use riven::models::summoner_v4::*;
fn validate_lugnutsk(s: Summoner, tag: &str) -> Result<(), String> { fn validate_lugnutsk(s: Summoner, tag: &str) -> Result<(), String> {

View File

@ -8,7 +8,7 @@ use testutils::{ RIOT_API, future_start };
use colored::*; use colored::*;
use riven::consts::*; use riven::consts::*;
use riven::endpoints::summoner_v4::Summoner; use riven::models::summoner_v4::Summoner;
const REGION: Region = Region::TR; const REGION: Region = Region::TR;