pub struct CedexTableBuilder { /* private fields */ }Expand description
Collects (code, delivery line, municipality) triples from the sources.
Implementations§
Source§impl CedexTableBuilder
impl CedexTableBuilder
pub fn new() -> Self
Sourcepub fn add(&mut self, code: &str, label: &str, insee: &str) -> bool
pub fn add(&mut self, code: &str, label: &str, insee: &str) -> bool
One CEDEX address: its code, its delivery label (“PARIS LA DEFENSE CEDEX 08”) and the INSEE code of its municipality. Kept only when the municipality is in the code’s department: the sources have a few stray ones (92081 → Paris 12e). Returns whether it was kept.
pub fn codes(&self) -> usize
Sourcepub fn build(self) -> CedexTable
pub fn build(self) -> CedexTable
A locality serves the municipalities of all its codes.
Trait Implementations§
Source§impl Debug for CedexTableBuilder
impl Debug for CedexTableBuilder
Auto Trait Implementations§
impl Forget for CedexTableBuilder
impl Freeze for CedexTableBuilder
impl Move for CedexTableBuilder
impl RefUnwindSafe for CedexTableBuilder
impl Send for CedexTableBuilder
impl Sync for CedexTableBuilder
impl Unpin for CedexTableBuilder
impl UnsafeUnpin for CedexTableBuilder
impl UnwindSafe for CedexTableBuilder
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