mod.rs
This file
Path
src/parameter/mod.rs
21 lines · 486 bytes · Rust
Last changed by
Move functions into SchedulerDavid Peterbefore adoption39c7736
History of this fileTake it
Move a few modules to utilDavid Peterbefore adoption5c634c9
line 1why, one step back1use crate::util::number::Number;New parameter moduleDavid Peterbefore adoption47091a5
line 2why, one step back2Split range into range_step and commandsDavid Peterbefore adoption6db82cd
line 3why, one step back3pub mod range_step;New parameter moduleDavid Peterbefore adoption47091a5
lines 4–8why, one step back4pub mod tokenize;56#[derive(Debug, Clone, PartialEq, Eq)]7pub enum ParameterValue {8 Text(String),Move more modules aroundDavid Peterbefore adoption999e7c4
line 9why, one step back9 Numeric(Number),New parameter moduleDavid Peterbefore adoption47091a5
lines 10–19why, one step back10}1112impl<'a> ToString for ParameterValue {13 fn to_string(&self) -> String {14 match self {15 ParameterValue::Text(ref value) => value.clone(),16 ParameterValue::Numeric(value) => value.to_string(),17 }18 }19}Move functions into SchedulerDavid Peterbefore adoption39c7736
lines 20–21why, one step back2021pub type ParameterNameAndValue<'a> = (&'a str, ParameterValue);