pub enum PortWatcherRequest {
Watch {
responder: PortWatcherWatchResponder,
},
}Expand description
Provides iteration over and updates for ports attached to a device.
Variants§
Watch
Get the next port event.
The first N calls return [DevicePortEvent.existing] where N is the
number of ports present on the device at the time of the watcher’s
creation. The next call returns [DevicePortEvent.idle] to indicate the
end of existing ports. Subsequent calls block until a port is added
([DevicePortEvent.added]) or removed ([DevicePortEvent.removed]).
The server closes the PortWatcher channel with ZX_ERR_CANCELED if
the number of unread events reaches a server-selected limit that is at
least two times MAX_PORTS. Clients are encouraged to maintain a
hanging call to Watch at all times to avoid triggering this condition.
- response
eventnext port event.
Fields
§
responder: PortWatcherWatchResponderImplementations§
Source§impl PortWatcherRequest
impl PortWatcherRequest
pub fn into_watch(self) -> Option<PortWatcherWatchResponder>
Sourcepub fn method_name(&self) -> &'static str
pub fn method_name(&self) -> &'static str
Name of the method defined in FIDL
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PortWatcherRequest
impl !RefUnwindSafe for PortWatcherRequest
impl Send for PortWatcherRequest
impl Sync for PortWatcherRequest
impl Unpin for PortWatcherRequest
impl !UnwindSafe for PortWatcherRequest
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