pub struct ChannelSynchronousProxy { /* private fields */ }
Implementations§
Source§impl ChannelSynchronousProxy
impl ChannelSynchronousProxy
pub fn new(channel: Channel) -> Self
pub fn into_channel(self) -> Channel
Sourcepub fn wait_for_event(
&self,
deadline: MonotonicInstant,
) -> Result<ChannelEvent, Error>
pub fn wait_for_event( &self, deadline: MonotonicInstant, ) -> Result<ChannelEvent, 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 send_(
&self,
packets: &[Packet],
___deadline: MonotonicInstant,
) -> Result<(), Error>
pub fn send_( &self, packets: &[Packet], ___deadline: MonotonicInstant, ) -> Result<(), Error>
Send multiple packets of data over the channel. Only one Send
may be pending at a time.
Sourcepub fn receive(
&self,
___deadline: MonotonicInstant,
) -> Result<Vec<Packet>, Error>
pub fn receive( &self, ___deadline: MonotonicInstant, ) -> Result<Vec<Packet>, Error>
Hanging get that waits for inbound packets. Only one Receive
may be pending at a time.
Sourcepub fn watch_channel_parameters(
&self,
___deadline: MonotonicInstant,
) -> Result<ChannelParameters, Error>
pub fn watch_channel_parameters( &self, ___deadline: MonotonicInstant, ) -> Result<ChannelParameters, Error>
For RFCOMM channels, this will not return and calls will hang indefinitely.
For BR/EDR L2CAP connection-oriented channels this will currently not
return and calls will hang indefinitely. The initial channel parameters
are provided in [fuchsia.bluetooth.bredr/Channel
].
For LE L2CAP connection-oriented channels, the first call will
immediately return the parameters of the remote side of the channel.
Subsequent calls will hang until the ChannelParameters
change, at
which point it will return the new parameters, including those that have
not changed.
Trait Implementations§
Source§impl Debug for ChannelSynchronousProxy
impl Debug for ChannelSynchronousProxy
Source§impl SynchronousProxy for ChannelSynchronousProxy
impl SynchronousProxy for ChannelSynchronousProxy
Source§type Proxy = ChannelProxy
type Proxy = ChannelProxy
Source§type Protocol = ChannelMarker
type Protocol = ChannelMarker
Proxy
controls.