#[repr(C)]pub struct RSensorDescriptor {
pub id: RSensorId,
pub display_name: String,
pub unit: RUnit,
pub kind: RSensorKind,
pub category: RCategory,
pub native_rate_hz: f32,
pub min: Option<f64>,
pub max: Option<f64>,
pub device_id: Option<String>,
pub device_key: Option<String>,
pub tags: Vec<String>,
}Fields§
§id: RSensorId§display_name: String§unit: RUnit§kind: RSensorKind§category: RCategory§native_rate_hz: f32§min: Option<f64>§max: Option<f64>§device_id: Option<String>§device_key: Option<String>ABI v4: optional hardware-device key (raw string form). Validated
by the host via HardwareDeviceKey::try_new in host_init.
NEW: sensor tags for filtering and grouping in the UI.
Implementations§
Source§impl RSensorDescriptorwhere
Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>>: IStable,
Vec<String>: IStable,
Option<String>: IStable,
Option<f64>: IStable,
f32: IStable,
RCategory: IStable,
RSensorKind: IStable,
RUnit: IStable,
String: IStable,
RSensorId: IStable,
impl RSensorDescriptorwhere
Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>>: IStable,
Vec<String>: IStable,
Option<String>: IStable,
Option<f64>: IStable,
f32: IStable,
RCategory: IStable,
RSensorKind: IStable,
RUnit: IStable,
String: IStable,
RSensorId: IStable,
Sourcepub const fn has_optimal_layout() -> bool
pub const fn has_optimal_layout() -> bool
Returns true if the layout for RSensorDescriptor is smaller or equal to that Rust would have generated for it.
Trait Implementations§
Source§impl Clone for RSensorDescriptor
impl Clone for RSensorDescriptor
Source§fn clone(&self) -> RSensorDescriptor
fn clone(&self) -> RSensorDescriptor
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RSensorDescriptor
impl Debug for RSensorDescriptor
Source§impl From<RSensorDescriptor> for SensorDescriptor
impl From<RSensorDescriptor> for SensorDescriptor
Source§fn from(r: RSensorDescriptor) -> Self
fn from(r: RSensorDescriptor) -> Self
Converts to this type from the input type.
Source§impl From<SensorDescriptor> for RSensorDescriptor
impl From<SensorDescriptor> for RSensorDescriptor
Source§fn from(d: SensorDescriptor) -> Self
fn from(d: SensorDescriptor) -> Self
Converts to this type from the input type.
Source§impl IStable for RSensorDescriptorwhere
Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>>: IStable,
Vec<String>: IStable,
Option<String>: IStable,
Option<f64>: IStable,
f32: IStable,
RCategory: IStable,
RSensorKind: IStable,
RUnit: IStable,
String: IStable,
RSensorId: IStable,
impl IStable for RSensorDescriptorwhere
Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>>: IStable,
Vec<String>: IStable,
Option<String>: IStable,
Option<f64>: IStable,
f32: IStable,
RCategory: IStable,
RSensorKind: IStable,
RUnit: IStable,
String: IStable,
RSensorId: IStable,
Source§const REPORT: &'static TypeReport
const REPORT: &'static TypeReport
A compile-time generated report of the fields of the type, allowing for compatibility inspection.
Source§const ID: u64
const ID: u64
A stable (and ideally unique) identifier for the type. Often generated using
crate::report::gen_id, but can be manually set.Source§type ForbiddenValues = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::ForbiddenValues
type ForbiddenValues = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::ForbiddenValues
The values that the annotated type cannot occupy.
Source§type UnusedBits = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::UnusedBits
type UnusedBits = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::UnusedBits
The padding bits in the annotated types
Source§type Size = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::Size
type Size = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::Size
The size of the annotated type in bytes.
Source§type Align = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::Align
type Align = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::Align
The alignment of the annotated type in bytes.
Source§type HasExactlyOneNiche = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::HasExactlyOneNiche
type HasExactlyOneNiche = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::HasExactlyOneNiche
Allows the detection of whether or not
core::option::Options are stable: Read moreSource§type ContainsIndirections = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::ContainsIndirections
type ContainsIndirections = <Struct<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<FieldPair<RSensorId, String>, RUnit>, RSensorKind>, RCategory>, f32>, Option<f64>>, Option<f64>>, Option<String>>, Option<String>>, Vec<String>>> as IStable>::ContainsIndirections
Whether or not the type contains indirections (pointers, indices in independent data-structures…)
Auto Trait Implementations§
impl Freeze for RSensorDescriptor
impl RefUnwindSafe for RSensorDescriptor
impl Send for RSensorDescriptor
impl Sync for RSensorDescriptor
impl Unpin for RSensorDescriptor
impl UnsafeUnpin for RSensorDescriptor
impl UnwindSafe for RSensorDescriptor
Blanket Implementations§
Source§impl<Source> AccessAs for Source
impl<Source> AccessAs for Source
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