MCPcopy Create free account
hub / github.com/chirpstack/chirpstack / set

Function set

chirpstack/src/region.rs:70–73  ·  view source on GitHub ↗
(region_config_id: &str, r: Box<dyn region::Region + Sync + Send>)

Source from the content-addressed store, hash-verified

68}
69
70pub fn set(region_config_id: &str, r: Box<dyn region::Region + Sync + Send>) {
71 let mut regions_w = REGIONS.write().unwrap();
72 regions_w.insert(region_config_id.to_string(), Arc::new(r));
73}
74
75pub fn get(region_config_id: &str) -> Result<Arc<Box<dyn region::Region + Sync + Send>>> {
76 let regions_r = REGIONS.read().unwrap();

Callers 1

setupFunction · 0.70

Calls 3

unwrapMethod · 0.80
insertMethod · 0.80
to_stringMethod · 0.80

Tested by

no test coverage detected