2003-01-26 20:15:03 +00:00
|
|
|
/*
|
|
|
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "inspircd_config.h"
|
2003-01-26 23:53:03 +00:00
|
|
|
#include "connection.h"
|
2003-01-26 20:15:03 +00:00
|
|
|
#include <string>
|
2003-07-22 21:56:38 +00:00
|
|
|
#include <map>
|
2003-01-26 20:15:03 +00:00
|
|
|
|
|
|
|
#ifndef __SERVERS_H__
|
|
|
|
#define __SERVERS_H__
|
|
|
|
|
|
|
|
#define LINK_ACTIVE 1
|
|
|
|
#define LINK_INACTIVE 0
|
|
|
|
|
2003-02-09 12:49:00 +00:00
|
|
|
/** A class that defines the local server or a remote server
|
|
|
|
*/
|
2003-01-26 23:53:03 +00:00
|
|
|
class serverrec : public connection
|
2003-01-26 20:15:03 +00:00
|
|
|
{
|
|
|
|
private:
|
|
|
|
public:
|
2004-04-10 13:29:38 +00:00
|
|
|
/** server name
|
|
|
|
*/
|
2003-02-09 12:49:00 +00:00
|
|
|
char name[MAXBUF];
|
|
|
|
/** last ping response (ms)
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-02-09 12:49:00 +00:00
|
|
|
long pingtime;
|
|
|
|
/** invisible users on server
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-02-09 12:49:00 +00:00
|
|
|
long usercount_i;
|
|
|
|
/** non-invisible users on server
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-02-09 12:49:00 +00:00
|
|
|
long usercount;
|
|
|
|
/** opers on server
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-02-09 12:49:00 +00:00
|
|
|
long opercount;
|
|
|
|
/** number of hops away (for quick access)
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-02-09 12:49:00 +00:00
|
|
|
int hops_away;
|
|
|
|
/** ircd version
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-02-09 12:49:00 +00:00
|
|
|
long version;
|
|
|
|
/** is a JUPE server (faked to enforce a server ban)
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-02-09 12:49:00 +00:00
|
|
|
bool jupiter;
|
2004-04-10 13:29:38 +00:00
|
|
|
|
|
|
|
/** Description of the server
|
|
|
|
*/
|
|
|
|
char description[MAXBUF];
|
2004-04-11 16:57:13 +00:00
|
|
|
|
2004-04-11 17:22:52 +00:00
|
|
|
bool sync_soon;
|
2003-01-26 20:15:03 +00:00
|
|
|
|
2003-02-09 12:49:00 +00:00
|
|
|
/** Constructor
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-01-26 20:15:03 +00:00
|
|
|
serverrec();
|
2003-02-09 12:49:00 +00:00
|
|
|
/** Constructor which initialises some of the main variables
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-02-02 16:43:53 +00:00
|
|
|
serverrec(char* n, long ver, bool jupe);
|
2003-02-09 12:49:00 +00:00
|
|
|
/** Destructor
|
2004-04-10 13:29:38 +00:00
|
|
|
*/
|
2003-01-26 23:53:03 +00:00
|
|
|
~serverrec();
|
2004-04-11 18:00:44 +00:00
|
|
|
|
2003-01-26 20:15:03 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
|
2003-01-26 23:53:03 +00:00
|
|
|
|
2003-01-26 20:15:03 +00:00
|
|
|
#endif
|
|
|
|
|