pub fn new(
        worker_name: String,
        worker_id: String,
        k: usize,
        p: f64,
        tx_queue: Sender<Transmission>,
        rng: Arc<Mutex<StdRng>>,
        logger: Logger,
    ) -> GossipRouting {
        let v = HashSet::with_capacity(MSG_CACHE_SIZE);
        GossipRouting {
            worker_name,
            worker_id,
            k,
            p,
            msg_cache: Arc::new(Mutex::new(v)),
            tx_queue,
            rng,
            logger,
        }
    }
/// Creates a new instance of the NaiveRouting protocol handler
Creates a new instance of the NaiveRouting protocol handler
Creates a new instance of the NaiveRouting protocol handler
pub fn new(
        worker_name: String,
        worker_id: String,
        k: usize,
        p: f64,
        tx_queue: Sender<Transmission>,
        rng: Arc<Mutex<StdRng>>,
        logger: Logger,
    ) -> GossipRouting {
        let v = HashSet::with_capacity(MSG_CACHE_SIZE);
        GossipRouting {
            worker_name,
            worker_id,
            k,
            p,
            msg_cache: Arc::new(Mutex::new(v)),
            tx_queue,
            rng,
            logger,
        }
    }
pub fn new ( worker_name : String , worker_id : String , k : usize , p : f64 , tx_queue : Sender < Transmission > , rng : Arc < Mutex < StdRng > > , logger : Logger , ) -> GossipRouting { let v = HashSet :: with_capacity ( MSG_CACHE_SIZE ) ; GossipRouting { worker_name , worker_id , k , p , msg_cache : Arc :: new ( Mutex :: new ( v ) ) , tx_queue , rng , logger , } }
Creates a new instance of the NaiveRouting protocol handler
Creates a new instance of the NaiveRouting protocol handler
worker_name
String
worker_id
String
k
usize
p
f64
tx_queue
Sender<Transmission>
rng
Arc<Mutex<StdRng>>
logger
Logger