#ifndef __CLIENT_H__ #define __CLIENT_H__ #include #include class ClientPrivate; class Client { friend class ClientPrivate; public: Client(); ~Client(); std::string id() const; static std::string randomId(size_t length); void log(const std::string &message); std::string log() const; bool setRemoteId(const std::string &id); bool sendMessage(const std::string &message); private: ClientPrivate *m_d = nullptr; std::string m_id; std::ostringstream m_oss; }; #endif // __CLIENT_H__