ITS
|
#include <LongPositionVector.h>
Public Types | |
enum | e_helper { helper_size = 24 } |
The e_helper enum is used to help to have sizes. More... | |
Public Member Functions | |
LongPositionVector () | |
LongPositionVector Default constructor. More... | |
LongPositionVector (GnAddr gnA, quint32 tmstmp, qint32 lat, qint32 lon, quint16 paiSpeed, quint16 head) | |
LongPositionVector Initialization constructor. More... | |
LongPositionVector (GnAddr gnA, quint32 tmstmp, qint32 lat, qint32 lon, quint8 pai, quint16 speed, quint16 head) | |
LongPositionVector Initialization constructor. More... | |
LongPositionVector (ShortPositionVector spv) | |
LongPositionVector Initialization constructor. More... | |
LongPositionVector (const LongPositionVector &other) | |
LongPositionVector Copy constructor. More... | |
LongPositionVector (char *data, int *offset) | |
LongPositionVector & | operator= (const LongPositionVector &other) |
operator = Overload of = operator More... | |
quint64 | extract (uchar *packet) |
extract Fill the LongPositionVector with values contained in the packet More... | |
QByteArray | toHex () |
toHex Create a QByteArray containing the hexadecimal format of the LongPositionVector. More... | |
GnAddr | gnAddr () const |
gnAddr GnAddr field getter More... | |
quint32 | timestamp () const |
timestamp Timestamp field getter More... | |
qint32 | latitude () const |
latitude Latitude field getter More... | |
qint32 | longitude () const |
longitude Longitude field getter More... | |
quint16 | pai_Speed () const |
pai_Speed Pai_Speed field getter (16 bits) More... | |
quint8 | pai () const |
pai Pai field getter (1 bit) More... | |
quint16 | speed () const |
speed Speed field getter (15 bits) More... | |
quint16 | heading () const |
heading Heading field getter More... | |
Private Attributes | |
GnAddr | m_gnAddr |
quint32 | m_timestamp |
qint32 | m_latitude |
qint32 | m_longitude |
quint16 | m_pai_Speed |
quint16 | m_heading |
Definition at line 24 of file LongPositionVector.h.
The e_helper enum is used to help to have sizes.
Enumerator | |
---|---|
helper_size | Size of the LPV. |
Definition at line 30 of file LongPositionVector.h.
LongPositionVector::LongPositionVector | ( | ) |
LongPositionVector Default constructor.
Definition at line 4 of file LongPositionVector.cpp.
References m_gnAddr, m_heading, m_latitude, m_longitude, m_pai_Speed, and m_timestamp.
LongPositionVector::LongPositionVector | ( | GnAddr | gnA, |
quint32 | tmstmp, | ||
qint32 | lat, | ||
qint32 | lon, | ||
quint16 | paiSpeed, | ||
quint16 | head | ||
) |
LongPositionVector Initialization constructor.
gnA | GnAddr field. |
tmstmp | Timestamp field. |
lat | Latitude field |
lon | Longitude field |
paiSpeed | Pai_Speed field |
head | Header field |
Definition at line 14 of file LongPositionVector.cpp.
References m_gnAddr, m_heading, m_latitude, m_longitude, m_pai_Speed, and m_timestamp.
LongPositionVector::LongPositionVector | ( | GnAddr | gnA, |
quint32 | tmstmp, | ||
qint32 | lat, | ||
qint32 | lon, | ||
quint8 | pai, | ||
quint16 | speed, | ||
quint16 | head | ||
) |
LongPositionVector Initialization constructor.
gnA | GnAddr field. |
tmstmp | Timestamp field. |
lat | Latitude field |
lon | Longitude field |
pai | Pai field |
speed | Speed field |
head | Header field |
Definition at line 24 of file LongPositionVector.cpp.
References m_gnAddr, m_heading, m_latitude, m_longitude, m_pai_Speed, m_timestamp, pai(), and speed().
LongPositionVector::LongPositionVector | ( | ShortPositionVector | spv | ) |
LongPositionVector Initialization constructor.
SPV | Short Position Vector. |
Definition at line 35 of file LongPositionVector.cpp.
References ShortPositionVector::gnAddr(), ShortPositionVector::latitude(), ShortPositionVector::longitude(), m_gnAddr, m_latitude, m_longitude, m_timestamp, and ShortPositionVector::timestamp().
LongPositionVector::LongPositionVector | ( | const LongPositionVector & | other | ) |
LongPositionVector Copy constructor.
other | The LongPositionVector to copy. |
Definition at line 52 of file LongPositionVector.cpp.
References gnAddr(), heading(), latitude(), longitude(), m_gnAddr, m_heading, m_latitude, m_longitude, m_pai_Speed, m_timestamp, pai_Speed(), and timestamp().
LongPositionVector::LongPositionVector | ( | char * | data, |
int * | offset | ||
) |
Definition at line 43 of file LongPositionVector.cpp.
References extractInt(), extractUInt(), m_gnAddr, m_latitude, m_longitude, and m_timestamp.
quint64 LongPositionVector::extract | ( | uchar * | packet | ) |
extract Fill the LongPositionVector with values contained in the packet
packet | The packet that contains the LongPositionVector data |
Definition at line 73 of file LongPositionVector.cpp.
References GnAddr::extract(), get_INT32(), get_UINT16(), get_UINT32(), m_gnAddr, m_heading, m_latitude, m_longitude, m_pai_Speed, and m_timestamp.
Referenced by BeaconPacket::extract(), SHBPacket::extract(), LSRequestPacket::extract(), TSBPacket::extract(), GUCPacket::extract(), and GBCPacket::extract().
|
inline |
gnAddr GnAddr field getter
Definition at line 100 of file LongPositionVector.h.
References m_gnAddr.
Referenced by HistoryPacketBuffer::addPacket(), GeoNet::advancedForwarding(), GeoNet::beaconPacketProcessing(), GeoNet::CBFUnicast(), GeoNet::contentionBasedForwardingAlgorithm(), HistoryPacketBuffer::isDuplicateTimestamp(), LongPositionVector(), GeoNet::LSReplyPacketProcessing(), GeoNet::LSRequestPacketProcessing(), operator=(), LocationTableEntry::print(), CBFPacketEntry::sendPacket(), CBFPacketBuffer::sendPacket(), GUCPacket::setDePv(), GeoNet::shbPacketProcessing(), CBFPacketBuffer::stopPacket(), UnicastForwardingPacketEntry::updateSourcePacketSoPv(), and BroadcastForwardingPacketEntry::updateSourcePacketSoPv().
|
inline |
heading Heading field getter
Definition at line 135 of file LongPositionVector.h.
References m_heading.
Referenced by LongPositionVector(), operator=(), and LocationTableEntry::print().
|
inline |
latitude Latitude field getter
Definition at line 110 of file LongPositionVector.h.
References m_latitude.
Referenced by GeoNet::advancedForwarding(), GeoNet::CBFUnicast(), GeoNet::contentionBasedForwardingAlgorithm(), LongPositionVector(), operator=(), LocationTableEntry::print(), GUCPacket::setDePv(), and GeoNet::simpleForwardingAlgorithm().
|
inline |
longitude Longitude field getter
Definition at line 115 of file LongPositionVector.h.
References m_longitude.
Referenced by GeoNet::advancedForwarding(), GeoNet::CBFUnicast(), GeoNet::contentionBasedForwardingAlgorithm(), LongPositionVector(), operator=(), LocationTableEntry::print(), GUCPacket::setDePv(), and GeoNet::simpleForwardingAlgorithm().
LongPositionVector & LongPositionVector::operator= | ( | const LongPositionVector & | other | ) |
operator = Overload of = operator
lpv | LongPositionVector to assign |
Definition at line 62 of file LongPositionVector.cpp.
References gnAddr(), heading(), latitude(), longitude(), m_gnAddr, m_heading, m_latitude, m_longitude, m_pai_Speed, m_timestamp, pai_Speed(), and timestamp().
|
inline |
pai Pai field getter (1 bit)
Definition at line 125 of file LongPositionVector.h.
References m_pai_Speed.
Referenced by LongPositionVector().
|
inline |
pai_Speed Pai_Speed field getter (16 bits)
Definition at line 120 of file LongPositionVector.h.
References m_pai_Speed.
Referenced by LongPositionVector(), operator=(), and LocationTableEntry::print().
|
inline |
speed Speed field getter (15 bits)
Definition at line 130 of file LongPositionVector.h.
References m_pai_Speed.
Referenced by LongPositionVector().
|
inline |
timestamp Timestamp field getter
Definition at line 105 of file LongPositionVector.h.
References m_timestamp.
Referenced by HistoryPacketBuffer::addPacket(), GeoNet::advancedForwarding(), GeoNet::beaconPacketProcessing(), UnicastForwardingPacketBuffer::erase(), CBFPacketBuffer::erase(), UnicastForwardingPacketBuffer::isDuplicateTimestamp(), CBFPacketBuffer::isDuplicateTimestamp(), BroadcastForwardingPacketBuffer::isDuplicateTimestamp(), HistoryPacketBuffer::isDuplicateTimestamp(), LongPositionVector(), GeoNet::LSReplyPacketProcessing(), GeoNet::LSRequestPacketProcessing(), operator=(), UnicastForwardingPacketEntry::operator==(), GBCPacket::operator==(), BroadcastForwardingPacketEntry::operator==(), PacketBuffersEntry::operator==(), LocationTableEntry::print(), CBFPacketBuffer::sendPacket(), GUCPacket::setDePv(), GeoNet::shbPacketProcessing(), CBFPacketBuffer::stopPacket(), and CBFPacketBuffer::update().
QByteArray LongPositionVector::toHex | ( | ) |
toHex Create a QByteArray containing the hexadecimal format of the LongPositionVector.
Definition at line 87 of file LongPositionVector.cpp.
References GnAddr::helper_size, m_gnAddr, m_heading, m_latitude, m_longitude, m_pai_Speed, m_timestamp, and GnAddr::toHex().
Referenced by BeaconPacket::toHex(), SHBPacket::toHex(), LSRequestPacket::toHex(), TSBPacket::toHex(), GUCPacket::toHex(), and GBCPacket::toHex().
|
private |
GN_ADDR field.
Definition at line 138 of file LongPositionVector.h.
Referenced by extract(), gnAddr(), LongPositionVector(), operator=(), and toHex().
|
private |
Heading field.
Definition at line 143 of file LongPositionVector.h.
Referenced by extract(), heading(), LongPositionVector(), operator=(), and toHex().
|
private |
Latitude field.
Definition at line 140 of file LongPositionVector.h.
Referenced by extract(), latitude(), LongPositionVector(), operator=(), and toHex().
|
private |
Longitude field.
Definition at line 141 of file LongPositionVector.h.
Referenced by extract(), longitude(), LongPositionVector(), operator=(), and toHex().
|
private |
PAI (1 bit) + Speed (15 bits) fields.
Definition at line 142 of file LongPositionVector.h.
Referenced by extract(), LongPositionVector(), operator=(), pai(), pai_Speed(), speed(), and toHex().
|
private |
Timestamp field (Timestamp % 2³²).
Definition at line 139 of file LongPositionVector.h.
Referenced by extract(), LongPositionVector(), operator=(), timestamp(), and toHex().