Struct cea708_types::CCDataParser
source · pub struct CCDataParser { /* private fields */ }Implementations§
source§impl CCDataParser
impl CCDataParser
sourcepub fn new() -> Self
pub fn new() -> Self
Create a new CCDataParser
pub fn handle_cea608(&mut self)
sourcepub fn push(&mut self, data: &[u8]) -> Result<(), ParserError>
pub fn push(&mut self, data: &[u8]) -> Result<(), ParserError>
Push a complete cc_data packet into the parser for processing.
Will fail with ParserError::LengthMismatch if the length of the data does not match the
number of cc triples specified in the cc_data header.
Ignores any CEA-608 data provided at the start of the data. Any CEA-608 data provided after valid CEA-708 data will return ParserError::Cea608AfterCea708.
sourcepub fn pop_packet(&mut self) -> Option<DTVCCPacket>
pub fn pop_packet(&mut self) -> Option<DTVCCPacket>
Pop a valid DTVCCPacket or None if no packet could be parsed
pub fn cea608(&mut self) -> Option<&[Cea608]>
Trait Implementations§
source§impl Debug for CCDataParser
impl Debug for CCDataParser
source§impl Default for CCDataParser
impl Default for CCDataParser
source§fn default() -> CCDataParser
fn default() -> CCDataParser
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl RefUnwindSafe for CCDataParser
impl Send for CCDataParser
impl Sync for CCDataParser
impl Unpin for CCDataParser
impl UnwindSafe for CCDataParser
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