00001 #ifndef ERIS_SERVER_INFO_H 00002 #define ERIS_SERVER_INFO_H 00003 00004 #include <Atlas/Objects/Entity/RootEntity.h> 00005 00006 namespace Eris { 00007 00008 class Meta; 00009 00019 class ServerInfo 00020 { 00021 public: 00022 // bookmark / favourites functionality 00023 00024 // accessors 00028 const std::string& getHostname() const 00029 { return _host; } 00030 00032 const std::string& getServername() const 00033 { return _host; } 00034 00036 const std::string& getRuleset() const 00037 { return _ruleset; } 00038 00040 const std::string& getServer() const 00041 { return _server; } 00042 00044 int getNumClients() const 00045 { return _clients; } 00046 00050 int getPing() const 00051 { return _ping; } 00052 00054 double getUptime() const 00055 { return _uptime; } 00056 00057 protected: 00058 friend class Meta; 00059 00061 ServerInfo(const std::string &host); 00062 00064 void processServer(const Atlas::Objects::Entity::RootEntity &svr); 00065 00066 void setPing(int p); 00067 00068 std::string _host; 00069 00070 std::string _name, 00071 _ruleset, 00072 _server; 00073 00074 int _clients; 00075 int _ping; 00076 00077 double _uptime; 00078 }; 00079 00080 } // of namespace Eris 00081 00082 #endif 00083