Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

serverrec Class Reference

#include <servers.h>

Inheritance diagram for serverrec:

connection classbase List of all members.

Public Methods

 serverrec ()
 serverrec (char *n, int link_t, long ver, bool jupe)
 ~serverrec ()
void AddLeaf (serverrec *child)
void DelLeaf (string n)

Public Attributes

char name [MAXBUF]
int pingtime
int linktype
time_t lastping
long usercount_i
long usercount
long opercount
time_t connected_at
time_t hops_away
long version
bool jupiter

Private Attributes

map< string, serverrec * > leaf

Constructor & Destructor Documentation

serverrec::serverrec  
 

Definition at line 20 of file servers.cpp.

References connected_at, connection::fd, hops_away, jupiter, lastping, leaf, LINK_ACTIVE, linktype, opercount, pingtime, usercount, usercount_i, and version.

00021 {
00022         leaf.clear();
00023         strcpy(name,"");
00024         pingtime = 0;
00025         linktype = LINK_ACTIVE;
00026         lastping = time(NULL);
00027         usercount_i = usercount = opercount = version = 0;
00028         hops_away = 1;
00029         connected_at = time(NULL);
00030         jupiter = false;
00031         fd = 0;
00032 }

serverrec::serverrec char *    n,
int    link_t,
long    ver,
bool    jupe
 

Definition at line 39 of file servers.cpp.

References connected_at, connection::fd, hops_away, jupiter, lastping, leaf, linktype, opercount, usercount, usercount_i, and version.

00040 {
00041         leaf.clear();
00042         strcpy(name,n);
00043         linktype = link_t;
00044         lastping = time(NULL);
00045         usercount_i = usercount = opercount = 0;
00046         version = ver;
00047         hops_away = 1;
00048         connected_at = time(NULL);
00049         jupiter = jupe;
00050         fd = 0;
00051 }

serverrec::~serverrec  
 

Definition at line 35 of file servers.cpp.

00036 {
00037 }


Member Function Documentation

void serverrec::AddLeaf serverrec *    child
 

Definition at line 53 of file servers.cpp.

References leaf, and name.

00054 {
00055         leaf[child->name] = child;
00056 }

void serverrec::DelLeaf string    n
 

Definition at line 58 of file servers.cpp.

References leaf.

00059 {
00060         server_list::iterator i = leaf.find(n);
00061 
00062         if (i != leaf.end())
00063                 leaf.erase(i);
00064 }


Member Data Documentation

time_t serverrec::connected_at
 

Definition at line 37 of file servers.h.

Referenced by serverrec().

time_t serverrec::hops_away
 

Definition at line 38 of file servers.h.

Referenced by serverrec().

bool serverrec::jupiter
 

Definition at line 40 of file servers.h.

Referenced by serverrec().

time_t serverrec::lastping
 

Reimplemented from connection.

Definition at line 33 of file servers.h.

Referenced by serverrec().

map<string, serverrec*> serverrec::leaf [private]
 

Definition at line 28 of file servers.h.

Referenced by AddLeaf(), DelLeaf(), and serverrec().

int serverrec::linktype
 

Definition at line 32 of file servers.h.

Referenced by serverrec().

char serverrec::name[MAXBUF]
 

Definition at line 30 of file servers.h.

Referenced by AddLeaf().

long serverrec::opercount
 

Definition at line 36 of file servers.h.

Referenced by serverrec().

int serverrec::pingtime
 

Definition at line 31 of file servers.h.

Referenced by serverrec().

long serverrec::usercount
 

Definition at line 35 of file servers.h.

Referenced by serverrec().

long serverrec::usercount_i
 

Definition at line 34 of file servers.h.

Referenced by serverrec().

long serverrec::version
 

Definition at line 39 of file servers.h.

Referenced by serverrec().


The documentation for this class was generated from the following files:
Generated on Mon Jan 27 00:16:43 2003 for InspIRCd by doxygen1.3-rc2