Struct timsrust::FileReader
source · pub struct FileReader { /* private fields */ }
Implementations§
source§impl FileReader
impl FileReader
NOTE: The functions to read a single frame or spectrum are not optimized.
In case many frames or spectra are required, it is best to use
any of the functions that directly return a Vec
.
pub fn new<T: AsRef<Path>>(path_name: T) -> Result<Self, Error>
pub fn read_single_frame(&self, index: usize) -> Frame
pub fn read_all_frames(&self) -> Vec<Frame>
sourcepub fn read_all_ms1_frames(&self) -> Vec<Frame>
pub fn read_all_ms1_frames(&self) -> Vec<Frame>
NOTE: The returned vec contains all frames to not disrupt indexing. MS2 frames are set to unknown and not read.
sourcepub fn read_all_ms2_frames(&self) -> Vec<Frame>
pub fn read_all_ms2_frames(&self) -> Vec<Frame>
NOTE: The returned vec contains all frames to not disrupt indexing. MS1 frames are set to unknown and not read.
pub fn read_single_spectrum(&self, index: usize) -> Spectrum
sourcepub fn read_all_spectra(&self) -> Vec<Spectrum>
pub fn read_all_spectra(&self) -> Vec<Spectrum>
NOTE: ddaPASEF MS2 spectra are automatically calibrated with
all unfragmented precursor signals.
Hence, reading spectra individually through read_single_spectrum
might yield slightly different mz values.
pub fn get_frame_converter(&self) -> Result<Frame2RtConverter, Error>
pub fn get_scan_converter(&self) -> Result<Scan2ImConverter, Error>
pub fn get_tof_converter(&self) -> Result<Tof2MzConverter, Error>
Auto Trait Implementations§
impl RefUnwindSafe for FileReader
impl Send for FileReader
impl Sync for FileReader
impl Unpin for FileReader
impl UnwindSafe for FileReader
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