pub struct RegistryFilter { /* private fields */ }Expand description
Filter criteria for registry lookups.
All active criteria are combined with AND semantics: a registration must match every specified filter to be included in results.
Implementations§
Source§impl RegistryFilter
impl RegistryFilter
Sourcepub fn version_prefix(self, prefix: &str) -> Self
pub fn version_prefix(self, prefix: &str) -> Self
Filter by version prefix (e.g. "1." matches "1.0.0", "1.2.3").
Sourcepub fn tag(self, key: &str, value: &str) -> Self
pub fn tag(self, key: &str, value: &str) -> Self
Require a tag key-value pair (AND with other tags).
Sourcepub fn health(self, status: HealthStatus) -> Self
pub fn health(self, status: HealthStatus) -> Self
Filter by health status.
Sourcepub fn matches(&self, reg: &ServiceRegistration) -> bool
pub fn matches(&self, reg: &ServiceRegistration) -> bool
Test whether a registration matches all active filter criteria.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RegistryFilter
impl RefUnwindSafe for RegistryFilter
impl Send for RegistryFilter
impl Sync for RegistryFilter
impl Unpin for RegistryFilter
impl UnwindSafe for RegistryFilter
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