Struct webrtc_ice::agent::agent_config::AgentConfig[][src]

pub struct AgentConfig {
Show fields pub urls: Vec<Url>, pub port_min: u16, pub port_max: u16, pub local_ufrag: String, pub local_pwd: String, pub multicast_dns_mode: MulticastDnsMode, pub multicast_dns_host_name: String, pub disconnected_timeout: Option<Duration>, pub failed_timeout: Option<Duration>, pub keepalive_interval: Option<Duration>, pub network_types: Vec<NetworkType>, pub candidate_types: Vec<CandidateType>, pub check_interval: Duration, pub max_binding_requests: Option<u16>, pub is_controlling: bool, pub lite: bool, pub nat_1to1_ip_candidate_type: CandidateType, pub nat_1to1_ips: Vec<String>, 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 net: Option<Arc<Net>>, pub interface_filter: Arc<Option<InterfaceFilterFn>>, 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>port_min: u16

This is optional. Leave it as 0 for the default UDP port allocation strategy.

port_max: u16

This is optional. Leave it as 0 for the default UDP port allocation strategy.

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.

multicast_dns_mode: MulticastDnsMode

Controls mDNS behavior for the ICE agent.

multicast_dns_host_name: String

Controls the hostname for this agent. If none is specified a random one will be generated.

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

network_types: Vec<NetworkType>

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

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: boollite: bool

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

nat_1to1_ip_candidate_type: CandidateType

It is used along with nat1to1ips to specify which candidate type the 1:1 NAT IP addresses should be mapped to. If unspecified or CandidateTypeHost, nat1to1ips are used to replace host candidate IPs. If CandidateTypeServerReflexive, it will insert a srflx candidate (as if it was dervied from a STUN server) with its port number being the one for the actual host candidate. Other values will result in an error.

nat_1to1_ips: Vec<String>

Contains a list of public IP addresses that are to be used as a host candidate or srflx candidate. This is used typically for servers that are behind 1:1 D-NAT (e.g. AWS EC2 instances) and to eliminate the need of server reflexisive candidate gathering.

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 srflx candidates.

prflx_acceptance_min_wait: Option<Duration>

Specify a minimum wait time before selecting prflx candidates.

relay_acceptance_min_wait: Option<Duration>

Specify a minimum wait time before selecting relay candidates.

net: Option<Arc<Net>>

Net is the our abstracted network interface for internal development purpose only (see (github.com/pion/transport/vnet)[github.com/pion/transport/vnet]).

interface_filter: Arc<Option<InterfaceFilterFn>>

A function that you can use in order to whitelist or blacklist the interfaces which are used to gather ICE candidates.

insecure_skip_verify: bool

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

Trait Implementations

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

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Converts self into a target type. Read more

Converts self into T using Into<T>. Read more

Causes self to use its Binary implementation when Debug-formatted.

Causes self to use its Display implementation when Debug-formatted. Read more

Causes self to use its LowerExp implementation when Debug-formatted. Read more

Causes self to use its LowerHex implementation when Debug-formatted. Read more

Causes self to use its Octal implementation when Debug-formatted.

Causes self to use its Pointer implementation when Debug-formatted. Read more

Causes self to use its UpperExp implementation when Debug-formatted. Read more

Causes self to use its UpperHex implementation when Debug-formatted. Read more

Performs the conversion.

Performs the conversion.

Pipes a value into a function that cannot ordinarily be called in suffix position. Read more

Pipes by value. This is generally the method you want to use. Read more

Borrows self and passes that borrow into the pipe function. Read more

Mutably borrows self and passes that borrow into the pipe function. Read more

Borrows self, then passes self.borrow() into the pipe function. Read more

Mutably borrows self, then passes self.borrow_mut() into the pipe function. Read more

Borrows self, then passes self.as_ref() into the pipe function.

Mutably borrows self, then passes self.as_mut() into the pipe function. Read more

Borrows self, then passes self.deref() into the pipe function.

Mutably borrows self, then passes self.deref_mut() into the pipe function. Read more

Pipes a trait borrow into a function that cannot normally be called in suffix position. Read more

Pipes a trait mutable borrow into a function that cannot normally be called in suffix position. Read more

Pipes a trait borrow into a function that cannot normally be called in suffix position. Read more

Pipes a trait mutable borrow into a function that cannot normally be called in suffix position. Read more

Pipes a dereference into a function that cannot normally be called in suffix position. Read more

Pipes a mutable dereference into a function that cannot normally be called in suffix position. Read more

Pipes a reference into a function that cannot ordinarily be called in suffix position. Read more

Pipes a mutable reference into a function that cannot ordinarily be called in suffix position. Read more

Should always be Self

Provides immutable access for inspection. Read more

Calls tap in debug builds, and does nothing in release builds.

Provides mutable access for modification. Read more

Calls tap_mut in debug builds, and does nothing in release builds.

Immutable access to a value. Read more

Mutable access to a value. Read more

Immutable access to the Borrow<B> of a value. Read more

Mutable access to the BorrowMut<B> of a value. Read more

Immutable access to the AsRef<R> view of a value. Read more

Mutable access to the AsMut<R> view of a value. Read more

Immutable access to the Deref::Target of a value. Read more

Mutable access to the Deref::Target of a value. Read more

Calls .tap() only in debug builds, and is erased in release builds.

Calls .tap_mut() only in debug builds, and is erased in release builds. Read more

Calls .tap_borrow() only in debug builds, and is erased in release builds. Read more

Calls .tap_borrow_mut() only in debug builds, and is erased in release builds. Read more

Calls .tap_ref() only in debug builds, and is erased in release builds. Read more

Calls .tap_ref_mut() only in debug builds, and is erased in release builds. Read more

Calls .tap_deref() only in debug builds, and is erased in release builds. Read more

Calls .tap_deref_mut() only in debug builds, and is erased in release builds. Read more

Provides immutable access to the reference for inspection.

Calls tap_ref in debug builds, and does nothing in release builds.

Provides mutable access to the reference for modification.

Calls tap_ref_mut in debug builds, and does nothing in release builds.

Provides immutable access to the borrow for inspection. Read more

Calls tap_borrow in debug builds, and does nothing in release builds.

Provides mutable access to the borrow for modification.

Calls tap_borrow_mut in debug builds, and does nothing in release builds. Read more

Immutably dereferences self for inspection.

Calls tap_deref in debug builds, and does nothing in release builds.

Mutably dereferences self for modification.

Calls tap_deref_mut in debug builds, and does nothing in release builds. Read more

Attempts to convert self into a target type. Read more

Attempts to convert self into T using TryInto<T>. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.