pub struct SyntaxFactoryStore { /* private fields */ }Expand description
Store for syntax driver factories registered by modules during init.
Similar to ModeInfoStore, CommandHandlerStore, etc.
Modules register their factories here, and bootstrap extracts them
after module initialization.
Implementations§
Source§impl SyntaxFactoryStore
impl SyntaxFactoryStore
Sourcepub fn add(&self, factory: Arc<dyn SyntaxDriverFactory>)
pub fn add(&self, factory: Arc<dyn SyntaxDriverFactory>)
Add a factory to the store.
Called by syntax modules during init().
Sourcepub fn take_factories(&self) -> Vec<Arc<dyn SyntaxDriverFactory>>
pub fn take_factories(&self) -> Vec<Arc<dyn SyntaxDriverFactory>>
Take all registered factories.
Called by bootstrap after all modules have initialized. This drains the store, so subsequent calls return empty vec.
Trait Implementations§
Source§impl Debug for SyntaxFactoryStore
impl Debug for SyntaxFactoryStore
Source§impl Default for SyntaxFactoryStore
impl Default for SyntaxFactoryStore
Source§fn default() -> SyntaxFactoryStore
fn default() -> SyntaxFactoryStore
Returns the “default value” for a type. Read more
impl Service for SyntaxFactoryStore
Implement Service trait for ServiceRegistry compatibility.
Auto Trait Implementations§
impl !Freeze for SyntaxFactoryStore
impl !RefUnwindSafe for SyntaxFactoryStore
impl Send for SyntaxFactoryStore
impl Sync for SyntaxFactoryStore
impl Unpin for SyntaxFactoryStore
impl UnsafeUnpin for SyntaxFactoryStore
impl !UnwindSafe for SyntaxFactoryStore
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