Added chrono as dep
This commit is contained in:
parent
ba5d149a60
commit
5c62300e6e
3 changed files with 59 additions and 2 deletions
|
|
@ -1,9 +1,32 @@
|
|||
use chrono::NaiveDate;
|
||||
|
||||
|
||||
/// Searches the Ivago API for streets in the given city
|
||||
///
|
||||
/// # Arguments
|
||||
///
|
||||
/// * `street` -name of the street
|
||||
/// * `street` - name of the street
|
||||
/// * `city` - city the street is in
|
||||
pub fn search_streets(street: String, city: String) -> Vec<String> {
|
||||
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()
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue