ChannelGroup

Struct ChannelGroup 

Source
pub struct ChannelGroup<'a> { /* private fields */ }
Expand description

High level wrapper for a channel group.

The struct references raw channel group data and provides ergonomic access to its metadata and channels without decoding any actual samples.

Implementations§

Source§

impl<'a> ChannelGroup<'a>

Source

pub fn new( raw_data_group: &'a RawDataGroup, raw_channel_group: &'a RawChannelGroup, mmap: &'a [u8], ) -> Self

Create a new ChannelGroup referencing the underlying raw blocks.

§Arguments
  • raw_data_group - Parent data group containing this channel group
  • raw_channel_group - The raw channel group block
  • mmap - Memory mapped file backing all data
§Returns

A ChannelGroup handle with no decoded data.

Source

pub fn name(&self) -> Result<Option<String>>

Retrieve the human readable group name.

Source

pub fn comment(&self) -> Result<Option<String>>

Retrieve the group comment if present.

Source

pub fn source(&self) -> Result<Option<SourceInfo>>

Get the acquisition source information if available.

Source

pub fn channels(&self) -> Vec<Channel<'a>>

Build all Channel objects for this group.

No channel data is decoded; the returned channels simply reference the raw blocks.

Source

pub fn raw_data_group(&self) -> &RawDataGroup

Get the raw data group (for internal use)

Source

pub fn raw_channel_group(&self) -> &RawChannelGroup

Get the raw channel group (for internal use)

Source

pub fn mmap(&self) -> &[u8]

Get the memory mapped data (for internal use)

Auto Trait Implementations§

§

impl<'a> Freeze for ChannelGroup<'a>

§

impl<'a> RefUnwindSafe for ChannelGroup<'a>

§

impl<'a> Send for ChannelGroup<'a>

§

impl<'a> Sync for ChannelGroup<'a>

§

impl<'a> Unpin for ChannelGroup<'a>

§

impl<'a> UnwindSafe for ChannelGroup<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.