pub struct ServiceRegistry { /* private fields */ }Expand description
Service registry that manages all available providers.
Implementations§
Source§impl ServiceRegistry
impl ServiceRegistry
Sourcepub fn new() -> Self
pub fn new() -> Self
Create a new registry with all built-in providers. Only 5 core services are supported: Docker, Nginx, PostgreSQL, Redis, Node.js.
Sourcepub fn detect_services(&self, probe_output: &ProbeOutput) -> Vec<ServiceKind>
pub fn detect_services(&self, probe_output: &ProbeOutput) -> Vec<ServiceKind>
Detect which services are present based on probe output.
Returns a list of service kinds that were detected.
Sourcepub fn get_provider(&self, kind: &ServiceKind) -> Option<&dyn ServiceProvider>
pub fn get_provider(&self, kind: &ServiceKind) -> Option<&dyn ServiceProvider>
Get a provider by service kind.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for ServiceRegistry
impl !UnwindSafe for ServiceRegistry
impl Freeze for ServiceRegistry
impl Send for ServiceRegistry
impl Sync for ServiceRegistry
impl Unpin for ServiceRegistry
impl UnsafeUnpin for ServiceRegistry
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