Struct gnss_message
Defined in File gnss_messages_common.h
Inheritance Relationships
Derived Types
public mrpt::obs::gnss::Message_NMEA_GGA(Struct Message_NMEA_GGA)public mrpt::obs::gnss::Message_NMEA_GLL(Struct Message_NMEA_GLL)public mrpt::obs::gnss::Message_NMEA_GSA(Struct Message_NMEA_GSA)public mrpt::obs::gnss::Message_NMEA_RMC(Struct Message_NMEA_RMC)public mrpt::obs::gnss::Message_NMEA_VTG(Struct Message_NMEA_VTG)public mrpt::obs::gnss::Message_NMEA_ZDA(Struct Message_NMEA_ZDA)public mrpt::obs::gnss::Message_NV_OEM6_GENERIC_FRAME(Struct Message_NV_OEM6_GENERIC_FRAME)public mrpt::obs::gnss::Message_NV_OEM6_GENERIC_SHORT_FRAME(Struct Message_NV_OEM6_GENERIC_SHORT_FRAME)public mrpt::obs::gnss::Message_NV_OEM6_RANGECMP(Struct Message_NV_OEM6_RANGECMP)public mrpt::obs::gnss::Message_NV_OEM6_VERSION(Struct Message_NV_OEM6_VERSION)public mrpt::obs::gnss::Message_TOPCON_PZS(Struct Message_TOPCON_PZS)public mrpt::obs::gnss::Message_TOPCON_SATS(Struct Message_TOPCON_SATS)
Struct Documentation
-
struct gnss_message
Pure virtual base for all message types.
See also
Subclassed by mrpt::obs::gnss::Message_NMEA_GGA, mrpt::obs::gnss::Message_NMEA_GLL, mrpt::obs::gnss::Message_NMEA_GSA, mrpt::obs::gnss::Message_NMEA_RMC, mrpt::obs::gnss::Message_NMEA_VTG, mrpt::obs::gnss::Message_NMEA_ZDA, mrpt::obs::gnss::Message_NV_OEM6_GENERIC_FRAME, mrpt::obs::gnss::Message_NV_OEM6_GENERIC_SHORT_FRAME, mrpt::obs::gnss::Message_NV_OEM6_RANGECMP, mrpt::obs::gnss::Message_NV_OEM6_VERSION, mrpt::obs::gnss::Message_TOPCON_PZS, mrpt::obs::gnss::Message_TOPCON_SATS
Public Functions
-
inline gnss_message(gnss_message_type_t msg_type_id)
-
void writeToStream(mrpt::serialization::CArchive &out) const
Save to binary stream. Launches an exception upon error
-
void readFromStream(mrpt::serialization::CArchive &in)
Load from binary stream into this existing object. Launches an exception upon error.
-
inline bool isOfType(const gnss_message_type_t type_id) const
-
template<class MSG_CLASS>
inline bool isOfClass() const
-
virtual void dumpToStream(std::ostream &out) const = 0
Dumps the contents of the observation in a human-readable form to a given output stream
See also
-
inline virtual void fixEndianness()
If we are in a big endian system, reverse all fields >1 byte to fix its representation. Only in binary frames, text-based derived classes obviously do not need to reimplement this one.
-
virtual void dumpToConsole(std::ostream &o) const
Dumps the contents of the observation in a human-readable form to an std::ostream (set to std::cout to print to console)
-
inline virtual bool getAllFieldDescriptions([[maybe_unused]] std::ostream &o) const
Dumps a header for getAllFieldValues()
- Returns:
false if not implemented for this message type
-
inline virtual bool getAllFieldValues([[maybe_unused]] std::ostream &o) const
Dumps a line with the sequence of all field values (without a line feed at the end).
See also
- Returns:
false if not implemented for this message type
-
const std::string &getMessageTypeAsString() const
Returns “NMEA_GGA”, etc.
-
virtual ~gnss_message() = default
Public Members
-
gnss_message_type_t message_type
Type of GNSS message
Public Static Functions
-
static gnss_message *readAndBuildFromStream(mrpt::serialization::CArchive &in)
Load from binary stream and creates object detecting its type (class factory). Launches an exception upon error
-
static gnss_message *Factory(gnss_message_type_t msg_id)
Creates message
- Returns:
nullptr on unknown msg type
-
static bool FactoryKnowsMsgType(gnss_message_type_t msg_id)
Returns true if Factory() has a registered constructor for this msg type
-
inline gnss_message(gnss_message_type_t msg_type_id)