pub fn event_stream_from_state<I: FidlRouteIpExt>(
    routes_state: &<I::StateMarker as ProtocolMarker>::Proxy
) -> Result<impl Stream<Item = Result<Event<I>, WatchError>>, WatcherCreationError>
Expand description

Connects to the watcher protocol and converts the Hanging-Get style API into an Event stream.

Each call to Watch returns a batch of events, which are flattened into a single stream. If an error is encountered while calling Watch or while converting the event, the stream is immediately terminated.