pub struct ProfileRegistry { /* private fields */ }Expand description
In-memory map of installed LanguageProfiles keyed by profile symbol.
Implementations§
Source§impl ProfileRegistry
impl ProfileRegistry
Sourcepub fn register_profile(&mut self, profile: LanguageProfile) -> Result<()>
pub fn register_profile(&mut self, profile: LanguageProfile) -> Result<()>
Register profile, failing if a profile with the same symbol is already
installed.
Sourcepub fn profile(&self, symbol: &Symbol) -> Option<&LanguageProfile>
pub fn profile(&self, symbol: &Symbol) -> Option<&LanguageProfile>
Look up an installed profile by symbol.
Sourcepub fn profiles(&self) -> impl Iterator<Item = &LanguageProfile>
pub fn profiles(&self) -> impl Iterator<Item = &LanguageProfile>
Iterate the installed profiles in symbol order.
Trait Implementations§
Source§impl Clone for ProfileRegistry
impl Clone for ProfileRegistry
Source§fn clone(&self) -> ProfileRegistry
fn clone(&self) -> ProfileRegistry
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 ProfileRegistry
impl Debug for ProfileRegistry
Source§impl Default for ProfileRegistry
impl Default for ProfileRegistry
Source§fn default() -> ProfileRegistry
fn default() -> ProfileRegistry
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ProfileRegistry
impl RefUnwindSafe for ProfileRegistry
impl Send for ProfileRegistry
impl Sync for ProfileRegistry
impl Unpin for ProfileRegistry
impl UnsafeUnpin for ProfileRegistry
impl UnwindSafe for ProfileRegistry
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