pub struct DtnConfig {Show 27 fields
pub debug: bool,
pub unsafe_httpd: bool,
pub v4: bool,
pub v6: bool,
pub custom_timeout: bool,
pub enable_period: bool,
pub nodeid: String,
pub host_eid: EndpointID,
pub webport: u16,
pub announcement_interval: Duration,
pub disable_neighbour_discovery: bool,
pub discovery_destinations: BTreeMap<String, u32>,
pub janitor_interval: Duration,
pub endpoints: Vec<String>,
pub clas: Vec<(CLAsAvailable, HashMap<String, String>)>,
pub cla_global_settings: HashMap<CLAsAvailable, HashMap<String, String>>,
pub services: BTreeMap<u8, String>,
pub routing: String,
pub routing_settings: BTreeMap<String, HashMap<String, String>>,
pub peer_timeout: Duration,
pub statics: Vec<DtnPeer>,
pub workdir: PathBuf,
pub db: String,
pub generate_status_reports: bool,
pub ecla_tcp_port: u16,
pub ecla_enable: bool,
pub parallel_bundle_processing: bool,
}
Fields§
§debug: bool
§unsafe_httpd: bool
§v4: bool
§v6: bool
§custom_timeout: bool
§enable_period: bool
§nodeid: String
§host_eid: EndpointID
§webport: u16
§announcement_interval: Duration
§disable_neighbour_discovery: bool
§discovery_destinations: BTreeMap<String, u32>
§janitor_interval: Duration
§endpoints: Vec<String>
§clas: Vec<(CLAsAvailable, HashMap<String, String>)>
§cla_global_settings: HashMap<CLAsAvailable, HashMap<String, String>>
§services: BTreeMap<u8, String>
§routing: String
§routing_settings: BTreeMap<String, HashMap<String, String>>
§peer_timeout: Duration
§statics: Vec<DtnPeer>
§workdir: PathBuf
§db: String
§generate_status_reports: bool
§ecla_tcp_port: u16
§ecla_enable: bool
§parallel_bundle_processing: bool
Implementations§
source§impl DtnConfig
impl DtnConfig
pub fn new() -> DtnConfig
pub fn set(&mut self, cfg: DtnConfig)
sourcepub fn add_destination(&mut self, destination: String) -> Result<()>
pub fn add_destination(&mut self, destination: String) -> Result<()>
Helper function that adds discovery destinations to a config struct
When provided with an IP address without port the default port 3003 is appended
pub fn check_destinations(&mut self) -> Result<()>
sourcepub fn update_beacon_sequence_number(&mut self, destination: &str)
pub fn update_beacon_sequence_number(&mut self, destination: &str)
Updates the beacon sequence number everytime a beacon is sent to a specific IP address
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DtnConfig
impl RefUnwindSafe for DtnConfig
impl Send for DtnConfig
impl Sync for DtnConfig
impl Unpin for DtnConfig
impl UnwindSafe for DtnConfig
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more