Trait fidl::endpoints::RequestStream
source · pub trait RequestStream: Sized + Send + Stream + TryStream<Error = Error> + Unpin {
type Protocol: ProtocolMarker<RequestStream = Self>;
type ControlHandle: ControlHandle;
// Required methods
fn control_handle(&self) -> Self::ControlHandle;
fn from_channel(inner: AsyncChannel) -> Self;
fn into_inner(self) -> (Arc<ServeInner>, bool);
fn from_inner(inner: Arc<ServeInner>, is_terminated: bool) -> Self;
// Provided method
fn cast_stream<T: RequestStream>(self) -> T { ... }
}
Expand description
A stream of requests coming into a FIDL server over a channel.
Required Associated Types§
sourcetype Protocol: ProtocolMarker<RequestStream = Self>
type Protocol: ProtocolMarker<RequestStream = Self>
The protocol which this RequestStream
serves.
sourcetype ControlHandle: ControlHandle
type ControlHandle: ControlHandle
The control handle for this RequestStream
.
Required Methods§
sourcefn control_handle(&self) -> Self::ControlHandle
fn control_handle(&self) -> Self::ControlHandle
Returns a copy of the ControlHandle
for the given stream.
This handle can be used to send events or shut down the request stream.
sourcefn from_channel(inner: AsyncChannel) -> Self
fn from_channel(inner: AsyncChannel) -> Self
Create a request stream from the given channel.
sourcefn into_inner(self) -> (Arc<ServeInner>, bool)
fn into_inner(self) -> (Arc<ServeInner>, bool)
Convert this channel into its underlying components.
sourcefn from_inner(inner: Arc<ServeInner>, is_terminated: bool) -> Self
fn from_inner(inner: Arc<ServeInner>, is_terminated: bool) -> Self
Create this channel from its underlying components.
Provided Methods§
sourcefn cast_stream<T: RequestStream>(self) -> T
fn cast_stream<T: RequestStream>(self) -> T
Convert this FIDL request stream into a request stream of another FIDL protocol.
Object Safety§
This trait is not object safe.