pub struct CallsignHashTable { /* private fields */ }Expand description
Runtime callsign hash lookup table.
Populated during decoding; used to resolve <...> placeholders in
messages containing hashed callsigns.
Implementations§
Source§impl CallsignHashTable
impl CallsignHashTable
Sourcepub fn insert(&mut self, call: &str)
pub fn insert(&mut self, call: &str)
Register a decoded callsign, populating all three hash tables.
Skips empty strings, <...> placeholders, and strings shorter than
3 characters. Strips <> brackets if present.
Sourcepub fn lookup10(&self, n10: u32) -> Option<&str>
pub fn lookup10(&self, n10: u32) -> Option<&str>
Look up a 10-bit hash. Returns the callsign if found.
Sourcepub fn lookup12(&self, n12: u32) -> Option<&str>
pub fn lookup12(&self, n12: u32) -> Option<&str>
Look up a 12-bit hash. Returns the callsign if found.
Trait Implementations§
Source§impl Clone for CallsignHashTable
impl Clone for CallsignHashTable
Source§fn clone(&self) -> CallsignHashTable
fn clone(&self) -> CallsignHashTable
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CallsignHashTable
impl Debug for CallsignHashTable
Auto Trait Implementations§
impl Freeze for CallsignHashTable
impl RefUnwindSafe for CallsignHashTable
impl Send for CallsignHashTable
impl Sync for CallsignHashTable
impl Unpin for CallsignHashTable
impl UnsafeUnpin for CallsignHashTable
impl UnwindSafe for CallsignHashTable
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<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more