INNER CODE UNIT · Rust

from

qaul/qaul.net · rust/libp2p_modules/qaul_info/src/lib.rs:174

    fn from(event: QaulInfoEvent) -> QaulInfoData {
        match event {
            QaulInfoEvent::Message(data) => QaulInfoData { data: data.data },
        }
    }
}

/// Configuration options for the qaul info behaviour
#[derive(Debug, Clone)]
pub struct QaulInfoConfig {
    /// Peer id of the local node. Used for the source of the messages that we publish.
    pub local_peer_id: PeerId,
}

impl QaulInfoConfig {
    pub fn new(local_peer_id: PeerId) -> Self {
        Self { local_peer_id }
    }

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…