Struct timewarrior_report::TimewarriorData [−][src]
Expand description
A representation of the data within the report
Fields
config: HashMap<String, String>
The configurations passed to the report
sessions: Vec<Session>
A vector of all tracked sessions within the report
Implementations
Read the report from standard input
This should be the usual way to read the report data.
Read the report from a given string
Example
use timewarrior_report::TimewarriorData; let report_data = TimewarriorData::from_string("test: test\n\n[]".into()).unwrap(); assert_eq!( report_data, TimewarriorData { config: [("test".to_string(), "test".to_string())] .iter() .cloned() .collect(), sessions: Vec::new(), } );
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for TimewarriorData
impl Send for TimewarriorData
impl Sync for TimewarriorData
impl Unpin for TimewarriorData
impl UnwindSafe for TimewarriorData