X-Git-Url: https://git.llucax.com/z.facultad/75.42/plaqui.git/blobdiff_plain/6e0194f46ac77c18bfeabf84ef94a32f23e41073..b804b4bd1f222976f6a1fb3156fede8e26e32d3d:/Server/include/plaqui/server/transmitter.h diff --git a/Server/include/plaqui/server/transmitter.h b/Server/include/plaqui/server/transmitter.h index faff2ef..16f751d 100644 --- a/Server/include/plaqui/server/transmitter.h +++ b/Server/include/plaqui/server/transmitter.h @@ -31,35 +31,51 @@ #include "plaqui/server/connection.h" #include -namespace Plaqui { +namespace PlaQui { + +namespace Server { /// Conexión para transmitir el estado de una planta. class Transmitter: public Connection { + ///////////////////////////////////////////////////////////////////// + // Métodos. + private: /** * Comienza a transmitir. */ - virtual void real_run(void); + virtual void real_run(void) throw(); public: /** * Destructor. */ - virtual ~Transmitter(void) {} + virtual ~Transmitter(void); /** * Constructor. * - * \param host Host al cual transmitir. - * \param port Puerto al cual transmitir. + * Los parámetros son modificados por los valores reales que toma + * una vez conectado. + * + * \param _host Host al cual transmitir. + * \param _port Puerto al cual transmitir. + */ + Transmitter(const std::string& _host, + const Connection::Port& _port) throw(sockerr); + + /** + * Envia datos. */ - Transmitter(std::string host = "localhost", int port = 7528); + void send(const std::string& data); }; } +} + #endif // PLAQUI_TRANSMITTER_H