#ifndef PLEXSERVER_H #define PLEXSERVER_H #include #include #include #include #include #include #include #include #include #include #include namespace plexclient { class PlexServer { friend class plexgdm; public: int GetMaster() const { return m_nMaster; } int GetOwned() const { return m_nOwned; } int GetPort() const { return m_nPort; } const std::string& GetContentType() const { return m_sContentType; } const std::string& GetDiscovery() const { return m_sDiscovery; } const std::string& GetRole() const { return m_sRole; } const std::string& GetServerName() const { return m_sServerName; } long GetUpdated() const { return m_nUpdated; } const std::string& GetUuid() const { return m_sUuid; } const std::string& GetVersion() const { return m_sVersion; } const std::string& GetIpAdress() const { return m_sIpAddress; } std::string GetUri(); void DiscoverSettings(); bool Offline; protected: PlexServer(std::string data, std::string ip); PlexServer(std::string ip, int port); PlexServer() {}; void ParseData(std::string data, std::string ip); private: std::string m_sDiscovery; int m_nOwned; int m_nMaster; std::string m_sRole; std::string m_sContentType; std::string m_sUuid; std::string m_sServerName; std::string m_sIpAddress; int m_nPort; long m_nUpdated; std::string m_sVersion; }; } #endif // PLEXSERVER_H