pub enum HostControllerRequest {
GetHosts {
responder: HostControllerGetHostsResponder,
},
SetDiscoverability {
payload: HostControllerSetDiscoverabilityRequest,
responder: HostControllerSetDiscoverabilityResponder,
},
SetLocalName {
payload: HostControllerSetLocalNameRequest,
responder: HostControllerSetLocalNameResponder,
},
StartPairingDelegate {
payload: HostControllerStartPairingDelegateRequest,
responder: HostControllerStartPairingDelegateResponder,
},
StopPairingDelegate {
responder: HostControllerStopPairingDelegateResponder,
},
SetDeviceClass {
payload: HostControllerSetDeviceClassRequest,
responder: HostControllerSetDeviceClassResponder,
},
#[non_exhaustive] _UnknownMethod {
ordinal: u64,
control_handle: HostControllerControlHandle,
method_type: MethodType,
},
}Variants§
GetHosts
Get all known hosts.
- error Returns
INTERNALif the operation failed (check logs).
Fields
responder: HostControllerGetHostsResponderSetDiscoverability
Set discoverability state.
- error Returns
INTERNALif the operation failed (check logs).
Fields
responder: HostControllerSetDiscoverabilityResponderSetLocalName
Set the active host’s local name.
- request
nameName to assign to the host.
- error Returns
INTERNALif the operation failed (check logs).
StartPairingDelegate
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).
Fields
responder: HostControllerStartPairingDelegateResponderStopPairingDelegate
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).
Fields
responder: HostControllerStopPairingDelegateResponderSetDeviceClass
Set the active host’s device class.
- error Returns
INTERNALif the operation failed (check logs).
Fields
payload: HostControllerSetDeviceClassRequestresponder: HostControllerSetDeviceClassResponder#[non_exhaustive]_UnknownMethod
An interaction was received which does not match any known method.
Fields
This variant is marked as non-exhaustive
control_handle: HostControllerControlHandlemethod_type: MethodTypeImplementations§
Source§impl HostControllerRequest
impl HostControllerRequest
pub fn into_get_hosts(self) -> Option<HostControllerGetHostsResponder>
pub fn into_set_discoverability( self, ) -> Option<(HostControllerSetDiscoverabilityRequest, HostControllerSetDiscoverabilityResponder)>
pub fn into_set_local_name( self, ) -> Option<(HostControllerSetLocalNameRequest, HostControllerSetLocalNameResponder)>
pub fn into_start_pairing_delegate( self, ) -> Option<(HostControllerStartPairingDelegateRequest, HostControllerStartPairingDelegateResponder)>
pub fn into_stop_pairing_delegate( self, ) -> Option<HostControllerStopPairingDelegateResponder>
pub fn into_set_device_class( self, ) -> Option<(HostControllerSetDeviceClassRequest, HostControllerSetDeviceClassResponder)>
Sourcepub fn method_name(&self) -> &'static str
pub fn method_name(&self) -> &'static str
Name of the method defined in FIDL