pub struct CedexTable { /* private fields */ }Expand description
CEDEX code → INSEE codes, and locality → INSEE codes.
Implementations§
Source§impl CedexTable
impl CedexTable
Sourcepub fn by_locality(&self, locality: &str) -> &[String]
pub fn by_locality(&self, locality: &str) -> &[String]
Municipalities served under a locality (“PARIS LA DEFENSE”), any
spelling (locality_key).
pub fn codes(&self) -> usize
pub fn localities(&self) -> usize
pub fn is_empty(&self) -> bool
Sourcepub fn to_bytes(&self) -> Result<Vec<u8>, GeocoderError>
pub fn to_bytes(&self) -> Result<Vec<u8>, GeocoderError>
zlib compressed lines: 92074 92062 (code, municipalities), then
=PARIS LA DEFENSE 92026 92062 (locality, municipalities).
Sourcepub fn from_bytes(bytes: &[u8]) -> Result<Self, GeocoderError>
pub fn from_bytes(bytes: &[u8]) -> Result<Self, GeocoderError>
Reads Self::to_bytes; malformed lines are skipped.
Trait Implementations§
Source§impl Clone for CedexTable
impl Clone for CedexTable
Source§impl Debug for CedexTable
impl Debug for CedexTable
Source§impl Default for CedexTable
impl Default for CedexTable
impl Eq for CedexTable
Source§impl PartialEq for CedexTable
impl PartialEq for CedexTable
impl StructuralPartialEq for CedexTable
Auto Trait Implementations§
impl Forget for CedexTable
impl Freeze for CedexTable
impl Move for CedexTable
impl RefUnwindSafe for CedexTable
impl Send for CedexTable
impl Sync for CedexTable
impl Unpin for CedexTable
impl UnsafeUnpin for CedexTable
impl UnwindSafe for CedexTable
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.