Trait quinn_proto::ConnectionIdGenerator[][src]

pub trait ConnectionIdGenerator: Send {
    fn generate_cid(&mut self) -> ConnectionId;
fn cid_len(&self) -> usize;
fn cid_lifetime(&self) -> Option<Duration>; }

Generates connection IDs for incoming connections

Required methods

fn generate_cid(&mut self) -> ConnectionId[src]

Generates a new CID

Connection IDs MUST NOT contain any information that can be used by an external observer (that is, one that does not cooperate with the issuer) to correlate them with other connection IDs for the same connection.

fn cid_len(&self) -> usize[src]

Returns the length of a CID for cononections created by this generator

fn cid_lifetime(&self) -> Option<Duration>[src]

Returns the lifetime of generated Connection IDs

Connection IDs will be retired after the returned Duration, if any. Assumed to be constant.

Loading content...

Implementors

impl ConnectionIdGenerator for RandomConnectionIdGenerator[src]

fn cid_len(&self) -> usize[src]

Provide the length of dst_cid in short header packet

Loading content...