pub struct FunctionMapRegistry { /* private fields */ }Expand description
Lookup table of FunctionMap values addressed by name.
Implementations§
Source§impl FunctionMapRegistry
impl FunctionMapRegistry
Sourcepub fn new_with_builtins() -> Self
pub fn new_with_builtins() -> Self
Creates a registry preloaded with the built-in diatonic functions.
Sourcepub fn register(&mut self, map: FunctionMap)
pub fn register(&mut self, map: FunctionMap)
Inserts a function under its own name, replacing any prior entry.
Sourcepub fn get(&self, name: &str) -> Option<&FunctionMap>
pub fn get(&self, name: &str) -> Option<&FunctionMap>
Looks up a function by name.
Trait Implementations§
Source§impl Clone for FunctionMapRegistry
impl Clone for FunctionMapRegistry
Source§fn clone(&self) -> FunctionMapRegistry
fn clone(&self) -> FunctionMapRegistry
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 FunctionMapRegistry
impl Debug for FunctionMapRegistry
Source§impl Default for FunctionMapRegistry
impl Default for FunctionMapRegistry
Source§fn default() -> FunctionMapRegistry
fn default() -> FunctionMapRegistry
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for FunctionMapRegistry
impl RefUnwindSafe for FunctionMapRegistry
impl Send for FunctionMapRegistry
impl Sync for FunctionMapRegistry
impl Unpin for FunctionMapRegistry
impl UnsafeUnpin for FunctionMapRegistry
impl UnwindSafe for FunctionMapRegistry
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