pub struct InputReport {
pub event_time: Option<i64>,
pub mouse: Option<MouseInputReport>,
pub sensor: Option<SensorInputReport>,
pub touch: Option<TouchInputReport>,
pub keyboard: Option<KeyboardInputReport>,
pub consumer_control: Option<ConsumerControlInputReport>,
pub trace_id: Option<u64>,
pub report_id: Option<u8>,
pub wake_lease: Option<EventPair>,
/* private fields */
}
Expand description
An InputReport
is a single report that is created by an input device.
An InputReport
can contain one of many different report types. The report
types are not mutually exclusive. The event_time
is the time in
nanoseconds when the report was generated.
Fields§
§event_time: Option<i64>
event_time
is in nanoseconds when the event was recorded.
mouse: Option<MouseInputReport>
mouse
is the report generated if the device contains a mouse.
sensor: Option<SensorInputReport>
sensor
is the report generated if the device contains a sensor.
touch: Option<TouchInputReport>
touch
is the report generated if the device contains a touch device.
keyboard: Option<KeyboardInputReport>
keyboard
is the report generated if the device contains a keyboard.
consumer_control: Option<ConsumerControlInputReport>
consumer_controls
is the report generated if the device contains a
ConsumerControl device.
trace_id: Option<u64>
Unique ID to connect trace async begin/end events.
report_id: Option<u8>
The Descriptor that describes this InputReport will have a matching ReportID. If this doesn’t exist, report_id is 0.
wake_lease: Option<EventPair>
Optional wake lease for power baton passing.
Trait Implementations§
Source§impl Debug for InputReport
impl Debug for InputReport
Source§impl Decode<InputReport, DefaultFuchsiaResourceDialect> for InputReport
impl Decode<InputReport, DefaultFuchsiaResourceDialect> for InputReport
Source§impl Default for InputReport
impl Default for InputReport
Source§fn default() -> InputReport
fn default() -> InputReport
Source§impl Encode<InputReport, DefaultFuchsiaResourceDialect> for &mut InputReport
impl Encode<InputReport, DefaultFuchsiaResourceDialect> for &mut InputReport
Source§impl PartialEq for InputReport
impl PartialEq for InputReport
Source§impl ResourceTypeMarker for InputReport
impl ResourceTypeMarker for InputReport
Source§type Borrowed<'a> = &'a mut InputReport
type Borrowed<'a> = &'a mut InputReport
Encode<Self>
type cheaply obtainable from &mut Self::Owned
. There are three cases: Read moreSource§fn take_or_borrow<'a>(
value: &'a mut <Self as TypeMarker>::Owned,
) -> Self::Borrowed<'a>
fn take_or_borrow<'a>( value: &'a mut <Self as TypeMarker>::Owned, ) -> Self::Borrowed<'a>
&mut Self::Owned
to Self::Borrowed
. For
HandleBased
types this is “take” (it returns an owned handle and
replaces value
with Handle::invalid
), and for all other types it is
“borrow” (just converts from one reference to another).Source§impl TypeMarker for InputReport
impl TypeMarker for InputReport
Source§type Owned = InputReport
type Owned = InputReport
Source§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Source§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
inline_align
.Source§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read moreSource§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.