Struct SensorFeatureDescriptor
pub struct SensorFeatureDescriptor {
pub report_interval: Option<Axis>,
pub sensitivity: Option<Vec<SensorAxis>>,
pub supports_reporting_state: Option<bool>,
pub threshold_high: Option<Vec<SensorAxis>>,
pub threshold_low: Option<Vec<SensorAxis>>,
pub sampling_rate: Option<Axis>,
pub report_id: Option<u8>,
/* private fields */
}
Expand description
Describes the format of the sensor’s feature report. Feature reports can be requested from the sensor, or sent to the sensor.
Fields§
§report_interval: Option<Axis>
Describes the minimum and maximum reporting interval this sensor supports.
sensitivity: Option<Vec<SensorAxis>>
Sets the sensitivity for the given SensorType
.
supports_reporting_state: Option<bool>
If this is true then SensorFeatureReport supports setting a SensorReportingState.
threshold_high: Option<Vec<SensorAxis>>
Sets the high threshold values for the given SensorType
.
threshold_low: Option<Vec<SensorAxis>>
Sets the low threshold values for the given SensorType
.
sampling_rate: Option<Axis>
Describes the minimum and maximum sampling rate this sensor supports.
report_id: Option<u8>
ReportID of current descriptor. Report with same report ID should be associated with this descriptor.
Trait Implementations§
§impl Clone for SensorFeatureDescriptor
impl Clone for SensorFeatureDescriptor
§fn clone(&self) -> SensorFeatureDescriptor
fn clone(&self) -> SensorFeatureDescriptor
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more§impl Debug for SensorFeatureDescriptor
impl Debug for SensorFeatureDescriptor
§impl<D> Decode<SensorFeatureDescriptor, D> for SensorFeatureDescriptorwhere
D: ResourceDialect,
impl<D> Decode<SensorFeatureDescriptor, D> for SensorFeatureDescriptorwhere
D: ResourceDialect,
§fn new_empty() -> SensorFeatureDescriptor
fn new_empty() -> SensorFeatureDescriptor
Creates a valid instance of
Self
. The specific value does not matter,
since it will be overwritten by decode
.§impl Default for SensorFeatureDescriptor
impl Default for SensorFeatureDescriptor
§fn default() -> SensorFeatureDescriptor
fn default() -> SensorFeatureDescriptor
Returns the “default value” for a type. Read more
§impl<D> Encode<SensorFeatureDescriptor, D> for &SensorFeatureDescriptorwhere
D: ResourceDialect,
impl<D> Encode<SensorFeatureDescriptor, D> for &SensorFeatureDescriptorwhere
D: ResourceDialect,
§impl PartialEq for SensorFeatureDescriptor
impl PartialEq for SensorFeatureDescriptor
§impl TypeMarker for SensorFeatureDescriptor
impl TypeMarker for SensorFeatureDescriptor
§type Owned = SensorFeatureDescriptor
type Owned = SensorFeatureDescriptor
The owned Rust type which this FIDL type decodes into.
§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Returns the minimum required alignment of the inline portion of the
encoded object. It must be a (nonzero) power of two.
§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
Returns the size of the inline portion of the encoded object, including
padding for alignment. Must be a multiple of
inline_align
.§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Returns true if the memory layout of
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 more§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Returns true if the memory layout of
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.§impl ValueTypeMarker for SensorFeatureDescriptor
impl ValueTypeMarker for SensorFeatureDescriptor
§type Borrowed<'a> = &'a SensorFeatureDescriptor
type Borrowed<'a> = &'a SensorFeatureDescriptor
The Rust type to use for encoding. This is a particular
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read more§fn borrow(
value: &<SensorFeatureDescriptor as TypeMarker>::Owned,
) -> <SensorFeatureDescriptor as ValueTypeMarker>::Borrowed<'_>
fn borrow( value: &<SensorFeatureDescriptor as TypeMarker>::Owned, ) -> <SensorFeatureDescriptor as ValueTypeMarker>::Borrowed<'_>
Cheaply converts from
&Self::Owned
to Self::Borrowed
.impl Persistable for SensorFeatureDescriptor
impl StructuralPartialEq for SensorFeatureDescriptor
Auto Trait Implementations§
impl Freeze for SensorFeatureDescriptor
impl RefUnwindSafe for SensorFeatureDescriptor
impl Send for SensorFeatureDescriptor
impl Sync for SensorFeatureDescriptor
impl Unpin for SensorFeatureDescriptor
impl UnwindSafe for SensorFeatureDescriptor
Blanket Implementations§
§impl<T> Body for Twhere
T: Persistable,
impl<T> Body for Twhere
T: Persistable,
§type MarkerAtTopLevel = T
type MarkerAtTopLevel = T
The marker type to use when the body is at the top-level.
§type MarkerInResultUnion = T
type MarkerInResultUnion = T
The marker type to use when the body is nested in a result union.
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more