pub struct InputDeviceProxy { /* private fields */ }
Implementations§
source§impl InputDeviceProxy
impl InputDeviceProxy
sourcepub fn new(channel: AsyncChannel) -> Self
pub fn new(channel: AsyncChannel) -> Self
Create a new Proxy for fuchsia.input.report/InputDevice.
sourcepub fn take_event_stream(&self) -> InputDeviceEventStream
pub fn take_event_stream(&self) -> InputDeviceEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
sourcepub fn get_input_reports_reader(
&self,
reader: ServerEnd<InputReportsReaderMarker>
) -> Result<(), Error>
pub fn get_input_reports_reader( &self, reader: ServerEnd<InputReportsReaderMarker> ) -> Result<(), Error>
Open a new InputReportsReader on this device. Each reader receives their own reports.
sourcepub fn get_descriptor(&self) -> QueryResponseFut<DeviceDescriptor>
pub fn get_descriptor(&self) -> QueryResponseFut<DeviceDescriptor>
Gets the device descriptor for this device.
sourcepub fn send_output_report(
&self,
report: &OutputReport
) -> QueryResponseFut<InputDeviceSendOutputReportResult>
pub fn send_output_report( &self, report: &OutputReport ) -> QueryResponseFut<InputDeviceSendOutputReportResult>
Send a single output report to the device. This will throw an error if the output report does not follow the OutputDescriptor.
sourcepub fn get_feature_report(
&self
) -> QueryResponseFut<InputDeviceGetFeatureReportResult>
pub fn get_feature_report( &self ) -> QueryResponseFut<InputDeviceGetFeatureReportResult>
Get the feature report for a given device. This requests the state of the device’s features.
sourcepub fn set_feature_report(
&self,
report: &FeatureReport
) -> QueryResponseFut<InputDeviceSetFeatureReportResult>
pub fn set_feature_report( &self, report: &FeatureReport ) -> QueryResponseFut<InputDeviceSetFeatureReportResult>
Set the feature report for a given device. This sets the state of the device’s features.
sourcepub fn get_input_report(
&self,
device_type: DeviceType
) -> QueryResponseFut<InputDeviceGetInputReportResult>
pub fn get_input_report( &self, device_type: DeviceType ) -> QueryResponseFut<InputDeviceGetInputReportResult>
For general cases, InputReportReader is the preferred way of getting
InputReports. For devices that don’t send InputReports naturally, this
method can be used to request a report from the device type indicated.
Does not block, and returns ZX_ERR_NOT_SUPPORTED if GetInputReport
or
device_type
are not supported.
Trait Implementations§
source§impl Clone for InputDeviceProxy
impl Clone for InputDeviceProxy
source§fn clone(&self) -> InputDeviceProxy
fn clone(&self) -> InputDeviceProxy
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for InputDeviceProxy
impl Debug for InputDeviceProxy
source§impl InputDeviceProxyInterface for InputDeviceProxy
impl InputDeviceProxyInterface for InputDeviceProxy
fn get_input_reports_reader( &self, reader: ServerEnd<InputReportsReaderMarker> ) -> Result<(), Error>
type GetDescriptorResponseFut = QueryResponseFut<DeviceDescriptor>
fn get_descriptor(&self) -> Self::GetDescriptorResponseFut
type SendOutputReportResponseFut = QueryResponseFut<Result<(), i32>>
fn send_output_report( &self, report: &OutputReport ) -> Self::SendOutputReportResponseFut
type GetFeatureReportResponseFut = QueryResponseFut<Result<FeatureReport, i32>>
fn get_feature_report(&self) -> Self::GetFeatureReportResponseFut
type SetFeatureReportResponseFut = QueryResponseFut<Result<(), i32>>
fn set_feature_report( &self, report: &FeatureReport ) -> Self::SetFeatureReportResponseFut
type GetInputReportResponseFut = QueryResponseFut<Result<InputReport, i32>>
fn get_input_report( &self, device_type: DeviceType ) -> Self::GetInputReportResponseFut
source§impl Proxy for InputDeviceProxy
impl Proxy for InputDeviceProxy
§type Protocol = InputDeviceMarker
type Protocol = InputDeviceMarker
Proxy
controls.