The Header struct 32 bytes.
More...
#include <header.h>
|
| Header () |
| Header default constructor.
|
|
| ~Header ()=default |
|
bool | isValid () const |
| isValid This method check header size and compare commands.
|
|
void | reset () |
| reset This method reset all data and set for header invalid status.
|
|
QString | toString () const |
| toString This method return string of header of package.
|
|
|
unsigned short | command = 0 |
| command of package for more information see the AbstractData::toPackage method.
|
|
const unsigned char | headerVersion = 1 |
| headerVersion This is version of the header struct
|
|
unsigned int | size = 0 |
| size This is size of package data (exclude header size).
|
|
unsigned int | hash = 0 |
| hash This is unique id of a package. id calc with CRC32 function for Qt implementation.
|
|
unsigned int | triggerHash = 0 |
| triggerHash This is hash of request package that package has been responded. The server should write to which command it responds.
|
|
unsigned long long | unusedSpace1 = 0 |
| unusedSpace This is unused space for changes of the header struct in the future.
|
|
unsigned long long | unusedSpace2 = 0 |
|
unsigned char | unusedSpace3 = 0 |
|
The Header struct 32 bytes.
Definition at line 19 of file header.h.
◆ Header()
◆ ~Header()
◆ isValid()
bool QH::Header::isValid |
( |
| ) |
const |
isValid This method check header size and compare commands.
- Returns
- true if header is valid.
Definition at line 18 of file header.cpp.
◆ reset()
void QH::Header::reset |
( |
| ) |
|
reset This method reset all data and set for header invalid status.
Definition at line 25 of file header.cpp.
◆ toString()
QString QH::Header::toString |
( |
| ) |
const |
toString This method return string of header of package.
- Returns
- string value.
Definition at line 36 of file header.cpp.
◆ command
unsigned short QH::Header::command = 0 |
◆ hash
unsigned int QH::Header::hash = 0 |
hash This is unique id of a package. id calc with CRC32 function for Qt implementation.
Definition at line 38 of file header.h.
◆ headerVersion
const unsigned char QH::Header::headerVersion = 1 |
headerVersion This is version of the header struct
Definition at line 28 of file header.h.
◆ size
unsigned int QH::Header::size = 0 |
size This is size of package data (exclude header size).
Definition at line 33 of file header.h.
◆ triggerHash
unsigned int QH::Header::triggerHash = 0 |
triggerHash This is hash of request package that package has been responded. The server should write to which command it responds.
Definition at line 44 of file header.h.
◆ unusedSpace1
unsigned long long QH::Header::unusedSpace1 = 0 |
unusedSpace This is unused space for changes of the header struct in the future.
Definition at line 49 of file header.h.
◆ unusedSpace2
unsigned long long QH::Header::unusedSpace2 = 0 |
◆ unusedSpace3
unsigned char QH::Header::unusedSpace3 = 0 |
The documentation for this struct was generated from the following files: