Skip to main content

moq_client_config

Struct moq_client_config 

Source
#[repr(C)]
pub struct moq_client_config {
Show 49 fields pub versions: *const moq_string, pub versions_len: usize, pub bind: *const c_char, pub bind_len: usize, pub connect_timeout_us: u64, pub has_connect_timeout: bool, pub failover_delay_us: u64, pub has_failover_delay: bool, pub resolution_delay_us: u64, pub has_resolution_delay: bool, pub websocket_enabled: bool, pub has_websocket_enabled: bool, pub websocket_delay_us: u64, pub has_websocket_delay: bool, pub tls_disable_verify: bool, pub tls_system_roots: bool, pub has_tls_system_roots: bool, pub tls_roots: *const moq_string, pub tls_roots_len: usize, pub tls_fingerprints: *const moq_string, pub tls_fingerprints_len: usize, pub tls_host_name: *const c_char, pub tls_host_name_len: usize, pub tls_cert: *const c_char, pub tls_cert_len: usize, pub tls_key: *const c_char, pub tls_key_len: usize, pub backoff_initial_us: u64, pub has_backoff_initial: bool, pub backoff_multiplier: u32, pub has_backoff_multiplier: bool, pub backoff_max_us: u64, pub has_backoff_max: bool, pub backoff_timeout_us: u64, pub has_backoff_timeout: bool, pub quic_max_streams: u64, pub has_quic_max_streams: bool, pub quic_idle_timeout_us: u64, pub has_quic_idle_timeout: bool, pub quic_keep_alive_us: u64, pub has_quic_keep_alive: bool, pub quic_gso: bool, pub has_quic_gso: bool, pub quic_mtu_discovery: bool, pub has_quic_mtu_discovery: bool, pub quic_congestion_control: *const c_char, pub quic_congestion_control_len: usize, pub quic_qlog: *const c_char, pub quic_qlog_len: usize,
}
Expand description

Settings for moq_session_connect, or NULL to dial with the defaults.

Zero it (memset, or a {0} initializer) and set only what you need: a zeroed struct means the defaults throughout. That is why the knobs whose default is not zero carry a has_* flag rather than being read directly. The WebSocket fallback is on by default and the reconnect backoff starts at one second, so a caller who never touched them would otherwise silently turn them off.

New settings are appended to the end of this struct, and a zeroed one keeps the previous behavior, so adding one does not disturb existing callers.

Fields§

§versions: *const moq_string

Protocol versions to offer during the handshake, most preferred first. NULL/0 offers everything this build supports. Names are spelled the way the CLI spells them (moq-lite-05, moq-transport-22); moq_versions lists what is on offer.

§versions_len: usize§bind: *const c_char

Local socket address to bind, or NULL for the wildcard address.

§bind_len: usize§connect_timeout_us: u64

How long a dial may take before it gives up.

§has_connect_timeout: bool§failover_delay_us: u64

Happy Eyeballs: how long before the next address is also dialed.

§has_failover_delay: bool§resolution_delay_us: u64

Happy Eyeballs: how long the first family waits for the AAAA answer.

§has_resolution_delay: bool§websocket_enabled: bool

Whether the WebSocket fallback may be raced, for a UDP-blocked network. Enabled unless you turn it off, hence the flag.

§has_websocket_enabled: bool§websocket_delay_us: u64

How long QUIC gets before the WebSocket fallback is also dialed.

§has_websocket_delay: bool§tls_disable_verify: bool

Accept any certificate. Development only: prefer tls_fingerprints, and pairing this with a fingerprint or a root is rejected at dial.

§tls_system_roots: bool

Whether to trust the platform root store. Its default depends on the backend, so it needs the flag to distinguish “off” from “unset”.

§has_tls_system_roots: bool§tls_roots: *const moq_string

Extra root certificate paths to trust.

§tls_roots_len: usize§tls_fingerprints: *const moq_string

SHA-256 certificate fingerprints to pin, hex encoded. The native equivalent of the browser’s serverCertificateHashes.

§tls_fingerprints_len: usize§tls_host_name: *const c_char

SNI override, or NULL to use the host from the URL.

§tls_host_name_len: usize§tls_cert: *const c_char

Client certificate and key paths for mTLS, or NULL for none.

§tls_cert_len: usize§tls_key: *const c_char§tls_key_len: usize§backoff_initial_us: u64

Reconnect pacing. Each must leave a non-zero delay or retrying would spin, which is rejected at dial.

§has_backoff_initial: bool§backoff_multiplier: u32§has_backoff_multiplier: bool§backoff_max_us: u64§has_backoff_max: bool§backoff_timeout_us: u64

How long reconnection keeps trying before giving up for good.

§has_backoff_timeout: bool§quic_max_streams: u64

QUIC transport tuning, all ignored by the WebSocket fallback.

§has_quic_max_streams: bool§quic_idle_timeout_us: u64§has_quic_idle_timeout: bool§quic_keep_alive_us: u64§has_quic_keep_alive: bool§quic_gso: bool

Generic segmentation offload and path MTU discovery. Both default to the backend’s choice, so both need their flag.

§has_quic_gso: bool§quic_mtu_discovery: bool§has_quic_mtu_discovery: bool§quic_congestion_control: *const c_char

Congestion control family name, or NULL for the backend’s choice.

§quic_congestion_control_len: usize§quic_qlog: *const c_char

Directory to write qlog traces into, or NULL for none. Capture is compile-time optional; see moq_qlog_supported.

§quic_qlog_len: usize

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

Source§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

Source§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

Source§

fn implicit( self, class: Class, constructed: bool, tag: u32, ) -> TaggedParser<'a, Implicit, Self, E>

Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<F, T> IntoSample<T> for F
where T: FromSample<F>,

Source§

fn into_sample(self) -> T

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more