From f293aa28600faa7898b6b11e0ffac3ac60a85e69 Mon Sep 17 00:00:00 2001 From: Jonathan Strong Date: Mon, 5 Mar 2018 18:19:22 -0500 Subject: [PATCH] adds InfluxWriter::nanos(&self) -> i64 convenience fn --- src/influx.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/influx.rs b/src/influx.rs index 95e86d5..1ec8d35 100644 --- a/src/influx.rs +++ b/src/influx.rs @@ -218,6 +218,8 @@ impl InfluxWriter { self.tx.send(Some(m)) } + pub fn nanos(&self, d: DateTime) -> i64 { nanos(d) as i64 } + pub fn tx(&self) -> Sender> { self.tx.clone() }