fej/src/ivago/controller.rs

33 lines
731 B
Rust

use chrono::NaiveDate;
/// Searches the Ivago API for streets in the given city
///
/// # Arguments
///
/// * `street` - name of the street
/// * `city` - city the street is in
pub fn search_streets(street: String, city: Option<String>) -> Vec<String> {
Vec::new()
}
/// Represents a pickup time instance. All fields are a direct map of the
/// original API
pub struct PickupTime {
date: NaiveDate,
label: String,
classes: Vec<String>,
url: String
}
/// Return the known pickup times for the given street and/or city
///
/// # Arguments
///
/// * `street` - name of the street
/// * `city` - city the street is in
pub fn get_pickup_times(street: String, city: String) -> Vec<PickupTime> {
Vec::new()
}