pub struct SensorArray {
pub channels: Vec<SensorChannel>,
pub sensor_type: SensorType,
pub name: String,
}Expand description
Sensor array configuration (a collection of channels of one type).
Fields§
§channels: Vec<SensorChannel>All channels in the array.
sensor_type: SensorTypeSensor technology used by this array.
name: StringHuman-readable name for the array.
Implementations§
Source§impl SensorArray
impl SensorArray
Sourcepub fn num_channels(&self) -> usize
pub fn num_channels(&self) -> usize
Number of channels in the array.
Sourcepub fn get_channel(&self, index: usize) -> Option<&SensorChannel>
pub fn get_channel(&self, index: usize) -> Option<&SensorChannel>
Get a channel by its index within this array.
Trait Implementations§
Source§impl Clone for SensorArray
impl Clone for SensorArray
Source§fn clone(&self) -> SensorArray
fn clone(&self) -> SensorArray
Returns a duplicate 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 moreSource§impl Debug for SensorArray
impl Debug for SensorArray
Source§impl<'de> Deserialize<'de> for SensorArray
impl<'de> Deserialize<'de> for SensorArray
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for SensorArray
impl RefUnwindSafe for SensorArray
impl Send for SensorArray
impl Sync for SensorArray
impl Unpin for SensorArray
impl UnsafeUnpin for SensorArray
impl UnwindSafe for SensorArray
Blanket Implementations§
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