Struct sctp_proto::EndpointConfig
source · pub struct EndpointConfig { /* private fields */ }
Expand description
Global configuration for the endpoint, affecting all associations
Default values should be suitable for most internet applications.
Implementations§
source§impl EndpointConfig
impl EndpointConfig
sourcepub fn aid_generator<F: Fn() -> Box<dyn AssociationIdGenerator> + Send + Sync + 'static>(
&mut self,
factory: F,
) -> &mut Self
pub fn aid_generator<F: Fn() -> Box<dyn AssociationIdGenerator> + Send + Sync + 'static>( &mut self, factory: F, ) -> &mut Self
Supply a custom Association ID generator factory
Called once by each Endpoint
constructed from this configuration to obtain the AID
generator which will be used to generate the AIDs used for incoming packets on all
associations involving that Endpoint
. A custom AID generator allows applications to embed
information in local association IDs, e.g. to support stateless packet-level load balancers.
EndpointConfig::new()
applies a default random AID generator factory. This functions
accepts any customized AID generator to reset AID generator factory that implements
the AssociationIdGenerator
trait.
sourcepub fn max_payload_size(&mut self, value: u32) -> &mut Self
pub fn max_payload_size(&mut self, value: u32) -> &mut Self
Maximum payload size accepted from peers.
The default is suitable for typical internet applications. Applications which expect to run on networks supporting Ethernet jumbo frames or similar should set this appropriately.
Trait Implementations§
source§impl Clone for EndpointConfig
impl Clone for EndpointConfig
source§fn clone(&self) -> EndpointConfig
fn clone(&self) -> EndpointConfig
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for EndpointConfig
impl Debug for EndpointConfig
Auto Trait Implementations§
impl Freeze for EndpointConfig
impl !RefUnwindSafe for EndpointConfig
impl Send for EndpointConfig
impl Sync for EndpointConfig
impl Unpin for EndpointConfig
impl !UnwindSafe for EndpointConfig
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)