pub struct SwarmConfig {
pub addr_filters: Vec<String>,
pub disable_bandwidth_metrics: bool,
pub disable_nat_port_map: bool,
pub relay_client: RelayClient,
pub relay_service: RelayService,
pub enable_hole_punching: Option<Flag>,
pub transports: Transports,
pub conn_mgr: ConnMgr,
pub resource_mgr: ResourceMgr,
}Expand description
Swarm configuration section
Fields§
§addr_filters: Vec<String>Address filters (multiaddr filters to block)
disable_bandwidth_metrics: boolDisable bandwidth metrics collection
disable_nat_port_map: boolDisable NAT port mapping
relay_client: RelayClientRelay client configuration
relay_service: RelayServiceRelay service configuration
enable_hole_punching: Option<Flag>Enable hole punching
transports: TransportsTransport configuration
conn_mgr: ConnMgrConnection manager configuration
resource_mgr: ResourceMgrResource manager configuration
Trait Implementations§
Source§impl Clone for SwarmConfig
impl Clone for SwarmConfig
Source§fn clone(&self) -> SwarmConfig
fn clone(&self) -> SwarmConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SwarmConfig
impl Debug for SwarmConfig
Source§impl Default for SwarmConfig
impl Default for SwarmConfig
Source§fn default() -> SwarmConfig
fn default() -> SwarmConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for SwarmConfig
impl<'de> Deserialize<'de> for SwarmConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for SwarmConfig
impl RefUnwindSafe for SwarmConfig
impl Send for SwarmConfig
impl Sync for SwarmConfig
impl Unpin for SwarmConfig
impl UnwindSafe for SwarmConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more