Expand description
Multi-draft entry-point types (AnyConnection,
AnyClientEvent,
AnyConnectionObserver) for downstream
consumers that need to hold a connection without compile-time coupling to
one draft.
Unified multi-draft entry-point types.
This module is the facade downstream consumers (e.g. a CLI or desktop app)
use to hold a MoQT connection without caring which draft was negotiated.
It mirrors moqtap_codec::dispatch: one enum variant per enabled draft,
gated on its feature flag.
Three types live here:
AnyConnection— wraps a draft-specificConnection.AnyClientEvent— wraps a draft-specificClientEvent.AnyConnectionObserver— a trait that receivesAnyClientEvents. Attached to anAnyConnectionviaAnyConnection::set_observer, which installs a per-draft adapter on the inner connection.
Draft-specific protocol methods (e.g. subscribe, fetch) are not on
AnyConnection because their signatures differ across drafts — match
on the variant to reach them.
Structs§
- AnyClient
Config - Draft-agnostic client configuration. The exact per-draft
ClientConfigis constructed internally byAnyConnection::connectbased ondraft. - AnyConnection
Error - Error returned by
AnyConnection::connectandAnyConnection::recv_and_dispatch. Draft-specific errors are flattened to strings so callers don’t have to branch on draft to inspect errors. - NoOp
Observer - A no-op observer that discards all events.
Enums§
- AnyClient
Event - An event from a MoQT connection of any enabled draft version.
- AnyConnection
- A MoQT client connection of any enabled draft version.
- AnyTransport
Type - Draft-agnostic transport choice for
AnyConnection::connect.
Traits§
- AnyConnection
Observer - Trait for receiving events from an
AnyConnection.