Changeset 5569 in orxonox.OLD for branches/network/src/lib
- Timestamp:
- Nov 15, 2005, 9:13:32 AM (19 years ago)
- Location:
- branches/network/src/lib/network
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/network/src/lib/network/data_stream.cc
r5562 r5569 28 28 */ 29 29 DataStream::DataStream(DataStream& upStream, DataStream& downStream) 30 { 31 30 { 31 32 32 } 33 33 … … 37 37 DataStream::DataStream(Synchronizeable& sync, NetworkSocket& socket) 38 38 { 39 39 40 40 } 41 41 … … 45 45 DataStream::~DataStream() 46 46 { 47 47 48 48 } 49 49 50 50 /** 51 * This function connects this stream to another stream. The connected DataStream is an up-stream, meaning 51 * This function connects this stream to another stream. The connected DataStream is an up-stream, meaning 52 52 * that the stream is "further away" from the NetworkSocket. The local reference upStream will be set to this 53 53 * Stream … … 55 55 void DataStream::connectUpStream(DataStream& upStream) 56 56 { 57 57 58 58 } 59 59 60 60 /** 61 * This function connects this stream to another stream. The connected DataStream is an down-stream, meaning 61 * This function connects this stream to another stream. The connected DataStream is an down-stream, meaning 62 62 * that the stream is "closer" to the NetworkSocket. 63 63 */ 64 64 void DataStream::connectDownStream(DataStream& upStream) 65 65 { 66 66 67 67 } 68 68 … … 72 72 void DataStream::disconnectUpStream() 73 73 { 74 74 75 75 } 76 76 … … 80 80 void DataStream::disconnectDownStream() 81 81 { 82 82 83 83 } 84 84 … … 89 89 void DataStream::processData() 90 90 { 91 91 92 92 } 93 93 … … 97 97 * it. 98 98 */ 99 void DataStream::write( )99 void DataStream::write(byte& data) 100 100 { 101 101 102 102 } 103 103 … … 110 110 byte& DataStream::read() 111 111 { 112 112 113 113 } -
branches/network/src/lib/network/data_stream.h
r5562 r5569 13 13 #include "netdefs.h" 14 14 15 class Synchronizeable; 16 class NetworkSocket; 17 15 18 class DataStream : public BaseObject 16 19 { … … 18 21 DataStream(Synchronizeable& sync, NetworkSocket& socket); 19 22 ~DataStream(); 20 21 protected: 23 24 protected: 22 25 byte inBuffer []; 23 26 byte outBuffer []; 24 27 unsigned int bufferSize; 25 DataStream &upStream;26 DataStream &downStream;27 28 DataStream* upStream; 29 DataStream* downStream; 30 28 31 public: 29 32 void connectUpStream(DataStream& upStream); 30 33 31 34 void disconnectUpStream(); 32 35 33 36 void connectDownStream(DataStream& downStream); 34 37 35 38 void disconnectDownStream(); 36 39 37 40 virtual void processData() = 0; 38 41 39 42 protected: 40 43 void write(byte& data); 41 42 byte& read(); 44 45 byte& read(); 43 46 }; 44 47
Note: See TracChangeset
for help on using the changeset viewer.