From afb51347b493a6ab54fcc8595b4a3f46972ce18f Mon Sep 17 00:00:00 2001 From: brain Date: Sat, 17 Apr 2004 12:33:39 +0000 Subject: Added new documentation to cover ircd_connector git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@629 e03df62e-2008-0410-955e-edbf42e46eb7 --- docs/module-doc/annotated.html | 5 +- docs/module-doc/base_8h-source.html | 2 +- docs/module-doc/base_8h.html | 2 +- docs/module-doc/channels_8cpp-source.html | 2 +- docs/module-doc/channels_8cpp.html | 2 +- docs/module-doc/channels_8h-source.html | 2 +- docs/module-doc/channels_8h.html | 2 +- docs/module-doc/classAdmin-members.html | 2 +- docs/module-doc/classAdmin.html | 10 +- docs/module-doc/classBanItem-members.html | 2 +- docs/module-doc/classBanItem.html | 2 +- docs/module-doc/classConfigReader-members.html | 2 +- docs/module-doc/classConfigReader.html | 86 +-- docs/module-doc/classConnectClass-members.html | 7 +- docs/module-doc/classConnectClass.html | 71 +- docs/module-doc/classConnectClass__coll__graph.gif | Bin 7484 -> 8061 bytes docs/module-doc/classExemptItem-members.html | 2 +- docs/module-doc/classExemptItem.html | 2 +- docs/module-doc/classExtMode-members.html | 2 +- docs/module-doc/classExtMode.html | 2 +- docs/module-doc/classFileReader-members.html | 2 +- docs/module-doc/classFileReader.html | 96 +-- docs/module-doc/classHostItem-members.html | 2 +- docs/module-doc/classHostItem.html | 2 +- docs/module-doc/classInviteItem-members.html | 2 +- docs/module-doc/classInviteItem.html | 2 +- docs/module-doc/classInvited-members.html | 2 +- docs/module-doc/classInvited.html | 4 +- docs/module-doc/classModeParameter-members.html | 2 +- docs/module-doc/classModeParameter.html | 2 +- docs/module-doc/classModule-members.html | 2 +- docs/module-doc/classModule.html | 4 +- docs/module-doc/classModuleFactory-members.html | 2 +- docs/module-doc/classModuleFactory.html | 12 +- docs/module-doc/classServer-members.html | 5 +- docs/module-doc/classServer.html | 413 +++++++---- docs/module-doc/classVersion-members.html | 2 +- docs/module-doc/classVersion.html | 12 +- docs/module-doc/classchanrec-members.html | 2 +- docs/module-doc/classchanrec.html | 2 +- docs/module-doc/classclassbase-members.html | 2 +- docs/module-doc/classclassbase.html | 10 +- docs/module-doc/classclassbase__inherit__graph.gif | Bin 24976 -> 25098 bytes docs/module-doc/classcommand__t-members.html | 2 +- docs/module-doc/classcommand__t.html | 2 +- docs/module-doc/classconnection-members.html | 43 +- docs/module-doc/classconnection.html | 419 +++++++---- docs/module-doc/classconnection__coll__graph.gif | Bin 18868 -> 26326 bytes docs/module-doc/classes.html | 22 +- docs/module-doc/classircd__connector-members.html | 41 ++ docs/module-doc/classircd__connector.html | 784 +++++++++++++++++++++ .../classircd__connector__coll__graph.gif | Bin 0 -> 12986 bytes .../classircd__connector__inherit__graph.gif | Bin 0 -> 1871 bytes docs/module-doc/classpacket.html | 174 +---- docs/module-doc/classserverrec-members.html | 45 +- docs/module-doc/classserverrec.html | 101 ++- docs/module-doc/classserverrec__coll__graph.gif | Bin 20871 -> 21684 bytes docs/module-doc/classucrec-members.html | 2 +- docs/module-doc/classucrec.html | 6 +- docs/module-doc/classuserrec-members.html | 45 +- docs/module-doc/classuserrec.html | 201 +++--- docs/module-doc/classuserrec__coll__graph.gif | Bin 16225 -> 19648 bytes docs/module-doc/connection_8h-source.html | 195 +++-- docs/module-doc/connection_8h.html | 64 +- docs/module-doc/connection_8h__incl.gif | Bin 18700 -> 22270 bytes docs/module-doc/ctables_8h-source.html | 2 +- docs/module-doc/ctables_8h.html | 2 +- docs/module-doc/files.html | 2 +- docs/module-doc/functions.html | 133 ++-- docs/module-doc/globals.html | 18 +- docs/module-doc/graph_legend.html | 2 +- docs/module-doc/hierarchy.html | 5 +- docs/module-doc/inherit__graph__0.gif | Bin 31116 -> 31226 bytes docs/module-doc/inherit__graph__2.gif | Bin 0 -> 558 bytes docs/module-doc/inherits.html | 14 +- docs/module-doc/main.html | 2 +- docs/module-doc/modules_8cpp-source.html | 405 ++++++----- docs/module-doc/modules_8cpp.html | 6 +- docs/module-doc/modules_8h-source.html | 365 +++++----- docs/module-doc/modules_8h.html | 18 +- docs/module-doc/namespaces.html | 2 +- docs/module-doc/namespacestd.html | 2 +- docs/module-doc/servers_8cpp-source.html | 44 +- docs/module-doc/servers_8cpp.html | 2 +- docs/module-doc/servers_8h-source.html | 27 +- docs/module-doc/servers_8h.html | 2 +- docs/module-doc/tree.html | 6 +- docs/module-doc/users_8cpp-source.html | 127 ++-- docs/module-doc/users_8cpp.html | 8 +- docs/module-doc/users_8cpp__incl.gif | Bin 18857 -> 19114 bytes docs/module-doc/users_8h-source.html | 130 ++-- docs/module-doc/users_8h.html | 6 +- include/connection.h | 6 +- 93 files changed, 2784 insertions(+), 1489 deletions(-) create mode 100644 docs/module-doc/classircd__connector-members.html create mode 100644 docs/module-doc/classircd__connector.html create mode 100644 docs/module-doc/classircd__connector__coll__graph.gif create mode 100644 docs/module-doc/classircd__connector__inherit__graph.gif create mode 100644 docs/module-doc/inherit__graph__2.gif diff --git a/docs/module-doc/annotated.html b/docs/module-doc/annotated.html index 7cd5f9dfe..c8c46392c 100644 --- a/docs/module-doc/annotated.html +++ b/docs/module-doc/annotated.html @@ -14,13 +14,14 @@ command_tA structure that defines a command ConfigReaderAllows reading of values from configuration files This class allows a module to read from either the main configuration file (inspircd.conf) or from a module-specified configuration file ConnectClassHolds information relevent to <connect allow> and <connect deny> tags in the config file - connection + connectionPlease note: classes serverrec and userrec both inherit from class connection ExemptItemA subclass of HostItem designed to hold channel exempts (+e) ExtMode FileReaderCaches a text file into memory and can be used to retrieve lines from it HostItemHolds an entry for a ban list, exemption list, or invite list InvitedHolds a channel name to which a user has been invited InviteItemA subclass of HostItem designed to hold channel invites (+I) + ircd_connectorEach connection has one or more of these each represents ONE outbound connection to another ircd so each inbound has multiple outbounds ModeParameterHolds a custom parameter to a module-defined channel mode e.g ModuleBase class for all InspIRCd modules This class is the base class for InspIRCd modules ModuleFactoryInstantiates classes inherited from Module This class creates a class inherited from type Module, using new @@ -31,7 +32,7 @@ userrecHolds all information about a user This class stores all information about a user connected to the irc server VersionHolds a module's Version information The four members (set by the constructor only) indicate details as to the version number of a module -
Generated on Thu Apr 8 19:12:45 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:44 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/base_8h-source.html b/docs/module-doc/base_8h-source.html index 2882d8332..badf7cc53 100644 --- a/docs/module-doc/base_8h-source.html +++ b/docs/module-doc/base_8h-source.html @@ -29,7 +29,7 @@ 00028 00029 #endif 00030 -
Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/base_8h.html b/docs/module-doc/base_8h.html index 72086d48b..42822db73 100644 --- a/docs/module-doc/base_8h.html +++ b/docs/module-doc/base_8h.html @@ -34,7 +34,7 @@ This graph shows which files directly or indirectly include this file:

class  classbase  The base class for all inspircd classes. More...

-
Generated on Thu Apr 8 19:12:30 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:39 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/channels_8cpp-source.html b/docs/module-doc/channels_8cpp-source.html index f7a03c83d..859e2c155 100644 --- a/docs/module-doc/channels_8cpp-source.html +++ b/docs/module-doc/channels_8cpp-source.html @@ -106,7 +106,7 @@ 00098 } 00099 return std::string(""); 00100 } -
Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/channels_8cpp.html b/docs/module-doc/channels_8cpp.html index b2d498596..e799c1699 100644 --- a/docs/module-doc/channels_8cpp.html +++ b/docs/module-doc/channels_8cpp.html @@ -55,7 +55,7 @@ Definition at line 10 Referenced by chanrec::GetModeParameter(), and chanrec::SetCustomModeParam(). -
Generated on Thu Apr 8 19:12:31 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:40 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/channels_8h-source.html b/docs/module-doc/channels_8h-source.html index 410460a1c..c3439e0ef 100644 --- a/docs/module-doc/channels_8h-source.html +++ b/docs/module-doc/channels_8h-source.html @@ -129,7 +129,7 @@ 00207 00208 #endif 00209 -
Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/channels_8h.html b/docs/module-doc/channels_8h.html index 29ba57854..dbc51aa27 100644 --- a/docs/module-doc/channels_8h.html +++ b/docs/module-doc/channels_8h.html @@ -258,7 +258,7 @@ Holds a complete invite list. Definition at line 77 of file channels.h. -
Generated on Thu Apr 8 19:12:33 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:40 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classAdmin-members.html b/docs/module-doc/classAdmin-members.html index 7851b955e..118f4020d 100644 --- a/docs/module-doc/classAdmin-members.html +++ b/docs/module-doc/classAdmin-members.html @@ -14,7 +14,7 @@ NameAdmin NickAdmin ~classbase()classbase [inline] -
Generated on Thu Apr 8 19:12:46 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:44 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classAdmin.html b/docs/module-doc/classAdmin.html index 4f132b26a..a1a8f35d3 100644 --- a/docs/module-doc/classAdmin.html +++ b/docs/module-doc/classAdmin.html @@ -35,7 +35,7 @@ It is constructed by class Server, and

-Definition at line 79 of file modules.h.


Constructor & Destructor Documentation

+Definition at line 80 of file modules.h.

Constructor & Destructor Documentation

@@ -107,7 +107,7 @@ Definition at line 106

-Definition at line 82 of file modules.h. +Definition at line 83 of file modules.h.

@@ -131,7 +131,7 @@ Definition at line 82 of

-Definition at line 82 of file modules.h. +Definition at line 83 of file modules.h.

@@ -155,12 +155,12 @@ Definition at line 82 of

-Definition at line 82 of file modules.h. +Definition at line 83 of file modules.h.


The documentation for this class was generated from the following files: -
Generated on Thu Apr 8 19:12:46 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:44 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classBanItem-members.html b/docs/module-doc/classBanItem-members.html index c7f0d3375..cd873c8b4 100644 --- a/docs/module-doc/classBanItem-members.html +++ b/docs/module-doc/classBanItem-members.html @@ -15,7 +15,7 @@ set_timeHostItem ~classbase()classbase [inline] ~HostItem()HostItem [inline, virtual] -
Generated on Thu Apr 8 19:12:48 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:45 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classBanItem.html b/docs/module-doc/classBanItem.html index 16fa46ad7..7336d4410 100644 --- a/docs/module-doc/classBanItem.html +++ b/docs/module-doc/classBanItem.html @@ -31,7 +31,7 @@ A subclass of HostItem designed to h

Definition at line 34 of file channels.h.


The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:12:48 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:45 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classConfigReader-members.html b/docs/module-doc/classConfigReader-members.html index 0c808632f..e9493bd32 100644 --- a/docs/module-doc/classConfigReader-members.html +++ b/docs/module-doc/classConfigReader-members.html @@ -19,7 +19,7 @@ Verify()ConfigReader ~classbase()classbase [inline] ~ConfigReader()ConfigReader -
Generated on Thu Apr 8 19:12:55 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:47 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classConfigReader.html b/docs/module-doc/classConfigReader.html index 663a59fe3..91aa3ef65 100644 --- a/docs/module-doc/classConfigReader.html +++ b/docs/module-doc/classConfigReader.html @@ -49,7 +49,7 @@ It may either be instantiated with one parameter or none. Constructing the class

-Definition at line 469 of file modules.h.


Constructor & Destructor Documentation

+Definition at line 497 of file modules.h.

Constructor & Destructor Documentation

@@ -79,14 +79,14 @@ Default constructor.

This constructor initialises the ConfigReader class to read the inspircd.conf file as specified when running ./configure.

-Definition at line 319 of file modules.cpp. +Definition at line 334 of file modules.cpp.

-References cache, and error. +References cache, and error.

-

00320 {
-00321         this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out);
-00322         this->error = LoadConf(CONFIG_FILE,this->cache);
-00323 }
+
00335 {
+00336         this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out);
+00337         this->error = LoadConf(CONFIG_FILE,this->cache);
+00338 }
 
@@ -120,14 +120,14 @@ Overloaded constructor.

This constructor initialises the ConfigReader class to read a user-specified config file

-Definition at line 333 of file modules.cpp. +Definition at line 348 of file modules.cpp.

-References cache, and error. +References cache, and error.

-

00334 {
-00335         this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out);
-00336         this->error = LoadConf(filename.c_str(),this->cache);
-00337 };
+
00349 {
+00350         this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out);
+00351         this->error = LoadConf(filename.c_str(),this->cache);
+00352 };
 
@@ -160,14 +160,14 @@ Default destructor.

This method destroys the ConfigReader class.

-Definition at line 326 of file modules.cpp. +Definition at line 341 of file modules.cpp.

-References cache. +References cache.

-

00327 {
-00328         if (this->cache)
-00329                 delete this->cache;
-00330 }
+
00342 {
+00343         if (this->cache)
+00344                 delete this->cache;
+00345 }
 
@@ -202,11 +202,11 @@ Counts the number of times a given tag appears in the config file.

This method counts the number of times a tag appears in a config file, for use where there are several tags of the same kind, e.g. with opers and connect types. It can be used with the index value of ConfigReader::ReadValue to loop through all copies of a multiple instance tag.

-Definition at line 347 of file modules.cpp. +Definition at line 362 of file modules.cpp.

-

00348 {
-00349         return EnumConf(cache,tag.c_str());
-00350 }
+
00363 {
+00364         return EnumConf(cache,tag.c_str());
+00365 }
 
@@ -249,11 +249,11 @@ Returns the number of items within a tag.

For example if the tag was <test tag="blah" data="foo"> then this function would return 2. Spaces and newlines both qualify as valid seperators between values.

-Definition at line 352 of file modules.cpp. +Definition at line 367 of file modules.cpp.

-

00353 {
-00354         return EnumValues(cache, tag.c_str(), index);
-00355 }
+
00368 {
+00369         return EnumValues(cache, tag.c_str(), index);
+00370 }
 
@@ -302,13 +302,13 @@ Retrieves a value from the config file.

This method retrieves a value from the config file. Where multiple copies of the tag exist in the config file, index indicates which of the values to retrieve.

-Definition at line 339 of file modules.cpp. +Definition at line 354 of file modules.cpp.

-

00340 {
-00341         char val[MAXBUF];
-00342         ReadConf(cache,tag.c_str(),name.c_str(),index,val);
-00343         return val;
-00344 }
+
00355 {
+00356         char val[MAXBUF];
+00357         ReadConf(cache,tag.c_str(),name.c_str(),index,val);
+00358         return val;
+00359 }
 
@@ -341,13 +341,13 @@ Returns true if a config file is valid.

This method is partially implemented and will only return false if the config file does not exist or could not be opened.

-Definition at line 357 of file modules.cpp. +Definition at line 372 of file modules.cpp.

-References error. +References error.

-

00358 {
-00359         return this->error;
-00360 }
+
00373 {
+00374         return this->error;
+00375 }
 
@@ -375,9 +375,9 @@ The contents of the configuration file This protected member should never be acc

It will contain a pointer to the configuration file data with unneeded data (such as comments) stripped from it.

-Definition at line 477 of file modules.h. +Definition at line 505 of file modules.h.

-Referenced by ConfigReader(), and ~ConfigReader(). +Referenced by ConfigReader(), and ~ConfigReader().

@@ -403,14 +403,14 @@ Used to store errors.

-Definition at line 480 of file modules.h. +Definition at line 508 of file modules.h.

-Referenced by ConfigReader(), and Verify(). +Referenced by ConfigReader(), and Verify().


The documentation for this class was generated from the following files: -
Generated on Thu Apr 8 19:12:55 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:47 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classConnectClass-members.html b/docs/module-doc/classConnectClass-members.html index 25608a747..25335a2db 100644 --- a/docs/module-doc/classConnectClass-members.html +++ b/docs/module-doc/classConnectClass-members.html @@ -10,12 +10,13 @@ ageclassbase classbase()classbase [inline] ConnectClass()ConnectClass [inline] - hostConnectClass - passConnectClass + floodConnectClass + hostConnectClass + passConnectClass registration_timeoutConnectClass typeConnectClass ~classbase()classbase [inline] -
Generated on Thu Apr 8 19:12:57 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:48 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classConnectClass.html b/docs/module-doc/classConnectClass.html index 412d670b5..fd3af8430 100644 --- a/docs/module-doc/classConnectClass.html +++ b/docs/module-doc/classConnectClass.html @@ -25,9 +25,15 @@ Inheritance diagram for ConnectClass:

ConnectClass ()

Public Attributes

int typeType of line, either CC_ALLOW or CC_DENY.

int registration_timeout -char host [MAXBUF] -char pass [MAXBUF] + Max time to register the connection in seconds.

+int floodNumber of lines in buffer before excess flood is triggered.

+char host [MAXBUF] + Host mask for this line.

+char pass [MAXBUF] + (Optional) Password for this line


Detailed Description

Holds information relevent to <connect allow> and <connect deny> tags in the config file. @@ -62,18 +68,45 @@ Definition at line 34 of fi

-Definition at line 42 of file users.h. +Definition at line 53 of file users.h.

-

00043         {
-00044                 registration_timeout = 0;
-00045                 strcpy(host,"");
-00046                 strcpy(pass,"");
-00047         }
+
00054         {
+00055                 registration_timeout = 0;
+00056                 flood = 0;
+00057                 strcpy(host,"");
+00058                 strcpy(pass,"");
+00059         }
 

Member Data Documentation

-

+

+ + + + +
+ + +
int ConnectClass::flood +
+
+ + + + + +
+   + + +

+Number of lines in buffer before excess flood is triggered. +

+ +

+Definition at line 45 of file users.h.

+

+Definition at line 48 of file users.h.
@@ -92,12 +125,14 @@ Definition at line 42 of fi

+Host mask for this line. +

-Definition at line 39 of file users.h.

-

+

+Definition at line 51 of file users.h.
@@ -116,9 +151,11 @@ Definition at line 39 of fi

+(Optional) Password for this line +

-Definition at line 40 of file users.h.

@@ -140,9 +177,11 @@ Definition at line 40 of fi

+Max time to register the connection in seconds. +

-Definition at line 38 of file users.h. +Definition at line 42 of file users.h.

@@ -164,14 +203,16 @@ Definition at line 38 of fi

+Type of line, either CC_ALLOW or CC_DENY. +

-Definition at line 37 of file users.h. +Definition at line 39 of file users.h.


The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:12:57 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:48 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classConnectClass__coll__graph.gif b/docs/module-doc/classConnectClass__coll__graph.gif index 14f3c91f4..17653635d 100644 Binary files a/docs/module-doc/classConnectClass__coll__graph.gif and b/docs/module-doc/classConnectClass__coll__graph.gif differ diff --git a/docs/module-doc/classExemptItem-members.html b/docs/module-doc/classExemptItem-members.html index 1e0c85696..4a533e883 100644 --- a/docs/module-doc/classExemptItem-members.html +++ b/docs/module-doc/classExemptItem-members.html @@ -15,7 +15,7 @@ set_timeHostItem ~classbase()classbase [inline] ~HostItem()HostItem [inline, virtual] -
Generated on Thu Apr 8 19:13:01 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:49 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classExemptItem.html b/docs/module-doc/classExemptItem.html index b9dbfde32..be330da9b 100644 --- a/docs/module-doc/classExemptItem.html +++ b/docs/module-doc/classExemptItem.html @@ -31,7 +31,7 @@ A subclass of HostItem designed to h

Definition at line 42 of file channels.h.


The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:13:01 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:49 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classExtMode-members.html b/docs/module-doc/classExtMode-members.html index ef603e0b4..15f06f3cf 100644 --- a/docs/module-doc/classExtMode-members.html +++ b/docs/module-doc/classExtMode-members.html @@ -13,7 +13,7 @@ params_when_offExtMode params_when_onExtMode typeExtMode -
Generated on Thu Apr 8 19:13:02 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:49 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classExtMode.html b/docs/module-doc/classExtMode.html index b0251dfb4..0278970cd 100644 --- a/docs/module-doc/classExtMode.html +++ b/docs/module-doc/classExtMode.html @@ -203,7 +203,7 @@ Definition at line 22 o
The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:13:02 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:49 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classFileReader-members.html b/docs/module-doc/classFileReader-members.html index d6a050771..f7e358b15 100644 --- a/docs/module-doc/classFileReader-members.html +++ b/docs/module-doc/classFileReader-members.html @@ -18,7 +18,7 @@ LoadFile(std::string filename)FileReader ~classbase()classbase [inline] ~FileReader()FileReader -
Generated on Thu Apr 8 19:13:03 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:50 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classFileReader.html b/docs/module-doc/classFileReader.html index 3ca670a48..ed114b8d9 100644 --- a/docs/module-doc/classFileReader.html +++ b/docs/module-doc/classFileReader.html @@ -46,7 +46,7 @@ This class contains methods for read-only manipulation of a text file in memory.

-Definition at line 529 of file modules.h.


Constructor & Destructor Documentation

+Definition at line 557 of file modules.h.

Constructor & Destructor Documentation

@@ -76,10 +76,10 @@ Default constructor.

This method does not load any file into memory, you must use the LoadFile method after constructing the class this way.

-Definition at line 370 of file modules.cpp. +Definition at line 385 of file modules.cpp.

-

00371 {
-00372 }
+
00386 {
+00387 }
 
@@ -113,15 +113,15 @@ Secondary constructor.

This method initialises the class with a file loaded into it ready for GetLine and and other methods to be called. If the file could not be loaded, FileReader::FileSize returns 0.

-Definition at line 363 of file modules.cpp. +Definition at line 378 of file modules.cpp.

-References fc, and file_cache. +References fc, and file_cache.

-

00364 {
-00365         file_cache c;
-00366         readfile(c,filename.c_str());
-00367         this->fc = c;
-00368 }
+
00379 {
+00380         file_cache c;
+00381         readfile(c,filename.c_str());
+00382         this->fc = c;
+00383 }
 
@@ -154,10 +154,10 @@ Default destructor.

This deletes the memory allocated to the file.

-Definition at line 382 of file modules.cpp. +Definition at line 397 of file modules.cpp.

-

00383 {
-00384 }
+
00398 {
+00399 }
 
@@ -191,20 +191,20 @@ Returns true if the file exists This function will return false if the file coul

-Definition at line 386 of file modules.cpp. +Definition at line 401 of file modules.cpp.

-References fc. +References fc.

-

00387 {
-00388         if (fc.size() == 0)
-00389         {
-00390                 return(false);
-00391         }
-00392         else
-00393         {
-00394                 return(true);
-00395         }
-00396 }
+
00402 {
+00403         if (fc.size() == 0)
+00404         {
+00405                 return(false);
+00406         }
+00407         else
+00408         {
+00409                 return(true);
+00410         }
+00411 }
 
@@ -237,13 +237,13 @@ Returns the size of the file in lines.

This method returns the number of lines in the read file. If it is 0, no lines have been read into memory, either because the file is empty or it does not exist, or cannot be opened due to permission problems.

-Definition at line 405 of file modules.cpp. +Definition at line 420 of file modules.cpp.

-References fc. +References fc.

-

00406 {
-00407         return fc.size();
-00408 }
+
00421 {
+00422         return fc.size();
+00423 }
 
@@ -277,15 +277,15 @@ Retrieve one line from the file.

This method retrieves one line from the text file. If an empty non-NULL string is returned, the index was out of bounds, or the line had no data on it.

-Definition at line 398 of file modules.cpp. +Definition at line 413 of file modules.cpp.

-References fc. +References fc.

-

00399 {
-00400         if ((x<0) || (x>fc.size()))
-00401                 return "";
-00402         return fc[x];
-00403 }
+
00414 {
+00415         if ((x<0) || (x>fc.size()))
+00416                 return "";
+00417         return fc[x];
+00418 }
 
@@ -319,15 +319,15 @@ Used to load a file.

This method loads a file into the class ready for GetLine and and other methods to be called. If the file could not be loaded, FileReader::FileSize returns 0.

-Definition at line 374 of file modules.cpp. +Definition at line 389 of file modules.cpp.

-References fc, and file_cache. +References fc, and file_cache.

-

00375 {
-00376         file_cache c;
-00377         readfile(c,filename.c_str());
-00378         this->fc = c;
-00379 }
+
00390 {
+00391         file_cache c;
+00392         readfile(c,filename.c_str());
+00393         this->fc = c;
+00394 }
 
@@ -353,14 +353,14 @@ References fc, and

-Definition at line 531 of file modules.h. +Definition at line 559 of file modules.h.

-Referenced by Exists(), FileReader(), FileSize(), GetLine(), and LoadFile(). +Referenced by Exists(), FileReader(), FileSize(), GetLine(), and LoadFile().


The documentation for this class was generated from the following files: -
Generated on Thu Apr 8 19:13:03 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:50 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classHostItem-members.html b/docs/module-doc/classHostItem-members.html index 26918e97d..7163a0817 100644 --- a/docs/module-doc/classHostItem-members.html +++ b/docs/module-doc/classHostItem-members.html @@ -15,7 +15,7 @@ set_timeHostItem ~classbase()classbase [inline] ~HostItem()HostItem [inline, virtual] -
Generated on Thu Apr 8 19:13:05 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:50 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classHostItem.html b/docs/module-doc/classHostItem.html index 391400b89..b944ab14e 100644 --- a/docs/module-doc/classHostItem.html +++ b/docs/module-doc/classHostItem.html @@ -181,7 +181,7 @@ Definition at line 21 of
The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:13:05 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:50 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classInviteItem-members.html b/docs/module-doc/classInviteItem-members.html index 3732f219d..828c331ce 100644 --- a/docs/module-doc/classInviteItem-members.html +++ b/docs/module-doc/classInviteItem-members.html @@ -15,7 +15,7 @@ set_timeHostItem ~classbase()classbase [inline] ~HostItem()HostItem [inline, virtual] -
Generated on Thu Apr 8 19:13:08 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:51 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classInviteItem.html b/docs/module-doc/classInviteItem.html index c3f02830d..958a982ec 100644 --- a/docs/module-doc/classInviteItem.html +++ b/docs/module-doc/classInviteItem.html @@ -31,7 +31,7 @@ A subclass of HostItem designed to h

Definition at line 50 of file channels.h.


The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:13:08 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:51 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classInvited-members.html b/docs/module-doc/classInvited-members.html index 61d4a85cb..889ac69cc 100644 --- a/docs/module-doc/classInvited-members.html +++ b/docs/module-doc/classInvited-members.html @@ -11,7 +11,7 @@ channelInvited classbase()classbase [inline] ~classbase()classbase [inline] -
Generated on Thu Apr 8 19:13:07 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:51 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classInvited.html b/docs/module-doc/classInvited.html index c59b9a439..979671438 100644 --- a/docs/module-doc/classInvited.html +++ b/docs/module-doc/classInvited.html @@ -53,12 +53,12 @@ Definition at line 25 of fi

Definition at line 28 of file users.h.

-Referenced by userrec::InviteTo(). +Referenced by userrec::InviteTo().


The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:13:07 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:51 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classModeParameter-members.html b/docs/module-doc/classModeParameter-members.html index 1e77da1ea..32c621820 100644 --- a/docs/module-doc/classModeParameter-members.html +++ b/docs/module-doc/classModeParameter-members.html @@ -13,7 +13,7 @@ modeModeParameter parameterModeParameter ~classbase()classbase [inline] -
Generated on Thu Apr 8 19:13:10 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:53 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classModeParameter.html b/docs/module-doc/classModeParameter.html index cbfc69822..4eb72346e 100644 --- a/docs/module-doc/classModeParameter.html +++ b/docs/module-doc/classModeParameter.html @@ -114,7 +114,7 @@ Referenced by chanrec::Set
The documentation for this class was generated from the following file:
-
Generated on Thu Apr 8 19:13:10 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:53 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classModule-members.html b/docs/module-doc/classModule-members.html index a0695a3fe..386134f6e 100644 --- a/docs/module-doc/classModule-members.html +++ b/docs/module-doc/classModule-members.html @@ -28,7 +28,7 @@ OnWhois(userrec *source, userrec *dest)Module [virtual] ~classbase()classbase [inline] ~Module()Module [virtual] -
Generated on Thu Apr 8 19:13:11 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:53 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classModule.html b/docs/module-doc/classModule.html index 9f61cb706..2c7277c74 100644 --- a/docs/module-doc/classModule.html +++ b/docs/module-doc/classModule.html @@ -66,7 +66,7 @@ All modules must inherit from this class, its methods will be called when irc se

-Definition at line 91 of file modules.h.


Constructor & Destructor Documentation

+Definition at line 92 of file modules.h.

Constructor & Destructor Documentation

@@ -843,7 +843,7 @@ Definition at line 123


The documentation for this class was generated from the following files: -
Generated on Thu Apr 8 19:13:11 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:53 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classModuleFactory-members.html b/docs/module-doc/classModuleFactory-members.html index e821ae67a..85f704a92 100644 --- a/docs/module-doc/classModuleFactory-members.html +++ b/docs/module-doc/classModuleFactory-members.html @@ -13,7 +13,7 @@ ModuleFactory()ModuleFactory [inline] ~classbase()classbase [inline] ~ModuleFactory()ModuleFactory [inline, virtual] -
Generated on Thu Apr 8 19:13:13 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:54 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classModuleFactory.html b/docs/module-doc/classModuleFactory.html index 427fe5328..b6cf2e068 100644 --- a/docs/module-doc/classModuleFactory.html +++ b/docs/module-doc/classModuleFactory.html @@ -34,7 +34,7 @@ This is to allow for modules to create many different variants of

-Definition at line 584 of file modules.h.


Constructor & Destructor Documentation

+Definition at line 612 of file modules.h.

Constructor & Destructor Documentation

@@ -62,9 +62,9 @@ Definition at line 584 of

-Definition at line 587 of file modules.h. +Definition at line 615 of file modules.h.

-

00587 { }
+
00615 { }
 
@@ -95,9 +95,9 @@ Definition at line 587 of

-Definition at line 588 of file modules.h. +Definition at line 616 of file modules.h.

-

00588 { }
+
00616 { }
 
@@ -134,7 +134,7 @@ Your inherited class of ModuleFactory must return a pointer to your modules.h -
Generated on Thu Apr 8 19:13:13 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:54 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classServer-members.html b/docs/module-doc/classServer-members.html index 9aa8cf46f..da295972d 100644 --- a/docs/module-doc/classServer-members.html +++ b/docs/module-doc/classServer-members.html @@ -10,6 +10,9 @@ AddCommand(char *cmd, handlerfunc f, char flags, int minparams)Server [virtual] AddExtendedMode(char modechar, int type, bool requires_oper, int params_when_on, int params_when_off)Server [virtual] ageclassbase + CallCommandHandler(std::string commandname, char **parameters, int pcnt, userrec *user)Server [virtual] + ChangeGECOS(userrec *user, std::string gecos)Server [virtual] + ChangeHost(userrec *user, std::string host)Server [virtual] ChangeUserNick(userrec *user, std::string nickname)Server [virtual] ChanMode(userrec *User, chanrec *Chan)Server [virtual] classbase()classbase [inline] @@ -39,7 +42,7 @@ Server()Server ~classbase()classbase [inline] ~Server()Server [virtual] -
Generated on Thu Apr 8 19:13:16 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:54 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classServer.html b/docs/module-doc/classServer.html index c882ab073..9022d36dc 100644 --- a/docs/module-doc/classServer.html +++ b/docs/module-doc/classServer.html @@ -80,6 +80,12 @@ Inheritance diagram for Server:



virtual bool MatchText (std::string sliteral, std::string spattern)  Matches text against a glob pattern.

+virtual void CallCommandHandler (std::string commandname, char **parameters, int pcnt, userrec *user) + Calls the handler for a command, either implemented by the core or by another module.

+virtual void ChangeHost (userrec *user, std::string host) + Change displayed hostname of a user.

+virtual void ChangeGECOS (userrec *user, std::string gecos) + Change GECOS (fullname) of a user.


Detailed Description

Allows server output and query functions This class contains methods which allow a module to query the state of the irc server, and produce output to users and other servers. @@ -88,7 +94,7 @@ All modules should instantiate at least one copy of this class, and use its memb

-Definition at line 240 of file modules.h.


Constructor & Destructor Documentation

+Definition at line 241 of file modules.h.

Constructor & Destructor Documentation

@@ -215,13 +221,13 @@ This allows modules to add extra commands into the command table. You must place typedef void (handlerfunc) (char**, int, userrec*); ... void handle_kill(char **parameters, int pcnt, userrec *user)

When the command is typed, the parameters will be placed into the parameters array (similar to argv) and the parameter count will be placed into pcnt (similar to argv). There will never be any less parameters than the 'minparams' value you specified when creating the command. The *user parameter is the class of the user which caused the command to trigger, who will always have the flag you specified in 'flags' when creating the initial command. For example to create an oper only command create the commands with flags='o'.

-Definition at line 183 of file modules.cpp. +Definition at line 188 of file modules.cpp.

References createcommand().

-

00184 {
-00185         createcommand(cmd,f,flags,minparams);
-00186 }
+
00189 {
+00190         createcommand(cmd,f,flags,minparams);
+00191 }
 
@@ -282,28 +288,182 @@ Adds an extended mode letter which is parsed by a module This allows modules to

+x for hostcloak. the "type" parameter is either MT_CHANNEL, MT_CLIENT, or MT_SERVER, to indicate wether the mode is a channel mode, a client mode, or a server mode. requires_oper is used with MT_CLIENT type modes only to indicate the mode can only be set or unset by an oper. If this is used for MT_CHANNEL type modes it is ignored. params_when_on is the number of modes to expect when the mode is turned on (for type MT_CHANNEL only), e.g. with mode +k, this would have a value of 1. the params_when_off value has a similar value to params_when_on, except it indicates the number of parameters to expect when the mode is disabled. Modes which act in a similar way to channel mode +l (e.g. require a parameter to enable, but not to disable) should use this parameter. The function returns false if the mode is unavailable, and will not attempt to allocate another character, as this will confuse users. This also means that as only one module can claim a specific mode character, the core does not need to keep track of which modules own which modes, which speeds up operation of the server. In this version, a mode can have at most one parameter, attempting to use more parameters will have undefined effects.

-Definition at line 293 of file modules.cpp. +Definition at line 308 of file modules.cpp.

References DoAddExtendedMode(), MT_CLIENT, and MT_SERVER.

-

00294 {
-00295         if (type == MT_SERVER)
-00296         {
-00297                 log(DEBUG,"*** API ERROR *** Modes of type MT_SERVER are reserved for future expansion");
-00298                 return false;
-00299         }
-00300         if (((params_when_on>0) || (params_when_off>0)) && (type == MT_CLIENT))
-00301         {
-00302                 log(DEBUG,"*** API ERROR *** Parameters on MT_CLIENT modes are not supported");
-00303                 return false;
-00304         }
-00305         if ((params_when_on>1) || (params_when_off>1))
-00306         {
-00307                 log(DEBUG,"*** API ERROR *** More than one parameter for an MT_CHANNEL mode is not yet supported");
-00308                 return false;
-00309         }
-00310         return DoAddExtendedMode(modechar,type,requires_oper,params_when_on,params_when_off);
-00311 }
+
00309 {
+00310         if (type == MT_SERVER)
+00311         {
+00312                 log(DEBUG,"*** API ERROR *** Modes of type MT_SERVER are reserved for future expansion");
+00313                 return false;
+00314         }
+00315         if (((params_when_on>0) || (params_when_off>0)) && (type == MT_CLIENT))
+00316         {
+00317                 log(DEBUG,"*** API ERROR *** Parameters on MT_CLIENT modes are not supported");
+00318                 return false;
+00319         }
+00320         if ((params_when_on>1) || (params_when_off>1))
+00321         {
+00322                 log(DEBUG,"*** API ERROR *** More than one parameter for an MT_CHANNEL mode is not yet supported");
+00323                 return false;
+00324         }
+00325         return DoAddExtendedMode(modechar,type,requires_oper,params_when_on,params_when_off);
+00326 }
+
+ + +

+ + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
void Server::CallCommandHandler std::string   commandname,
char **   parameters,
int   pcnt,
userrec  user
[virtual]
+
+ + + + + +
+   + + +

+Calls the handler for a command, either implemented by the core or by another module. +

+You can use this function to trigger other commands in the ircd, such as PRIVMSG, JOIN, KICK etc, or even as a method of callback. By defining command names that are untypeable for users on irc (e.g. those which contain a or
+) you may use them as callback identifiers. The first parameter to this method is the name of the command handler you wish to call, e.g. PRIVMSG. This will be a command handler previously registered by the core or wih AddCommand(). The second parameter is an array of parameters, and the third parameter is a count of parameters in the array. If you do not pass enough parameters to meet the minimum needed by the handler, the functiom will silently ignore it. The final parameter is the user executing the command handler, used for privilage checks, etc. +

+Definition at line 178 of file modules.cpp. +

+

00179 {
+00180         call_handler(commandname.c_str(),parameters,pcnt,user);
+00181 }
+
+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
void Server::ChangeGECOS userrec  user,
std::string   gecos
[virtual]
+
+ + + + + +
+   + + +

+Change GECOS (fullname) of a user. +

+You should always call this method to change a user's GECOS rather than writing directly to the fullname member of userrec, as any change applied via this method will be propogated to any linked servers. +

+Definition at line 266 of file modules.cpp. +

+

00267 {
+00268         ChangeName(user,gecos.c_str());
+00269 }
+
+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
void Server::ChangeHost userrec  user,
std::string   host
[virtual]
+
+ + + +
+   + + +

+Change displayed hostname of a user. +

+You should always call this method to change a user's host rather than writing directly to the dhost member of userrec, as any change applied via this method will be propogated to any linked servers. +

+Definition at line 261 of file modules.cpp. +

+

00262 {
+00263         ChangeDisplayedHost(user,host.c_str());
+00264 }
 
@@ -393,11 +553,11 @@ Attempts to look up a user's privilages on a channel.

This function will return a string containing either @, , +, or an empty string, representing the user's privilages upon the channel you specify.

-Definition at line 271 of file modules.cpp. +Definition at line 286 of file modules.cpp.

-

00272 {
-00273         return cmode(User,Chan);
-00274 }
+
00287 {
+00288         return cmode(User,Chan);
+00289 }
 
@@ -440,11 +600,11 @@ Returns true if two users share a common channel.

This method is used internally by the NICK and QUIT commands, and the Server::SendCommon method.

-Definition at line 234 of file modules.cpp. +Definition at line 239 of file modules.cpp.

-

00235 {
-00236         return (common_channels(u1,u2) != 0);
-00237 }
+
00240 {
+00241         return (common_channels(u1,u2) != 0);
+00242 }
 
@@ -478,11 +638,11 @@ Returns a count of the number of users on a channel.

This will NEVER be 0, as if the chanrec exists, it will have at least one user in the channel.

-Definition at line 313 of file modules.cpp. +Definition at line 328 of file modules.cpp.

-

00314 {
-00315         return usercount(c);
-00316 }
+
00329 {
+00330         return usercount(c);
+00331 }
 
@@ -516,11 +676,11 @@ Attempts to look up a channel and return a pointer to it.

This function will return NULL if the channel does not exist.

-Definition at line 266 of file modules.cpp. +Definition at line 281 of file modules.cpp.

-

00267 {
-00268         return FindChan(channel.c_str());
-00269 }
+
00282 {
+00283         return FindChan(channel.c_str());
+00284 }
 
@@ -554,11 +714,11 @@ Attempts to look up a nick and return a pointer to it.

This function will return NULL if the nick does not exist.

-Definition at line 261 of file modules.cpp. +Definition at line 276 of file modules.cpp.

-

00262 {
-00263         return Find(nick);
-00264 }
+
00277 {
+00278         return Find(nick);
+00279 }
 
@@ -591,11 +751,11 @@ Returns the information of the server as returned by the /ADMIN command.

See the Admin class for further information of the return value. The members Admin::Nick, Admin::Email and Admin::Name contain the information for the server where the module is loaded.

-Definition at line 286 of file modules.cpp. +Definition at line 301 of file modules.cpp.

-

00287 {
-00288         return Admin(getadminname(),getadminemail(),getadminnick());
-00289 }
+
00302 {
+00303         return Admin(getadminname(),getadminemail(),getadminnick());
+00304 }
 
@@ -628,11 +788,11 @@ Returns the network name, global to all linked servers.

-Definition at line 281 of file modules.cpp. +Definition at line 296 of file modules.cpp.

-

00282 {
-00283         return getnetworkname();
-00284 }
+
00297 {
+00298         return getnetworkname();
+00299 }
 
@@ -665,11 +825,11 @@ Returns the server name of the server where the module is loaded.

-Definition at line 276 of file modules.cpp. +Definition at line 291 of file modules.cpp.

-

00277 {
-00278         return getservername();
-00279 }
+
00292 {
+00293         return getservername();
+00294 }
 
@@ -703,11 +863,11 @@ Returns true if a nick is valid.

Nicks for unregistered connections will return false.

-Definition at line 256 of file modules.cpp. +Definition at line 271 of file modules.cpp.

-

00257 {
-00258         return (isnick(nick.c_str()) != 0);
-00259 }
+
00272 {
+00273         return (isnick(nick.c_str()) != 0);
+00274 }
 
@@ -759,7 +919,7 @@ This is similar to svsjoin and can be used to implement redirection, etc. On suc Definition at line 157 of file modules.cpp.

00158 {
-00159         return add_channel(user,cname.c_str(),key.c_str());
+00159         return add_channel(user,cname.c_str(),key.c_str(),true);
 00160 }
 
@@ -803,11 +963,11 @@ Writes a log string.

This method writes a line of text to the log. If the level given is lower than the level given in the configuration, this command has no effect.

-Definition at line 178 of file modules.cpp. +Definition at line 183 of file modules.cpp.

-

00179 {
-00180         log(level,"%s",s.c_str());
-00181 }
+
00184 {
+00185         log(level,"%s",s.c_str());
+00186 }
 
@@ -909,7 +1069,7 @@ This is similar to svspart and can be used to implement redirection, etc. Althou Definition at line 162 of file modules.cpp.

00163 {
-00164         return del_channel(user,cname.c_str(),reason.c_str());
+00164         return del_channel(user,cname.c_str(),reason.c_str(),false);
 00165 }
 
@@ -957,9 +1117,12 @@ Once you call this function, userrec* user will immediately become INVALID. You

Definition at line 172 of file modules.cpp.

+References userrec::nick. +

00173 {
-00174         kill_link(user,reason.c_str());
-00175 }
+00174         send_network_quit(user->nick,reason.c_str());
+00175         kill_link(user,reason.c_str());
+00176 }
 
@@ -1002,11 +1165,11 @@ Sends a line of text down a TCP/IP socket.

This method writes a line of text to an established socket, cutting it to 510 characters plus a carriage return and linefeed if required.

-Definition at line 193 of file modules.cpp. +Definition at line 198 of file modules.cpp.

-

00194 {
-00195         Write(Socket,"%s",s.c_str());
-00196 }
+
00199 {
+00200         Write(Socket,"%s",s.c_str());
+00201 }
 
@@ -1061,18 +1224,18 @@ Sends text from a user to a channel (mulicast).

This method writes a line of text to a channel, with the given user's nick/ident /host combination prepended, as used in PRIVMSG etc commands (see RFC 1459). If the IncludeSender flag is set, then the text is also sent back to the user from which it originated, as seen in MODE (see RFC 1459).

-Definition at line 222 of file modules.cpp. -

-

00223 {
-00224         if (IncludeSender)
-00225         {
-00226                 WriteChannel(Channel,User,"%s",s.c_str());
-00227         }
-00228         else
-00229         {
-00230                 ChanExceptSender(Channel,User,"%s",s.c_str());
-00231         }
-00232 }
+Definition at line 227 of file modules.cpp.
+

+

00228 {
+00229         if (IncludeSender)
+00230         {
+00231                 WriteChannel(Channel,User,"%s",s.c_str());
+00232         }
+00233         else
+00234         {
+00235                 ChanExceptSender(Channel,User,"%s",s.c_str());
+00236         }
+00237 }
 
@@ -1121,18 +1284,18 @@ Sends text from a user to one or more channels (mulicast).

This method writes a line of text to all users which share a common channel with a given user, with the user's nick/ident/host combination prepended, as used in PRIVMSG etc commands (see RFC 1459). If the IncludeSender flag is set, then the text is also sent back to the user from which it originated, as seen in NICK (see RFC 1459). Otherwise, it is only sent to the other recipients, as seen in QUIT.

-Definition at line 239 of file modules.cpp. -

-

00240 {
-00241         if (IncludeSender)
-00242         {
-00243                 WriteCommon(User,"%s",text.c_str());
-00244         }
-00245         else
-00246         {
-00247                 WriteCommonExcept(User,"%s",text.c_str());
-00248         }
-00249 }
+Definition at line 244 of file modules.cpp.
+

+

00245 {
+00246         if (IncludeSender)
+00247         {
+00248                 WriteCommon(User,"%s",text.c_str());
+00249         }
+00250         else
+00251         {
+00252                 WriteCommonExcept(User,"%s",text.c_str());
+00253         }
+00254 }
 
@@ -1181,11 +1344,11 @@ Sends text from a user to a socket.

This method writes a line of text to an established socket, with the given user's nick/ident /host combination prepended, as used in PRIVSG etc commands (see RFC 1459)

-Definition at line 203 of file modules.cpp. +Definition at line 208 of file modules.cpp.

-

00204 {
-00205         WriteFrom(Socket,User,"%s",s.c_str());
-00206 }
+
00209 {
+00210         WriteFrom(Socket,User,"%s",s.c_str());
+00211 }
 
@@ -1241,13 +1404,13 @@ modes[2] = user->nick;

Srv->SendMode(modes,3,user);

The modes will originate from the server where the command was issued, however responses (e.g. numerics) will be sent to the user you provide as the third parameter. You must be sure to get the number of parameters correct in the pcnt parameter otherwise you could leave your server in an unstable state!

-Definition at line 188 of file modules.cpp. +Definition at line 193 of file modules.cpp.

References server_mode().

-

00189 {
-00190         server_mode(parameters,pcnt,user);
-00191 }
+
00194 {
+00195         server_mode(parameters,pcnt,user);
+00196 }
 
@@ -1328,11 +1491,11 @@ Sends text from the server to a socket.

This method writes a line of text to an established socket, with the servername prepended as used by numerics (see RFC 1459)

-Definition at line 198 of file modules.cpp. +Definition at line 203 of file modules.cpp.

-

00199 {
-00200         WriteServ(Socket,"%s",s.c_str());
-00201 }
+
00204 {
+00205         WriteServ(Socket,"%s",s.c_str());
+00206 }
 
@@ -1385,22 +1548,22 @@ The format will become:

:localserver TEXT

Which is useful for numerics and server notices to single users, etc.

-Definition at line 208 of file modules.cpp. +Definition at line 213 of file modules.cpp.

-References connection::fd. +References connection::fd.

-

00209 {
-00210         if (!Source)
-00211         {
-00212                 // if source is NULL, then the message originates from the local server
-00213                 Write(Dest->fd,":%s %s",this->GetServerName().c_str(),s.c_str());
-00214         }
-00215         else
+
00214 {
+00215         if (!Source)
 00216         {
-00217                 // otherwise it comes from the user specified
-00218                 WriteTo(Source,Dest,"%s",s.c_str());
+00217                 // if source is NULL, then the message originates from the local server
+00218                 Write(Dest->fd,":%s %s",this->GetServerName().c_str(),s.c_str());
 00219         }
-00220 }
+00220         else
+00221         {
+00222                 // otherwise it comes from the user specified
+00223                 WriteTo(Source,Dest,"%s",s.c_str());
+00224         }
+00225 }
 
@@ -1498,17 +1661,17 @@ Sends a WALLOPS message.

This method writes a WALLOPS message to all users with the +w flag, originating from the specified user.

-Definition at line 251 of file modules.cpp. +Definition at line 256 of file modules.cpp.

-

00252 {
-00253         WriteWallOps(User,"%s",text.c_str());
-00254 }
+
00257 {
+00258         WriteWallOps(User,false,"%s",text.c_str());
+00259 }
 

The documentation for this class was generated from the following files: -
Generated on Thu Apr 8 19:13:16 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:54 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classVersion-members.html b/docs/module-doc/classVersion-members.html index f3954c819..d2ab2ba68 100644 --- a/docs/module-doc/classVersion-members.html +++ b/docs/module-doc/classVersion-members.html @@ -15,7 +15,7 @@ RevisionVersion Version(int major, int minor, int revision, int build)Version ~classbase()classbase [inline] -
Generated on Thu Apr 8 19:13:25 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:57 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classVersion.html b/docs/module-doc/classVersion.html index 52032b4fd..2f06ef003 100644 --- a/docs/module-doc/classVersion.html +++ b/docs/module-doc/classVersion.html @@ -36,7 +36,7 @@ A class of type Version is returned by the GetVersion method of the 67 of file modules.h.

Constructor & Destructor Documentation

+Definition at line 68 of file modules.h.

Constructor & Destructor Documentation

@@ -114,7 +114,7 @@ Definition at line 102

-Definition at line 70 of file modules.h. +Definition at line 71 of file modules.h.

@@ -138,7 +138,7 @@ Definition at line 70 of

-Definition at line 70 of file modules.h. +Definition at line 71 of file modules.h.

@@ -162,7 +162,7 @@ Definition at line 70 of

-Definition at line 70 of file modules.h. +Definition at line 71 of file modules.h.

@@ -186,12 +186,12 @@ Definition at line 70 of

-Definition at line 70 of file modules.h. +Definition at line 71 of file modules.h.


The documentation for this class was generated from the following files: -
Generated on Thu Apr 8 19:13:25 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:57 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classchanrec-members.html b/docs/module-doc/classchanrec-members.html index 9779336c5..98a3de5b1 100644 --- a/docs/module-doc/classchanrec-members.html +++ b/docs/module-doc/classchanrec-members.html @@ -31,7 +31,7 @@ topicsetchanrec ~chanrec()chanrec [inline, virtual] ~classbase()classbase [inline] -
Generated on Thu Apr 8 19:12:50 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:46 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classchanrec.html b/docs/module-doc/classchanrec.html index c4a358426..5c7f2e635 100644 --- a/docs/module-doc/classchanrec.html +++ b/docs/module-doc/classchanrec.html @@ -808,7 +808,7 @@ Referenced by chanrec()
The documentation for this class was generated from the following files: -
Generated on Thu Apr 8 19:12:50 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:46 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classclassbase-members.html b/docs/module-doc/classclassbase-members.html index cec3359be..809f293a9 100644 --- a/docs/module-doc/classclassbase-members.html +++ b/docs/module-doc/classclassbase-members.html @@ -10,7 +10,7 @@ ageclassbase classbase()classbase [inline] ~classbase()classbase [inline] -
Generated on Thu Apr 8 19:12:52 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:46 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classclassbase.html b/docs/module-doc/classclassbase.html index 4e358f69d..4bd5a9ffb 100644 --- a/docs/module-doc/classclassbase.html +++ b/docs/module-doc/classclassbase.html @@ -22,10 +22,10 @@ Inheritance diagram for classbase:

- - - - + + + + @@ -144,7 +144,7 @@ Definition at line 20 of fil
The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:12:52 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:46 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classclassbase__inherit__graph.gif b/docs/module-doc/classclassbase__inherit__graph.gif index cabc2c0f2..c9e92ed9f 100644 Binary files a/docs/module-doc/classclassbase__inherit__graph.gif and b/docs/module-doc/classclassbase__inherit__graph.gif differ diff --git a/docs/module-doc/classcommand__t-members.html b/docs/module-doc/classcommand__t-members.html index 7e3c94fd0..43ab0ed8d 100644 --- a/docs/module-doc/classcommand__t-members.html +++ b/docs/module-doc/classcommand__t-members.html @@ -16,7 +16,7 @@ total_bytescommand_t use_countcommand_t ~classbase()classbase [inline] -
Generated on Thu Apr 8 19:12:54 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:47 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classcommand__t.html b/docs/module-doc/classcommand__t.html index cc0b01062..00199dc2e 100644 --- a/docs/module-doc/classcommand__t.html +++ b/docs/module-doc/classcommand__t.html @@ -199,7 +199,7 @@ Definition at line 44 of
The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:12:54 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:47 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classconnection-members.html b/docs/module-doc/classconnection-members.html index 6e5472b03..07506b20f 100644 --- a/docs/module-doc/classconnection-members.html +++ b/docs/module-doc/classconnection-members.html @@ -7,36 +7,39 @@
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

connection Member List

This is the complete list of members for connection, including all inherited members. + - - - + + + - - + + + - - - - + + + + + - + - - + + + - - - - - - + + + + - + + -
AddIncoming(int fd, char *targethost, int sourceport)connection
ageclassbase
BeginLink(char *targethost, int port, char *password)connection
bytes_inconnection
bytes_outconnection
BeginLink(char *targethost, int port, char *password, char *servername, int myport)connection
bytes_inconnection
bytes_outconnection
classbase()classbase [inline]
cmds_inconnection
cmds_outconnection
cmds_inconnection
cmds_outconnection
connection()connection
connectorsconnection
CreateListener(char *host, int p)connection
fdconnection
GenKey()connection
haspassedconnection
hostconnection
fdconnection
FindHost(std::string host)connection
GenKey()connection
haspassedconnection
hostconnection
idle_lastmsgconnection
inbufconnection
inbufconnection
internal_addrconnection
ipconnection
keyconnection
internal_portconnection
ipconnection
lastpingconnection
MeshCookie(char *targethost, int port, long cookie, char *servername)connection
npingconnection
portconnection
RecvPacket(char *message, char *host, int &prt, long &theirkey)connection
registeredconnection
SendACK(char *host, int port, int reply_id)connection
SendPacket(char *message, char *host, int port, long ourkey)connection
SendSYN(char *host, int port)connection
portconnection
RecvPacket(std::deque< std::string > &messages, char *host)connection
registeredconnection
SendPacket(char *message, const char *host)connection
signonconnection
TerminateLink(char *targethost)connection
stateconnection
TerminateLink(char *targethost)connection
~classbase()classbase [inline]

Generated on Thu Apr 8 19:12:59 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:49 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classconnection.html b/docs/module-doc/classconnection.html index 8c133be35..1a6962cb8 100644 --- a/docs/module-doc/classconnection.html +++ b/docs/module-doc/classconnection.html @@ -6,7 +6,10 @@
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  
-

connection Class Reference

#include <connection.h> +

connection Class Reference

Please note: classes serverrec and userrec both inherit from class connection. +More... +

+#include <connection.h>

Inheritance diagram for connection:

Inheritance graph
@@ -16,40 +19,77 @@ Inheritance diagram for connection:

[legend]
Collaboration diagram for connection:

Collaboration graph
- +
[legend]
List of all members. - - - - - - - - + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Public Member Functions

 connection ()
bool CreateListener (char *host, int p)
bool BeginLink (char *targethost, int port, char *password)
void TerminateLink (char *targethost)
bool SendPacket (char *message, char *host, int port, long ourkey)
bool RecvPacket (char *message, char *host, int &prt, long &theirkey)
bool SendSYN (char *host, int port)
bool SendACK (char *host, int port, int reply_id)
long GenKey ()
 Default constructor.

bool CreateListener (char *host, int p)
 Create a listening socket on 'host' using port number 'p'.

bool BeginLink (char *targethost, int port, char *password, char *servername, int myport)
 Begin an outbound link to another ircd at targethost.

bool MeshCookie (char *targethost, int port, long cookie, char *servername)
 Begin an outbound mesh link to another ircd on a network you are already an authenticated member of.

void TerminateLink (char *targethost)
 Terminate a link to 'targethost' by calling the ircd_connector::CloseConnection method.

bool SendPacket (char *message, const char *host)
 Send a message to a server by name, if the server is unavailable directly route the packet via another server If the server still cannot be reached after attempting to route the message remotely, returns false.

bool RecvPacket (std::deque< std::string > &messages, char *host)
 Returns the next available packet and returns true if data is available.

ircd_connectorFindHost (std::string host)
 Find the ircd_connector oject related to a certain servername given in 'host'.

bool AddIncoming (int fd, char *targethost, int sourceport)
 Add an incoming connection to the connection pool.

long GenKey ()
 This function is deprecated and may be removed in a later alpha/beta.


Public Attributes

long key
int fd
char host [256]
long ip
char inbuf [MAXBUF]
long bytes_in
long bytes_out
long cmds_in
long cmds_out
bool haspassed
int port
int registered
int fd
 File descriptor of the connection.

char host [256]
 Hostname of connection.

long ip
 IP of connection.

char inbuf [MAXBUF]
 Inbuf of connection.

long bytes_in
 Stats counter for bytes inbound.

long bytes_out
 Stats counter for bytes outbound.

long cmds_in
 Stats counter for commands inbound.

long cmds_out
 Stats counter for commands outbound.

bool haspassed
 True if server/user has authenticated, false if otherwise.

int port
 Port number For a userrec, this is the port they connected to the network on.

int registered
 Used by userrec to indicate the registration status of the connection.

short int state
 Reserved for future use.

time_t lastping
 Time the connection was last pinged.

time_t signon
 Time the connection was created, set in the constructor.

time_t idle_lastmsg
 Time that the connection last sent data, used to calculate idle time.

time_t nping
 Used by PING checks with clients.

char internal_addr [1024]
 Unused, will be removed in a future alpha/beta.

int internal_port
 Unused, will be removed in a future alpha/beta.

std::vector< ircd_connectorconnectors
 With a serverrec, this is a list of all established server connections.

-

Constructor & Destructor Documentation

+

Detailed Description

+Please note: classes serverrec and userrec both inherit from class connection. +

+ +

+Definition at line 160 of file connection.h.


Constructor & Destructor Documentation

@@ -74,11 +114,59 @@ Inheritance diagram for connection:

+

+ + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + +
bool connection::AddIncoming int   fd,
char *   targethost,
int   sourceport
+
+ + + + + +
+   + + +

+Add an incoming connection to the connection pool. +

+(reserved for core use)

@@ -100,7 +188,19 @@ Inheritance diagram for connection:

char *  -
+ + + + + + + + + + + + + @@ -119,6 +219,8 @@ Inheritance diagram for connection:

  password  password,
char *   servername,
int   myport
+

+Create a listening socket on 'host' using port number 'p'.

-

+

- + - + + @@ -185,43 +290,23 @@ Inheritance diagram for connection:

ircd_connector oject related to a certain servername given in 'host'.

long connection::GenKey ircd_connector* connection::FindHost   std::string   host
-

+

- + - - - - - - - - - - - - - - - - - - - - - - - - - + + +
bool connection::RecvPacket long connection::GenKey char *   message,
char *   host,
int &   prt,
long &   theirkey
 
@@ -235,20 +320,22 @@ Inheritance diagram for connection:

+

@@ -750,14 +891,16 @@ Referenced by serverrec::se
- + - + @@ -259,8 +346,14 @@ Inheritance diagram for connection:

int  -
+ + + + + + + + @@ -279,38 +372,28 @@ Inheritance diagram for connection:

+

bool connection::SendACK bool connection::MeshCookie char *   host,   targethost,
  reply_idlong   cookie,
char *   servername
+Definition at line 231 of file connection.h.
- + - - + + - - - - - - - - - - - - - + @@ -330,25 +413,27 @@ Inheritance diagram for connection:

+

bool connection::SendPacket bool connection::RecvPacket char *   message, std::deque< std::string > &   messages,
char *   host,
int   port,
long   ourkey  host
- + - + - - + + @@ -367,11 +452,13 @@ Inheritance diagram for connection:

+

bool connection::SendSYN bool connection::SendPacket char *   host,   message,
int   portconst char *   host
@@ -396,12 +483,14 @@ Inheritance diagram for connection:

ircd_connector::CloseConnection method.


Member Data Documentation

-

+

@@ -420,14 +509,16 @@ Inheritance diagram for connection:

47 of file connection.h. +Definition at line 181 of file connection.h.

Referenced by userrec::userrec().

-

+

@@ -446,14 +537,16 @@ Referenced by userrec::userre

+Stats counter for bytes outbound. +

-Definition at line 48 of file connection.h. +Definition at line 185 of file connection.h.

Referenced by userrec::userrec().

-

+

@@ -472,14 +565,16 @@ Referenced by userrec::userre

+Stats counter for commands inbound. +

-Definition at line 49 of file connection.h. +Definition at line 189 of file connection.h.

Referenced by userrec::userrec().

-

+

@@ -498,14 +593,42 @@ Referenced by userrec::userre

+Stats counter for commands outbound. +

-Definition at line 50 of file connection.h. +Definition at line 193 of file connection.h.

Referenced by userrec::userrec().

-

+

+ + + + +
+ + +
std::vector<ircd_connector> connection::connectors +
+
+ + + + + +
+   + + +

+With a serverrec, this is a list of all established server connections. +

+With a userrec this is unused. +

+Definition at line 240 of file connection.h.

+

+Referenced by Server::SendTo(), serverrec::serverrec(), and userrec::userrec().
@@ -524,14 +647,16 @@ Referenced by userrec::userre

+File descriptor of the connection. +

-Definition at line 43 of file connection.h. +Definition at line 165 of file connection.h.

-Referenced by Server::SendTo(), serverrec::serverrec(), and userrec::userrec().

-

+

@@ -550,14 +675,16 @@ Referenced by Server::SendT

+True if server/user has authenticated, false if otherwise. +

-Definition at line 51 of file connection.h. +Definition at line 197 of file connection.h.

Referenced by userrec::userrec().

-

+

+Definition at line 169 of file connection.h.
@@ -576,9 +703,11 @@ Referenced by userrec::userre

- +Hostname of connection. +

+Not used if this is a serverrec

-Definition at line 44 of file connection.h.

@@ -600,14 +729,16 @@ Definition at line 44

+Time that the connection last sent data, used to calculate idle time. +

-Definition at line 56 of file connection.h. +Definition at line 223 of file connection.h.

Referenced by userrec::userrec().

-

+

+Definition at line 177 of file connection.h.
@@ -626,9 +757,11 @@ Referenced by userrec::userre

- +Inbuf of connection. +

+Only used for userrec

-Definition at line 46 of file connection.h.

@@ -650,18 +783,20 @@ Definition at line 46

+Unused, will be removed in a future alpha/beta. +

-Definition at line 58 of file connection.h.

-

+

@@ -674,20 +809,20 @@ Definition at line 58 +Definition at line 235 of file connection.h.
-
long connection::ip + int connection::internal_port

- +Unused, will be removed in a future alpha/beta.

-Definition at line 45 of file connection.h. +

-Referenced by userrec::userrec().

-

+

@@ -700,9 +835,13 @@ Referenced by userrec::userre +Referenced by userrec::userrec().
-
long connection::key + long connection::ip

- +IP of connection. +

+Reserved for future use. +

+Definition at line 173 of file connection.h.

-Definition at line 42 of file connection.h.

@@ -724,9 +863,11 @@ Definition at line 42

+Time the connection was last pinged. +

-Definition at line 54 of file connection.h. +Definition at line 215 of file connection.h.

Referenced by serverrec::serverrec(), and userrec::userrec().

+Used by PING checks with clients. +

-Definition at line 57 of file connection.h. +Definition at line 227 of file connection.h.

Referenced by userrec::userrec().

-

+

@@ -776,14 +919,16 @@ Referenced by userrec::userre

- +Port number For a userrec, this is the port they connected to the network on. +

+For a serverrec this is the current listening port of the serverrec object.

-Definition at line 52 of file connection.h. +Definition at line 203 of file connection.h.

Referenced by userrec::userrec().

-

+

@@ -828,16 +975,44 @@ Referenced by userrec::userre
@@ -802,9 +947,11 @@ Referenced by userrec::userre

+Used by userrec to indicate the registration status of the connection. +

-Definition at line 53 of file connection.h. +Definition at line 207 of file connection.h.

Referenced by userrec::userrec().

+Time the connection was created, set in the constructor. +

-Definition at line 55 of file connection.h. +Definition at line 219 of file connection.h.

Referenced by serverrec::serverrec(), and userrec::userrec().

+

+ + + + +
+ + +
short int connection::state +
+
+ + + + + +
+   + + +

+Reserved for future use. +

+ +

+Definition at line 211 of file connection.h.


The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:12:59 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:48 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classconnection__coll__graph.gif b/docs/module-doc/classconnection__coll__graph.gif index c3e247008..97c4c8ec3 100644 Binary files a/docs/module-doc/classconnection__coll__graph.gif and b/docs/module-doc/classconnection__coll__graph.gif differ diff --git a/docs/module-doc/classes.html b/docs/module-doc/classes.html index 9842e9d97..e54f4d8eb 100644 --- a/docs/module-doc/classes.html +++ b/docs/module-doc/classes.html @@ -8,18 +8,18 @@ Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

InspIRCd Compound Index

  A  
-
command_t   
  F  
-
  M  
-
Server   
Admin   ConfigReader   FileReader   ModeParameter   serverrec   
  B  
-
ConnectClass   
  H  
-
Module   
  U  
-
BanItem   connection   HostItem   ModuleFactory   ucrec   
  C  
-
  E  
+
ConfigReader   FileReader   
  M  
+
Server   
Admin   ConnectClass   
  H  
+
ModeParameter   serverrec   
  B  
+
connection   HostItem   Module   
  U  
+
BanItem   
  E  
  I  
-
  P  
-
userrec   
chanrec   ExemptItem   Invited   packet   
  V  
-
classbase   ExtMode   InviteItem   
  S  
-
Version   

Generated on Thu Apr 8 19:12:45 2004 for InspIRCd by +
ModuleFactory   ucrec   
  C  
+
ExemptItem   Invited   
  P  
+
userrec   
chanrec   ExtMode   InviteItem   packet   
  V  
+
classbase   
  F  
+
ircd_connector   
  S  
+
Version   
command_t   


Generated on Sat Apr 17 13:31:44 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classircd__connector-members.html b/docs/module-doc/classircd__connector-members.html new file mode 100644 index 000000000..c7163bde6 --- /dev/null +++ b/docs/module-doc/classircd__connector-members.html @@ -0,0 +1,41 @@ + + +Member List + + + +
+Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  
+

ircd_connector Member List

This is the complete list of members for ircd_connector, including all inherited members. + + + + + + + + + + + + + + + + + + + + + + + + + + +
addrircd_connector [private]
ageclassbase
classbase()classbase [inline]
CloseConnection()ircd_connector
descriptionircd_connector [private]
fdircd_connector [private]
GetDescription()ircd_connector
GetDescriptor()ircd_connector
GetServerIP()ircd_connector
GetServerName()ircd_connector
GetServerPort()ircd_connector
GetState()ircd_connector
hostircd_connector
MakeOutboundConnection(char *host, int port)ircd_connector
portircd_connector
routesircd_connector
servernameircd_connector [private]
SetDescription(std::string desc)ircd_connector
SetDescriptor(int fd)ircd_connector
SetHostAddress(char *host, int port)ircd_connector [private]
SetHostAndPort(char *host, int port)ircd_connector
SetServerName(std::string serv)ircd_connector
SetServerPort(int p)ircd_connector
SetState(int state)ircd_connector
stateircd_connector [private]
~classbase()classbase [inline]

Generated on Sat Apr 17 13:31:52 2004 for InspIRCd by + +doxygen1.3-rc3
+ + diff --git a/docs/module-doc/classircd__connector.html b/docs/module-doc/classircd__connector.html new file mode 100644 index 000000000..15ac75abc --- /dev/null +++ b/docs/module-doc/classircd__connector.html @@ -0,0 +1,784 @@ + + +ircd_connector class Reference + + + +
+Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  
+

ircd_connector Class Reference

Each connection has one or more of these each represents ONE outbound connection to another ircd so each inbound has multiple outbounds. +More... +

+#include <connection.h> +

+Inheritance diagram for ircd_connector:

Inheritance graph
+ + + +
[legend]
Collaboration diagram for ircd_connector:

Collaboration graph
+ + + +
[legend]
List of all members. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Public Member Functions

bool MakeOutboundConnection (char *host, int port)
 Create an outbound connection to a listening socket.

std::string GetServerName ()
 Return the servername on this established connection.

void SetServerName (std::string serv)
 Set the server name of this connection.

int GetDescriptor ()
 Get the file descriptor associated with this connection.

void SetDescriptor (int fd)
 Set the file descriptor for this connection.

int GetState ()
 Get the state flags for this connection.

void SetState (int state)
 Set the state flags for this connection.

char * GetServerIP ()
 Get the ip address (not servername) associated with this connection.

std::string GetDescription ()
 Get the server description of this connection.

void SetDescription (std::string desc)
 Set the server description of this connection.

int GetServerPort ()
 Get the port number being used for this connection If the connection is outbound this will be the remote port otherwise it will be the local port, so it can always be gautanteed as open at the address given in GetServerIP().

void SetServerPort (int p)
 Set the port used by this connection.

bool SetHostAndPort (char *host, int port)
 Set both the host and the port in one operation for this connection.

void CloseConnection ()
 Close the connection by calling close() on its file descriptor This function call updates no other data.


Public Attributes

char host [MAXBUF]
 When MakeOutboundConnection is called, these public members are filled with the details passed to the function, for future reference.

int port
 When MakeOutboundConnection is called, these public members are filled with the details passed to the function, for future reference.

std::vector< std::string > routes
 Server names of servers that this server is linked to So for A->B->C, if this was the record for B it would contain A and C whilever both servers are connected to B.


Private Member Functions

bool SetHostAddress (char *host, int port)
 PRIVATE function to set the host address and port to connect to.


Private Attributes

sockaddr_in addr
 Sockaddr of the outbound ip and port.

int fd
 File descriptor of the connection.

std::string servername
 Server name.

std::string description
 Server 'GECOS'.

int state
 State.

+

Detailed Description

+Each connection has one or more of these each represents ONE outbound connection to another ircd so each inbound has multiple outbounds. +

+A listening socket that accepts server type connections is represented by one class serverrec. Class serverrec will instantiate several objects of type ircd_connector to represent each established connection, inbound or outbound. So, to determine all linked servers you must walk through all the serverrecs that the core defines, and in each one iterate through until you find connection(s) relating to the server you want information on. The core and module API provide functions for this. +

+ +

+Definition at line 40 of file connection.h.


Member Function Documentation

+

+ + + + +
+ + + + + + + + + +
void ircd_connector::CloseConnection  
+
+ + + + + +
+   + + +

+Close the connection by calling close() on its file descriptor This function call updates no other data. +

+

+

+ + + + +
+ + + + + + + + + +
std::string ircd_connector::GetDescription  
+
+ + + + + +
+   + + +

+Get the server description of this connection. +

+

+

+ + + + +
+ + + + + + + + + +
int ircd_connector::GetDescriptor  
+
+ + + + + +
+   + + +

+Get the file descriptor associated with this connection. +

+

+

+ + + + +
+ + + + + + + + + +
char* ircd_connector::GetServerIP  
+
+ + + + + +
+   + + +

+Get the ip address (not servername) associated with this connection. +

+

+

+ + + + +
+ + + + + + + + + +
std::string ircd_connector::GetServerName  
+
+ + + + + +
+   + + +

+Return the servername on this established connection. +

+

+

+ + + + +
+ + + + + + + + + +
int ircd_connector::GetServerPort  
+
+ + + + + +
+   + + +

+Get the port number being used for this connection If the connection is outbound this will be the remote port otherwise it will be the local port, so it can always be gautanteed as open at the address given in GetServerIP(). +

+

+

+ + + + +
+ + + + + + + + + +
int ircd_connector::GetState  
+
+ + + + + +
+   + + +

+Get the state flags for this connection. +

+

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
bool ircd_connector::MakeOutboundConnection char *   host,
int   port
+
+ + + + + +
+   + + +

+Create an outbound connection to a listening socket. +

+

+

+ + + + +
+ + + + + + + + + + +
void ircd_connector::SetDescription std::string   desc
+
+ + + + + +
+   + + +

+Set the server description of this connection. +

+

+

+ + + + +
+ + + + + + + + + + +
void ircd_connector::SetDescriptor int   fd
+
+ + + + + +
+   + + +

+Set the file descriptor for this connection. +

+

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
bool ircd_connector::SetHostAddress char *   host,
int   port
[private]
+
+ + + + + +
+   + + +

+PRIVATE function to set the host address and port to connect to. +

+

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
bool ircd_connector::SetHostAndPort char *   host,
int   port
+
+ + + + + +
+   + + +

+Set both the host and the port in one operation for this connection. +

+

+

+ + + + +
+ + + + + + + + + + +
void ircd_connector::SetServerName std::string   serv
+
+ + + + + +
+   + + +

+Set the server name of this connection. +

+

+

+ + + + +
+ + + + + + + + + + +
void ircd_connector::SetServerPort int   p
+
+ + + + + +
+   + + +

+Set the port used by this connection. +

+

+

+ + + + +
+ + + + + + + + + + +
void ircd_connector::SetState int   state
+
+ + + + + +
+   + + +

+Set the state flags for this connection. +

+

+


Member Data Documentation

+

+ + + + +
+ + +
sockaddr_in ircd_connector::addr [private] +
+
+ + + + + +
+   + + +

+Sockaddr of the outbound ip and port. +

+ +

+Definition at line 45 of file connection.h.

+

+ + + + +
+ + +
std::string ircd_connector::description [private] +
+
+ + + + + +
+   + + +

+Server 'GECOS'. +

+ +

+Definition at line 57 of file connection.h.

+

+ + + + +
+ + +
int ircd_connector::fd [private] +
+
+ + + + + +
+   + + +

+File descriptor of the connection. +

+ +

+Definition at line 49 of file connection.h.

+

+ + + + +
+ + +
char ircd_connector::host[MAXBUF] +
+
+ + + + + +
+   + + +

+When MakeOutboundConnection is called, these public members are filled with the details passed to the function, for future reference. +

+ +

+Definition at line 74 of file connection.h.

+

+ + + + +
+ + +
int ircd_connector::port +
+
+ + + + + +
+   + + +

+When MakeOutboundConnection is called, these public members are filled with the details passed to the function, for future reference. +

+ +

+Definition at line 80 of file connection.h.

+

+ + + + +
+ + +
std::vector<std::string> ircd_connector::routes +
+
+ + + + + +
+   + + +

+Server names of servers that this server is linked to So for A->B->C, if this was the record for B it would contain A and C whilever both servers are connected to B. +

+ +

+Definition at line 86 of file connection.h.

+

+ + + + +
+ + +
std::string ircd_connector::servername [private] +
+
+ + + + + +
+   + + +

+Server name. +

+ +

+Definition at line 53 of file connection.h.

+

+ + + + +
+ + +
int ircd_connector::state [private] +
+
+ + + + + +
+   + + +

+State. +

+STATE_NOAUTH_INBOUND, STATE_NOAUTH_OUTBOUND STATE_SYNC, STATE_DISCONNECTED, STATE_CONNECTED +

+Definition at line 62 of file connection.h.

+


The documentation for this class was generated from the following file: +
Generated on Sat Apr 17 13:31:52 2004 for InspIRCd by + +doxygen1.3-rc3
+ + diff --git a/docs/module-doc/classircd__connector__coll__graph.gif b/docs/module-doc/classircd__connector__coll__graph.gif new file mode 100644 index 000000000..09f1acfba Binary files /dev/null and b/docs/module-doc/classircd__connector__coll__graph.gif differ diff --git a/docs/module-doc/classircd__connector__inherit__graph.gif b/docs/module-doc/classircd__connector__inherit__graph.gif new file mode 100644 index 000000000..00c05386b Binary files /dev/null and b/docs/module-doc/classircd__connector__inherit__graph.gif differ diff --git a/docs/module-doc/classpacket.html b/docs/module-doc/classpacket.html index 2c7e909b4..cb4cafee7 100644 --- a/docs/module-doc/classpacket.html +++ b/docs/module-doc/classpacket.html @@ -8,182 +8,12 @@ Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

packet Class Reference

#include <connection.h>

-Inheritance diagram for packet:

Inheritance graph
- - - -
[legend]
Collaboration diagram for packet:

Collaboration graph
- - - -
[legend]
List of all members. +
- - - - - - - - -

Public Member Functions

 packet ()
 ~packet ()

Public Attributes

long key
short int id
short int type
char data [MAXBUF]
-

Constructor & Destructor Documentation

-

- - - - -
- - - - - - - - - -
packet::packet  
-
- - - - - -
-   - - -

-

-

- - - - -
- - - - - - - - - -
packet::~packet  
-
- - - - - -
-   - - -

-

-


Member Data Documentation

-

- - - - -
- - -
char packet::data[MAXBUF] -
-
- - - - - -
-   - - -

- -

-Definition at line 32 of file connection.h.

-

- - - - -
- - -
short int packet::id -
-
- - - - - -
-   - - -

- -

-Definition at line 30 of file connection.h.

-

- - - - -
- - -
long packet::key -
-
- - - - - -
-   - - -

- -

-Definition at line 29 of file connection.h.

-

- - - - -
- - -
short int packet::type -
-
- - - - -
-   - - -

- -

-Definition at line 31 of file connection.h.


The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:13:14 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:54 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classserverrec-members.html b/docs/module-doc/classserverrec-members.html index ddafd30b9..7a6a83bca 100644 --- a/docs/module-doc/classserverrec-members.html +++ b/docs/module-doc/classserverrec-members.html @@ -7,47 +7,52 @@
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

serverrec Member List

This is the complete list of members for serverrec, including all inherited members. + - - - + + + - - + + + - - - + + + + + - + - + - + + - + - - - - - - + + + + - + + + -
AddIncoming(int fd, char *targethost, int sourceport)connection
ageclassbase
BeginLink(char *targethost, int port, char *password)connection
bytes_inconnection
bytes_outconnection
BeginLink(char *targethost, int port, char *password, char *servername, int myport)connection
bytes_inconnection
bytes_outconnection
classbase()classbase [inline]
cmds_inconnection
cmds_outconnection
cmds_inconnection
cmds_outconnection
connection()connection
connectorsconnection
CreateListener(char *host, int p)connection
fdconnection
GenKey()connection
haspassedconnection
descriptionserverrec
fdconnection
FindHost(std::string host)connection
GenKey()connection
haspassedconnection
hops_awayserverrec
hostconnection
hostconnection
idle_lastmsgconnection
inbufconnection
inbufconnection
internal_addrconnection
ipconnection
internal_portconnection
ipconnection
jupiterserverrec
keyconnection
lastpingconnection
MeshCookie(char *targethost, int port, long cookie, char *servername)connection
nameserverrec
npingconnection
opercountserverrec
pingtimeserverrec
portconnection
RecvPacket(char *message, char *host, int &prt, long &theirkey)connection
registeredconnection
SendACK(char *host, int port, int reply_id)connection
SendPacket(char *message, char *host, int port, long ourkey)connection
SendSYN(char *host, int port)connection
portconnection
RecvPacket(std::deque< std::string > &messages, char *host)connection
registeredconnection
SendPacket(char *message, const char *host)connection
serverrec()serverrec
serverrec(char *n, long ver, bool jupe)serverrec
signonconnection
TerminateLink(char *targethost)connection
stateconnection
sync_soonserverrec
TerminateLink(char *targethost)connection
usercountserverrec
usercount_iserverrec
versionserverrec
~classbase()classbase [inline]
~serverrec()serverrec

Generated on Thu Apr 8 19:13:19 2004 for InspIRCd by +


Generated on Sat Apr 17 13:31:55 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classserverrec.html b/docs/module-doc/classserverrec.html index fbae629e7..5555cf74b 100644 --- a/docs/module-doc/classserverrec.html +++ b/docs/module-doc/classserverrec.html @@ -18,7 +18,7 @@ Inheritance diagram for serverrec:

[legend]
Collaboration diagram for serverrec:

Collaboration graph
- +
[legend]
List of all members. @@ -46,6 +46,9 @@ Inheritance diagram for serverrec:



+ + +
bool jupiter
 is a JUPE server (faked to enforce a server ban)

char description [MAXBUF]
 Description of the server.

bool sync_soon

Detailed Description

A class that defines the local server or a remote server. @@ -84,7 +87,7 @@ Constructor.

Definition at line 12 of file servers.cpp.

-References connection::fd, hops_away, jupiter, connection::lastping, opercount, pingtime, connection::signon, usercount, usercount_i, and version. +References connection::fd, hops_away, jupiter, connection::lastping, opercount, pingtime, connection::signon, sync_soon, usercount, usercount_i, and version.

00013 {
 00014         strcpy(name,"");
@@ -94,8 +97,9 @@ References connection::fd<
 00018         hops_away = 1;
 00019         signon = time(NULL);
 00020         jupiter = false;
-00021         fd = 0;
-00022 }
+00021         fd = 0;
+00022         sync_soon = false;
+00023 }
 
@@ -144,20 +148,21 @@ Constructor which initialises some of the main variables.

-Definition at line 29 of file servers.cpp. -

-References connection::fd, hops_away, jupiter, connection::lastping, opercount, connection::signon, usercount, usercount_i, and version. -

-

00030 {
-00031         strcpy(name,n);
-00032         lastping = time(NULL);
-00033         usercount_i = usercount = opercount = 0;
-00034         version = ver;
-00035         hops_away = 1;
-00036         signon = time(NULL);
-00037         jupiter = jupe;
-00038         fd = 0;
-00039 }
+Definition at line 30 of file servers.cpp.
+

+References connection::fd, hops_away, jupiter, connection::lastping, opercount, connection::signon, sync_soon, usercount, usercount_i, and version. +

+

00031 {
+00032         strcpy(name,n);
+00033         lastping = time(NULL);
+00034         usercount_i = usercount = opercount = 0;
+00035         version = ver;
+00036         hops_away = 1;
+00037         signon = time(NULL);
+00038         jupiter = jupe;
+00039         fd = 0;
+00040         sync_soon = false;
+00041 }
 
@@ -190,14 +195,40 @@ Destructor.

-Definition at line 25 of file servers.cpp. +Definition at line 26 of file servers.cpp.

-

00026 {
-00027 }
+
00027 {
+00028 }
 

Member Data Documentation

+

+ + + + +
+ + +
char serverrec::description[MAXBUF] +
+
+ + + + + +
+   + + +

+Description of the server. +

+ +

+Definition at line 50 of file servers.h.

@@ -336,6 +367,32 @@ Definition at line 28 of Referenced by serverrec().
+

+ + + + +
+ + +
bool serverrec::sync_soon +
+
+ + + + + +
+   + + +

+ +

+Definition at line 52 of file servers.h. +

+Referenced by serverrec().

@@ -422,7 +479,7 @@ Referenced by serverrec()
The documentation for this class was generated from the following files:
-
Generated on Thu Apr 8 19:13:19 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:55 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classserverrec__coll__graph.gif b/docs/module-doc/classserverrec__coll__graph.gif index e00af729c..1f5d00b4a 100644 Binary files a/docs/module-doc/classserverrec__coll__graph.gif and b/docs/module-doc/classserverrec__coll__graph.gif differ diff --git a/docs/module-doc/classucrec-members.html b/docs/module-doc/classucrec-members.html index cb1eeb7f2..02591bacc 100644 --- a/docs/module-doc/classucrec-members.html +++ b/docs/module-doc/classucrec-members.html @@ -14,7 +14,7 @@
-
ucrec()ucrec [inline]
~classbase()classbase [inline]
~ucrec()ucrec [inline, virtual]


Generated on Thu Apr 8 19:13:21 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:56 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classucrec.html b/docs/module-doc/classucrec.html index 2376f8459..f8d794497 100644 --- a/docs/module-doc/classucrec.html +++ b/docs/module-doc/classucrec.html @@ -157,12 +157,14 @@ Contains a bitmask of the UCMODE_OP ...

UCMODE_FOUNDER values. If this value is zero, the user has no privilages upon the channel.

-Definition at line 197 of file channels.h. +Definition at line 197 of file channels.h. +

+Referenced by userrec::userrec().


The documentation for this class was generated from the following file: -
Generated on Thu Apr 8 19:13:21 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:56 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classuserrec-members.html b/docs/module-doc/classuserrec-members.html index f4a75fb0e..3790c668a 100644 --- a/docs/module-doc/classuserrec-members.html +++ b/docs/module-doc/classuserrec-members.html @@ -7,55 +7,58 @@
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

userrec Member List

This is the complete list of members for userrec, including all inherited members. + - - - - + + + - - + + + - + + + - + - - + + - + + - + - + - - - + + + - - - + - + + -
AddIncoming(int fd, char *targethost, int sourceport)connection
ageclassbase
awaymsguserrec
BeginLink(char *targethost, int port, char *password)connection
bytes_inconnection
bytes_outconnection
carryoveruserrec
BeginLink(char *targethost, int port, char *password, char *servername, int myport)connection
bytes_inconnection
bytes_outconnection
chansuserrec
classbase()classbase [inline]
cmds_inconnection
cmds_outconnection
cmds_inconnection
cmds_outconnection
connection()connection
connectorsconnection
CreateListener(char *host, int p)connection
dhostuserrec
fdconnection
fdconnection
FindHost(std::string host)connection
flooduserrec
fullnameuserrec
GenKey()connection
GenKey()connection
GetFullHost()userrec [virtual]
GetFullRealHost()userrec [virtual]
haspassedconnection
hostconnection
haspassedconnection
hostconnection
identuserrec
idle_lastmsgconnection
inbufconnection
inbufconnection
internal_addrconnection
internal_portconnection
invitesuserrec [private]
InviteTo(char *channel)userrec [virtual]
ipconnection
ipconnection
IsInvited(char *channel)userrec [virtual]
keyconnection
lastpingconnection
MeshCookie(char *targethost, int port, long cookie, char *servername)connection
modesuserrec
nickuserrec
npingconnection
portconnection
RecvPacket(char *message, char *host, int &prt, long &theirkey)connection
registeredconnection
portconnection
RecvPacket(std::deque< std::string > &messages, char *host)connection
registeredconnection
RemoveInvite(char *channel)userrec [virtual]
resultuserrec
SendACK(char *host, int port, int reply_id)connection
SendPacket(char *message, char *host, int port, long ourkey)connection
SendSYN(char *host, int port)connection
SendPacket(char *message, const char *host)connection
serveruserrec
signonconnection
TerminateLink(char *targethost)connection
stateconnection
TerminateLink(char *targethost)connection
timeoutuserrec
userrec()userrec
~classbase()classbase [inline]
~userrec()userrec [inline, virtual]

Generated on Thu Apr 8 19:13:23 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:56 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classuserrec.html b/docs/module-doc/classuserrec.html index 5270e6a4e..f85539459 100644 --- a/docs/module-doc/classuserrec.html +++ b/docs/module-doc/classuserrec.html @@ -18,8 +18,8 @@ Inheritance diagram for userrec:

[legend]
Collaboration diagram for userrec:

Collaboration graph
- - + +
[legend]
List of all members. @@ -54,8 +54,10 @@ Inheritance diagram for userrec:



- + + + @@ -67,7 +69,7 @@ Everything about a connection is stored here primarily, from the user's socket I

-Definition at line 66 of file users.h.


Constructor & Destructor Documentation

+Definition at line 78 of file users.h.

Constructor & Destructor Documentation

char result [256]
 Stores the result of the last GetFullHost or GetRealHost call.

char carryover [MAXBUF]
int flood
 Number of lines the user can place into the buffer (up to the global NetBufferSize bytes) before they are disconnected for excess flood.

unsigned long timeout
 Number of seconds this user is given to send USER/NICK If they do not send their details in this time limit they will be disconnected.


Private Attributes

InvitedList invites
 A list of channels the user has a pending invite to.

@@ -97,12 +99,12 @@ Definition at line 66 of fi

Definition at line 11 of file users.cpp.

-References connection::bytes_in, connection::bytes_out, ucrec::channel, chans, connection::cmds_in, connection::cmds_out, connection::fd, connection::haspassed, connection::idle_lastmsg, invites, connection::ip, connection::lastping, connection::nping, connection::port, connection::registered, connection::signon, and timeout. +References connection::bytes_in, connection::bytes_out, ucrec::channel, chans, connection::cmds_in, connection::cmds_out, connection::fd, flood, connection::haspassed, connection::idle_lastmsg, invites, connection::ip, connection::lastping, connection::nping, connection::port, connection::registered, connection::signon, timeout, and ucrec::uc_modes.

00012 {
 00013         // the PROPER way to do it, AVOID bzero at *ALL* costs
 00014         strcpy(nick,"");
-00015         ip = 0;
+00015         ip = 0;
 00016         timeout = 0;
 00017         strcpy(ident,"");
 00018         strcpy(host,"");
@@ -112,16 +114,17 @@ References connection::byt
 00022         strcpy(inbuf,"");
 00023         strcpy(server,"");
 00024         strcpy(awaymsg,"");
-00025         fd = lastping = signon = idle_lastmsg = nping = registered = 0;
-00026         port = bytes_in = bytes_out = cmds_in = cmds_out = 0;
-00027         haspassed = false;
+00025         fd = lastping = signon = idle_lastmsg = nping = registered = 0;
+00026         flood = port = bytes_in = bytes_out = cmds_in = cmds_out = 0;
+00027         haspassed = false;
 00028         strcpy(result,"");
 00029         for (int i = 0; i < MAXCHANS; i++)
 00030         {
-00031                 chans[i].channel = NULL;
-00032         }
-00033         invites.clear();
-00034 }
+00031                 this->chans[i].channel = NULL;
+00032                 this->chans[i].uc_modes = 0;
+00033         }
+00034         invites.clear();
+00035 }
 
@@ -152,9 +155,9 @@ References connection::byt

-Definition at line 122 of file users.h. +Definition at line 142 of file users.h.

-

00122 {  }
+
00142 {  }
 
@@ -188,14 +191,14 @@ Returns the full displayed host of the user This member function returns the hos

-Definition at line 38 of file users.cpp. +Definition at line 39 of file users.cpp.

-References result. +References result.

-

00039 {
-00040         sprintf(result,"%s!%s@%s",nick,ident,dhost);
-00041         return result;
-00042 }
+
00040 {
+00041         sprintf(result,"%s!%s@%s",nick,ident,dhost);
+00042         return result;
+00043 }
 
@@ -228,14 +231,14 @@ Returns the full real host of the user This member function returns the hostname

If any form of hostname cloaking is in operation, e.g. through a module, then this method will ignore it and return the true hostname.

-Definition at line 45 of file users.cpp. +Definition at line 46 of file users.cpp.

-References result. +References result.

-

00046 {
-00047         sprintf(result,"%s!%s@%s",nick,ident,host);
-00048         return result;
-00049 }
+
00047 {
+00048         sprintf(result,"%s!%s@%s",nick,ident,host);
+00049         return result;
+00050 }
 
@@ -269,15 +272,15 @@ Adds a channel to a users invite list (invites them to a channel).

-Definition at line 65 of file users.cpp. +Definition at line 66 of file users.cpp.

-References Invited::channel, and invites. +References Invited::channel, and invites.

-

00066 {
-00067         Invited i;
-00068         strcpy(i.channel,channel);
-00069         invites.push_back(i);
-00070 }
+
00067 {
+00068         Invited i;
+00069         strcpy(i.channel,channel);
+00070         invites.push_back(i);
+00071 }
 
@@ -311,22 +314,22 @@ Returns true if a user is invited to a channel.

-Definition at line 51 of file users.cpp. +Definition at line 52 of file users.cpp.

-References invites. +References invites.

-

00052 {
-00053         for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++)
-00054         {
-00055                 if (i->channel) {
-00056                         if (!strcasecmp(i->channel,channel))
-00057                         {
-00058                                 return true;
-00059                         }
-00060                 }
-00061         }
-00062         return false;
-00063 }
+
00053 {
+00054         for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++)
+00055         {
+00056                 if (i->channel) {
+00057                         if (!strcasecmp(i->channel,channel))
+00058                         {
+00059                                 return true;
+00060                         }
+00061                 }
+00062         }
+00063         return false;
+00064 }
 
@@ -360,26 +363,30 @@ Removes a channel from a users invite list.

This member function is called on successfully joining an invite only channel to which the user has previously been invited, to clear the invitation.

-Definition at line 72 of file users.cpp. -

-References invites. -

-

00073 {
-00074         log(DEBUG,"Removing invites");
-00075         if (invites.size())
-00076         {
-00077                 for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++)
-00078                 {
-00079                         if (i->channel) {
-00080                                 if (!strcasecmp(i->channel,channel))
-00081                                 {
-00082                                         invites.erase(i);
-00083                                         return;
-00084                                 }
-00085                         }
-00086                 }
-00087         }
-00088 }
+Definition at line 73 of file users.cpp.
+

+References invites. +

+

00074 {
+00075         log(DEBUG,"Removing invites");
+00076         if (channel)
+00077         {
+00078                 if (invites.size())
+00079                 {
+00080                         for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++)
+00081                         {
+00082                                 if (i->channel)
+00083                                 {
+00084                                         if (!strcasecmp(i->channel,channel))
+00085                                         {
+00086                                                 invites.erase(i);
+00087                                                 return;
+00088                                         }
+00089                                 }
+00090                         }
+00091                 }
+00092         }
+00093 }
 
@@ -407,16 +414,16 @@ The user's away message.

If this string is empty, the user is not marked as away.

-Definition at line 109 of file users.h. +Definition at line 121 of file users.h. -

+

@@ -431,16 +438,18 @@ Definition at line 109 of f

-Definition at line 116 of file users.h. +Definition at line 112 of file users.h. +

+Referenced by userrec().

-
char userrec::carryover[MAXBUF] + ucrec userrec::chans[MAXCHANS]
-

+

@@ -453,20 +462,20 @@ Definition at line 116 of f +Definition at line 100 of file users.h.
-
ucrec userrec::chans[MAXCHANS] + char userrec::dhost[256]

- +The host displayed to non-opers (used for cloaking etc).

-Definition at line 100 of file users.h. +This usually matches the value of userrec::host.

-Referenced by userrec().

-

+

@@ -479,11 +488,13 @@ Referenced by userrec(). +Referenced by userrec().
-
char userrec::dhost[256] + int userrec::flood

-The host displayed to non-opers (used for cloaking etc). +Number of lines the user can place into the buffer (up to the global NetBufferSize bytes) before they are disconnected for excess flood.

-This usually matches the value of userrec::host. + +

+Definition at line 132 of file users.h.

-Definition at line 88 of file users.h.

@@ -509,7 +520,7 @@ The users full name.

-Definition at line 92 of file users.h. +Definition at line 104 of file users.h.

@@ -535,7 +546,7 @@ The users ident reply.

-Definition at line 83 of file users.h. +Definition at line 95 of file users.h.

@@ -561,9 +572,9 @@ A list of channels the user has a pending invite to.

-Definition at line 72 of file users.h. +Definition at line 84 of file users.h.

-Referenced by InviteTo(), IsInvited(), RemoveInvite(), and userrec(). +Referenced by InviteTo(), IsInvited(), RemoveInvite(), and userrec().

@@ -589,7 +600,7 @@ The user's mode string.

This may contain any of the following RFC characters: o, w, s, i Your module may define other mode characters as it sees fit.

-Definition at line 98 of file users.h. +Definition at line 110 of file users.h.

@@ -615,7 +626,9 @@ The users nickname.

An invalid nickname indicates an unregistered connection prior to the NICK command.

-Definition at line 79 of file users.h. +Definition at line 91 of file users.h. +

+Referenced by Server::QuitUser().

@@ -641,9 +654,9 @@ Stores the result of the last GetFullHost or GetRealHost call.

You may use this to increase the speed of use of this class.

-Definition at line 114 of file users.h. +Definition at line 126 of file users.h.

-Referenced by GetFullHost(), and GetFullRealHost(). +Referenced by GetFullHost(), and GetFullRealHost().

@@ -669,7 +682,7 @@ The server the user is connected to.

-Definition at line 104 of file users.h. +Definition at line 116 of file users.h.

@@ -691,16 +704,18 @@ Definition at line 104 of f

+Number of seconds this user is given to send USER/NICK If they do not send their details in this time limit they will be disconnected. +

-Definition at line 118 of file users.h. +Definition at line 138 of file users.h.

Referenced by userrec().


The documentation for this class was generated from the following files: -
Generated on Thu Apr 8 19:13:23 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:56 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/classuserrec__coll__graph.gif b/docs/module-doc/classuserrec__coll__graph.gif index de3b9bb77..3c36e05ec 100644 Binary files a/docs/module-doc/classuserrec__coll__graph.gif and b/docs/module-doc/classuserrec__coll__graph.gif differ diff --git a/docs/module-doc/connection_8h-source.html b/docs/module-doc/connection_8h-source.html index 13f3b5169..d0c8b9ff6 100644 --- a/docs/module-doc/connection_8h-source.html +++ b/docs/module-doc/connection_8h-source.html @@ -21,65 +21,142 @@ 00013 #include <unistd.h> 00014 #include <errno.h> 00015 #include <time.h> -00016 -00017 #ifndef __CONNECTION_H__ -00018 #define __CONNECTION_H__ -00019 -00020 #define PT_SYN_ONLY 0 -00021 #define PT_ACK_ONLY 1 -00022 #define PT_SYN_WITH_DATA 2 -00023 #define PT_KEY_EXCHANGE 3 -00024 -00025 -00026 class packet : public classbase -00027 { -00028 public: -00029 long key; -00030 short int id; -00031 short int type; -00032 char data[MAXBUF]; -00033 -00034 packet(); -00035 ~packet(); -00036 }; -00037 -00038 -00039 class connection : public classbase -00040 { -00041 public: -00042 long key; -00043 int fd; // file descriptor -00044 char host[256]; // hostname -00045 long ip; // ipv4 address -00046 char inbuf[MAXBUF]; // recvQ -00047 long bytes_in; -00048 long bytes_out; -00049 long cmds_in; -00050 long cmds_out; -00051 bool haspassed; -00052 int port; -00053 int registered; -00054 time_t lastping; -00055 time_t signon; -00056 time_t idle_lastmsg; -00057 time_t nping; -00058 char internal_addr[1024]; -00059 -00060 connection(); -00061 bool CreateListener(char* host, int p); -00062 bool BeginLink(char* targethost, int port, char* password); -00063 void TerminateLink(char* targethost); -00064 bool SendPacket(char *message, char* host, int port, long ourkey); -00065 bool RecvPacket(char *message, char* host, int &prt, long &theirkey); -00066 bool SendSYN(char* host, int port); -00067 bool SendACK(char* host, int port, int reply_id); -00068 long GenKey(); -00069 }; -00070 -00071 -00072 #endif -00073 -

Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +00016 #include <vector> +00017 #include <deque> +00018 +00019 #ifndef __CONNECTION_H__ +00020 #define __CONNECTION_H__ +00021 +00022 #define STATE_DISCONNECTED 0 +00023 #define STATE_CONNECTED 1 +00024 #define STATE_SYNC 2 +00025 #define STATE_NOAUTH_INBOUND 3 +00026 #define STATE_NOAUTH_OUTBOUND 4 +00027 +00040 class ircd_connector : public classbase +00041 { +00042 private: +00045 sockaddr_in addr; +00046 +00049 int fd; +00050 +00053 std::string servername; +00054 +00057 std::string description; +00058 +00062 int state; +00063 +00066 bool SetHostAddress(char* host, int port); +00067 +00068 public: +00069 +00074 char host[MAXBUF]; +00075 +00080 int port; +00081 +00086 std::vector<std::string> routes; +00087 +00088 +00091 bool MakeOutboundConnection(char* host, int port); +00092 +00095 std::string GetServerName(); +00096 +00099 void SetServerName(std::string serv); +00100 +00103 int GetDescriptor(); +00104 +00107 void SetDescriptor(int fd); +00108 +00111 int GetState(); +00112 +00115 void SetState(int state); +00116 +00119 char* GetServerIP(); +00120 +00123 std::string GetDescription(); +00124 +00127 void SetDescription(std::string desc); +00128 +00134 int GetServerPort(); +00135 +00138 void SetServerPort(int p); +00139 +00142 bool SetHostAndPort(char* host, int port); +00143 +00147 void CloseConnection(); +00148 }; +00149 +00150 +00151 class packet +00152 { +00156 }; +00157 +00160 class connection : public classbase +00161 { +00162 public: +00165 int fd; +00166 +00169 char host[256]; +00170 +00173 long ip; +00174 +00177 char inbuf[MAXBUF]; +00178 +00181 long bytes_in; +00182 +00185 long bytes_out; +00186 +00189 long cmds_in; +00190 +00193 long cmds_out; +00194 +00197 bool haspassed; +00198 +00203 int port; +00204 +00207 int registered; +00208 +00211 short int state; +00212 +00215 time_t lastping; +00216 +00219 time_t signon; +00220 +00223 time_t idle_lastmsg; +00224 +00227 time_t nping; +00228 +00231 char internal_addr[1024]; +00232 +00235 int internal_port; +00236 +00240 std::vector<ircd_connector> connectors; +00241 +00244 connection(); +00245 +00248 bool CreateListener(char* host, int p); +00249 +00252 bool BeginLink(char* targethost, int port, char* password, char* servername, int myport); +00253 +00256 bool MeshCookie(char* targethost, int port, long cookie, char* servername); +00257 +00260 void TerminateLink(char* targethost); +00261 +00265 bool SendPacket(char *message, const char* host); +00266 +00271 bool RecvPacket(std::deque<std::string> &messages, char* host); +00272 +00275 ircd_connector* FindHost(std::string host); +00276 +00280 bool AddIncoming(int fd,char* targethost, int sourceport); +00281 +00284 long GenKey(); +00285 }; +00286 +00287 +00288 #endif +00289 +

Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/connection_8h.html b/docs/module-doc/connection_8h.html index c476a99b5..e15b987c6 100644 --- a/docs/module-doc/connection_8h.html +++ b/docs/module-doc/connection_8h.html @@ -17,6 +17,8 @@ #include <unistd.h>
#include <errno.h>
#include <time.h>
+#include <vector>
+#include <deque>

Include dependency graph for connection.h:

Include dependency graph
@@ -38,21 +40,25 @@ This graph shows which files directly or indirectly include this file:


Compounds

class  connectionPlease note: classes serverrec and userrec both inherit from class connection. More...

+class  ircd_connectorEach connection has one or more of these each represents ONE outbound connection to another ircd so each inbound has multiple outbounds. More...

class  packet

Defines

-#define PT_SYN_ONLY   0 -#define PT_ACK_ONLY   1 -#define PT_SYN_WITH_DATA   2 -#define PT_KEY_EXCHANGE   3 +#define STATE_DISCONNECTED   0 +#define STATE_CONNECTED   1 +#define STATE_SYNC   2 +#define STATE_NOAUTH_INBOUND   3 +#define STATE_NOAUTH_OUTBOUND   4

Define Documentation

-

+

@@ -67,16 +73,16 @@ This graph shows which files directly or indirectly include this file:

-Definition at line 21 of file connection.h. +Definition at line 23 of file connection.h.

-
#define PT_ACK_ONLY   1 + #define STATE_CONNECTED   1
-

+

@@ -91,16 +97,16 @@ Definition at line 21

-Definition at line 23 of file connection.h. +Definition at line 22 of file connection.h.

-
#define PT_KEY_EXCHANGE   3 + #define STATE_DISCONNECTED   0
-

+

@@ -115,16 +121,16 @@ Definition at line 23

-Definition at line 20 of file connection.h. +Definition at line 25 of file connection.h.

-
#define PT_SYN_ONLY   0 + #define STATE_NOAUTH_INBOUND   3
-

+

@@ -139,10 +145,34 @@ Definition at line 20

-Definition at line 22 of file connection.h. +Definition at line 26 of file connection.h. + +

-
#define PT_SYN_WITH_DATA   2 + #define STATE_NOAUTH_OUTBOUND   4
+

+ + + + +
+ + +
#define STATE_SYNC   2 +
+
+ + + +
+   + + +

+ +

+Definition at line 24 of file connection.h.

-


Generated on Thu Apr 8 19:12:35 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:41 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/connection_8h__incl.gif b/docs/module-doc/connection_8h__incl.gif index b297abff2..04859471c 100644 Binary files a/docs/module-doc/connection_8h__incl.gif and b/docs/module-doc/connection_8h__incl.gif differ diff --git a/docs/module-doc/ctables_8h-source.html b/docs/module-doc/ctables_8h-source.html index b0fe3dd81..d3809fdce 100644 --- a/docs/module-doc/ctables_8h-source.html +++ b/docs/module-doc/ctables_8h-source.html @@ -43,7 +43,7 @@ 00049 00050 #endif 00051 -

Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +

Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/ctables_8h.html b/docs/module-doc/ctables_8h.html index c71511fb6..fa61df484 100644 --- a/docs/module-doc/ctables_8h.html +++ b/docs/module-doc/ctables_8h.html @@ -57,7 +57,7 @@ This graph shows which files directly or indirectly include this file:

23 of file ctables.h. -
Generated on Thu Apr 8 19:12:36 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:41 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/files.html b/docs/module-doc/files.html index aa5bf9c38..beee50cba 100644 --- a/docs/module-doc/files.html +++ b/docs/module-doc/files.html @@ -19,7 +19,7 @@ users.cpp [code] users.h [code] -
Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +
Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
diff --git a/docs/module-doc/functions.html b/docs/module-doc/functions.html index 578a1298c..620e6e5df 100644 --- a/docs/module-doc/functions.html +++ b/docs/module-doc/functions.html @@ -14,7 +14,9 @@ Here is a list of all class members with links to the classes they belong to:

@@ -24,27 +26,31 @@ Here is a list of all class members with links to the classes they belong to:

chanrec
  • BeginLink() : connection
  • Build : Version
  • bytes_in -: connection
  • bytes_out -: connection +: connection
  • bytes_out +: connection

    - c -

    - q -

    - s -

    +: chanrec
  • SetDescription() +: ircd_connector
  • SetDescriptor() +: ircd_connector
  • SetHostAddress() +: ircd_connector
  • SetHostAndPort() +: ircd_connector
  • SetServerName() +: ircd_connector
  • SetServerPort() +: ircd_connector
  • SetState() +: ircd_connector
  • signon +: connection
  • state +: connection, ircd_connector
  • sync_soon +: serverrec

    - t -

    +: ConnectClass, ExtMode

    - u -

    - ~ -

    -
    Generated on Thu Apr 8 19:12:45 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:44 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/globals.html b/docs/module-doc/globals.html index f8c37422c..194bbd162 100644 --- a/docs/module-doc/globals.html +++ b/docs/module-doc/globals.html @@ -7,7 +7,7 @@
    Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

    InspIRCd File Members

    -b | c | d | e | f | h | i | l | m | n | p | s | u | v
    +b | c | d | e | f | h | i | l | m | n | s | u | v
  • Here is a list of all file members with links to the files they belong to:

    - b - @@ -73,18 +73,16 @@ Here is a list of all file members with links to the files they belong to:

    -

    - p - -

    - s -

    • server_mode() : modules.h
    • SPARSE -: modules.h
    • STATUS_HOP +: modules.h
    • STATE_CONNECTED +: connection.h
    • STATE_DISCONNECTED +: connection.h
    • STATE_NOAUTH_INBOUND +: connection.h
    • STATE_NOAUTH_OUTBOUND +: connection.h
    • STATE_SYNC +: connection.h
    • STATUS_HOP : users.h
    • STATUS_NORMAL : users.h
    • STATUS_OP : users.h
    • STATUS_VOICE @@ -102,7 +100,7 @@ Here is a list of all file members with links to the files they belong to:

      -
      Generated on Thu Apr 8 19:13:25 2004 for InspIRCd by +
      Generated on Sat Apr 17 13:31:57 2004 for InspIRCd by doxygen1.3-rc3
      diff --git a/docs/module-doc/graph_legend.html b/docs/module-doc/graph_legend.html index ca986b29f..4a0af6498 100644 --- a/docs/module-doc/graph_legend.html +++ b/docs/module-doc/graph_legend.html @@ -69,7 +69,7 @@ A purple dashed arrow is used if a class is contained or used by another class.
    • A yellow dashed arrow denotes a relation between a template instance and the template class it was instantiated from. The arrow is labeled with the template parameters of the instance.
    -
    Generated on Thu Apr 8 19:13:25 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:57 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/hierarchy.html b/docs/module-doc/hierarchy.html index e83db36f0..3b4de127e 100644 --- a/docs/module-doc/hierarchy.html +++ b/docs/module-doc/hierarchy.html @@ -29,17 +29,18 @@ This inheritance list is sorted roughly, but not completely, alphabetically:
  • Invited +
  • ircd_connector
  • ModeParameter
  • Module
  • ModuleFactory -
  • packet
  • Server
  • ucrec
  • Version
  • ExtMode +
  • packet -
    Generated on Thu Apr 8 19:12:45 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:44 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/inherit__graph__0.gif b/docs/module-doc/inherit__graph__0.gif index e6ee4dda3..8c092afca 100644 Binary files a/docs/module-doc/inherit__graph__0.gif and b/docs/module-doc/inherit__graph__0.gif differ diff --git a/docs/module-doc/inherit__graph__2.gif b/docs/module-doc/inherit__graph__2.gif new file mode 100644 index 000000000..fbe411c4d Binary files /dev/null and b/docs/module-doc/inherit__graph__2.gif differ diff --git a/docs/module-doc/inherits.html b/docs/module-doc/inherits.html index 896ab60aa..dddb024b6 100644 --- a/docs/module-doc/inherits.html +++ b/docs/module-doc/inherits.html @@ -21,10 +21,10 @@ - - - - + + + + @@ -38,8 +38,12 @@ + + + + -
    Generated on Thu Apr 8 19:13:27 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:58 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/main.html b/docs/module-doc/main.html index d15246941..2267d9975 100644 --- a/docs/module-doc/main.html +++ b/docs/module-doc/main.html @@ -8,7 +8,7 @@ Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

  • InspIRCd Documentation

    -


    Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/modules_8cpp-source.html b/docs/module-doc/modules_8cpp-source.html index 8281865c1..9f8bf98d1 100644 --- a/docs/module-doc/modules_8cpp-source.html +++ b/docs/module-doc/modules_8cpp-source.html @@ -164,12 +164,12 @@ 00156 00157 chanrec* Server::JoinUserToChannel(userrec* user, std::string cname, std::string key) 00158 { -00159 return add_channel(user,cname.c_str(),key.c_str()); +00159 return add_channel(user,cname.c_str(),key.c_str(),true); 00160 } 00161 00162 chanrec* Server::PartUserFromChannel(userrec* user, std::string cname, std::string reason) 00163 { -00164 return del_channel(user,cname.c_str(),reason.c_str()); +00164 return del_channel(user,cname.c_str(),reason.c_str(),false); 00165 } 00166 00167 void Server::ChangeUserNick(userrec* user, std::string nickname) @@ -179,250 +179,265 @@ 00171 00172 void Server::QuitUser(userrec* user, std::string reason) 00173 { -00174 kill_link(user,reason.c_str()); -00175 } -00176 +00174 send_network_quit(user->nick,reason.c_str()); +00175 kill_link(user,reason.c_str()); +00176 } 00177 -00178 void Server::Log(int level, std::string s) +00178 void Server::CallCommandHandler(std::string commandname, char** parameters, int pcnt, userrec* user) 00179 { -00180 log(level,"%s",s.c_str()); +00180 call_handler(commandname.c_str(),parameters,pcnt,user); 00181 } 00182 -00183 void Server::AddCommand(char* cmd, handlerfunc f, char flags, int minparams) +00183 void Server::Log(int level, std::string s) 00184 { -00185 createcommand(cmd,f,flags,minparams); +00185 log(level,"%s",s.c_str()); 00186 } 00187 -00188 void Server::SendMode(char **parameters, int pcnt, userrec *user) +00188 void Server::AddCommand(char* cmd, handlerfunc f, char flags, int minparams) 00189 { -00190 server_mode(parameters,pcnt,user); +00190 createcommand(cmd,f,flags,minparams); 00191 } 00192 -00193 void Server::Send(int Socket, std::string s) +00193 void Server::SendMode(char **parameters, int pcnt, userrec *user) 00194 { -00195 Write(Socket,"%s",s.c_str()); +00195 server_mode(parameters,pcnt,user); 00196 } 00197 -00198 void Server::SendServ(int Socket, std::string s) +00198 void Server::Send(int Socket, std::string s) 00199 { -00200 WriteServ(Socket,"%s",s.c_str()); +00200 Write(Socket,"%s",s.c_str()); 00201 } 00202 -00203 void Server::SendFrom(int Socket, userrec* User, std::string s) +00203 void Server::SendServ(int Socket, std::string s) 00204 { -00205 WriteFrom(Socket,User,"%s",s.c_str()); +00205 WriteServ(Socket,"%s",s.c_str()); 00206 } 00207 -00208 void Server::SendTo(userrec* Source, userrec* Dest, std::string s) +00208 void Server::SendFrom(int Socket, userrec* User, std::string s) 00209 { -00210 if (!Source) -00211 { -00212 // if source is NULL, then the message originates from the local server -00213 Write(Dest->fd,":%s %s",this->GetServerName().c_str(),s.c_str()); -00214 } -00215 else +00210 WriteFrom(Socket,User,"%s",s.c_str()); +00211 } +00212 +00213 void Server::SendTo(userrec* Source, userrec* Dest, std::string s) +00214 { +00215 if (!Source) 00216 { -00217 // otherwise it comes from the user specified -00218 WriteTo(Source,Dest,"%s",s.c_str()); +00217 // if source is NULL, then the message originates from the local server +00218 Write(Dest->fd,":%s %s",this->GetServerName().c_str(),s.c_str()); 00219 } -00220 } -00221 -00222 void Server::SendChannel(userrec* User, chanrec* Channel, std::string s,bool IncludeSender) -00223 { -00224 if (IncludeSender) -00225 { -00226 WriteChannel(Channel,User,"%s",s.c_str()); -00227 } -00228 else -00229 { -00230 ChanExceptSender(Channel,User,"%s",s.c_str()); -00231 } -00232 } -00233 -00234 bool Server::CommonChannels(userrec* u1, userrec* u2) -00235 { -00236 return (common_channels(u1,u2) != 0); +00220 else +00221 { +00222 // otherwise it comes from the user specified +00223 WriteTo(Source,Dest,"%s",s.c_str()); +00224 } +00225 } +00226 +00227 void Server::SendChannel(userrec* User, chanrec* Channel, std::string s,bool IncludeSender) +00228 { +00229 if (IncludeSender) +00230 { +00231 WriteChannel(Channel,User,"%s",s.c_str()); +00232 } +00233 else +00234 { +00235 ChanExceptSender(Channel,User,"%s",s.c_str()); +00236 } 00237 } 00238 -00239 void Server::SendCommon(userrec* User, std::string text,bool IncludeSender) +00239 bool Server::CommonChannels(userrec* u1, userrec* u2) 00240 { -00241 if (IncludeSender) -00242 { -00243 WriteCommon(User,"%s",text.c_str()); -00244 } -00245 else -00246 { -00247 WriteCommonExcept(User,"%s",text.c_str()); -00248 } -00249 } -00250 -00251 void Server::SendWallops(userrec* User, std::string text) -00252 { -00253 WriteWallOps(User,"%s",text.c_str()); +00241 return (common_channels(u1,u2) != 0); +00242 } +00243 +00244 void Server::SendCommon(userrec* User, std::string text,bool IncludeSender) +00245 { +00246 if (IncludeSender) +00247 { +00248 WriteCommon(User,"%s",text.c_str()); +00249 } +00250 else +00251 { +00252 WriteCommonExcept(User,"%s",text.c_str()); +00253 } 00254 } 00255 -00256 bool Server::IsNick(std::string nick) +00256 void Server::SendWallops(userrec* User, std::string text) 00257 { -00258 return (isnick(nick.c_str()) != 0); +00258 WriteWallOps(User,false,"%s",text.c_str()); 00259 } 00260 -00261 userrec* Server::FindNick(std::string nick) +00261 void Server::ChangeHost(userrec* user, std::string host) 00262 { -00263 return Find(nick); +00263 ChangeDisplayedHost(user,host.c_str()); 00264 } 00265 -00266 chanrec* Server::FindChannel(std::string channel) +00266 void Server::ChangeGECOS(userrec* user, std::string gecos) 00267 { -00268 return FindChan(channel.c_str()); +00268 ChangeName(user,gecos.c_str()); 00269 } 00270 -00271 std::string Server::ChanMode(userrec* User, chanrec* Chan) +00271 bool Server::IsNick(std::string nick) 00272 { -00273 return cmode(User,Chan); +00273 return (isnick(nick.c_str()) != 0); 00274 } 00275 -00276 std::string Server::GetServerName() +00276 userrec* Server::FindNick(std::string nick) 00277 { -00278 return getservername(); +00278 return Find(nick); 00279 } 00280 -00281 std::string Server::GetNetworkName() +00281 chanrec* Server::FindChannel(std::string channel) 00282 { -00283 return getnetworkname(); +00283 return FindChan(channel.c_str()); 00284 } 00285 -00286 Admin Server::GetAdmin() +00286 std::string Server::ChanMode(userrec* User, chanrec* Chan) 00287 { -00288 return Admin(getadminname(),getadminemail(),getadminnick()); +00288 return cmode(User,Chan); 00289 } 00290 -00291 -00292 -00293 bool Server::AddExtendedMode(char modechar, int type, bool requires_oper, int params_when_on, int params_when_off) -00294 { -00295 if (type == MT_SERVER) -00296 { -00297 log(DEBUG,"*** API ERROR *** Modes of type MT_SERVER are reserved for future expansion"); -00298 return false; -00299 } -00300 if (((params_when_on>0) || (params_when_off>0)) && (type == MT_CLIENT)) -00301 { -00302 log(DEBUG,"*** API ERROR *** Parameters on MT_CLIENT modes are not supported"); -00303 return false; -00304 } -00305 if ((params_when_on>1) || (params_when_off>1)) -00306 { -00307 log(DEBUG,"*** API ERROR *** More than one parameter for an MT_CHANNEL mode is not yet supported"); -00308 return false; -00309 } -00310 return DoAddExtendedMode(modechar,type,requires_oper,params_when_on,params_when_off); -00311 } -00312 -00313 int Server::CountUsers(chanrec* c) -00314 { -00315 return usercount(c); -00316 } -00317 -00318 -00319 ConfigReader::ConfigReader() -00320 { -00321 this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out); -00322 this->error = LoadConf(CONFIG_FILE,this->cache); -00323 } -00324 -00325 -00326 ConfigReader::~ConfigReader() -00327 { -00328 if (this->cache) -00329 delete this->cache; -00330 } -00331 +00291 std::string Server::GetServerName() +00292 { +00293 return getservername(); +00294 } +00295 +00296 std::string Server::GetNetworkName() +00297 { +00298 return getnetworkname(); +00299 } +00300 +00301 Admin Server::GetAdmin() +00302 { +00303 return Admin(getadminname(),getadminemail(),getadminnick()); +00304 } +00305 +00306 +00307 +00308 bool Server::AddExtendedMode(char modechar, int type, bool requires_oper, int params_when_on, int params_when_off) +00309 { +00310 if (type == MT_SERVER) +00311 { +00312 log(DEBUG,"*** API ERROR *** Modes of type MT_SERVER are reserved for future expansion"); +00313 return false; +00314 } +00315 if (((params_when_on>0) || (params_when_off>0)) && (type == MT_CLIENT)) +00316 { +00317 log(DEBUG,"*** API ERROR *** Parameters on MT_CLIENT modes are not supported"); +00318 return false; +00319 } +00320 if ((params_when_on>1) || (params_when_off>1)) +00321 { +00322 log(DEBUG,"*** API ERROR *** More than one parameter for an MT_CHANNEL mode is not yet supported"); +00323 return false; +00324 } +00325 return DoAddExtendedMode(modechar,type,requires_oper,params_when_on,params_when_off); +00326 } +00327 +00328 int Server::CountUsers(chanrec* c) +00329 { +00330 return usercount(c); +00331 } 00332 -00333 ConfigReader::ConfigReader(std::string filename) -00334 { -00335 this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out); -00336 this->error = LoadConf(filename.c_str(),this->cache); -00337 }; -00338 -00339 std::string ConfigReader::ReadValue(std::string tag, std::string name, int index) -00340 { -00341 char val[MAXBUF]; -00342 ReadConf(cache,tag.c_str(),name.c_str(),index,val); -00343 return val; -00344 } -00345 +00333 +00334 ConfigReader::ConfigReader() +00335 { +00336 this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out); +00337 this->error = LoadConf(CONFIG_FILE,this->cache); +00338 } +00339 +00340 +00341 ConfigReader::~ConfigReader() +00342 { +00343 if (this->cache) +00344 delete this->cache; +00345 } 00346 -00347 int ConfigReader::Enumerate(std::string tag) -00348 { -00349 return EnumConf(cache,tag.c_str()); -00350 } -00351 -00352 int ConfigReader::EnumerateValues(std::string tag, int index) -00353 { -00354 return EnumValues(cache, tag.c_str(), index); -00355 } -00356 -00357 bool ConfigReader::Verify() -00358 { -00359 return this->error; -00360 } +00347 +00348 ConfigReader::ConfigReader(std::string filename) +00349 { +00350 this->cache = new std::stringstream(std::stringstream::in | std::stringstream::out); +00351 this->error = LoadConf(filename.c_str(),this->cache); +00352 }; +00353 +00354 std::string ConfigReader::ReadValue(std::string tag, std::string name, int index) +00355 { +00356 char val[MAXBUF]; +00357 ReadConf(cache,tag.c_str(),name.c_str(),index,val); +00358 return val; +00359 } +00360 00361 -00362 -00363 FileReader::FileReader(std::string filename) -00364 { -00365 file_cache c; -00366 readfile(c,filename.c_str()); -00367 this->fc = c; -00368 } -00369 -00370 FileReader::FileReader() -00371 { -00372 } -00373 -00374 void FileReader::LoadFile(std::string filename) -00375 { -00376 file_cache c; -00377 readfile(c,filename.c_str()); -00378 this->fc = c; -00379 } -00380 -00381 -00382 FileReader::~FileReader() -00383 { -00384 } -00385 -00386 bool FileReader::Exists() -00387 { -00388 if (fc.size() == 0) -00389 { -00390 return(false); -00391 } -00392 else -00393 { -00394 return(true); -00395 } -00396 } -00397 -00398 std::string FileReader::GetLine(int x) -00399 { -00400 if ((x<0) || (x>fc.size())) -00401 return ""; -00402 return fc[x]; -00403 } -00404 -00405 int FileReader::FileSize() -00406 { -00407 return fc.size(); -00408 } -00409 -00410 -00411 std::vector<Module*> modules(255); -00412 std::vector<ircd_module*> factory(255); -00413 -00414 int MODCOUNT = -1; -00415 -00416 -

    Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +00362 int ConfigReader::Enumerate(std::string tag) +00363 { +00364 return EnumConf(cache,tag.c_str()); +00365 } +00366 +00367 int ConfigReader::EnumerateValues(std::string tag, int index) +00368 { +00369 return EnumValues(cache, tag.c_str(), index); +00370 } +00371 +00372 bool ConfigReader::Verify() +00373 { +00374 return this->error; +00375 } +00376 +00377 +00378 FileReader::FileReader(std::string filename) +00379 { +00380 file_cache c; +00381 readfile(c,filename.c_str()); +00382 this->fc = c; +00383 } +00384 +00385 FileReader::FileReader() +00386 { +00387 } +00388 +00389 void FileReader::LoadFile(std::string filename) +00390 { +00391 file_cache c; +00392 readfile(c,filename.c_str()); +00393 this->fc = c; +00394 } +00395 +00396 +00397 FileReader::~FileReader() +00398 { +00399 } +00400 +00401 bool FileReader::Exists() +00402 { +00403 if (fc.size() == 0) +00404 { +00405 return(false); +00406 } +00407 else +00408 { +00409 return(true); +00410 } +00411 } +00412 +00413 std::string FileReader::GetLine(int x) +00414 { +00415 if ((x<0) || (x>fc.size())) +00416 return ""; +00417 return fc[x]; +00418 } +00419 +00420 int FileReader::FileSize() +00421 { +00422 return fc.size(); +00423 } +00424 +00425 +00426 std::vector<Module*> modules(255); +00427 std::vector<ircd_module*> factory(255); +00428 +00429 int MODCOUNT = -1; +00430 +00431 +

    Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/modules_8cpp.html b/docs/module-doc/modules_8cpp.html index d45304586..efefb31cc 100644 --- a/docs/module-doc/modules_8cpp.html +++ b/docs/module-doc/modules_8cpp.html @@ -153,7 +153,7 @@ Definition at line 90 o

    References EMode, and ModeDefined().

    -Referenced by Server::AddExtendedMode(). +Referenced by Server::AddExtendedMode().

    00091 {
     00092         if (ModeDefined(modechar,type)) {
    @@ -493,10 +493,10 @@ Referenced by DoAddExtended
     

    -Definition at line 414 of file modules.cpp. +Definition at line 429 of file modules.cpp. -


    Generated on Thu Apr 8 19:12:38 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:41 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/modules_8h-source.html b/docs/module-doc/modules_8h-source.html index 7b6666e5c..32ecb0af4 100644 --- a/docs/module-doc/modules_8h-source.html +++ b/docs/module-doc/modules_8h-source.html @@ -36,189 +36,196 @@ 00030 typedef std::deque<std::string> file_cache; 00031 typedef file_cache string_list; 00032 -00033 // This #define allows us to call a method in all -00034 // loaded modules in a readable simple way, e.g.: -00035 // 'FOREACH_MOD OnConnect(user);' -00036 -00037 #define FOREACH_MOD for (int i = 0; i <= MODCOUNT; i++) modules[i]-> -00038 -00039 // This define is similar to the one above but returns a result in MOD_RESULT. -00040 // The first module to return a nonzero result is the value to be accepted, -00041 // and any modules after are ignored. -00042 -00043 // ********************************************************************************************* -00044 -00045 #define FOREACH_RESULT(x) { MOD_RESULT = 0; \ -00046 for (int i = 0; i <= MODCOUNT; i++) { \ -00047 int res = modules[i]->x ; \ -00048 if (res) { \ -00049 MOD_RESULT = res; \ -00050 break; \ -00051 } \ -00052 } \ -00053 } -00054 -00055 // ********************************************************************************************* -00056 -00057 extern void createcommand(char* cmd, handlerfunc f, char flags, int minparams); -00058 extern void server_mode(char **parameters, int pcnt, userrec *user); -00059 -00060 // class Version holds the version information of a Module, returned -00061 // by Module::GetVersion (thanks RD) -00062 -00067 class Version : public classbase -00068 { -00069 public: -00070 const int Major, Minor, Revision, Build; -00071 Version(int major, int minor, int revision, int build); -00072 }; -00073 -00079 class Admin : public classbase -00080 { -00081 public: -00082 const std::string Name, Email, Nick; -00083 Admin(std::string name, std::string email, std::string nick); -00084 }; -00085 -00091 class Module : public classbase -00092 { -00093 public: -00094 -00098 Module(); -00099 -00103 virtual ~Module(); -00104 -00109 virtual Version GetVersion(); -00110 -00114 virtual void OnUserConnect(userrec* user); -00115 -00119 virtual void OnUserQuit(userrec* user); -00120 -00125 virtual void OnUserJoin(userrec* user, chanrec* channel); -00126 -00131 virtual void OnUserPart(userrec* user, chanrec* channel); -00132 -00139 virtual void OnPacketTransmit(char *p); -00140 -00148 virtual void OnPacketReceive(char *p); -00149 -00155 virtual void OnRehash(); -00156 -00163 virtual void OnServerRaw(std::string &raw, bool inbound); -00164 -00174 virtual bool OnExtendedMode(userrec* user, void* target, char modechar, int type, bool mode_on, string_list &params); -00175 -00188 virtual int OnUserPreJoin(userrec* user, chanrec* chan, const char* cname); -00189 +00033 +00034 // This #define allows us to call a method in all +00035 // loaded modules in a readable simple way, e.g.: +00036 // 'FOREACH_MOD OnConnect(user);' +00037 +00038 #define FOREACH_MOD for (int i = 0; i <= MODCOUNT; i++) modules[i]-> +00039 +00040 // This define is similar to the one above but returns a result in MOD_RESULT. +00041 // The first module to return a nonzero result is the value to be accepted, +00042 // and any modules after are ignored. +00043 +00044 // ********************************************************************************************* +00045 +00046 #define FOREACH_RESULT(x) { MOD_RESULT = 0; \ +00047 for (int i = 0; i <= MODCOUNT; i++) { \ +00048 int res = modules[i]->x ; \ +00049 if (res) { \ +00050 MOD_RESULT = res; \ +00051 break; \ +00052 } \ +00053 } \ +00054 } +00055 +00056 // ********************************************************************************************* +00057 +00058 extern void createcommand(char* cmd, handlerfunc f, char flags, int minparams); +00059 extern void server_mode(char **parameters, int pcnt, userrec *user); +00060 +00061 // class Version holds the version information of a Module, returned +00062 // by Module::GetVersion (thanks RD) +00063 +00068 class Version : public classbase +00069 { +00070 public: +00071 const int Major, Minor, Revision, Build; +00072 Version(int major, int minor, int revision, int build); +00073 }; +00074 +00080 class Admin : public classbase +00081 { +00082 public: +00083 const std::string Name, Email, Nick; +00084 Admin(std::string name, std::string email, std::string nick); +00085 }; +00086 +00092 class Module : public classbase +00093 { +00094 public: +00095 +00099 Module(); +00100 +00104 virtual ~Module(); +00105 +00110 virtual Version GetVersion(); +00111 +00115 virtual void OnUserConnect(userrec* user); +00116 +00120 virtual void OnUserQuit(userrec* user); +00121 +00126 virtual void OnUserJoin(userrec* user, chanrec* channel); +00127 +00132 virtual void OnUserPart(userrec* user, chanrec* channel); +00133 +00140 virtual void OnPacketTransmit(char *p); +00141 +00149 virtual void OnPacketReceive(char *p); +00150 +00156 virtual void OnRehash(); +00157 +00164 virtual void OnServerRaw(std::string &raw, bool inbound); +00165 +00175 virtual bool OnExtendedMode(userrec* user, void* target, char modechar, int type, bool mode_on, string_list &params); +00176 +00189 virtual int OnUserPreJoin(userrec* user, chanrec* chan, const char* cname); 00190 -00195 virtual void OnOper(userrec* user); -00196 -00205 virtual void OnInfo(userrec* user); -00206 -00211 virtual void OnWhois(userrec* source, userrec* dest); -00212 -00221 virtual int OnUserPreMessage(userrec* user,void* dest,int target_type, std::string text); -00222 -00231 virtual int OnUserPreNotice(userrec* user,void* dest,int target_type, std::string text); -00232 }; -00233 +00191 +00196 virtual void OnOper(userrec* user); +00197 +00206 virtual void OnInfo(userrec* user); +00207 +00212 virtual void OnWhois(userrec* source, userrec* dest); +00213 +00222 virtual int OnUserPreMessage(userrec* user,void* dest,int target_type, std::string text); +00223 +00232 virtual int OnUserPreNotice(userrec* user,void* dest,int target_type, std::string text); +00233 }; 00234 -00240 class Server : public classbase -00241 { -00242 public: -00246 Server(); -00250 virtual ~Server(); -00251 -00255 virtual void SendOpers(std::string s); -00260 virtual void Log(int level, std::string s); -00265 virtual void Send(int Socket, std::string s); -00270 virtual void SendServ(int Socket, std::string s); -00275 virtual void SendFrom(int Socket, userrec* User, std::string s); -00290 virtual void SendTo(userrec* Source, userrec* Dest, std::string s); -00297 virtual void SendChannel(userrec* User, chanrec* Channel, std::string s,bool IncludeSender); -00302 virtual bool CommonChannels(userrec* u1, userrec* u2); -00310 virtual void SendCommon(userrec* User, std::string text,bool IncludeSender); -00315 virtual void SendWallops(userrec* User, std::string text); -00316 -00320 virtual bool IsNick(std::string nick); -00324 virtual int CountUsers(chanrec* c); -00328 virtual userrec* FindNick(std::string nick); -00332 virtual chanrec* FindChannel(std::string channel); -00337 virtual std::string ChanMode(userrec* User, chanrec* Chan); -00340 virtual std::string GetServerName(); -00343 virtual std::string GetNetworkName(); -00349 virtual Admin GetAdmin(); -00368 virtual bool AddExtendedMode(char modechar, int type, bool requires_oper, int params_when_on, int params_when_off); -00369 -00384 virtual void AddCommand(char* cmd, handlerfunc f, char flags, int minparams); -00385 -00407 virtual void SendMode(char **parameters, int pcnt, userrec *user); -00408 -00421 virtual void SendToModeMask(std::string modes, int flags, std::string text); -00422 -00428 virtual chanrec* JoinUserToChannel(userrec* user, std::string cname, std::string key); -00429 -00435 virtual chanrec* PartUserFromChannel(userrec* user, std::string cname, std::string reason); -00436 -00442 virtual void ChangeUserNick(userrec* user, std::string nickname); -00443 -00454 virtual void QuitUser(userrec* user, std::string reason); -00455 -00460 virtual bool MatchText(std::string sliteral, std::string spattern); -00461 }; -00462 -00469 class ConfigReader : public classbase -00470 { -00471 protected: -00477 std::stringstream *cache; -00480 bool error; -00481 -00482 public: -00487 ConfigReader(); // default constructor reads ircd.conf -00491 ConfigReader(std::string filename); // read a module-specific config -00495 ~ConfigReader(); -00500 std::string ReadValue(std::string tag, std::string name, int index); -00507 int Enumerate(std::string tag); -00512 bool Verify(); -00513 -00519 int EnumerateValues(std::string tag, int index); -00520 }; -00521 -00522 -00523 -00529 class FileReader : public classbase -00530 { -00531 file_cache fc; -00532 public: -00537 FileReader(); -00538 -00544 FileReader(std::string filename); -00545 -00549 ~FileReader(); +00235 +00241 class Server : public classbase +00242 { +00243 public: +00247 Server(); +00251 virtual ~Server(); +00252 +00256 virtual void SendOpers(std::string s); +00261 virtual void Log(int level, std::string s); +00266 virtual void Send(int Socket, std::string s); +00271 virtual void SendServ(int Socket, std::string s); +00276 virtual void SendFrom(int Socket, userrec* User, std::string s); +00291 virtual void SendTo(userrec* Source, userrec* Dest, std::string s); +00298 virtual void SendChannel(userrec* User, chanrec* Channel, std::string s,bool IncludeSender); +00303 virtual bool CommonChannels(userrec* u1, userrec* u2); +00311 virtual void SendCommon(userrec* User, std::string text,bool IncludeSender); +00316 virtual void SendWallops(userrec* User, std::string text); +00317 +00321 virtual bool IsNick(std::string nick); +00325 virtual int CountUsers(chanrec* c); +00329 virtual userrec* FindNick(std::string nick); +00333 virtual chanrec* FindChannel(std::string channel); +00338 virtual std::string ChanMode(userrec* User, chanrec* Chan); +00341 virtual std::string GetServerName(); +00344 virtual std::string GetNetworkName(); +00350 virtual Admin GetAdmin(); +00369 virtual bool AddExtendedMode(char modechar, int type, bool requires_oper, int params_when_on, int params_when_off); +00370 +00385 virtual void AddCommand(char* cmd, handlerfunc f, char flags, int minparams); +00386 +00408 virtual void SendMode(char **parameters, int pcnt, userrec *user); +00409 +00422 virtual void SendToModeMask(std::string modes, int flags, std::string text); +00423 +00429 virtual chanrec* JoinUserToChannel(userrec* user, std::string cname, std::string key); +00430 +00436 virtual chanrec* PartUserFromChannel(userrec* user, std::string cname, std::string reason); +00437 +00443 virtual void ChangeUserNick(userrec* user, std::string nickname); +00444 +00455 virtual void QuitUser(userrec* user, std::string reason); +00456 +00461 virtual bool MatchText(std::string sliteral, std::string spattern); +00462 +00474 virtual void CallCommandHandler(std::string commandname, char** parameters, int pcnt, userrec* user); +00475 +00481 virtual void ChangeHost(userrec* user, std::string host); +00482 +00488 virtual void ChangeGECOS(userrec* user, std::string gecos); +00489 }; +00490 +00497 class ConfigReader : public classbase +00498 { +00499 protected: +00505 std::stringstream *cache; +00508 bool error; +00509 +00510 public: +00515 ConfigReader(); // default constructor reads ircd.conf +00519 ConfigReader(std::string filename); // read a module-specific config +00523 ~ConfigReader(); +00528 std::string ReadValue(std::string tag, std::string name, int index); +00535 int Enumerate(std::string tag); +00540 bool Verify(); +00541 +00547 int EnumerateValues(std::string tag, int index); +00548 }; +00549 00550 -00556 void LoadFile(std::string filename); -00557 -00561 bool Exists(); -00562 -00567 std::string GetLine(int x); -00568 -00574 int FileSize(); -00575 }; -00576 -00577 -00584 class ModuleFactory : public classbase -00585 { -00586 public: -00587 ModuleFactory() { } -00588 virtual ~ModuleFactory() { } -00593 virtual Module * CreateModule() = 0; -00594 }; -00595 +00551 +00557 class FileReader : public classbase +00558 { +00559 file_cache fc; +00560 public: +00565 FileReader(); +00566 +00572 FileReader(std::string filename); +00573 +00577 ~FileReader(); +00578 +00584 void LoadFile(std::string filename); +00585 +00589 bool Exists(); +00590 +00595 std::string GetLine(int x); 00596 -00597 typedef DLLFactory<ModuleFactory> ircd_module; -00598 -00599 #endif -

    Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +00602 int FileSize(); +00603 }; +00604 +00605 +00612 class ModuleFactory : public classbase +00613 { +00614 public: +00615 ModuleFactory() { } +00616 virtual ~ModuleFactory() { } +00621 virtual Module * CreateModule() = 0; +00622 }; +00623 +00624 +00625 typedef DLLFactory<ModuleFactory> ircd_module; +00626 +00627 #endif +

    Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/modules_8h.html b/docs/module-doc/modules_8h.html index 905e2c000..163116633 100644 --- a/docs/module-doc/modules_8h.html +++ b/docs/module-doc/modules_8h.html @@ -134,7 +134,7 @@ Definition at line 13 of

    -Definition at line 37 of file modules.h. +Definition at line 38 of file modules.h.

    @@ -172,7 +172,7 @@ Definition at line 37 of }

    -Definition at line 45 of file modules.h. +Definition at line 46 of file modules.h.

    @@ -222,7 +222,7 @@ Definition at line 17 of

    Definition at line 18 of file modules.h.

    -Referenced by Server::AddExtendedMode(). +Referenced by Server::AddExtendedMode().

    @@ -248,7 +248,7 @@ Referenced by Server::AddEx

    Definition at line 19 of file modules.h.

    -Referenced by Server::AddExtendedMode(). +Referenced by Server::AddExtendedMode().

    @@ -349,7 +349,7 @@ Low level definition of a FileReader Definition at line 30 of file modules.h.

    -Referenced by FileReader::FileReader(), and FileReader::LoadFile(). +Referenced by FileReader::FileReader(), and FileReader::LoadFile().

    @@ -373,7 +373,7 @@ Referenced by FileReader::F

    -Definition at line 597 of file modules.h. +Definition at line 625 of file modules.h.

    @@ -450,7 +450,7 @@ Definition at line 31 of

    -Referenced by Server::AddCommand(). +Referenced by Server::AddCommand().

    @@ -496,10 +496,10 @@ Referenced by Server::AddCo

    -Referenced by Server::SendMode(). +Referenced by Server::SendMode(). -


    Generated on Thu Apr 8 19:12:39 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:42 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/namespaces.html b/docs/module-doc/namespaces.html index 6ab7ce4cc..7537f6f9a 100644 --- a/docs/module-doc/namespaces.html +++ b/docs/module-doc/namespaces.html @@ -9,7 +9,7 @@

    InspIRCd Namespace List

    Here is a list of all namespaces with brief descriptions:
    std
    -
    Generated on Thu Apr 8 19:13:25 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:57 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/namespacestd.html b/docs/module-doc/namespacestd.html index f75cb72d4..44561f09e 100644 --- a/docs/module-doc/namespacestd.html +++ b/docs/module-doc/namespacestd.html @@ -11,7 +11,7 @@
    -
    Generated on Thu Apr 8 19:13:25 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:57 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/servers_8cpp-source.html b/docs/module-doc/servers_8cpp-source.html index 760fa2b8d..5317f8a95 100644 --- a/docs/module-doc/servers_8cpp-source.html +++ b/docs/module-doc/servers_8cpp-source.html @@ -26,27 +26,29 @@ 00018 hops_away = 1; 00019 signon = time(NULL); 00020 jupiter = false; -00021 fd = 0; -00022 } -00023 -00024 -00025 serverrec::~serverrec() -00026 { -00027 } -00028 -00029 serverrec::serverrec(char* n, long ver, bool jupe) -00030 { -00031 strcpy(name,n); -00032 lastping = time(NULL); -00033 usercount_i = usercount = opercount = 0; -00034 version = ver; -00035 hops_away = 1; -00036 signon = time(NULL); -00037 jupiter = jupe; -00038 fd = 0; -00039 } -00040 -

    Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +00021 fd = 0; +00022 sync_soon = false; +00023 } +00024 +00025 +00026 serverrec::~serverrec() +00027 { +00028 } +00029 +00030 serverrec::serverrec(char* n, long ver, bool jupe) +00031 { +00032 strcpy(name,n); +00033 lastping = time(NULL); +00034 usercount_i = usercount = opercount = 0; +00035 version = ver; +00036 hops_away = 1; +00037 signon = time(NULL); +00038 jupiter = jupe; +00039 fd = 0; +00040 sync_soon = false; +00041 } +00042 +

    Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/servers_8cpp.html b/docs/module-doc/servers_8cpp.html index 8b6391d93..8d9a24e52 100644 --- a/docs/module-doc/servers_8cpp.html +++ b/docs/module-doc/servers_8cpp.html @@ -23,7 +23,7 @@ Include dependency graph for servers.cpp:

    Go to the source code of this file.
    -
    Generated on Thu Apr 8 19:12:40 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:42 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/servers_8h-source.html b/docs/module-doc/servers_8h-source.html index 347fc07a4..3a3106189 100644 --- a/docs/module-doc/servers_8h-source.html +++ b/docs/module-doc/servers_8h-source.html @@ -34,17 +34,22 @@ 00040 int hops_away; 00043 long version; 00046 bool jupiter; -00047 -00050 serverrec(); -00053 serverrec(char* n, long ver, bool jupe); -00056 ~serverrec(); -00057 }; -00058 -00059 -00060 -00061 #endif -00062 -

    Generated on Thu Apr 8 19:12:27 2004 for InspIRCd by +00047 +00050 char description[MAXBUF]; +00051 +00052 bool sync_soon; +00053 +00056 serverrec(); +00059 serverrec(char* n, long ver, bool jupe); +00062 ~serverrec(); +00063 +00064 }; +00065 +00066 +00067 +00068 #endif +00069 +

    Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/servers_8h.html b/docs/module-doc/servers_8h.html index c53be807e..e09e59cbb 100644 --- a/docs/module-doc/servers_8h.html +++ b/docs/module-doc/servers_8h.html @@ -82,7 +82,7 @@ Definition at line 14 of Definition at line 15 of file servers.h. -
    Generated on Thu Apr 8 19:12:42 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:43 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/tree.html b/docs/module-doc/tree.html index 15ebe779d..e5d887d47 100644 --- a/docs/module-doc/tree.html +++ b/docs/module-doc/tree.html @@ -141,6 +141,7 @@

    HostItem

    Invited

    InviteItem

    +

    ircd_connector

    ModeParameter

    Module

    ModuleFactory

    @@ -173,15 +174,16 @@

    InviteItem

    Invited

    +

    ircd_connector

    ModeParameter

    Module

    ModuleFactory

    -

    packet

    Server

    ucrec

    Version

    -

    ExtMode

    +

    ExtMode

    +

    packet

    Compound Members

    Namespace List

    diff --git a/docs/module-doc/users_8cpp-source.html b/docs/module-doc/users_8cpp-source.html index a30869ad5..83057ad04 100644 --- a/docs/module-doc/users_8cpp-source.html +++ b/docs/module-doc/users_8cpp-source.html @@ -20,7 +20,7 @@ 00012 { 00013 // the PROPER way to do it, AVOID bzero at *ALL* costs 00014 strcpy(nick,""); -00015 ip = 0; +00015 ip = 0; 00016 timeout = 0; 00017 strcpy(ident,""); 00018 strcpy(host,""); @@ -30,71 +30,76 @@ 00022 strcpy(inbuf,""); 00023 strcpy(server,""); 00024 strcpy(awaymsg,""); -00025 fd = lastping = signon = idle_lastmsg = nping = registered = 0; -00026 port = bytes_in = bytes_out = cmds_in = cmds_out = 0; -00027 haspassed = false; +00025 fd = lastping = signon = idle_lastmsg = nping = registered = 0; +00026 flood = port = bytes_in = bytes_out = cmds_in = cmds_out = 0; +00027 haspassed = false; 00028 strcpy(result,""); 00029 for (int i = 0; i < MAXCHANS; i++) 00030 { -00031 chans[i].channel = NULL; -00032 } -00033 invites.clear(); -00034 } -00035 +00031 this->chans[i].channel = NULL; +00032 this->chans[i].uc_modes = 0; +00033 } +00034 invites.clear(); +00035 } 00036 -00037 -00038 char* userrec::GetFullHost() -00039 { -00040 sprintf(result,"%s!%s@%s",nick,ident,dhost); -00041 return result; -00042 } -00043 +00037 +00038 +00039 char* userrec::GetFullHost() +00040 { +00041 sprintf(result,"%s!%s@%s",nick,ident,dhost); +00042 return result; +00043 } 00044 -00045 char* userrec::GetFullRealHost() -00046 { -00047 sprintf(result,"%s!%s@%s",nick,ident,host); -00048 return result; -00049 } -00050 -00051 bool userrec::IsInvited(char* channel) -00052 { -00053 for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++) -00054 { -00055 if (i->channel) { -00056 if (!strcasecmp(i->channel,channel)) -00057 { -00058 return true; -00059 } -00060 } -00061 } -00062 return false; -00063 } -00064 -00065 void userrec::InviteTo(char* channel) -00066 { -00067 Invited i; -00068 strcpy(i.channel,channel); -00069 invites.push_back(i); -00070 } -00071 -00072 void userrec::RemoveInvite(char* channel) -00073 { -00074 log(DEBUG,"Removing invites"); -00075 if (invites.size()) -00076 { -00077 for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++) -00078 { -00079 if (i->channel) { -00080 if (!strcasecmp(i->channel,channel)) -00081 { -00082 invites.erase(i); -00083 return; -00084 } -00085 } -00086 } -00087 } -00088 } -

    Generated on Thu Apr 8 19:12:28 2004 for InspIRCd by +00045 +00046 char* userrec::GetFullRealHost() +00047 { +00048 sprintf(result,"%s!%s@%s",nick,ident,host); +00049 return result; +00050 } +00051 +00052 bool userrec::IsInvited(char* channel) +00053 { +00054 for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++) +00055 { +00056 if (i->channel) { +00057 if (!strcasecmp(i->channel,channel)) +00058 { +00059 return true; +00060 } +00061 } +00062 } +00063 return false; +00064 } +00065 +00066 void userrec::InviteTo(char* channel) +00067 { +00068 Invited i; +00069 strcpy(i.channel,channel); +00070 invites.push_back(i); +00071 } +00072 +00073 void userrec::RemoveInvite(char* channel) +00074 { +00075 log(DEBUG,"Removing invites"); +00076 if (channel) +00077 { +00078 if (invites.size()) +00079 { +00080 for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++) +00081 { +00082 if (i->channel) +00083 { +00084 if (!strcasecmp(i->channel,channel)) +00085 { +00086 invites.erase(i); +00087 return; +00088 } +00089 } +00090 } +00091 } +00092 } +00093 } +

    Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/users_8cpp.html b/docs/module-doc/users_8cpp.html index 1db0c02cd..4ba16ebe5 100644 --- a/docs/module-doc/users_8cpp.html +++ b/docs/module-doc/users_8cpp.html @@ -15,17 +15,17 @@

    Include dependency graph for users.cpp:

    Include dependency graph
    - + - - + +

    Go to the source code of this file.
    -


    Generated on Thu Apr 8 19:12:43 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:43 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/users_8cpp__incl.gif b/docs/module-doc/users_8cpp__incl.gif index 8b2adf33d..d0b671c94 100644 Binary files a/docs/module-doc/users_8cpp__incl.gif and b/docs/module-doc/users_8cpp__incl.gif differ diff --git a/docs/module-doc/users_8h-source.html b/docs/module-doc/users_8h-source.html index 05c0fb657..666c0a7c5 100644 --- a/docs/module-doc/users_8h-source.html +++ b/docs/module-doc/users_8h-source.html @@ -38,73 +38,75 @@ 00034 class ConnectClass : public classbase 00035 { 00036 public: -00037 int type; -00038 int registration_timeout; -00039 char host[MAXBUF]; -00040 char pass[MAXBUF]; -00041 -00042 ConnectClass() -00043 { -00044 registration_timeout = 0; -00045 strcpy(host,""); -00046 strcpy(pass,""); -00047 } -00048 }; -00049 -00052 typedef std::vector<Invited> InvitedList; -00053 -00054 -00055 -00058 typedef std::vector<ConnectClass> ClassVector; -00059 -00066 class userrec : public connection -00067 { -00068 private: -00069 -00072 InvitedList invites; -00073 public: -00074 -00079 char nick[NICKMAX]; -00080 -00083 char ident[64]; -00084 -00088 char dhost[256]; -00089 -00092 char fullname[128]; -00093 -00098 char modes[MAXBUF]; -00099 -00100 ucrec chans[MAXCHANS]; +00039 int type; +00042 int registration_timeout; +00045 int flood; +00048 char host[MAXBUF]; +00051 char pass[MAXBUF]; +00052 +00053 ConnectClass() +00054 { +00055 registration_timeout = 0; +00056 flood = 0; +00057 strcpy(host,""); +00058 strcpy(pass,""); +00059 } +00060 }; +00061 +00064 typedef std::vector<Invited> InvitedList; +00065 +00066 +00067 +00070 typedef std::vector<ConnectClass> ClassVector; +00071 +00078 class userrec : public connection +00079 { +00080 private: +00081 +00084 InvitedList invites; +00085 public: +00086 +00091 char nick[NICKMAX]; +00092 +00095 char ident[64]; +00096 +00100 char dhost[256]; 00101 -00104 char server[256]; +00104 char fullname[128]; 00105 -00109 char awaymsg[512]; -00110 -00114 char result[256]; -00115 -00116 char carryover[MAXBUF]; +00110 char modes[MAXBUF]; +00111 +00112 ucrec chans[MAXCHANS]; +00113 +00116 char server[256]; 00117 -00118 unsigned long timeout; -00119 -00120 userrec(); -00121 -00122 virtual ~userrec() { } -00123 -00128 virtual char* GetFullHost(); -00129 -00135 virtual char* GetFullRealHost(); -00136 -00139 virtual bool IsInvited(char* channel); -00140 -00143 virtual void InviteTo(char* channel); -00144 -00149 virtual void RemoveInvite(char* channel); -00150 -00151 }; -00152 -00153 -00154 #endif -

    Generated on Thu Apr 8 19:12:28 2004 for InspIRCd by +00121 char awaymsg[512]; +00122 +00126 char result[256]; +00127 +00132 int flood; +00133 +00138 unsigned long timeout; +00139 +00140 userrec(); +00141 +00142 virtual ~userrec() { } +00143 +00148 virtual char* GetFullHost(); +00149 +00155 virtual char* GetFullRealHost(); +00156 +00159 virtual bool IsInvited(char* channel); +00160 +00163 virtual void InviteTo(char* channel); +00164 +00169 virtual void RemoveInvite(char* channel); +00170 +00171 }; +00172 +00173 +00174 #endif +

    Generated on Sat Apr 17 13:31:38 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/docs/module-doc/users_8h.html b/docs/module-doc/users_8h.html index 5285e2246..fff121f55 100644 --- a/docs/module-doc/users_8h.html +++ b/docs/module-doc/users_8h.html @@ -216,7 +216,7 @@ Holds a complete list of all allow and deny tags from the configuration file (co

    -Definition at line 58 of file users.h. +Definition at line 70 of file users.h.

    @@ -242,10 +242,10 @@ Holds a complete list of all channels to which a user has been invited and has n

    -Definition at line 52 of file users.h. +Definition at line 64 of file users.h. -


    Generated on Thu Apr 8 19:12:45 2004 for InspIRCd by +
    Generated on Sat Apr 17 13:31:44 2004 for InspIRCd by doxygen1.3-rc3
    diff --git a/include/connection.h b/include/connection.h index 6bc497b61..c74a494b1 100644 --- a/include/connection.h +++ b/include/connection.h @@ -148,11 +148,11 @@ class ircd_connector : public classbase }; +/** Class packet is deprecated. + * This declaration is preserved here to maintain documentation only. + */ class packet { - /** Class packet is deprecated. - * This declaration is preserved here to maintain documentation only. - */ }; /** Please note: classes serverrec and userrec both inherit from class connection. -- cgit v1.2.3