/// The method adds a node with the given node ID and channel configuration.
The method adds a node with the given node ID and channel configuration.
The method adds a node with the given node ID and channel configuration .
fn add_node(&self, node_id: NodeId, channel_config: &ChannelConfig) {
        for flow_type in FlowType::iter() {
            let flow_type = &flow_type;
            match flow_type {
                FlowType::Advert => self.advert.add_node(node_id, channel_config.map[flow_type]),
                FlowType::Request => self
                    .request
                    .add_node(node_id, channel_config.map[flow_type]),
                FlowType::Chunk => self.chunk.add_node(node_id, channel_config.map[flow_type]),
                FlowType::Retransmission => self
                    .retransmission
                    .add_node(node_id, channel_config.map[flow_type]),
                FlowType::Transport => self
                    .transport
                    .add_node(node_id, channel_config.map[flow_type]),
                FlowType::SendAdvert => self
                    .send_advert
                    .add_node(node_id, channel_config.map[flow_type]),
            };
        }
    }
fn add_node ( & self , node_id : NodeId , channel_config : & ChannelConfig ) { for flow_type in FlowType :: iter ( ) { let flow_type = & flow_type ; match flow_type { FlowType :: Advert => self . advert . add_node ( node_id , channel_config . map [ flow_type ] ) , FlowType :: Request => self . request . add_node ( node_id , channel_config . map [ flow_type ] ) , FlowType :: Chunk => self . chunk . add_node ( node_id , channel_config . map [ flow_type ] ) , FlowType :: Retransmission => self . retransmission . add_node ( node_id , channel_config . map [ flow_type ] ) , FlowType :: Transport => self . transport . add_node ( node_id , channel_config . map [ flow_type ] ) , FlowType :: SendAdvert => self . send_advert . add_node ( node_id , channel_config . map [ flow_type ] ) , } ; } }
The method adds a node with the given node ID and channel configuration.
The method adds a node with the given node ID and channel configuration .
&self
node_id
NodeId
channel_config
&ChannelConfig