#ifndef COMC_HH #define COMC_HH /* comc.hh - Classe la plus haute dans la transmission par socket */ /* Simulotron - Programme de simulation de robot {{{ * * Copyright (C) 2006 Nicolas Haller * * Robot APB Team/Efrei 2006. * Web: http://assos.efrei.fr/robot/ * Email: robot AT efrei DOT fr * * 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 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * * }}} */ #include "aiguillage/aiguillage.hh" #include "comc/struct_message.hh" #include "utils/non_copyable.hh" class ComC : public NonCopyable { private: Aiguillage aiguillage_; std::string moduleName_; public: /// Constructeur client ComC(const std::string & address, int port, const std::string & name); /// Constructeur serveur ComC(SocketServer & socket, const std::string & name); /// Initialise la communication avec le hub void initHub(void); /// Envoie un truc dans le réseau void send(const msgX & message, const std::string & destname); /// Récupération de la GS bool receiveGS(GSMessage & gsm, std::string & source, std::string & dest, int & msgId, bool bloquant); }; #endif //COMC_HH