Skip to main content

moqtap_client/draft12/
mod.rs

1//! MoQT client implementation for draft-12.
2//!
3//! Each draft lives in its own top-level module with a complete, independent
4//! implementation: connection, endpoint state machine, event types, observer
5//! trait, and per-flow state machines (subscribe, fetch, announce, track
6//! status). No code is shared across drafts — each draft carries its own copy
7//! because wire-level differences would make a shared layer leaky.
8//!
9//! Enable via the `draft12` feature.
10//!
11//! # Differences from draft-11
12//!
13//! Draft-12 is a small, targeted revision of draft-11. The visible shifts:
14//!
15//! - `track_alias` moves out of `Subscribe` and is instead returned by the
16//!   publisher in `SubscribeOk`. The subscribe API no longer takes a
17//!   client-chosen alias; the alias becomes available once SUBSCRIBE_OK
18//!   arrives.
19//! - `SubscribeError` loses its trailing `track_alias` field (there is no
20//!   alias to echo since the client never sent one).
21//! - New publisher-initiated messages: `Publish` (0x1D), `PublishOk` (0x1E),
22//!   and `PublishError` (0x1F). A publisher can actively offer a track to
23//!   the peer without waiting for a SUBSCRIBE; the peer responds with
24//!   PUBLISH_OK (accepting with a filter/range) or PUBLISH_ERROR.
25//! - Subgroup data-stream type ids shift from the 0x08–0x0D range to
26//!   0x10–0x15. Datagram ids (0x00–0x03) and fetch ids (0x05) are unchanged.
27//!   This is handled inside `AnySubgroupHeader::decode` when called with
28//!   `DraftVersion::Draft12`.
29//!
30//! The version varint is `0xff000000 + 12`.
31
32/// Outbound MoQT connection with MoQT framing over QUIC.
33pub mod connection;
34/// Unified endpoint state machine orchestrating all MoQT protocol flows.
35pub mod endpoint;
36/// Client event types emitted via the observer.
37pub mod event;
38/// Fetch lifecycle state machine.
39pub mod fetch;
40/// Announce / SubscribeAnnounces state machines.
41pub mod namespace;
42/// Connection observer trait for receiving client events.
43pub mod observer;
44/// Session state, setup validation, and request ID allocation.
45pub mod session;
46/// Subscription lifecycle state machine.
47pub mod subscription;
48/// Track status lifecycle state machine.
49pub mod track_status;