diff options
author | Jesse Luehrs <doy@tozt.net> | 2019-11-04 10:15:12 -0500 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2019-11-04 10:17:56 -0500 |
commit | 7c8fa35807d3b3cda991715d9735e151367b2fb6 (patch) | |
tree | 2e492ae140a2d343c680cec15fb28090d52bf8de /src/reader.rs | |
parent | e7beaa60f8c246190a8d9089c66d546abadab577 (diff) | |
download | ttyrec-7c8fa35807d3b3cda991715d9735e151367b2fb6.tar.gz ttyrec-7c8fa35807d3b3cda991715d9735e151367b2fb6.zip |
track the time offset during parsing
Diffstat (limited to 'src/reader.rs')
-rw-r--r-- | src/reader.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/reader.rs b/src/reader.rs index fd87cd5..ff5f7f9 100644 --- a/src/reader.rs +++ b/src/reader.rs @@ -46,4 +46,11 @@ impl<R: tokio::io::AsyncRead> Reader<R> { } } } + + /// How much the timestamps in this file should be offset by. + /// + /// See `Parser::offset`. + pub fn offset(&self) -> Option<std::time::Duration> { + self.parser.offset() + } } |