pub struct ChartMLRegistry { /* private fields */ }Expand description
Central plugin registry. Holds all registered plugins and provides lookup.
Implementations§
Source§impl ChartMLRegistry
impl ChartMLRegistry
pub fn new() -> Self
pub fn register_data_source( &mut self, name: &str, source: impl DataSource + 'static, )
pub fn register_transform( &mut self, middleware: impl TransformMiddleware + 'static, )
pub fn set_transform(&mut self, middleware: impl TransformMiddleware + 'static)
pub fn register_renderer( &mut self, chart_type: &str, renderer: impl ChartRenderer + 'static, )
pub fn set_datasource_resolver( &mut self, resolver: impl DatasourceResolver + 'static, )
pub fn get_renderer(&self, chart_type: &str) -> Option<&dyn ChartRenderer>
pub fn get_data_source(&self, name: &str) -> Option<&dyn DataSource>
Sourcepub fn get_transform(&self) -> Option<&dyn TransformMiddleware>
pub fn get_transform(&self) -> Option<&dyn TransformMiddleware>
Get the first registered transform middleware (if any).
pub fn has_renderer(&self, chart_type: &str) -> bool
pub fn renderer_types(&self) -> Vec<String>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ChartMLRegistry
impl !RefUnwindSafe for ChartMLRegistry
impl Send for ChartMLRegistry
impl Sync for ChartMLRegistry
impl Unpin for ChartMLRegistry
impl UnsafeUnpin for ChartMLRegistry
impl !UnwindSafe for ChartMLRegistry
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