diff options
Diffstat (limited to '')
| -rw-r--r-- | src/packet.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/packet.h b/src/packet.h new file mode 100644 index 0000000..5ddc9ee --- /dev/null +++ b/src/packet.h | |||
| @@ -0,0 +1,29 @@ | |||
| 1 | #ifndef GATS_PACKET_H | ||
| 2 | #define GATS_PACKET_H | ||
| 3 | |||
| 4 | namespace Gats | ||
| 5 | { | ||
| 6 | class Object; | ||
| 7 | |||
| 8 | /** | ||
| 9 | * A D-encoded packet is a header and metadata related to encoding as well | ||
| 10 | * as a single object. The advantage of this method is that the packet | ||
| 11 | * contains all information related to encoding and is highly portable, it | ||
| 12 | * also lets the reader know how much data to expect, which makes this | ||
| 13 | * efficient for use in protocols and embedding in other data streams. | ||
| 14 | */ | ||
| 15 | class Packet | ||
| 16 | { | ||
| 17 | public: | ||
| 18 | Packet(); | ||
| 19 | Packet( Object *pObject ); | ||
| 20 | virtual ~Packet(); | ||
| 21 | |||
| 22 | Object *getObject() { return pRoot; } | ||
| 23 | |||
| 24 | private: | ||
| 25 | Object *pRoot; | ||
| 26 | }; | ||
| 27 | }; | ||
| 28 | |||
| 29 | #endif | ||
