pub struct HostControllerProxy { /* private fields */ }Implementations§
Source§impl HostControllerProxy
impl HostControllerProxy
Sourcepub fn new(channel: AsyncChannel) -> Self
pub fn new(channel: AsyncChannel) -> Self
Create a new Proxy for fuchsia.bluetooth.affordances/HostController.
Sourcepub fn take_event_stream(&self) -> HostControllerEventStream
pub fn take_event_stream(&self) -> HostControllerEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
Sourcepub fn get_hosts(
&self,
) -> QueryResponseFut<HostControllerGetHostsResult, DefaultFuchsiaResourceDialect>
pub fn get_hosts( &self, ) -> QueryResponseFut<HostControllerGetHostsResult, DefaultFuchsiaResourceDialect>
Get all known hosts.
- error Returns
INTERNALif the operation failed (check logs).
Sourcepub fn set_discoverability(
&self,
payload: &HostControllerSetDiscoverabilityRequest,
) -> QueryResponseFut<HostControllerSetDiscoverabilityResult, DefaultFuchsiaResourceDialect>
pub fn set_discoverability( &self, payload: &HostControllerSetDiscoverabilityRequest, ) -> QueryResponseFut<HostControllerSetDiscoverabilityResult, DefaultFuchsiaResourceDialect>
Set discoverability state.
- error Returns
INTERNALif the operation failed (check logs).
Sourcepub fn set_local_name(
&self,
payload: &HostControllerSetLocalNameRequest,
) -> QueryResponseFut<HostControllerSetLocalNameResult, DefaultFuchsiaResourceDialect>
pub fn set_local_name( &self, payload: &HostControllerSetLocalNameRequest, ) -> QueryResponseFut<HostControllerSetLocalNameResult, DefaultFuchsiaResourceDialect>
Set the active host’s local name.
- request
nameName to assign to the host.
- error Returns
INTERNALif the operation failed (check logs).
Sourcepub fn start_pairing_delegate(
&self,
payload: &HostControllerStartPairingDelegateRequest,
) -> QueryResponseFut<HostControllerStartPairingDelegateResult, DefaultFuchsiaResourceDialect>
pub fn start_pairing_delegate( &self, payload: &HostControllerStartPairingDelegateRequest, ) -> QueryResponseFut<HostControllerStartPairingDelegateResult, DefaultFuchsiaResourceDialect>
Start a pairing delegate to respond to pairing procedures. Only one pairing delegate can be set at a time host-wide. Calling this while a delegate started by this method is already active will drop and overwrite the existing delegate. If this is called while a delegate started through other means is active, the new delegate will be closed immediately. Closing a pairing delegate after it is set aborts all ongoing pairing procedures without accepting and unsets the delegate.
If no pairing delegate is set, all pairings will be rejected even if the peer connection was initiated by the host.
- error Returns
INTERNALif the operation failed (check logs).
Sourcepub fn stop_pairing_delegate(
&self,
) -> QueryResponseFut<HostControllerStopPairingDelegateResult, DefaultFuchsiaResourceDialect>
pub fn stop_pairing_delegate( &self, ) -> QueryResponseFut<HostControllerStopPairingDelegateResult, DefaultFuchsiaResourceDialect>
Stop a pairing delegate previously started by [StartPairingDelegate]. This will abort all
ongoing pairing procedures without accepting and unsets the delegate.
This method can only stop a delegate started by [StartPairingDelegate], and will not stop
a delegate started through other means.
- error Returns
INTERNALif the operation failed (check logs).
Sourcepub fn set_device_class(
&self,
payload: &HostControllerSetDeviceClassRequest,
) -> QueryResponseFut<HostControllerSetDeviceClassResult, DefaultFuchsiaResourceDialect>
pub fn set_device_class( &self, payload: &HostControllerSetDeviceClassRequest, ) -> QueryResponseFut<HostControllerSetDeviceClassResult, DefaultFuchsiaResourceDialect>
Set the active host’s device class.
- error Returns
INTERNALif the operation failed (check logs).
Trait Implementations§
Source§impl Clone for HostControllerProxy
impl Clone for HostControllerProxy
Source§fn clone(&self) -> HostControllerProxy
fn clone(&self) -> HostControllerProxy
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for HostControllerProxy
impl Debug for HostControllerProxy
Source§impl HostControllerProxyInterface for HostControllerProxy
impl HostControllerProxyInterface for HostControllerProxy
type GetHostsResponseFut = QueryResponseFut<Result<HostControllerGetHostsResponse, Error>>
type SetDiscoverabilityResponseFut = QueryResponseFut<Result<(), Error>>
type SetLocalNameResponseFut = QueryResponseFut<Result<(), Error>>
type StartPairingDelegateResponseFut = QueryResponseFut<Result<(), Error>>
type StopPairingDelegateResponseFut = QueryResponseFut<Result<(), Error>>
type SetDeviceClassResponseFut = QueryResponseFut<Result<(), Error>>
fn get_hosts(&self) -> Self::GetHostsResponseFut
fn set_discoverability( &self, payload: &HostControllerSetDiscoverabilityRequest, ) -> Self::SetDiscoverabilityResponseFut
fn set_local_name( &self, payload: &HostControllerSetLocalNameRequest, ) -> Self::SetLocalNameResponseFut
fn start_pairing_delegate( &self, payload: &HostControllerStartPairingDelegateRequest, ) -> Self::StartPairingDelegateResponseFut
fn stop_pairing_delegate(&self) -> Self::StopPairingDelegateResponseFut
fn set_device_class( &self, payload: &HostControllerSetDeviceClassRequest, ) -> Self::SetDeviceClassResponseFut
Source§impl Proxy for HostControllerProxy
impl Proxy for HostControllerProxy
Source§type Protocol = HostControllerMarker
type Protocol = HostControllerMarker
Proxy controls.Source§fn from_channel(inner: AsyncChannel) -> Self
fn from_channel(inner: AsyncChannel) -> Self
Source§fn into_channel(self) -> Result<AsyncChannel, Self>
fn into_channel(self) -> Result<AsyncChannel, Self>
Source§fn as_channel(&self) -> &AsyncChannel
fn as_channel(&self) -> &AsyncChannel
Source§fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
Source§fn on_closed(&self) -> OnSignals<'_, Unowned<'_, NullableHandle>>
fn on_closed(&self) -> OnSignals<'_, Unowned<'_, NullableHandle>>
PEER_CLOSED signal.