1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
//! `flowscope::driver` — the typed `Driver<E>` + `SlotHandle<M, K>`
//! shape (plan 121).
//!
//! ```ignore
//! use flowscope::driver::{Driver, Event, SlotMessage};
//! use flowscope::extract::{FiveTuple, FiveTupleKey};
//! use flowscope::http::{HttpMessage, HttpParser};
//!
//! let mut builder = Driver::builder(FiveTuple::bidirectional());
//! let mut http_slot = builder.session_on_ports(HttpParser::default(), [80, 8080]);
//! let mut driver = builder.build();
//!
//! let mut events: Vec<Event<FiveTupleKey>> = Vec::new();
//! let mut http_msgs: Vec<SlotMessage<HttpMessage, FiveTupleKey>> = Vec::new();
//!
//! // driver.track_into(view, &mut events);
//! // http_slot.drain(&mut http_msgs);
//! ```
//!
//! ## Architecture
//!
//! - [`Driver<E>`] owns a central [`crate::FlowTracker`] for flow
//! lifecycle + per-parser slots that own their inner
//! session/datagram drivers.
//! - Each `.session_*` / `.datagram_*` builder call returns a
//! typed [`SlotHandle<M, K>`]; the slot's typed messages flow
//! into the handle's internal buffer via shared
//! `Rc<RefCell<…>>`.
//! - Per-packet: `driver.track_into(view, &mut events)` emits
//! flow-lifecycle events; `slot.drain(&mut msgs)` drains the
//! typed messages produced this packet.
//! - Zero-allocation in steady state across the full dispatch
//! path including registered slots.
//!
//! Single-threaded by design — the slot bufs are `Rc<RefCell>`,
//! not `Arc<Mutex>`. For cross-task delivery, drain inside the
//! event loop and post through a channel.
pub use ;
pub use ;
pub use ;