OpenCPN Partial API docs
Loading...
Searching...
No Matches
Nmea2000Msg Class Reference

See: https://github.com/OpenCPN/OpenCPN/issues/2729#issuecomment-1179506343. More...

#include <comm_navmsg.h>

Inheritance diagram for Nmea2000Msg:
NavMsg KeyProvider

Public Member Functions

 Nmea2000Msg (const uint64_t _pgn)
 
 Nmea2000Msg (const uint64_t _pgn, std::shared_ptr< const NavAddr2000 > src)
 
 Nmea2000Msg (const uint64_t _pgn, const std::vector< unsigned char > &_payload, std::shared_ptr< const NavAddr2000 > src)
 
 Nmea2000Msg (const uint64_t _pgn, const std::vector< unsigned char > &_payload, std::shared_ptr< const NavAddr2000 > src, int _priority)
 
std::string key () const
 Return unique key used by observable to notify/listen.
 
std::string to_string () const
 Print "bus key id payload".
 
- Public Member Functions inherited from NavMsg
std::string GetKey () const
 Alias for key().
 

Public Attributes

N2kPGN PGN
 
std::vector< unsigned char > payload
 
int priority
 
- Public Attributes inherited from NavMsg
const NavAddr::Bus bus
 
std::shared_ptr< const NavAddrsource
 Source address is set by drivers when receiving, unused and should be empty when sending.
 

Additional Inherited Members

- Protected Member Functions inherited from NavMsg
 NavMsg (const NavAddr::Bus &_bus, std::shared_ptr< const NavAddr > src)
 

Detailed Description

Constructor & Destructor Documentation

◆ Nmea2000Msg() [1/4]

Nmea2000Msg::Nmea2000Msg ( const uint64_t  _pgn)
inline

Definition at line 245 of file comm_navmsg.h.

◆ Nmea2000Msg() [2/4]

Nmea2000Msg::Nmea2000Msg ( const uint64_t  _pgn,
std::shared_ptr< const NavAddr2000 src 
)
inline

Definition at line 248 of file comm_navmsg.h.

◆ Nmea2000Msg() [3/4]

Nmea2000Msg::Nmea2000Msg ( const uint64_t  _pgn,
const std::vector< unsigned char > &  _payload,
std::shared_ptr< const NavAddr2000 src 
)
inline

Definition at line 251 of file comm_navmsg.h.

◆ Nmea2000Msg() [4/4]

Nmea2000Msg::Nmea2000Msg ( const uint64_t  _pgn,
const std::vector< unsigned char > &  _payload,
std::shared_ptr< const NavAddr2000 src,
int  _priority 
)
inline

Definition at line 255 of file comm_navmsg.h.

Member Function Documentation

◆ key()

std::string Nmea2000Msg::key ( ) const
inlinevirtual

Return unique key used by observable to notify/listen.

Implements NavMsg.

Definition at line 264 of file comm_navmsg.h.

◆ to_string()

std::string Nmea2000Msg::to_string ( ) const
virtual

Print "bus key id payload".

Reimplemented from NavMsg.

Definition at line 84 of file comm_navmsg.cpp.

Member Data Documentation

◆ payload

std::vector<unsigned char> Nmea2000Msg::payload

Definition at line 270 of file comm_navmsg.h.

◆ PGN

N2kPGN Nmea2000Msg::PGN

Definition at line 269 of file comm_navmsg.h.

◆ priority

int Nmea2000Msg::priority

Definition at line 271 of file comm_navmsg.h.


The documentation for this class was generated from the following files: