pub struct RouteValidatorSynchronousProxy { /* private fields */ }
Implementations§
Source§impl RouteValidatorSynchronousProxy
impl RouteValidatorSynchronousProxy
pub fn new(channel: Channel) -> Self
pub fn into_channel(self) -> Channel
Sourcepub fn wait_for_event(
&self,
deadline: MonotonicInstant,
) -> Result<RouteValidatorEvent, Error>
pub fn wait_for_event( &self, deadline: MonotonicInstant, ) -> Result<RouteValidatorEvent, Error>
Waits until an event arrives and returns it. It is safe for other threads to make concurrent requests while waiting for an event.
Sourcepub fn validate(
&self,
moniker: &str,
___deadline: MonotonicInstant,
) -> Result<RouteValidatorValidateResult, Error>
pub fn validate( &self, moniker: &str, ___deadline: MonotonicInstant, ) -> Result<RouteValidatorValidateResult, Error>
Routes all incoming and exposed capabilities of a component identified by the given moniker. If the routing failed, an error is returned in the response. This function may cause components to be resolved.
Errors:
- INVALID_ARGUMENTS: The given moniker is not valid.
- INSTANCE_NOT_FOUND: No instance was found matching the given moniker.
Sourcepub fn route(
&self,
moniker: &str,
targets: &[RouteTarget],
___deadline: MonotonicInstant,
) -> Result<RouteValidatorRouteResult, Error>
pub fn route( &self, moniker: &str, targets: &[RouteTarget], ___deadline: MonotonicInstant, ) -> Result<RouteValidatorRouteResult, Error>
Routes a component’s used or exposed capabilities, and returns information about them.
If targets
is empty, returns results for all the component’s used and
exposed capabilities. Otherwise, returns only results for capabilities
specified in targets
.
This method only supports routing namespace capabilities (protocols, directories, services, and storage).
Errors:
- INVALID_ARGUMENTS: The given moniker or name is not valid, or
name
is not a namespace capability. - INSTANCE_NOT_FOUND: No instance was found matching the given moniker.
- RESOURCE_NOT_FOUND: No capability was found matching one of the given names.
Trait Implementations§
Source§impl SynchronousProxy for RouteValidatorSynchronousProxy
impl SynchronousProxy for RouteValidatorSynchronousProxy
Source§type Proxy = RouteValidatorProxy
type Proxy = RouteValidatorProxy
The async proxy for the same protocol.
Source§type Protocol = RouteValidatorMarker
type Protocol = RouteValidatorMarker
The protocol which this
Proxy
controls.Source§fn from_channel(inner: Channel) -> Self
fn from_channel(inner: Channel) -> Self
Create a proxy over the given channel.
Source§fn into_channel(self) -> Channel
fn into_channel(self) -> Channel
Convert the proxy back into a channel.
Source§fn as_channel(&self) -> &Channel
fn as_channel(&self) -> &Channel
Get a reference to the proxy’s underlying channel. Read more
Auto Trait Implementations§
impl Freeze for RouteValidatorSynchronousProxy
impl RefUnwindSafe for RouteValidatorSynchronousProxy
impl Send for RouteValidatorSynchronousProxy
impl Sync for RouteValidatorSynchronousProxy
impl Unpin for RouteValidatorSynchronousProxy
impl UnwindSafe for RouteValidatorSynchronousProxy
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