eris  1.4.0
A WorldForge client library.
ServerInfo.h
1 #ifndef ERIS_SERVER_INFO_H
2 #define ERIS_SERVER_INFO_H
3 
4 #include <Atlas/Objects/ObjectsFwd.h>
5 
6 #include <string>
7 #include <vector>
8 
9 namespace Eris {
10 
11 class Meta;
12 
22 struct ServerInfo
23 {
24 
25  typedef enum {
26  INVALID,
27  QUERYING,
28  VALID,
29  TIMEOUT
30  } Status;
31 
32  // bookmark / favourites functionality
33 
34 
37  void processServer(const Atlas::Objects::Entity::RootEntity &svr);
38 
42  std::string host;
43 
44  Status status = INVALID;
45 
47  std::string name;
49  std::string ruleset;
51  std::string server;
54 
56  int clients;
60  int ping = -1;
62  long entities;
63 
65  double uptime;
66 
68  std::string version;
70  std::string buildDate;
71 
75  std::vector<std::string> assets;
76 };
77 
78 } // of namespace Eris
79 
80 #endif
81 
Eris::ServerInfo::uptime
double uptime
the server's uptime in seconds
Definition: ServerInfo.h:65
Eris::ServerInfo::version
std::string version
the server program version, as a free text string
Definition: ServerInfo.h:68
Eris::ServerInfo::server
std::string server
the server program name, i.e 'stage' or 'cyphesis'
Definition: ServerInfo.h:51
Eris::ServerInfo::ping
int ping
Definition: ServerInfo.h:60
Eris::ServerInfo::host
std::string host
Definition: ServerInfo.h:42
Eris::ServerInfo::clients
int clients
the number of clients currently connected to the server
Definition: ServerInfo.h:56
Eris::ServerInfo::TIMEOUT
@ TIMEOUT
server query timed out
Definition: ServerInfo.h:29
Eris::ServerInfo::processServer
void processServer(const Atlas::Objects::Entity::RootEntity &svr)
Definition: ServerInfo.cpp:19
Eris::ServerInfo::ruleset
std::string ruleset
retrieve a human-readable name of the ruleset (e.g. 'mason' or 'circe')
Definition: ServerInfo.h:49
Eris
Definition: Account.cpp:33
Eris::ServerInfo::protocol_version
long protocol_version
version of the protocol used
Definition: ServerInfo.h:53
Eris::ServerInfo
Definition: ServerInfo.h:23
Eris::ServerInfo::entities
long entities
the number of entities on the server
Definition: ServerInfo.h:62
Eris::ServerInfo::Status
Status
Definition: ServerInfo.h:25
Eris::ServerInfo::name
std::string name
retrieve the human-readable name of the server (e.g 'Bob's Mason Server')
Definition: ServerInfo.h:47
Eris::ServerInfo::assets
std::vector< std::string > assets
Definition: ServerInfo.h:75
Eris::ServerInfo::buildDate
std::string buildDate
the server program build-date, as a free text string
Definition: ServerInfo.h:70