pub struct FTRView<'a> { /* private fields */ }Expand description
Zero-copy view over the field data of a FTR record.
Borrows the raw bytes and reads fields on demand via getters. Create one with Self::new or via [StdfRecordView::read_from_bytes]; convert back to an owned FTR with Self::to_owned.
Implementations§
Source§impl<'a> FTRView<'a>
impl<'a> FTRView<'a>
Sourcepub fn new(raw: &'a [u8], order: &ByteOrder) -> Self
pub fn new(raw: &'a [u8], order: &ByteOrder) -> Self
Scan the given raw data and store byte offset of each field.
pub fn test_num(&self) -> U4
pub fn head_num(&self) -> U1
pub fn site_num(&self) -> U1
pub fn test_flg(&self) -> B1
pub fn opt_flag(&self) -> B1
pub fn cycl_cnt(&self) -> U4
pub fn rel_vadr(&self) -> U4
pub fn rept_cnt(&self) -> U4
pub fn num_fail(&self) -> U4
pub fn xfail_ad(&self) -> I4
pub fn yfail_ad(&self) -> I4
pub fn vect_off(&self) -> I2
pub fn rtn_icnt(&self) -> U2
pub fn pgm_icnt(&self) -> U2
pub fn rtn_indx(&self) -> KxU2
pub fn rtn_stat(&self) -> KxN1
pub fn pgm_indx(&self) -> KxU2
pub fn pgm_stat(&self) -> KxN1
pub fn fail_pin(&self) -> DnRef<'a>
pub fn vect_nam(&self) -> CnRef<'a>
pub fn time_set(&self) -> CnRef<'a>
pub fn op_code(&self) -> CnRef<'a>
pub fn test_txt(&self) -> CnRef<'a>
pub fn alarm_id(&self) -> CnRef<'a>
pub fn prog_txt(&self) -> CnRef<'a>
pub fn rslt_txt(&self) -> CnRef<'a>
pub fn patg_num(&self) -> U1
pub fn spin_map(&self) -> DnRef<'a>
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for FTRView<'a>
impl<'a> RefUnwindSafe for FTRView<'a>
impl<'a> Send for FTRView<'a>
impl<'a> Sync for FTRView<'a>
impl<'a> Unpin for FTRView<'a>
impl<'a> UnsafeUnpin for FTRView<'a>
impl<'a> UnwindSafe for FTRView<'a>
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