pub struct DefaultServiceIntrospection;Expand description
Default implementation that reads from the global registry.
This implementation provides runtime introspection by reading from the global service registry.
§Example
ⓘ
use rapace_registry::introspection::DefaultServiceIntrospection;
let introspection = DefaultServiceIntrospection;
let services = introspection.list_services();
for service in services {
println!("Service: {}", service.name);
}Implementations§
Source§impl DefaultServiceIntrospection
impl DefaultServiceIntrospection
Sourcepub fn new() -> DefaultServiceIntrospection
pub fn new() -> DefaultServiceIntrospection
Create a new default introspection implementation.
Sourcepub fn list_services(&self) -> Vec<ServiceInfo>
pub fn list_services(&self) -> Vec<ServiceInfo>
List all services registered in the global registry.
Returns a snapshot of all currently registered services and their methods.
Sourcepub fn describe_service(&self, name: &str) -> Option<ServiceInfo>
pub fn describe_service(&self, name: &str) -> Option<ServiceInfo>
Describe a specific service by name.
Returns Some(ServiceInfo) if the service exists, None otherwise.
Sourcepub fn has_method(&self, method_id: u32) -> bool
pub fn has_method(&self, method_id: u32) -> bool
Check if a method ID is supported.
Returns true if any registered service has a method with this ID.
Trait Implementations§
Source§impl Clone for DefaultServiceIntrospection
impl Clone for DefaultServiceIntrospection
Source§fn clone(&self) -> DefaultServiceIntrospection
fn clone(&self) -> DefaultServiceIntrospection
Returns a duplicate of the value. Read more
1.0.0 · 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 DefaultServiceIntrospection
impl Debug for DefaultServiceIntrospection
Source§impl Default for DefaultServiceIntrospection
impl Default for DefaultServiceIntrospection
Source§fn default() -> DefaultServiceIntrospection
fn default() -> DefaultServiceIntrospection
Returns the “default value” for a type. Read more
Source§impl ServiceIntrospection for DefaultServiceIntrospection
impl ServiceIntrospection for DefaultServiceIntrospection
Source§async fn list_services(&self) -> Vec<ServiceInfo>
async fn list_services(&self) -> Vec<ServiceInfo>
List all services registered in this process. Read more
Source§async fn describe_service(&self, name: String) -> Option<ServiceInfo>
async fn describe_service(&self, name: String) -> Option<ServiceInfo>
Describe a specific service by name. Read more
Auto Trait Implementations§
impl Freeze for DefaultServiceIntrospection
impl RefUnwindSafe for DefaultServiceIntrospection
impl Send for DefaultServiceIntrospection
impl Sync for DefaultServiceIntrospection
impl Unpin for DefaultServiceIntrospection
impl UnwindSafe for DefaultServiceIntrospection
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