Struct ckb_network::network::NetworkState
source · [−]pub struct NetworkState { /* private fields */ }Expand description
The global shared state of the network module
Implementations
Init from config
For restrict lock in inner scope
Get peer id of local node
Use on test
Get local node’s listen address list
pub fn get_protocol_ids<F: Fn(ProtocolId) -> bool>(
&self,
filter: F
) -> Vec<ProtocolId>ⓘ
pub fn get_protocol_ids<F: Fn(ProtocolId) -> bool>(
&self,
filter: F
) -> Vec<ProtocolId>ⓘ
use a filter to get protocol id list
Dial just identify protocol
Dial just feeler protocol