[package]
name = "timeout-iterator"
version = "1.0.1"
authors = ["Archis Gore <archis@polyverse.io>"]
edition = "2018"
license-file = "LICENSE"
categories = ["asynchronous", "caching", "rust-patterns"]
keywords = ["iterator", "wrapper", "timeout", "peek", "buffer"]
readme = "README.md"
repository = "https://github.com/polyverse/timeout-iterator"
description = """TimeoutIterator is a wrapper over any iterator that adds peek_timeout and next_timeout functions.
The canonical use-case is parsing multi-line free-form records (such as tailing a log fime) where it is desirable to
consume the very last line, and peek whether the record continues on the next time, but not block
indefinitely on the peek."""
[features]
async = ["futures", "futures-util", "tokio", "tokio-stream"]
[dependencies]
futures = { version = "0.3.8", optional = true }
futures-util = { version = "0.3.8", optional = true }
tokio = { version = "1.0.1", features = ["time"], optional = true }
tokio-stream = { version = "0.1.0", optional = true }
[dev-dependencies]
tokio-test = "0.4.0"
assert_matches = "1.4.0"