comparison rust/src/sensor.rs @ 632:bde302def78e rust

moving to riker, nowhere near yet
author Matt Johnston <matt@ucc.asn.au>
date Thu, 22 Aug 2019 23:59:50 +0800
parents c57821a60e51
children 490e9e15b98c
comparison
equal deleted inserted replaced
631:c57821a60e51 632:bde302def78e
1 extern crate regex; 1 use riker::actors::*;
2
3 use actix::prelude::*;
4 2
5 use std::time::Duration; 3 use std::time::Duration;
6 use std::io; 4 use std::io;
7 use std::fs::File; 5 use std::fs::File;
8 use std::io::{Read,BufReader,BufRead}; 6 use std::io::{Read,BufReader,BufRead};
9 use std::path::PathBuf; 7 use std::path::PathBuf;
10 use std::error::Error; 8
11 use std::sync::Arc;
12 use std::str::FromStr; 9 use std::str::FromStr;
13 10
14 use tokio_core::reactor::Interval; 11 use super::types::*;
15 use tokio_core::reactor::Handle; 12 use super::config::Config;
16 use futures::Stream;
17 use types::*;
18 use ::Config;
19 13
20 pub struct OneWireSensor { 14 pub struct OneWireSensor {
21 config: Config, 15 config: Config,
22 fridge: Recipient<Readings>, 16 fridge: Recipient<Readings>,
23 } 17 }