/* orxonox - the future of 3D-vertical-scrollers Copyright (C) 2004 orx This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. ### File Specific: main-programmer: claudio co-programmer: */ /* this is for debug output. It just says, that all calls to PRINT() belong to the DEBUG_MODULE_NETWORK module For more information refere to https://www.orxonox.net/cgi-bin/trac.cgi/wiki/DebugOutput */ #define DEBUG_MODULE_NETWORK /* include your own header */ #include "network_stream.h" /* probably unnecessary */ using namespace std; NetworkStream::NetworkStream() { /* set the class id for the base object */ this->setClassID(CL_NETWORK_STREAM, "NetworkStream"); /* initialize the references */ this->networkSockets = new NetworkSocket(); this->synchronizeables = new Synchronizeable(); this->connectionMonitor = new ConnectionMonitor(); } NetworkStream::~NetworkStream() { delete networkSockets; delete synchronizeables; delete connectionMonitor; } void NetworkStream::processData() { byte data[10] ; // obsolete, for debugging only byte* test = (byte *)data[0]; // obsolete, for debugging only this->synchronizeables->writeByteStream(NULL); this->networkSockets->writeBytes(NULL); test = this->synchronizeables->readByteStream(); test = this->networkSockets->readBytes(); }