Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/trunk/src/lib/network/network_protocol.h @ 6300

Last change on this file since 6300 was 6139, checked in by patrick, 19 years ago

trunk: merged branche network with trunk using command: svn merge -r5999:HEAD, conflicts resolved in favor of the trunk bla

File size: 754 bytes
Line 
1/*!
2
3*/
4
5#ifndef _NETWORK_PROTOCOL_H
6#define _NETWORK_PROTOCOL_H
7
8/* include base_object.h since all classes are derived from this one */
9#include "base_object.h"
10
11/* include this file, it contains some default definitions */
12#include "netdefs.h"
13
14typedef struct Header
15{
16  byte synchronizeableID;
17  byte length;
18};
19
20class Synchronizeable;
21
22/*!
23
24*/
25class NetworkProtocol : virtual public BaseObject
26{
27  public:
28    NetworkProtocol();
29    ~NetworkProtocol();
30
31    int createHeader(byte* data, int length, int bufferLength, const Synchronizeable& source);
32    Header extractHeader(byte* data, int length);
33
34  private:
35    unsigned int headerLength; //The Length of the Header in bytes
36};
37
38#endif //_NETWORK_PROTOCOL_H
Note: See TracBrowser for help on using the repository browser.