pub struct AgentConfig {
Show 16 fields pub urls: Vec<Url>, pub local_ufrag: String, pub local_pwd: String, pub disconnected_timeout: Option<Duration>, pub failed_timeout: Option<Duration>, pub keepalive_interval: Option<Duration>, pub candidate_types: Vec<CandidateType>, pub check_interval: Duration, pub max_binding_requests: Option<u16>, pub is_controlling: bool, pub lite: bool, pub host_acceptance_min_wait: Option<Duration>, pub srflx_acceptance_min_wait: Option<Duration>, pub prflx_acceptance_min_wait: Option<Duration>, pub relay_acceptance_min_wait: Option<Duration>, pub insecure_skip_verify: bool,
}
Expand description

Collects the arguments to ice::Agent construction into a single structure, for future-proofness of the interface.

Fields§

§urls: Vec<Url>§local_ufrag: String

It is used to perform connectivity checks. The values MUST be unguessable, with at least 128 bits of random number generator output used to generate the password, and at least 24 bits of output to generate the username fragment.

§local_pwd: String

It is used to perform connectivity checks. The values MUST be unguessable, with at least 128 bits of random number generator output used to generate the password, and at least 24 bits of output to generate the username fragment.

§disconnected_timeout: Option<Duration>

Defaults to 5 seconds when this property is nil. If the duration is 0, the ICE Agent will never go to disconnected.

§failed_timeout: Option<Duration>

Defaults to 25 seconds when this property is nil. If the duration is 0, we will never go to failed.

§keepalive_interval: Option<Duration>

Determines how often should we send ICE keepalives (should be less then connectiontimeout above) when this is nil, it defaults to 10 seconds. A keepalive interval of 0 means we never send keepalive packets

§candidate_types: Vec<CandidateType>

An optional configuration for disabling or enabling support for specific candidate types.

§check_interval: Duration

Controls how often our internal task loop runs when in the connecting state. Only useful for testing.

§max_binding_requests: Option<u16>

The max amount of binding requests the agent will send over a candidate pair for validation or nomination, if after max_binding_requests the candidate is yet to answer a binding request or a nomination we set the pair as failed.

§is_controlling: bool§lite: bool

lite agents do not perform connectivity check and only provide host candidates.

§host_acceptance_min_wait: Option<Duration>

Specify a minimum wait time before selecting host candidates.

§srflx_acceptance_min_wait: Option<Duration>

Specify a minimum wait time before selecting srfl candidates.

§prflx_acceptance_min_wait: Option<Duration>

Specify a minimum wait time before selecting prfl candidates.

§relay_acceptance_min_wait: Option<Duration>

Specify a minimum wait time before selecting relay candidates.

§insecure_skip_verify: bool

Controls if self-signed certificates are accepted when connecting to TURN servers via TLS or DTLS.

Trait Implementations§

source§

impl Default for AgentConfig

source§

fn default() -> AgentConfig

Returns the “default value” for a type. Read more

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<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<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<T> Same for T

§

type Output = T

Should always be Self
source§

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

§

type Error = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

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

§

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