pub struct DHTSettingsBuilder { /* private fields */ }
Expand description
Builder for DHTSettings
Implementations§
Source§impl DHTSettingsBuilder
impl DHTSettingsBuilder
pub fn new() -> DHTSettingsBuilder
pub fn token_secret_size(self, token_secret_size: usize) -> Self
pub fn max_peers_response(self, max_peers_response: usize) -> Self
pub fn max_sample_response(self, max_sample_response: usize) -> Self
pub fn min_sample_interval_secs(self, min_sample_interval_secs: i32) -> Self
pub fn router_ping_interval_secs(self, router_ping_interval_secs: u64) -> Self
pub fn reverify_interval_secs(self, reverify_interval_secs: u64) -> Self
pub fn reverify_grace_period_secs(self, reverify_grace_period_secs: u64) -> Self
pub fn verify_grace_period_secs(self, verify_grace_period_secs: u64) -> Self
pub fn get_peers_freshness_secs(self, get_peers_freshness_secs: u64) -> Self
pub fn find_nodes_interval_secs(self, find_nodes_interval_secs: u64) -> Self
pub fn find_nodes_skip_count(self, find_nodes_skip_count: usize) -> Self
pub fn max_torrents(self, max_torrents: usize) -> Self
pub fn max_peers_per_torrent(self, max_peers_per_torrent: usize) -> Self
pub fn ping_check_interval_secs(self, ping_check_interval_secs: u64) -> Self
pub fn outgoing_request_prune_secs( self, outgoing_request_prune_secs: u64, ) -> Self
pub fn outgoing_reqiest_check_interval_secs( self, outgoing_reqiest_check_interval_secs: u64, ) -> Self
pub fn read_only(self, read_only: bool) -> Self
pub fn routers(self, routers: Vec<String>) -> Self
pub fn throttle_packet_count(self, throttle_packet_count: usize) -> Self
pub fn throttle_period_secs(self, throttle_period_secs: u64) -> Self
pub fn throttle_naughty_timeout_secs( self, throttle_naughty_timeout_secs: u64, ) -> Self
pub fn throttle_max_tracking_secs(self, throttle_max_tracking_secs: u64) -> Self
pub fn build(self) -> DHTSettings
Trait Implementations§
Source§impl Clone for DHTSettingsBuilder
impl Clone for DHTSettingsBuilder
Source§fn clone(&self) -> DHTSettingsBuilder
fn clone(&self) -> DHTSettingsBuilder
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 Default for DHTSettingsBuilder
impl Default for DHTSettingsBuilder
Source§fn default() -> DHTSettingsBuilder
fn default() -> DHTSettingsBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for DHTSettingsBuilder
impl RefUnwindSafe for DHTSettingsBuilder
impl Send for DHTSettingsBuilder
impl Sync for DHTSettingsBuilder
impl Unpin for DHTSettingsBuilder
impl UnwindSafe for DHTSettingsBuilder
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