DUNE: Uniform Navigational Environment  2016.09.0
DUNE::IMC::Parser Class Reference

Detailed Description

Parser class.

Public Member Functions

 Parser (void)
 
 ~Parser (void)
 
void reset (void)
 
Messageparse (uint8_t byte)
 

Constructor & Destructor Documentation

DUNE::IMC::Parser::Parser ( void  )

Default constructor.

References reset().

DUNE::IMC::Parser::~Parser ( void  )

Destructor.

Member Function Documentation

Message * DUNE::IMC::Parser::parse ( uint8_t  byte)

Parse byte and return message if parsing of one message is done.

Parameters
bytedata byte
Returns
defined message or 0

References DUNE::IMC::Packet::deserializeHeader(), DUNE::IMC::Packet::deserializePayload(), reset(), and DUNE::IMC::Header::size.

Referenced by DUNE::Tasks::SimpleTransport::handleData().

void DUNE::IMC::Parser::reset ( void  )

Reset parser.

Referenced by parse(), and Parser().

Collaboration diagram for DUNE::IMC::Parser:
Collaboration graph