]> git.netwichtig.de Git - user/henk/code/inspircd.git/blob - docs/module-doc/classServer.html
Added new docs for class InspIRCd and globals.h etc
[user/henk/code/inspircd.git] / docs / module-doc / classServer.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
3 <title>InspIRCd: Server Class Reference</title>
4 <link href="inspircd.doxygen.css" rel="stylesheet" type="text/css">
5 </head><body>
6 <!-- Generated by Doxygen 1.4.4-20050815 -->
7 <div class="qindex"><a class="qindex" href="main.html">Main&nbsp;Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</a> | <a class="qindex" href="classes.html">Alphabetical&nbsp;List</a> | <a class="qindex" href="annotated.html">Class&nbsp;List</a> | <a class="qindex" href="dirs.html">Directories</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="namespacemembers.html">Namespace&nbsp;Members</a> | <a class="qindex" href="functions.html">Class&nbsp;Members</a> | <a class="qindex" href="globals.html">File&nbsp;Members</a></div>
8 <h1>Server Class Reference</h1><!-- doxytag: class="Server" --><!-- doxytag: inherits="classbase" -->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.  
9 <a href="#_details">More...</a>
10 <p>
11 <code>#include &lt;<a class="el" href="modules_8h-source.html">modules.h</a>&gt;</code>
12 <p>
13 Inheritance diagram for Server:<p><center><img src="classServer__inherit__graph.gif" border="0" usemap="#Server__inherit__map" alt="Inheritance graph"></center>
14 <map name="Server__inherit__map">
15 <area href="classclassbase.html" shape="rect" coords="7,7,87,34" alt="">
16 </map>
17 <center><font size="2">[<a target="top" href="graph_legend.html">legend</a>]</font></center>Collaboration diagram for Server:<p><center><img src="classServer__coll__graph.gif" border="0" usemap="#Server__coll__map" alt="Collaboration graph"></center>
18 <map name="Server__coll__map">
19 <area href="classclassbase.html" shape="rect" coords="7,97,87,124" alt="">
20 </map>
21 <center><font size="2">[<a target="top" href="graph_legend.html">legend</a>]</font></center><a href="classServer-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
22 <tr><td></td></tr>
23 <tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
24 <tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#Server_28_29">Server</a> ()</td></tr>
25
26 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Default constructor.  <a href="#Server_28_29"></a><br></td></tr>
27 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#_7EServer_28_29">~Server</a> ()</td></tr>
28
29 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Default destructor.  <a href="#_7EServer_28_29"></a><br></td></tr>
30 <tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classServerConfig.html">ServerConfig</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#GetConfig_28_29">GetConfig</a> ()</td></tr>
31
32 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Obtains a pointer to the server's <a class="el" href="classServerConfig.html">ServerConfig</a> object.  <a href="#GetConfig_28_29"></a><br></td></tr>
33 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendOpers_28std_3A_3Astring_20s_29">SendOpers</a> (<a class="el" href="namespaceirc.html#string">std::string</a> s)</td></tr>
34
35 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends text to all opers.  <a href="#SendOpers_28std_3A_3Astring_20s_29"></a><br></td></tr>
36 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#Log_28int_20level_2C_20std_3A_3Astring_20s_29">Log</a> (int level, <a class="el" href="namespaceirc.html#string">std::string</a> s)</td></tr>
37
38 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Writes a log string.  <a href="#Log_28int_20level_2C_20std_3A_3Astring_20s_29"></a><br></td></tr>
39 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#Send_28int_20Socket_2C_20std_3A_3Astring_20s_29">Send</a> (int Socket, <a class="el" href="namespaceirc.html#string">std::string</a> s)</td></tr>
40
41 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends a line of text down a TCP/IP socket.  <a href="#Send_28int_20Socket_2C_20std_3A_3Astring_20s_29"></a><br></td></tr>
42 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendServ_28int_20Socket_2C_20std_3A_3Astring_20s_29">SendServ</a> (int Socket, <a class="el" href="namespaceirc.html#string">std::string</a> s)</td></tr>
43
44 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends text from the server to a socket.  <a href="#SendServ_28int_20Socket_2C_20std_3A_3Astring_20s_29"></a><br></td></tr>
45 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendChannelServerNotice_28std_3A_3Astring_20ServName_2C_20chanrec_20_2AChannel_2C_20std_3A_3Astring_20text_29">SendChannelServerNotice</a> (<a class="el" href="namespaceirc.html#string">std::string</a> ServName, <a class="el" href="classchanrec.html">chanrec</a> *Channel, <a class="el" href="namespaceirc.html#string">std::string</a> text)</td></tr>
46
47 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Writes text to a channel, but from a server, including all.  <a href="#SendChannelServerNotice_28std_3A_3Astring_20ServName_2C_20chanrec_20_2AChannel_2C_20std_3A_3Astring_20text_29"></a><br></td></tr>
48 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendFrom_28int_20Socket_2C_20userrec_20_2AUser_2C_20std_3A_3Astring_20s_29">SendFrom</a> (int Socket, <a class="el" href="classuserrec.html">userrec</a> *User, <a class="el" href="namespaceirc.html#string">std::string</a> s)</td></tr>
49
50 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends text from a user to a socket.  <a href="#SendFrom_28int_20Socket_2C_20userrec_20_2AUser_2C_20std_3A_3Astring_20s_29"></a><br></td></tr>
51 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendTo_28userrec_20_2ASource_2C_20userrec_20_2ADest_2C_20std_3A_3Astring_20s_29">SendTo</a> (<a class="el" href="classuserrec.html">userrec</a> *Source, <a class="el" href="classuserrec.html">userrec</a> *Dest, <a class="el" href="namespaceirc.html#string">std::string</a> s)</td></tr>
52
53 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends text from a user to another user.  <a href="#SendTo_28userrec_20_2ASource_2C_20userrec_20_2ADest_2C_20std_3A_3Astring_20s_29"></a><br></td></tr>
54 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendChannel_28userrec_20_2AUser_2C_20chanrec_20_2AChannel_2C_20std_3A_3Astring_20s_2C_20bool_20IncludeSender_29">SendChannel</a> (<a class="el" href="classuserrec.html">userrec</a> *User, <a class="el" href="classchanrec.html">chanrec</a> *Channel, <a class="el" href="namespaceirc.html#string">std::string</a> s, bool IncludeSender)</td></tr>
55
56 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends text from a user to a channel (mulicast).  <a href="#SendChannel_28userrec_20_2AUser_2C_20chanrec_20_2AChannel_2C_20std_3A_3Astring_20s_2C_20bool_20IncludeSender_29"></a><br></td></tr>
57 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#CommonChannels_28userrec_20_2Au_31_2C_20userrec_20_2Au_32_29">CommonChannels</a> (<a class="el" href="classuserrec.html">userrec</a> *u1, <a class="el" href="classuserrec.html">userrec</a> *u2)</td></tr>
58
59 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns true if two users share a common channel.  <a href="#CommonChannels_28userrec_20_2Au_31_2C_20userrec_20_2Au_32_29"></a><br></td></tr>
60 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendCommon_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_2C_20bool_20IncludeSender_29">SendCommon</a> (<a class="el" href="classuserrec.html">userrec</a> *User, <a class="el" href="namespaceirc.html#string">std::string</a> text, bool IncludeSender)</td></tr>
61
62 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends text from a user to one or more channels (mulicast).  <a href="#SendCommon_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_2C_20bool_20IncludeSender_29"></a><br></td></tr>
63 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendWallops_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_29">SendWallops</a> (<a class="el" href="classuserrec.html">userrec</a> *User, <a class="el" href="namespaceirc.html#string">std::string</a> text)</td></tr>
64
65 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends a WALLOPS message.  <a href="#SendWallops_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_29"></a><br></td></tr>
66 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#IsNick_28std_3A_3Astring_20nick_29">IsNick</a> (<a class="el" href="namespaceirc.html#string">std::string</a> nick)</td></tr>
67
68 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns true if a nick is valid.  <a href="#IsNick_28std_3A_3Astring_20nick_29"></a><br></td></tr>
69 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#CountUsers_28chanrec_20_2Ac_29">CountUsers</a> (<a class="el" href="classchanrec.html">chanrec</a> *c)</td></tr>
70
71 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns a count of the number of users on a channel.  <a href="#CountUsers_28chanrec_20_2Ac_29"></a><br></td></tr>
72 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#FindNick_28std_3A_3Astring_20nick_29">FindNick</a> (<a class="el" href="namespaceirc.html#string">std::string</a> nick)</td></tr>
73
74 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Attempts to look up a nick and return a pointer to it.  <a href="#FindNick_28std_3A_3Astring_20nick_29"></a><br></td></tr>
75 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#FindDescriptor_28int_20socket_29">FindDescriptor</a> (int socket)</td></tr>
76
77 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Attempts to look up a nick using the file descriptor associated with that nick.  <a href="#FindDescriptor_28int_20socket_29"></a><br></td></tr>
78 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#FindChannel_28std_3A_3Astring_20channel_29">FindChannel</a> (<a class="el" href="namespaceirc.html#string">std::string</a> channel)</td></tr>
79
80 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Attempts to look up a channel and return a pointer to it.  <a href="#FindChannel_28std_3A_3Astring_20channel_29"></a><br></td></tr>
81 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#ChanMode_28userrec_20_2AUser_2C_20chanrec_20_2AChan_29">ChanMode</a> (<a class="el" href="classuserrec.html">userrec</a> *User, <a class="el" href="classchanrec.html">chanrec</a> *Chan)</td></tr>
82
83 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Attempts to look up a user's privilages on a channel.  <a href="#ChanMode_28userrec_20_2AUser_2C_20chanrec_20_2AChan_29"></a><br></td></tr>
84 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#IsOnChannel_28userrec_20_2AUser_2C_20chanrec_20_2AChan_29">IsOnChannel</a> (<a class="el" href="classuserrec.html">userrec</a> *User, <a class="el" href="classchanrec.html">chanrec</a> *Chan)</td></tr>
85
86 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Checks if a user is on a channel.  <a href="#IsOnChannel_28userrec_20_2AUser_2C_20chanrec_20_2AChan_29"></a><br></td></tr>
87 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#GetServerName_28_29">GetServerName</a> ()</td></tr>
88
89 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the server name of the server where the module is loaded.  <a href="#GetServerName_28_29"></a><br></td></tr>
90 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#GetNetworkName_28_29">GetNetworkName</a> ()</td></tr>
91
92 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the network name, global to all linked servers.  <a href="#GetNetworkName_28_29"></a><br></td></tr>
93 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#GetServerDescription_28_29">GetServerDescription</a> ()</td></tr>
94
95 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the server description string of the local server.  <a href="#GetServerDescription_28_29"></a><br></td></tr>
96 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classAdmin.html">Admin</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#GetAdmin_28_29">GetAdmin</a> ()</td></tr>
97
98 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the information of the server as returned by the /ADMIN command.  <a href="#GetAdmin_28_29"></a><br></td></tr>
99 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddExtendedMode_28char_20modechar_2C_20int_20type_2C_20bool_20requires_5Foper_2C_20int_20params_5Fwhen_5Fon_2C_20int_20params_5Fwhen_5Foff_29">AddExtendedMode</a> (char modechar, int type, bool requires_oper, int params_when_on, int params_when_off)</td></tr>
100
101 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds an extended mode letter which is parsed by a module.  <a href="#AddExtendedMode_28char_20modechar_2C_20int_20type_2C_20bool_20requires_5Foper_2C_20int_20params_5Fwhen_5Fon_2C_20int_20params_5Fwhen_5Foff_29"></a><br></td></tr>
102 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddExtendedListMode_28char_20modechar_29">AddExtendedListMode</a> (char modechar)</td></tr>
103
104 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds an extended mode letter which is parsed by a module and handled in a list fashion.  <a href="#AddExtendedListMode_28char_20modechar_29"></a><br></td></tr>
105 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddCommand_28char_20_2Acmd_2C_20handlerfunc_20f_2C_20char_20flags_2C_20int_20minparams_2C_20char_20_2Asource_29">AddCommand</a> (char *cmd, <a class="el" href="inspircd_8h.html#handlerfunc_29_28char_20_2A_2A_2C_20int_2C_20userrec_20_2A_29">handlerfunc</a> f, char flags, int minparams, char *source)</td></tr>
106
107 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds a command to the command table.  <a href="#AddCommand_28char_20_2Acmd_2C_20handlerfunc_20f_2C_20char_20flags_2C_20int_20minparams_2C_20char_20_2Asource_29"></a><br></td></tr>
108 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendMode_28char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">SendMode</a> (char **parameters, int pcnt, <a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
109
110 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends a servermode.  <a href="#SendMode_28char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29"></a><br></td></tr>
111 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#SendToModeMask_28std_3A_3Astring_20modes_2C_20int_20flags_2C_20std_3A_3Astring_20text_29">SendToModeMask</a> (<a class="el" href="namespaceirc.html#string">std::string</a> modes, int flags, <a class="el" href="namespaceirc.html#string">std::string</a> text)</td></tr>
112
113 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends to all users matching a mode mask You must specify one or more usermodes as the first parameter.  <a href="#SendToModeMask_28std_3A_3Astring_20modes_2C_20int_20flags_2C_20std_3A_3Astring_20text_29"></a><br></td></tr>
114 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#JoinUserToChannel_28userrec_20_2Auser_2C_20std_3A_3Astring_20cname_2C_20std_3A_3Astring_20key_29">JoinUserToChannel</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="namespaceirc.html#string">std::string</a> cname, <a class="el" href="namespaceirc.html#string">std::string</a> key)</td></tr>
115
116 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Forces a user to join a channel.  <a href="#JoinUserToChannel_28userrec_20_2Auser_2C_20std_3A_3Astring_20cname_2C_20std_3A_3Astring_20key_29"></a><br></td></tr>
117 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#PartUserFromChannel_28userrec_20_2Auser_2C_20std_3A_3Astring_20cname_2C_20std_3A_3Astring_20reason_29">PartUserFromChannel</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="namespaceirc.html#string">std::string</a> cname, <a class="el" href="namespaceirc.html#string">std::string</a> reason)</td></tr>
118
119 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Forces a user to part a channel.  <a href="#PartUserFromChannel_28userrec_20_2Auser_2C_20std_3A_3Astring_20cname_2C_20std_3A_3Astring_20reason_29"></a><br></td></tr>
120 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#ChangeUserNick_28userrec_20_2Auser_2C_20std_3A_3Astring_20nickname_29">ChangeUserNick</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="namespaceirc.html#string">std::string</a> nickname)</td></tr>
121
122 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Forces a user nickchange.  <a href="#ChangeUserNick_28userrec_20_2Auser_2C_20std_3A_3Astring_20nickname_29"></a><br></td></tr>
123 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#QuitUser_28userrec_20_2Auser_2C_20std_3A_3Astring_20reason_29">QuitUser</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="namespaceirc.html#string">std::string</a> reason)</td></tr>
124
125 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Forces a user to quit with the specified reason.  <a href="#QuitUser_28userrec_20_2Auser_2C_20std_3A_3Astring_20reason_29"></a><br></td></tr>
126 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#MatchText_28std_3A_3Astring_20sliteral_2C_20std_3A_3Astring_20spattern_29">MatchText</a> (<a class="el" href="namespaceirc.html#string">std::string</a> sliteral, <a class="el" href="namespaceirc.html#string">std::string</a> spattern)</td></tr>
127
128 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Matches text against a glob pattern.  <a href="#MatchText_28std_3A_3Astring_20sliteral_2C_20std_3A_3Astring_20spattern_29"></a><br></td></tr>
129 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#CallCommandHandler_28std_3A_3Astring_20commandname_2C_20char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">CallCommandHandler</a> (<a class="el" href="namespaceirc.html#string">std::string</a> commandname, char **parameters, int pcnt, <a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
130
131 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Calls the handler for a command, either implemented by the core or by another module.  <a href="#CallCommandHandler_28std_3A_3Astring_20commandname_2C_20char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29"></a><br></td></tr>
132 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#IsValidModuleCommand_28std_3A_3Astring_20commandname_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">IsValidModuleCommand</a> (<a class="el" href="namespaceirc.html#string">std::string</a> commandname, int pcnt, <a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
133
134 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#ChangeHost_28userrec_20_2Auser_2C_20std_3A_3Astring_20host_29">ChangeHost</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="namespaceirc.html#string">std::string</a> host)</td></tr>
135
136 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Change displayed hostname of a user.  <a href="#ChangeHost_28userrec_20_2Auser_2C_20std_3A_3Astring_20host_29"></a><br></td></tr>
137 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#ChangeGECOS_28userrec_20_2Auser_2C_20std_3A_3Astring_20gecos_29">ChangeGECOS</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="namespaceirc.html#string">std::string</a> gecos)</td></tr>
138
139 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Change GECOS (fullname) of a user.  <a href="#ChangeGECOS_28userrec_20_2Auser_2C_20std_3A_3Astring_20gecos_29"></a><br></td></tr>
140 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#IsUlined_28std_3A_3Astring_20server_29">IsUlined</a> (<a class="el" href="namespaceirc.html#string">std::string</a> server)</td></tr>
141
142 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns true if the servername you give is ulined.  <a href="#IsUlined_28std_3A_3Astring_20server_29"></a><br></td></tr>
143 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="modules_8h.html#chanuserlist">chanuserlist</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#GetUsers_28chanrec_20_2Achan_29">GetUsers</a> (<a class="el" href="classchanrec.html">chanrec</a> *chan)</td></tr>
144
145 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Fetches the userlist of a channel.  <a href="#GetUsers_28chanrec_20_2Achan_29"></a><br></td></tr>
146 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#UserToPseudo_28userrec_20_2Auser_2C_20std_3A_3Astring_20message_29">UserToPseudo</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="namespaceirc.html#string">std::string</a> message)</td></tr>
147
148 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Remove a user's connection to the irc server, but leave their client in existence in the user hash.  <a href="#UserToPseudo_28userrec_20_2Auser_2C_20std_3A_3Astring_20message_29"></a><br></td></tr>
149 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#PseudoToUser_28userrec_20_2Aalive_2C_20userrec_20_2Azombie_2C_20std_3A_3Astring_20message_29">PseudoToUser</a> (<a class="el" href="classuserrec.html">userrec</a> *alive, <a class="el" href="classuserrec.html">userrec</a> *zombie, <a class="el" href="namespaceirc.html#string">std::string</a> message)</td></tr>
150
151 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This user takes one user, and switches their file descriptor with another user, so that one user "becomes" the other.  <a href="#PseudoToUser_28userrec_20_2Aalive_2C_20userrec_20_2Azombie_2C_20std_3A_3Astring_20message_29"></a><br></td></tr>
152 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddGLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29">AddGLine</a> (long duration, <a class="el" href="namespaceirc.html#string">std::string</a> source, <a class="el" href="namespaceirc.html#string">std::string</a> reason, <a class="el" href="namespaceirc.html#string">std::string</a> hostmask)</td></tr>
153
154 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds a G-line The G-line is propogated to all of the servers in the mesh and enforced as soon as it is added.  <a href="#AddGLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29"></a><br></td></tr>
155 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddQLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20nickname_29">AddQLine</a> (long duration, <a class="el" href="namespaceirc.html#string">std::string</a> source, <a class="el" href="namespaceirc.html#string">std::string</a> reason, <a class="el" href="namespaceirc.html#string">std::string</a> nickname)</td></tr>
156
157 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds a Q-line The Q-line is propogated to all of the servers in the mesh and enforced as soon as it is added.  <a href="#AddQLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20nickname_29"></a><br></td></tr>
158 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddZLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20ipaddr_29">AddZLine</a> (long duration, <a class="el" href="namespaceirc.html#string">std::string</a> source, <a class="el" href="namespaceirc.html#string">std::string</a> reason, <a class="el" href="namespaceirc.html#string">std::string</a> ipaddr)</td></tr>
159
160 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds a Z-line The Z-line is propogated to all of the servers in the mesh and enforced as soon as it is added.  <a href="#AddZLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20ipaddr_29"></a><br></td></tr>
161 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddKLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29">AddKLine</a> (long duration, <a class="el" href="namespaceirc.html#string">std::string</a> source, <a class="el" href="namespaceirc.html#string">std::string</a> reason, <a class="el" href="namespaceirc.html#string">std::string</a> hostmask)</td></tr>
162
163 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds a K-line The K-line is enforced as soon as it is added.  <a href="#AddKLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29"></a><br></td></tr>
164 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddELine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29">AddELine</a> (long duration, <a class="el" href="namespaceirc.html#string">std::string</a> source, <a class="el" href="namespaceirc.html#string">std::string</a> reason, <a class="el" href="namespaceirc.html#string">std::string</a> hostmask)</td></tr>
165
166 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds a E-line The E-line is enforced as soon as it is added.  <a href="#AddELine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29"></a><br></td></tr>
167 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#DelGLine_28std_3A_3Astring_20hostmask_29">DelGLine</a> (<a class="el" href="namespaceirc.html#string">std::string</a> hostmask)</td></tr>
168
169 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Deletes a G-Line from all servers on the mesh.  <a href="#DelGLine_28std_3A_3Astring_20hostmask_29"></a><br></td></tr>
170 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#DelQLine_28std_3A_3Astring_20nickname_29">DelQLine</a> (<a class="el" href="namespaceirc.html#string">std::string</a> nickname)</td></tr>
171
172 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Deletes a Q-Line from all servers on the mesh.  <a href="#DelQLine_28std_3A_3Astring_20nickname_29"></a><br></td></tr>
173 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#DelZLine_28std_3A_3Astring_20ipaddr_29">DelZLine</a> (<a class="el" href="namespaceirc.html#string">std::string</a> ipaddr)</td></tr>
174
175 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Deletes a Z-Line from all servers on the mesh.  <a href="#DelZLine_28std_3A_3Astring_20ipaddr_29"></a><br></td></tr>
176 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#DelKLine_28std_3A_3Astring_20hostmask_29">DelKLine</a> (<a class="el" href="namespaceirc.html#string">std::string</a> hostmask)</td></tr>
177
178 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Deletes a local K-Line.  <a href="#DelKLine_28std_3A_3Astring_20hostmask_29"></a><br></td></tr>
179 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#DelELine_28std_3A_3Astring_20hostmask_29">DelELine</a> (<a class="el" href="namespaceirc.html#string">std::string</a> hostmask)</td></tr>
180
181 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Deletes a local E-Line.  <a href="#DelELine_28std_3A_3Astring_20hostmask_29"></a><br></td></tr>
182 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#CalcDuration_28std_3A_3Astring_20duration_29">CalcDuration</a> (<a class="el" href="namespaceirc.html#string">std::string</a> duration)</td></tr>
183
184 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Calculates a duration This method will take a string containing a formatted duration (e.g.  <a href="#CalcDuration_28std_3A_3Astring_20duration_29"></a><br></td></tr>
185 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#IsValidMask_28std_3A_3Astring_20mask_29">IsValidMask</a> (<a class="el" href="namespaceirc.html#string">std::string</a> mask)</td></tr>
186
187 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns true if a nick!ident string is correctly formatted, false if otherwise.  <a href="#IsValidMask_28std_3A_3Astring_20mask_29"></a><br></td></tr>
188 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classModule.html">Module</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#FindModule_28std_3A_3Astring_20name_29">FindModule</a> (<a class="el" href="namespaceirc.html#string">std::string</a> name)</td></tr>
189
190 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This function finds a module by name.  <a href="#FindModule_28std_3A_3Astring_20name_29"></a><br></td></tr>
191 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#AddSocket_28InspSocket_20_2Asock_29">AddSocket</a> (<a class="el" href="classInspSocket.html">InspSocket</a> *sock)</td></tr>
192
193 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Adds a class derived from <a class="el" href="classInspSocket.html">InspSocket</a> to the server's socket engine.  <a href="#AddSocket_28InspSocket_20_2Asock_29"></a><br></td></tr>
194 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#DelSocket_28InspSocket_20_2Asock_29">DelSocket</a> (<a class="el" href="classInspSocket.html">InspSocket</a> *sock)</td></tr>
195
196 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Deletes a class derived from <a class="el" href="classInspSocket.html">InspSocket</a> from the server's socket engine.  <a href="#DelSocket_28InspSocket_20_2Asock_29"></a><br></td></tr>
197 <tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classServer.html#RehashServer_28_29">RehashServer</a> ()</td></tr>
198
199 </table>
200 <hr><a name="_details"></a><h2>Detailed Description</h2>
201 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. 
202 <p>
203 All modules should instantiate at least one copy of this class, and use its member functions to perform their tasks.
204 <p>
205
206 <p>
207 Definition at line <a class="el" href="modules_8h-source.html#l01096">1096</a> of file <a class="el" href="modules_8h-source.html">modules.h</a>.<hr><h2>Constructor &amp; Destructor Documentation</h2>
208 <a class="anchor" name="Server_28_29"></a><!-- doxytag: member="Server::Server" ref="Server_28_29" args="()" --><p>
209 <table class="mdTable" cellpadding="2" cellspacing="0">
210   <tr>
211     <td class="mdRow">
212       <table cellpadding="0" cellspacing="0" border="0">
213         <tr>
214           <td class="md" nowrap valign="top">Server::Server           </td>
215           <td class="md" valign="top">(&nbsp;</td>
216           <td class="mdname1" valign="top" nowrap>          </td>
217           <td class="md" valign="top">&nbsp;)&nbsp;</td>
218           <td class="md" nowrap></td>
219         </tr>
220       </table>
221     </td>
222   </tr>
223 </table>
224 <table cellspacing="5" cellpadding="0" border="0">
225   <tr>
226     <td>
227       &nbsp;
228     </td>
229     <td>
230
231 <p>
232 Default constructor. 
233 <p>
234 Creates a Server object.
235 <p>
236 Definition at line <a class="el" href="modules_8cpp-source.html#l00305">305</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00306"></a>00306 {
237 <a name="l00307"></a>00307 }
238 </pre></div>
239 <p>
240     </td>
241   </tr>
242 </table>
243 <a class="anchor" name="_7EServer_28_29"></a><!-- doxytag: member="Server::~Server" ref="_7EServer_28_29" args="()" --><p>
244 <table class="mdTable" cellpadding="2" cellspacing="0">
245   <tr>
246     <td class="mdRow">
247       <table cellpadding="0" cellspacing="0" border="0">
248         <tr>
249           <td class="md" nowrap valign="top">Server::~Server           </td>
250           <td class="md" valign="top">(&nbsp;</td>
251           <td class="mdname1" valign="top" nowrap>          </td>
252           <td class="md" valign="top">&nbsp;)&nbsp;</td>
253           <td class="md" nowrap><code> [virtual]</code></td>
254         </tr>
255       </table>
256     </td>
257   </tr>
258 </table>
259 <table cellspacing="5" cellpadding="0" border="0">
260   <tr>
261     <td>
262       &nbsp;
263     </td>
264     <td>
265
266 <p>
267 Default destructor. 
268 <p>
269 Destroys a Server object.
270 <p>
271 Definition at line <a class="el" href="modules_8cpp-source.html#l00309">309</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00310"></a>00310 {
272 <a name="l00311"></a>00311 }
273 </pre></div>
274 <p>
275     </td>
276   </tr>
277 </table>
278 <hr><h2>Member Function Documentation</h2>
279 <a class="anchor" name="AddCommand_28char_20_2Acmd_2C_20handlerfunc_20f_2C_20char_20flags_2C_20int_20minparams_2C_20char_20_2Asource_29"></a><!-- doxytag: member="Server::AddCommand" ref="AddCommand_28char_20_2Acmd_2C_20handlerfunc_20f_2C_20char_20flags_2C_20int_20minparams_2C_20char_20_2Asource_29" args="(char *cmd, handlerfunc f, char flags, int minparams, char *source)" --><p>
280 <table class="mdTable" cellpadding="2" cellspacing="0">
281   <tr>
282     <td class="mdRow">
283       <table cellpadding="0" cellspacing="0" border="0">
284         <tr>
285           <td class="md" nowrap valign="top">void Server::AddCommand           </td>
286           <td class="md" valign="top">(&nbsp;</td>
287           <td class="md" nowrap valign="top">char *&nbsp;</td>
288           <td class="mdname" nowrap> <em>cmd</em>, </td>
289         </tr>
290         <tr>
291           <td class="md" nowrap align="right"></td>
292           <td class="md"></td>
293           <td class="md" nowrap><a class="el" href="inspircd_8h.html#handlerfunc_29_28char_20_2A_2A_2C_20int_2C_20userrec_20_2A_29">handlerfunc</a>&nbsp;</td>
294           <td class="mdname" nowrap> <em>f</em>, </td>
295         </tr>
296         <tr>
297           <td class="md" nowrap align="right"></td>
298           <td class="md"></td>
299           <td class="md" nowrap>char&nbsp;</td>
300           <td class="mdname" nowrap> <em>flags</em>, </td>
301         </tr>
302         <tr>
303           <td class="md" nowrap align="right"></td>
304           <td class="md"></td>
305           <td class="md" nowrap>int&nbsp;</td>
306           <td class="mdname" nowrap> <em>minparams</em>, </td>
307         </tr>
308         <tr>
309           <td class="md" nowrap align="right"></td>
310           <td class="md"></td>
311           <td class="md" nowrap>char *&nbsp;</td>
312           <td class="mdname" nowrap> <em>source</em></td>
313         </tr>
314         <tr>
315           <td class="md"></td>
316           <td class="md">)&nbsp;</td>
317           <td class="md" colspan="2"><code> [virtual]</code></td>
318         </tr>
319       </table>
320     </td>
321   </tr>
322 </table>
323 <table cellspacing="5" cellpadding="0" border="0">
324   <tr>
325     <td>
326       &nbsp;
327     </td>
328     <td>
329
330 <p>
331 Adds a command to the command table. 
332 <p>
333 This allows modules to add extra commands into the command table. You must place a function within your module which is is of type handlerfunc:<p>
334 typedef void (handlerfunc) (char**, int, userrec*); ... void <a class="el" href="commands_8h.html#handle_5Fkill_28char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">handle_kill(char **parameters, int pcnt, userrec *user)</a><p>
335 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'. The source parameter is used for resource tracking, and should contain the name of your module (with file extension) e.g. "m_blarp.so". If you place the wrong identifier here, you can cause crashes if your module is unloaded.
336 <p>
337 Definition at line <a class="el" href="modules_8cpp-source.html#l00411">411</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
338 <p>
339 References <a class="el" href="modules_8h.html#createcommand_28char_20_2Acmd_2C_20handlerfunc_20f_2C_20char_20flags_2C_20int_20minparams_2C_20char_20_2Asource_29">createcommand()</a>.<div class="fragment"><pre class="fragment"><a name="l00412"></a>00412 {
340 <a name="l00413"></a>00413         <a class="code" href="modules_8h.html#createcommand_28char_20_2Acmd_2C_20handlerfunc_20f_2C_20char_20flags_2C_20int_20minparams_2C_20char_20_2Asource_29">createcommand</a>(cmd,f,flags,minparams,source);
341 <a name="l00414"></a>00414 }
342 </pre></div>
343 <p>
344     </td>
345   </tr>
346 </table>
347 <a class="anchor" name="AddELine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29"></a><!-- doxytag: member="Server::AddELine" ref="AddELine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29" args="(long duration, std::string source, std::string reason, std::string hostmask)" --><p>
348 <table class="mdTable" cellpadding="2" cellspacing="0">
349   <tr>
350     <td class="mdRow">
351       <table cellpadding="0" cellspacing="0" border="0">
352         <tr>
353           <td class="md" nowrap valign="top">void Server::AddELine           </td>
354           <td class="md" valign="top">(&nbsp;</td>
355           <td class="md" nowrap valign="top">long&nbsp;</td>
356           <td class="mdname" nowrap> <em>duration</em>, </td>
357         </tr>
358         <tr>
359           <td class="md" nowrap align="right"></td>
360           <td class="md"></td>
361           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
362           <td class="mdname" nowrap> <em>source</em>, </td>
363         </tr>
364         <tr>
365           <td class="md" nowrap align="right"></td>
366           <td class="md"></td>
367           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
368           <td class="mdname" nowrap> <em>reason</em>, </td>
369         </tr>
370         <tr>
371           <td class="md" nowrap align="right"></td>
372           <td class="md"></td>
373           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
374           <td class="mdname" nowrap> <em>hostmask</em></td>
375         </tr>
376         <tr>
377           <td class="md"></td>
378           <td class="md">)&nbsp;</td>
379           <td class="md" colspan="2"><code> [virtual]</code></td>
380         </tr>
381       </table>
382     </td>
383   </tr>
384 </table>
385 <table cellspacing="5" cellpadding="0" border="0">
386   <tr>
387     <td>
388       &nbsp;
389     </td>
390     <td>
391
392 <p>
393 Adds a E-line The E-line is enforced as soon as it is added. 
394 <p>
395 The duration must be in seconds, however you can use the <a class="el" href="classServer.html#CalcDuration_28std_3A_3Astring_20duration_29">Server::CalcDuration</a> method to convert durations into the 1w2d3h3m6s format used by /GLINE etc. The source is an arbitary string used to indicate who or what sent the data, usually this is the nickname of a person, or a server name.
396 <p>
397 Definition at line <a class="el" href="modules_8cpp-source.html#l00655">655</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
398 <p>
399 References <a class="el" href="xline_8h.html#add_5Feline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Ahostmask_29">add_eline()</a>.<div class="fragment"><pre class="fragment"><a name="l00656"></a>00656 {
400 <a name="l00657"></a>00657         <a class="code" href="xline_8h.html#add_5Feline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Ahostmask_29">add_eline</a>(<a class="code" href="commands_8h.html#duration_28const_20char_20_2Astr_29">duration</a>, source.c_str(), reason.c_str(), hostmask.c_str());
401 <a name="l00658"></a>00658 }
402 </pre></div>
403 <p>
404     </td>
405   </tr>
406 </table>
407 <a class="anchor" name="AddExtendedListMode_28char_20modechar_29"></a><!-- doxytag: member="Server::AddExtendedListMode" ref="AddExtendedListMode_28char_20modechar_29" args="(char modechar)" --><p>
408 <table class="mdTable" cellpadding="2" cellspacing="0">
409   <tr>
410     <td class="mdRow">
411       <table cellpadding="0" cellspacing="0" border="0">
412         <tr>
413           <td class="md" nowrap valign="top">bool Server::AddExtendedListMode           </td>
414           <td class="md" valign="top">(&nbsp;</td>
415           <td class="md" nowrap valign="top">char&nbsp;</td>
416           <td class="mdname1" valign="top" nowrap> <em>modechar</em>          </td>
417           <td class="md" valign="top">&nbsp;)&nbsp;</td>
418           <td class="md" nowrap><code> [virtual]</code></td>
419         </tr>
420       </table>
421     </td>
422   </tr>
423 </table>
424 <table cellspacing="5" cellpadding="0" border="0">
425   <tr>
426     <td>
427       &nbsp;
428     </td>
429     <td>
430
431 <p>
432 Adds an extended mode letter which is parsed by a module and handled in a list fashion. 
433 <p>
434 This call is used to implement modes like +q and +a. The characteristics of these modes are as follows:<p>
435 (1) They are ALWAYS on channels, not on users, therefore their type is MT_CHANNEL<p>
436 (2) They always take exactly one parameter when being added or removed<p>
437 (3) They can be set multiple times, usually on users in channels<p>
438 (4) The mode and its parameter are NOT stored in the channels modes structure<p>
439 It is down to the module handling the mode to maintain state and determine what 'items' (e.g. users, or a banlist) have the mode set on them, and process the modes at the correct times, e.g. during access checks on channels, etc. When the extended mode is triggered the OnExtendedMode method will be triggered as above. Note that the target you are given will be a channel, if for example your mode is set 'on a user' (in for example +a) you must use <a class="el" href="globals_8h.html#Find_28std_3A_3Astring_20nick_29">Server::Find</a> to locate the user the mode is operating on. Your mode handler may return 1 to handle the mode AND tell the core to display the mode change, e.g. '+aaa one two three' in the case of the mode for 'two', or it may return -1 to 'eat' the mode change, so the above example would become '+aa one three' after processing.
440 <p>
441 Definition at line <a class="el" href="modules_8cpp-source.html#l00579">579</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
442 <p>
443 References <a class="el" href="modules_8cpp-source.html#l00134">DoAddExtendedMode()</a>, <a class="el" href="modules_8cpp-source.html#l00144">ModeMakeList()</a>, and <a class="el" href="modules_8h-source.html#l00031">MT_CHANNEL</a>.<div class="fragment"><pre class="fragment"><a name="l00580"></a>00580 {
444 <a name="l00581"></a>00581         <span class="keywordtype">bool</span> res = <a class="code" href="modules_8cpp.html#DoAddExtendedMode_28char_20modechar_2C_20int_20type_2C_20bool_20requires_5Foper_2C_20int_20params_5Fon_2C_20int_20params_5Foff_29">DoAddExtendedMode</a>(modechar,<a class="code" href="modules_8h.html#MT_5FCHANNEL">MT_CHANNEL</a>,<span class="keyword">false</span>,1,1);
445 <a name="l00582"></a>00582         <span class="keywordflow">if</span> (res)
446 <a name="l00583"></a>00583                 <a class="code" href="modules_8cpp.html#ModeMakeList_28char_20modechar_29">ModeMakeList</a>(modechar);
447 <a name="l00584"></a>00584         <span class="keywordflow">return</span> res;
448 <a name="l00585"></a>00585 }
449 </pre></div>
450 <p>
451     </td>
452   </tr>
453 </table>
454 <a class="anchor" name="AddExtendedMode_28char_20modechar_2C_20int_20type_2C_20bool_20requires_5Foper_2C_20int_20params_5Fwhen_5Fon_2C_20int_20params_5Fwhen_5Foff_29"></a><!-- doxytag: member="Server::AddExtendedMode" ref="AddExtendedMode_28char_20modechar_2C_20int_20type_2C_20bool_20requires_5Foper_2C_20int_20params_5Fwhen_5Fon_2C_20int_20params_5Fwhen_5Foff_29" args="(char modechar, int type, bool requires_oper, int params_when_on, int params_when_off)" --><p>
455 <table class="mdTable" cellpadding="2" cellspacing="0">
456   <tr>
457     <td class="mdRow">
458       <table cellpadding="0" cellspacing="0" border="0">
459         <tr>
460           <td class="md" nowrap valign="top">bool Server::AddExtendedMode           </td>
461           <td class="md" valign="top">(&nbsp;</td>
462           <td class="md" nowrap valign="top">char&nbsp;</td>
463           <td class="mdname" nowrap> <em>modechar</em>, </td>
464         </tr>
465         <tr>
466           <td class="md" nowrap align="right"></td>
467           <td class="md"></td>
468           <td class="md" nowrap>int&nbsp;</td>
469           <td class="mdname" nowrap> <em>type</em>, </td>
470         </tr>
471         <tr>
472           <td class="md" nowrap align="right"></td>
473           <td class="md"></td>
474           <td class="md" nowrap>bool&nbsp;</td>
475           <td class="mdname" nowrap> <em>requires_oper</em>, </td>
476         </tr>
477         <tr>
478           <td class="md" nowrap align="right"></td>
479           <td class="md"></td>
480           <td class="md" nowrap>int&nbsp;</td>
481           <td class="mdname" nowrap> <em>params_when_on</em>, </td>
482         </tr>
483         <tr>
484           <td class="md" nowrap align="right"></td>
485           <td class="md"></td>
486           <td class="md" nowrap>int&nbsp;</td>
487           <td class="mdname" nowrap> <em>params_when_off</em></td>
488         </tr>
489         <tr>
490           <td class="md"></td>
491           <td class="md">)&nbsp;</td>
492           <td class="md" colspan="2"><code> [virtual]</code></td>
493         </tr>
494       </table>
495     </td>
496   </tr>
497 </table>
498 <table cellspacing="5" cellpadding="0" border="0">
499   <tr>
500     <td>
501       &nbsp;
502     </td>
503     <td>
504
505 <p>
506 Adds an extended mode letter which is parsed by a module. 
507 <p>
508 This allows modules to add extra mode letters, e.g. +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.
509 <p>
510 Definition at line <a class="el" href="modules_8cpp-source.html#l00551">551</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
511 <p>
512 References <a class="el" href="inspircd__io_8h-source.html#l00028">DEBUG</a>, <a class="el" href="modules_8cpp-source.html#l00134">DoAddExtendedMode()</a>, <a class="el" href="globals_8h.html#log_28int_20level_2C_20char_20_2Atext_2C_2E_2E_2E_29">log()</a>, <a class="el" href="modules_8h-source.html#l00032">MT_CLIENT</a>, and <a class="el" href="modules_8h-source.html#l00033">MT_SERVER</a>.<div class="fragment"><pre class="fragment"><a name="l00552"></a>00552 {
513 <a name="l00553"></a>00553         <span class="keywordflow">if</span> (((modechar &gt;= <span class="charliteral">'A'</span>) &amp;&amp; (modechar &lt;= <span class="charliteral">'Z'</span>)) || ((modechar &gt;= <span class="charliteral">'a'</span>) &amp;&amp; (modechar &lt;= <span class="charliteral">'z'</span>)))
514 <a name="l00554"></a>00554         {
515 <a name="l00555"></a>00555                 <span class="keywordflow">if</span> (type == <a class="code" href="modules_8h.html#MT_5FSERVER">MT_SERVER</a>)
516 <a name="l00556"></a>00556                 {
517 <a name="l00557"></a>00557                         <a class="code" href="globals_8h.html#log_28int_20level_2C_20char_20_2Atext_2C_2E_2E_2E_29">log</a>(<a class="code" href="inspircd__io_8h.html#DEBUG">DEBUG</a>,<span class="stringliteral">"*** API ERROR *** Modes of type MT_SERVER are reserved for future expansion"</span>);
518 <a name="l00558"></a>00558                         <span class="keywordflow">return</span> <span class="keyword">false</span>;
519 <a name="l00559"></a>00559                 }
520 <a name="l00560"></a>00560                 <span class="keywordflow">if</span> (((params_when_on&gt;0) || (params_when_off&gt;0)) &amp;&amp; (type == <a class="code" href="modules_8h.html#MT_5FCLIENT">MT_CLIENT</a>))
521 <a name="l00561"></a>00561                 {
522 <a name="l00562"></a>00562                         <a class="code" href="globals_8h.html#log_28int_20level_2C_20char_20_2Atext_2C_2E_2E_2E_29">log</a>(<a class="code" href="inspircd__io_8h.html#DEBUG">DEBUG</a>,<span class="stringliteral">"*** API ERROR *** Parameters on MT_CLIENT modes are not supported"</span>);
523 <a name="l00563"></a>00563                         <span class="keywordflow">return</span> <span class="keyword">false</span>;
524 <a name="l00564"></a>00564                 }
525 <a name="l00565"></a>00565                 <span class="keywordflow">if</span> ((params_when_on&gt;1) || (params_when_off&gt;1))
526 <a name="l00566"></a>00566                 {
527 <a name="l00567"></a>00567                         <a class="code" href="globals_8h.html#log_28int_20level_2C_20char_20_2Atext_2C_2E_2E_2E_29">log</a>(<a class="code" href="inspircd__io_8h.html#DEBUG">DEBUG</a>,<span class="stringliteral">"*** API ERROR *** More than one parameter for an MT_CHANNEL mode is not yet supported"</span>);
528 <a name="l00568"></a>00568                         <span class="keywordflow">return</span> <span class="keyword">false</span>;
529 <a name="l00569"></a>00569                 }
530 <a name="l00570"></a>00570                 <span class="keywordflow">return</span> <a class="code" href="modules_8cpp.html#DoAddExtendedMode_28char_20modechar_2C_20int_20type_2C_20bool_20requires_5Foper_2C_20int_20params_5Fon_2C_20int_20params_5Foff_29">DoAddExtendedMode</a>(modechar,type,requires_oper,params_when_on,params_when_off);
531 <a name="l00571"></a>00571         }
532 <a name="l00572"></a>00572         <span class="keywordflow">else</span>
533 <a name="l00573"></a>00573         {
534 <a name="l00574"></a>00574                 <a class="code" href="globals_8h.html#log_28int_20level_2C_20char_20_2Atext_2C_2E_2E_2E_29">log</a>(<a class="code" href="inspircd__io_8h.html#DEBUG">DEBUG</a>,<span class="stringliteral">"*** API ERROR *** Muppet modechar detected."</span>);
535 <a name="l00575"></a>00575         }
536 <a name="l00576"></a>00576         <span class="keywordflow">return</span> <span class="keyword">false</span>;
537 <a name="l00577"></a>00577 }
538 </pre></div>
539 <p>
540     </td>
541   </tr>
542 </table>
543 <a class="anchor" name="AddGLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29"></a><!-- doxytag: member="Server::AddGLine" ref="AddGLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29" args="(long duration, std::string source, std::string reason, std::string hostmask)" --><p>
544 <table class="mdTable" cellpadding="2" cellspacing="0">
545   <tr>
546     <td class="mdRow">
547       <table cellpadding="0" cellspacing="0" border="0">
548         <tr>
549           <td class="md" nowrap valign="top">void Server::AddGLine           </td>
550           <td class="md" valign="top">(&nbsp;</td>
551           <td class="md" nowrap valign="top">long&nbsp;</td>
552           <td class="mdname" nowrap> <em>duration</em>, </td>
553         </tr>
554         <tr>
555           <td class="md" nowrap align="right"></td>
556           <td class="md"></td>
557           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
558           <td class="mdname" nowrap> <em>source</em>, </td>
559         </tr>
560         <tr>
561           <td class="md" nowrap align="right"></td>
562           <td class="md"></td>
563           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
564           <td class="mdname" nowrap> <em>reason</em>, </td>
565         </tr>
566         <tr>
567           <td class="md" nowrap align="right"></td>
568           <td class="md"></td>
569           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
570           <td class="mdname" nowrap> <em>hostmask</em></td>
571         </tr>
572         <tr>
573           <td class="md"></td>
574           <td class="md">)&nbsp;</td>
575           <td class="md" colspan="2"><code> [virtual]</code></td>
576         </tr>
577       </table>
578     </td>
579   </tr>
580 </table>
581 <table cellspacing="5" cellpadding="0" border="0">
582   <tr>
583     <td>
584       &nbsp;
585     </td>
586     <td>
587
588 <p>
589 Adds a G-line The G-line is propogated to all of the servers in the mesh and enforced as soon as it is added. 
590 <p>
591 The duration must be in seconds, however you can use the <a class="el" href="classServer.html#CalcDuration_28std_3A_3Astring_20duration_29">Server::CalcDuration</a> method to convert durations into the 1w2d3h3m6s format used by /GLINE etc. The source is an arbitary string used to indicate who or what sent the data, usually this is the nickname of a person, or a server name.
592 <p>
593 Definition at line <a class="el" href="modules_8cpp-source.html#l00635">635</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
594 <p>
595 References <a class="el" href="xline_8h.html#add_5Fgline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Ahostmask_29">add_gline()</a>.<div class="fragment"><pre class="fragment"><a name="l00636"></a>00636 {
596 <a name="l00637"></a>00637         <a class="code" href="xline_8h.html#add_5Fgline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Ahostmask_29">add_gline</a>(<a class="code" href="commands_8h.html#duration_28const_20char_20_2Astr_29">duration</a>, source.c_str(), reason.c_str(), hostmask.c_str());
597 <a name="l00638"></a>00638 }
598 </pre></div>
599 <p>
600     </td>
601   </tr>
602 </table>
603 <a class="anchor" name="AddKLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29"></a><!-- doxytag: member="Server::AddKLine" ref="AddKLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20hostmask_29" args="(long duration, std::string source, std::string reason, std::string hostmask)" --><p>
604 <table class="mdTable" cellpadding="2" cellspacing="0">
605   <tr>
606     <td class="mdRow">
607       <table cellpadding="0" cellspacing="0" border="0">
608         <tr>
609           <td class="md" nowrap valign="top">void Server::AddKLine           </td>
610           <td class="md" valign="top">(&nbsp;</td>
611           <td class="md" nowrap valign="top">long&nbsp;</td>
612           <td class="mdname" nowrap> <em>duration</em>, </td>
613         </tr>
614         <tr>
615           <td class="md" nowrap align="right"></td>
616           <td class="md"></td>
617           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
618           <td class="mdname" nowrap> <em>source</em>, </td>
619         </tr>
620         <tr>
621           <td class="md" nowrap align="right"></td>
622           <td class="md"></td>
623           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
624           <td class="mdname" nowrap> <em>reason</em>, </td>
625         </tr>
626         <tr>
627           <td class="md" nowrap align="right"></td>
628           <td class="md"></td>
629           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
630           <td class="mdname" nowrap> <em>hostmask</em></td>
631         </tr>
632         <tr>
633           <td class="md"></td>
634           <td class="md">)&nbsp;</td>
635           <td class="md" colspan="2"><code> [virtual]</code></td>
636         </tr>
637       </table>
638     </td>
639   </tr>
640 </table>
641 <table cellspacing="5" cellpadding="0" border="0">
642   <tr>
643     <td>
644       &nbsp;
645     </td>
646     <td>
647
648 <p>
649 Adds a K-line The K-line is enforced as soon as it is added. 
650 <p>
651 The duration must be in seconds, however you can use the <a class="el" href="classServer.html#CalcDuration_28std_3A_3Astring_20duration_29">Server::CalcDuration</a> method to convert durations into the 1w2d3h3m6s format used by /GLINE etc. The source is an arbitary string used to indicate who or what sent the data, usually this is the nickname of a person, or a server name.
652 <p>
653 Definition at line <a class="el" href="modules_8cpp-source.html#l00650">650</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
654 <p>
655 References <a class="el" href="xline_8h.html#add_5Fkline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Ahostmask_29">add_kline()</a>.<div class="fragment"><pre class="fragment"><a name="l00651"></a>00651 {
656 <a name="l00652"></a>00652         <a class="code" href="xline_8h.html#add_5Fkline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Ahostmask_29">add_kline</a>(<a class="code" href="commands_8h.html#duration_28const_20char_20_2Astr_29">duration</a>, source.c_str(), reason.c_str(), hostmask.c_str());
657 <a name="l00653"></a>00653 }
658 </pre></div>
659 <p>
660     </td>
661   </tr>
662 </table>
663 <a class="anchor" name="AddQLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20nickname_29"></a><!-- doxytag: member="Server::AddQLine" ref="AddQLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20nickname_29" args="(long duration, std::string source, std::string reason, std::string nickname)" --><p>
664 <table class="mdTable" cellpadding="2" cellspacing="0">
665   <tr>
666     <td class="mdRow">
667       <table cellpadding="0" cellspacing="0" border="0">
668         <tr>
669           <td class="md" nowrap valign="top">void Server::AddQLine           </td>
670           <td class="md" valign="top">(&nbsp;</td>
671           <td class="md" nowrap valign="top">long&nbsp;</td>
672           <td class="mdname" nowrap> <em>duration</em>, </td>
673         </tr>
674         <tr>
675           <td class="md" nowrap align="right"></td>
676           <td class="md"></td>
677           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
678           <td class="mdname" nowrap> <em>source</em>, </td>
679         </tr>
680         <tr>
681           <td class="md" nowrap align="right"></td>
682           <td class="md"></td>
683           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
684           <td class="mdname" nowrap> <em>reason</em>, </td>
685         </tr>
686         <tr>
687           <td class="md" nowrap align="right"></td>
688           <td class="md"></td>
689           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
690           <td class="mdname" nowrap> <em>nickname</em></td>
691         </tr>
692         <tr>
693           <td class="md"></td>
694           <td class="md">)&nbsp;</td>
695           <td class="md" colspan="2"><code> [virtual]</code></td>
696         </tr>
697       </table>
698     </td>
699   </tr>
700 </table>
701 <table cellspacing="5" cellpadding="0" border="0">
702   <tr>
703     <td>
704       &nbsp;
705     </td>
706     <td>
707
708 <p>
709 Adds a Q-line The Q-line is propogated to all of the servers in the mesh and enforced as soon as it is added. 
710 <p>
711 The duration must be in seconds, however you can use the <a class="el" href="classServer.html#CalcDuration_28std_3A_3Astring_20duration_29">Server::CalcDuration</a> method to convert durations into the 1w2d3h3m6s format used by /GLINE etc. The source is an arbitary string used to indicate who or what sent the data, usually this is the nickname of a person, or a server name.
712 <p>
713 Definition at line <a class="el" href="modules_8cpp-source.html#l00640">640</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
714 <p>
715 References <a class="el" href="xline_8h.html#add_5Fqline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Anickname_29">add_qline()</a>.<div class="fragment"><pre class="fragment"><a name="l00641"></a>00641 {
716 <a name="l00642"></a>00642         <a class="code" href="xline_8h.html#add_5Fqline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Anickname_29">add_qline</a>(<a class="code" href="commands_8h.html#duration_28const_20char_20_2Astr_29">duration</a>, source.c_str(), reason.c_str(), nickname.c_str());
717 <a name="l00643"></a>00643 }
718 </pre></div>
719 <p>
720     </td>
721   </tr>
722 </table>
723 <a class="anchor" name="AddSocket_28InspSocket_20_2Asock_29"></a><!-- doxytag: member="Server::AddSocket" ref="AddSocket_28InspSocket_20_2Asock_29" args="(InspSocket *sock)" --><p>
724 <table class="mdTable" cellpadding="2" cellspacing="0">
725   <tr>
726     <td class="mdRow">
727       <table cellpadding="0" cellspacing="0" border="0">
728         <tr>
729           <td class="md" nowrap valign="top">void Server::AddSocket           </td>
730           <td class="md" valign="top">(&nbsp;</td>
731           <td class="md" nowrap valign="top"><a class="el" href="classInspSocket.html">InspSocket</a> *&nbsp;</td>
732           <td class="mdname1" valign="top" nowrap> <em>sock</em>          </td>
733           <td class="md" valign="top">&nbsp;)&nbsp;</td>
734           <td class="md" nowrap><code> [virtual]</code></td>
735         </tr>
736       </table>
737     </td>
738   </tr>
739 </table>
740 <table cellspacing="5" cellpadding="0" border="0">
741   <tr>
742     <td>
743       &nbsp;
744     </td>
745     <td>
746
747 <p>
748 Adds a class derived from <a class="el" href="classInspSocket.html">InspSocket</a> to the server's socket engine. 
749 <p>
750
751 <p>
752 Definition at line <a class="el" href="modules_8cpp-source.html#l00313">313</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
753 <p>
754 References <a class="el" href="modules_8cpp.html#module_5Fsockets">module_sockets</a>.<div class="fragment"><pre class="fragment"><a name="l00314"></a>00314 {
755 <a name="l00315"></a>00315         <a class="code" href="modules_8cpp.html#module_5Fsockets">module_sockets</a>.push_back(sock);
756 <a name="l00316"></a>00316 }
757 </pre></div>
758 <p>
759     </td>
760   </tr>
761 </table>
762 <a class="anchor" name="AddZLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20ipaddr_29"></a><!-- doxytag: member="Server::AddZLine" ref="AddZLine_28long_20duration_2C_20std_3A_3Astring_20source_2C_20std_3A_3Astring_20reason_2C_20std_3A_3Astring_20ipaddr_29" args="(long duration, std::string source, std::string reason, std::string ipaddr)" --><p>
763 <table class="mdTable" cellpadding="2" cellspacing="0">
764   <tr>
765     <td class="mdRow">
766       <table cellpadding="0" cellspacing="0" border="0">
767         <tr>
768           <td class="md" nowrap valign="top">void Server::AddZLine           </td>
769           <td class="md" valign="top">(&nbsp;</td>
770           <td class="md" nowrap valign="top">long&nbsp;</td>
771           <td class="mdname" nowrap> <em>duration</em>, </td>
772         </tr>
773         <tr>
774           <td class="md" nowrap align="right"></td>
775           <td class="md"></td>
776           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
777           <td class="mdname" nowrap> <em>source</em>, </td>
778         </tr>
779         <tr>
780           <td class="md" nowrap align="right"></td>
781           <td class="md"></td>
782           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
783           <td class="mdname" nowrap> <em>reason</em>, </td>
784         </tr>
785         <tr>
786           <td class="md" nowrap align="right"></td>
787           <td class="md"></td>
788           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
789           <td class="mdname" nowrap> <em>ipaddr</em></td>
790         </tr>
791         <tr>
792           <td class="md"></td>
793           <td class="md">)&nbsp;</td>
794           <td class="md" colspan="2"><code> [virtual]</code></td>
795         </tr>
796       </table>
797     </td>
798   </tr>
799 </table>
800 <table cellspacing="5" cellpadding="0" border="0">
801   <tr>
802     <td>
803       &nbsp;
804     </td>
805     <td>
806
807 <p>
808 Adds a Z-line The Z-line is propogated to all of the servers in the mesh and enforced as soon as it is added. 
809 <p>
810 The duration must be in seconds, however you can use the <a class="el" href="classServer.html#CalcDuration_28std_3A_3Astring_20duration_29">Server::CalcDuration</a> method to convert durations into the 1w2d3h3m6s format used by /GLINE etc. The source is an arbitary string used to indicate who or what sent the data, usually this is the nickname of a person, or a server name.
811 <p>
812 Definition at line <a class="el" href="modules_8cpp-source.html#l00645">645</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
813 <p>
814 References <a class="el" href="xline_8h.html#add_5Fzline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Aipaddr_29">add_zline()</a>.<div class="fragment"><pre class="fragment"><a name="l00646"></a>00646 {
815 <a name="l00647"></a>00647         <a class="code" href="xline_8h.html#add_5Fzline_28long_20duration_2C_20const_20char_20_2Asource_2C_20const_20char_20_2Areason_2C_20const_20char_20_2Aipaddr_29">add_zline</a>(<a class="code" href="commands_8h.html#duration_28const_20char_20_2Astr_29">duration</a>, source.c_str(), reason.c_str(), ipaddr.c_str());
816 <a name="l00648"></a>00648 }
817 </pre></div>
818 <p>
819     </td>
820   </tr>
821 </table>
822 <a class="anchor" name="CalcDuration_28std_3A_3Astring_20duration_29"></a><!-- doxytag: member="Server::CalcDuration" ref="CalcDuration_28std_3A_3Astring_20duration_29" args="(std::string duration)" --><p>
823 <table class="mdTable" cellpadding="2" cellspacing="0">
824   <tr>
825     <td class="mdRow">
826       <table cellpadding="0" cellspacing="0" border="0">
827         <tr>
828           <td class="md" nowrap valign="top">long Server::CalcDuration           </td>
829           <td class="md" valign="top">(&nbsp;</td>
830           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
831           <td class="mdname1" valign="top" nowrap> <em>duration</em>          </td>
832           <td class="md" valign="top">&nbsp;)&nbsp;</td>
833           <td class="md" nowrap><code> [virtual]</code></td>
834         </tr>
835       </table>
836     </td>
837   </tr>
838 </table>
839 <table cellspacing="5" cellpadding="0" border="0">
840   <tr>
841     <td>
842       &nbsp;
843     </td>
844     <td>
845
846 <p>
847 Calculates a duration This method will take a string containing a formatted duration (e.g. 
848 <p>
849 "1w2d") and return its value as a total number of seconds. This is the same function used internally by /GLINE etc to set the ban times.
850 <p>
851 Definition at line <a class="el" href="modules_8cpp-source.html#l00685">685</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
852 <p>
853 References <a class="el" href="commands_8h.html#duration_28const_20char_20_2Astr_29">duration()</a>.<div class="fragment"><pre class="fragment"><a name="l00686"></a>00686 {
854 <a name="l00687"></a>00687         <span class="keywordflow">return</span> <a class="code" href="commands_8h.html#duration_28const_20char_20_2Astr_29">duration</a>(delta.c_str());
855 <a name="l00688"></a>00688 }
856 </pre></div>
857 <p>
858     </td>
859   </tr>
860 </table>
861 <a class="anchor" name="CallCommandHandler_28std_3A_3Astring_20commandname_2C_20char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29"></a><!-- doxytag: member="Server::CallCommandHandler" ref="CallCommandHandler_28std_3A_3Astring_20commandname_2C_20char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29" args="(std::string commandname, char **parameters, int pcnt, userrec *user)" --><p>
862 <table class="mdTable" cellpadding="2" cellspacing="0">
863   <tr>
864     <td class="mdRow">
865       <table cellpadding="0" cellspacing="0" border="0">
866         <tr>
867           <td class="md" nowrap valign="top">void Server::CallCommandHandler           </td>
868           <td class="md" valign="top">(&nbsp;</td>
869           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
870           <td class="mdname" nowrap> <em>commandname</em>, </td>
871         </tr>
872         <tr>
873           <td class="md" nowrap align="right"></td>
874           <td class="md"></td>
875           <td class="md" nowrap>char **&nbsp;</td>
876           <td class="mdname" nowrap> <em>parameters</em>, </td>
877         </tr>
878         <tr>
879           <td class="md" nowrap align="right"></td>
880           <td class="md"></td>
881           <td class="md" nowrap>int&nbsp;</td>
882           <td class="mdname" nowrap> <em>pcnt</em>, </td>
883         </tr>
884         <tr>
885           <td class="md" nowrap align="right"></td>
886           <td class="md"></td>
887           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
888           <td class="mdname" nowrap> <em>user</em></td>
889         </tr>
890         <tr>
891           <td class="md"></td>
892           <td class="md">)&nbsp;</td>
893           <td class="md" colspan="2"><code> [virtual]</code></td>
894         </tr>
895       </table>
896     </td>
897   </tr>
898 </table>
899 <table cellspacing="5" cellpadding="0" border="0">
900   <tr>
901     <td>
902       &nbsp;
903     </td>
904     <td>
905
906 <p>
907 Calls the handler for a command, either implemented by the core or by another module. 
908 <p>
909 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 <br>
910 ) 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 <a class="el" href="classServer.html#AddCommand_28char_20_2Acmd_2C_20handlerfunc_20f_2C_20char_20flags_2C_20int_20minparams_2C_20char_20_2Asource_29">AddCommand()</a>. 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.
911 <p>
912 Definition at line <a class="el" href="modules_8cpp-source.html#l00396">396</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
913 <p>
914 References <a class="el" href="inspircd_8h.html#call_5Fhandler_28const_20char_20_2Acommandname_2C_20char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">call_handler()</a>.<div class="fragment"><pre class="fragment"><a name="l00397"></a>00397 {
915 <a name="l00398"></a>00398         <a class="code" href="inspircd_8h.html#call_5Fhandler_28const_20char_20_2Acommandname_2C_20char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">call_handler</a>(commandname.c_str(),parameters,pcnt,user);
916 <a name="l00399"></a>00399 }
917 </pre></div>
918 <p>
919     </td>
920   </tr>
921 </table>
922 <a class="anchor" name="ChangeGECOS_28userrec_20_2Auser_2C_20std_3A_3Astring_20gecos_29"></a><!-- doxytag: member="Server::ChangeGECOS" ref="ChangeGECOS_28userrec_20_2Auser_2C_20std_3A_3Astring_20gecos_29" args="(userrec *user, std::string gecos)" --><p>
923 <table class="mdTable" cellpadding="2" cellspacing="0">
924   <tr>
925     <td class="mdRow">
926       <table cellpadding="0" cellspacing="0" border="0">
927         <tr>
928           <td class="md" nowrap valign="top">void Server::ChangeGECOS           </td>
929           <td class="md" valign="top">(&nbsp;</td>
930           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
931           <td class="mdname" nowrap> <em>user</em>, </td>
932         </tr>
933         <tr>
934           <td class="md" nowrap align="right"></td>
935           <td class="md"></td>
936           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
937           <td class="mdname" nowrap> <em>gecos</em></td>
938         </tr>
939         <tr>
940           <td class="md"></td>
941           <td class="md">)&nbsp;</td>
942           <td class="md" colspan="2"><code> [virtual]</code></td>
943         </tr>
944       </table>
945     </td>
946   </tr>
947 </table>
948 <table cellspacing="5" cellpadding="0" border="0">
949   <tr>
950     <td>
951       &nbsp;
952     </td>
953     <td>
954
955 <p>
956 Change GECOS (fullname) of a user. 
957 <p>
958 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.
959 <p>
960 Definition at line <a class="el" href="modules_8cpp-source.html#l00494">494</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
961 <p>
962 References <a class="el" href="message_8h.html#ChangeName_28userrec_20_2Auser_2C_20const_20char_20_2Agecos_29">ChangeName()</a>.<div class="fragment"><pre class="fragment"><a name="l00495"></a>00495 {
963 <a name="l00496"></a>00496         <a class="code" href="message_8h.html#ChangeName_28userrec_20_2Auser_2C_20const_20char_20_2Agecos_29">ChangeName</a>(user,gecos.c_str());
964 <a name="l00497"></a>00497 }
965 </pre></div>
966 <p>
967     </td>
968   </tr>
969 </table>
970 <a class="anchor" name="ChangeHost_28userrec_20_2Auser_2C_20std_3A_3Astring_20host_29"></a><!-- doxytag: member="Server::ChangeHost" ref="ChangeHost_28userrec_20_2Auser_2C_20std_3A_3Astring_20host_29" args="(userrec *user, std::string host)" --><p>
971 <table class="mdTable" cellpadding="2" cellspacing="0">
972   <tr>
973     <td class="mdRow">
974       <table cellpadding="0" cellspacing="0" border="0">
975         <tr>
976           <td class="md" nowrap valign="top">void Server::ChangeHost           </td>
977           <td class="md" valign="top">(&nbsp;</td>
978           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
979           <td class="mdname" nowrap> <em>user</em>, </td>
980         </tr>
981         <tr>
982           <td class="md" nowrap align="right"></td>
983           <td class="md"></td>
984           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
985           <td class="mdname" nowrap> <em>host</em></td>
986         </tr>
987         <tr>
988           <td class="md"></td>
989           <td class="md">)&nbsp;</td>
990           <td class="md" colspan="2"><code> [virtual]</code></td>
991         </tr>
992       </table>
993     </td>
994   </tr>
995 </table>
996 <table cellspacing="5" cellpadding="0" border="0">
997   <tr>
998     <td>
999       &nbsp;
1000     </td>
1001     <td>
1002
1003 <p>
1004 Change displayed hostname of a user. 
1005 <p>
1006 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.
1007 <p>
1008 Definition at line <a class="el" href="modules_8cpp-source.html#l00489">489</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1009 <p>
1010 References <a class="el" href="message_8h.html#ChangeDisplayedHost_28userrec_20_2Auser_2C_20const_20char_20_2Ahost_29">ChangeDisplayedHost()</a>.<div class="fragment"><pre class="fragment"><a name="l00490"></a>00490 {
1011 <a name="l00491"></a>00491         <a class="code" href="message_8h.html#ChangeDisplayedHost_28userrec_20_2Auser_2C_20const_20char_20_2Ahost_29">ChangeDisplayedHost</a>(user,host.c_str());
1012 <a name="l00492"></a>00492 }
1013 </pre></div>
1014 <p>
1015     </td>
1016   </tr>
1017 </table>
1018 <a class="anchor" name="ChangeUserNick_28userrec_20_2Auser_2C_20std_3A_3Astring_20nickname_29"></a><!-- doxytag: member="Server::ChangeUserNick" ref="ChangeUserNick_28userrec_20_2Auser_2C_20std_3A_3Astring_20nickname_29" args="(userrec *user, std::string nickname)" --><p>
1019 <table class="mdTable" cellpadding="2" cellspacing="0">
1020   <tr>
1021     <td class="mdRow">
1022       <table cellpadding="0" cellspacing="0" border="0">
1023         <tr>
1024           <td class="md" nowrap valign="top">void Server::ChangeUserNick           </td>
1025           <td class="md" valign="top">(&nbsp;</td>
1026           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1027           <td class="mdname" nowrap> <em>user</em>, </td>
1028         </tr>
1029         <tr>
1030           <td class="md" nowrap align="right"></td>
1031           <td class="md"></td>
1032           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1033           <td class="mdname" nowrap> <em>nickname</em></td>
1034         </tr>
1035         <tr>
1036           <td class="md"></td>
1037           <td class="md">)&nbsp;</td>
1038           <td class="md" colspan="2"><code> [virtual]</code></td>
1039         </tr>
1040       </table>
1041     </td>
1042   </tr>
1043 </table>
1044 <table cellspacing="5" cellpadding="0" border="0">
1045   <tr>
1046     <td>
1047       &nbsp;
1048     </td>
1049     <td>
1050
1051 <p>
1052 Forces a user nickchange. 
1053 <p>
1054 This command works similarly to SVSNICK, and can be used to implement Q-lines etc. If you specify an invalid nickname, the nick change will be dropped and the target user will receive the error numeric for it.
1055 <p>
1056 Definition at line <a class="el" href="modules_8cpp-source.html#l00381">381</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1057 <p>
1058 References <a class="el" href="inspircd_8h.html#force_5Fnickchange_28userrec_20_2Auser_2C_20const_20char_20_2Anewnick_29">force_nickchange()</a>.<div class="fragment"><pre class="fragment"><a name="l00382"></a>00382 {
1059 <a name="l00383"></a>00383         <a class="code" href="inspircd_8h.html#force_5Fnickchange_28userrec_20_2Auser_2C_20const_20char_20_2Anewnick_29">force_nickchange</a>(user,nickname.c_str());
1060 <a name="l00384"></a>00384 }
1061 </pre></div>
1062 <p>
1063     </td>
1064   </tr>
1065 </table>
1066 <a class="anchor" name="ChanMode_28userrec_20_2AUser_2C_20chanrec_20_2AChan_29"></a><!-- doxytag: member="Server::ChanMode" ref="ChanMode_28userrec_20_2AUser_2C_20chanrec_20_2AChan_29" args="(userrec *User, chanrec *Chan)" --><p>
1067 <table class="mdTable" cellpadding="2" cellspacing="0">
1068   <tr>
1069     <td class="mdRow">
1070       <table cellpadding="0" cellspacing="0" border="0">
1071         <tr>
1072           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a> Server::ChanMode           </td>
1073           <td class="md" valign="top">(&nbsp;</td>
1074           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1075           <td class="mdname" nowrap> <em>User</em>, </td>
1076         </tr>
1077         <tr>
1078           <td class="md" nowrap align="right"></td>
1079           <td class="md"></td>
1080           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
1081           <td class="mdname" nowrap> <em>Chan</em></td>
1082         </tr>
1083         <tr>
1084           <td class="md"></td>
1085           <td class="md">)&nbsp;</td>
1086           <td class="md" colspan="2"><code> [virtual]</code></td>
1087         </tr>
1088       </table>
1089     </td>
1090   </tr>
1091 </table>
1092 <table cellspacing="5" cellpadding="0" border="0">
1093   <tr>
1094     <td>
1095       &nbsp;
1096     </td>
1097     <td>
1098
1099 <p>
1100 Attempts to look up a user's privilages on a channel. 
1101 <p>
1102 This function will return a string containing either @, %, +, or an empty string, representing the user's privilages upon the channel you specify.
1103 <p>
1104 Definition at line <a class="el" href="modules_8cpp-source.html#l00519">519</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1105 <p>
1106 References <a class="el" href="globals_8h.html#cmode_28userrec_20_2Auser_2C_20chanrec_20_2Achan_29">cmode()</a>.<div class="fragment"><pre class="fragment"><a name="l00520"></a>00520 {
1107 <a name="l00521"></a>00521         <span class="keywordflow">return</span> <a class="code" href="globals_8h.html#cmode_28userrec_20_2Auser_2C_20chanrec_20_2Achan_29">cmode</a>(User,Chan);
1108 <a name="l00522"></a>00522 }
1109 </pre></div>
1110 <p>
1111     </td>
1112   </tr>
1113 </table>
1114 <a class="anchor" name="CommonChannels_28userrec_20_2Au_31_2C_20userrec_20_2Au_32_29"></a><!-- doxytag: member="Server::CommonChannels" ref="CommonChannels_28userrec_20_2Au_31_2C_20userrec_20_2Au_32_29" args="(userrec *u1, userrec *u2)" --><p>
1115 <table class="mdTable" cellpadding="2" cellspacing="0">
1116   <tr>
1117     <td class="mdRow">
1118       <table cellpadding="0" cellspacing="0" border="0">
1119         <tr>
1120           <td class="md" nowrap valign="top">bool Server::CommonChannels           </td>
1121           <td class="md" valign="top">(&nbsp;</td>
1122           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1123           <td class="mdname" nowrap> <em>u1</em>, </td>
1124         </tr>
1125         <tr>
1126           <td class="md" nowrap align="right"></td>
1127           <td class="md"></td>
1128           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1129           <td class="mdname" nowrap> <em>u2</em></td>
1130         </tr>
1131         <tr>
1132           <td class="md"></td>
1133           <td class="md">)&nbsp;</td>
1134           <td class="md" colspan="2"><code> [virtual]</code></td>
1135         </tr>
1136       </table>
1137     </td>
1138   </tr>
1139 </table>
1140 <table cellspacing="5" cellpadding="0" border="0">
1141   <tr>
1142     <td>
1143       &nbsp;
1144     </td>
1145     <td>
1146
1147 <p>
1148 Returns true if two users share a common channel. 
1149 <p>
1150 This method is used internally by the NICK and QUIT commands, and the <a class="el" href="classServer.html#SendCommon_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_2C_20bool_20IncludeSender_29">Server::SendCommon</a> method.
1151 <p>
1152 Definition at line <a class="el" href="modules_8cpp-source.html#l00467">467</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1153 <p>
1154 References <a class="el" href="globals_8h.html#common_5Fchannels_28userrec_20_2Au_2C_20userrec_20_2Au_32_29">common_channels()</a>.<div class="fragment"><pre class="fragment"><a name="l00468"></a>00468 {
1155 <a name="l00469"></a>00469         <span class="keywordflow">return</span> (<a class="code" href="globals_8h.html#common_5Fchannels_28userrec_20_2Au_2C_20userrec_20_2Au_32_29">common_channels</a>(u1,u2) != 0);
1156 <a name="l00470"></a>00470 }
1157 </pre></div>
1158 <p>
1159     </td>
1160   </tr>
1161 </table>
1162 <a class="anchor" name="CountUsers_28chanrec_20_2Ac_29"></a><!-- doxytag: member="Server::CountUsers" ref="CountUsers_28chanrec_20_2Ac_29" args="(chanrec *c)" --><p>
1163 <table class="mdTable" cellpadding="2" cellspacing="0">
1164   <tr>
1165     <td class="mdRow">
1166       <table cellpadding="0" cellspacing="0" border="0">
1167         <tr>
1168           <td class="md" nowrap valign="top">int Server::CountUsers           </td>
1169           <td class="md" valign="top">(&nbsp;</td>
1170           <td class="md" nowrap valign="top"><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
1171           <td class="mdname1" valign="top" nowrap> <em>c</em>          </td>
1172           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1173           <td class="md" nowrap><code> [virtual]</code></td>
1174         </tr>
1175       </table>
1176     </td>
1177   </tr>
1178 </table>
1179 <table cellspacing="5" cellpadding="0" border="0">
1180   <tr>
1181     <td>
1182       &nbsp;
1183     </td>
1184     <td>
1185
1186 <p>
1187 Returns a count of the number of users on a channel. 
1188 <p>
1189 This will NEVER be 0, as if the chanrec exists, it will have at least one user in the channel.
1190 <p>
1191 Definition at line <a class="el" href="modules_8cpp-source.html#l00587">587</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00588"></a>00588 {
1192 <a name="l00589"></a>00589         <span class="keywordflow">return</span> usercount(c);
1193 <a name="l00590"></a>00590 }
1194 </pre></div>
1195 <p>
1196     </td>
1197   </tr>
1198 </table>
1199 <a class="anchor" name="DelELine_28std_3A_3Astring_20hostmask_29"></a><!-- doxytag: member="Server::DelELine" ref="DelELine_28std_3A_3Astring_20hostmask_29" args="(std::string hostmask)" --><p>
1200 <table class="mdTable" cellpadding="2" cellspacing="0">
1201   <tr>
1202     <td class="mdRow">
1203       <table cellpadding="0" cellspacing="0" border="0">
1204         <tr>
1205           <td class="md" nowrap valign="top">bool Server::DelELine           </td>
1206           <td class="md" valign="top">(&nbsp;</td>
1207           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1208           <td class="mdname1" valign="top" nowrap> <em>hostmask</em>          </td>
1209           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1210           <td class="md" nowrap><code> [virtual]</code></td>
1211         </tr>
1212       </table>
1213     </td>
1214   </tr>
1215 </table>
1216 <table cellspacing="5" cellpadding="0" border="0">
1217   <tr>
1218     <td>
1219       &nbsp;
1220     </td>
1221     <td>
1222
1223 <p>
1224 Deletes a local E-Line. 
1225 <p>
1226
1227 <p>
1228 Definition at line <a class="el" href="modules_8cpp-source.html#l00680">680</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1229 <p>
1230 References <a class="el" href="xline_8h.html#del_5Feline_28const_20char_20_2Ahostmask_29">del_eline()</a>.<div class="fragment"><pre class="fragment"><a name="l00681"></a>00681 {
1231 <a name="l00682"></a>00682         <span class="keywordflow">return</span> <a class="code" href="xline_8h.html#del_5Feline_28const_20char_20_2Ahostmask_29">del_eline</a>(hostmask.c_str());
1232 <a name="l00683"></a>00683 }
1233 </pre></div>
1234 <p>
1235     </td>
1236   </tr>
1237 </table>
1238 <a class="anchor" name="DelGLine_28std_3A_3Astring_20hostmask_29"></a><!-- doxytag: member="Server::DelGLine" ref="DelGLine_28std_3A_3Astring_20hostmask_29" args="(std::string hostmask)" --><p>
1239 <table class="mdTable" cellpadding="2" cellspacing="0">
1240   <tr>
1241     <td class="mdRow">
1242       <table cellpadding="0" cellspacing="0" border="0">
1243         <tr>
1244           <td class="md" nowrap valign="top">bool Server::DelGLine           </td>
1245           <td class="md" valign="top">(&nbsp;</td>
1246           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1247           <td class="mdname1" valign="top" nowrap> <em>hostmask</em>          </td>
1248           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1249           <td class="md" nowrap><code> [virtual]</code></td>
1250         </tr>
1251       </table>
1252     </td>
1253   </tr>
1254 </table>
1255 <table cellspacing="5" cellpadding="0" border="0">
1256   <tr>
1257     <td>
1258       &nbsp;
1259     </td>
1260     <td>
1261
1262 <p>
1263 Deletes a G-Line from all servers on the mesh. 
1264 <p>
1265
1266 <p>
1267 Definition at line <a class="el" href="modules_8cpp-source.html#l00660">660</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1268 <p>
1269 References <a class="el" href="xline_8h.html#del_5Fgline_28const_20char_20_2Ahostmask_29">del_gline()</a>.<div class="fragment"><pre class="fragment"><a name="l00661"></a>00661 {
1270 <a name="l00662"></a>00662         <span class="keywordflow">return</span> <a class="code" href="xline_8h.html#del_5Fgline_28const_20char_20_2Ahostmask_29">del_gline</a>(hostmask.c_str());
1271 <a name="l00663"></a>00663 }
1272 </pre></div>
1273 <p>
1274     </td>
1275   </tr>
1276 </table>
1277 <a class="anchor" name="DelKLine_28std_3A_3Astring_20hostmask_29"></a><!-- doxytag: member="Server::DelKLine" ref="DelKLine_28std_3A_3Astring_20hostmask_29" args="(std::string hostmask)" --><p>
1278 <table class="mdTable" cellpadding="2" cellspacing="0">
1279   <tr>
1280     <td class="mdRow">
1281       <table cellpadding="0" cellspacing="0" border="0">
1282         <tr>
1283           <td class="md" nowrap valign="top">bool Server::DelKLine           </td>
1284           <td class="md" valign="top">(&nbsp;</td>
1285           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1286           <td class="mdname1" valign="top" nowrap> <em>hostmask</em>          </td>
1287           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1288           <td class="md" nowrap><code> [virtual]</code></td>
1289         </tr>
1290       </table>
1291     </td>
1292   </tr>
1293 </table>
1294 <table cellspacing="5" cellpadding="0" border="0">
1295   <tr>
1296     <td>
1297       &nbsp;
1298     </td>
1299     <td>
1300
1301 <p>
1302 Deletes a local K-Line. 
1303 <p>
1304
1305 <p>
1306 Definition at line <a class="el" href="modules_8cpp-source.html#l00675">675</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1307 <p>
1308 References <a class="el" href="xline_8h.html#del_5Fkline_28const_20char_20_2Ahostmask_29">del_kline()</a>.<div class="fragment"><pre class="fragment"><a name="l00676"></a>00676 {
1309 <a name="l00677"></a>00677         <span class="keywordflow">return</span> <a class="code" href="xline_8h.html#del_5Fkline_28const_20char_20_2Ahostmask_29">del_kline</a>(hostmask.c_str());
1310 <a name="l00678"></a>00678 }
1311 </pre></div>
1312 <p>
1313     </td>
1314   </tr>
1315 </table>
1316 <a class="anchor" name="DelQLine_28std_3A_3Astring_20nickname_29"></a><!-- doxytag: member="Server::DelQLine" ref="DelQLine_28std_3A_3Astring_20nickname_29" args="(std::string nickname)" --><p>
1317 <table class="mdTable" cellpadding="2" cellspacing="0">
1318   <tr>
1319     <td class="mdRow">
1320       <table cellpadding="0" cellspacing="0" border="0">
1321         <tr>
1322           <td class="md" nowrap valign="top">bool Server::DelQLine           </td>
1323           <td class="md" valign="top">(&nbsp;</td>
1324           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1325           <td class="mdname1" valign="top" nowrap> <em>nickname</em>          </td>
1326           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1327           <td class="md" nowrap><code> [virtual]</code></td>
1328         </tr>
1329       </table>
1330     </td>
1331   </tr>
1332 </table>
1333 <table cellspacing="5" cellpadding="0" border="0">
1334   <tr>
1335     <td>
1336       &nbsp;
1337     </td>
1338     <td>
1339
1340 <p>
1341 Deletes a Q-Line from all servers on the mesh. 
1342 <p>
1343
1344 <p>
1345 Definition at line <a class="el" href="modules_8cpp-source.html#l00665">665</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1346 <p>
1347 References <a class="el" href="xline_8h.html#del_5Fqline_28const_20char_20_2Anickname_29">del_qline()</a>.<div class="fragment"><pre class="fragment"><a name="l00666"></a>00666 {
1348 <a name="l00667"></a>00667         <span class="keywordflow">return</span> <a class="code" href="xline_8h.html#del_5Fqline_28const_20char_20_2Anickname_29">del_qline</a>(nickname.c_str());
1349 <a name="l00668"></a>00668 }
1350 </pre></div>
1351 <p>
1352     </td>
1353   </tr>
1354 </table>
1355 <a class="anchor" name="DelSocket_28InspSocket_20_2Asock_29"></a><!-- doxytag: member="Server::DelSocket" ref="DelSocket_28InspSocket_20_2Asock_29" args="(InspSocket *sock)" --><p>
1356 <table class="mdTable" cellpadding="2" cellspacing="0">
1357   <tr>
1358     <td class="mdRow">
1359       <table cellpadding="0" cellspacing="0" border="0">
1360         <tr>
1361           <td class="md" nowrap valign="top">void Server::DelSocket           </td>
1362           <td class="md" valign="top">(&nbsp;</td>
1363           <td class="md" nowrap valign="top"><a class="el" href="classInspSocket.html">InspSocket</a> *&nbsp;</td>
1364           <td class="mdname1" valign="top" nowrap> <em>sock</em>          </td>
1365           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1366           <td class="md" nowrap><code> [virtual]</code></td>
1367         </tr>
1368       </table>
1369     </td>
1370   </tr>
1371 </table>
1372 <table cellspacing="5" cellpadding="0" border="0">
1373   <tr>
1374     <td>
1375       &nbsp;
1376     </td>
1377     <td>
1378
1379 <p>
1380 Deletes a class derived from <a class="el" href="classInspSocket.html">InspSocket</a> from the server's socket engine. 
1381 <p>
1382
1383 <p>
1384 Definition at line <a class="el" href="modules_8cpp-source.html#l00329">329</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1385 <p>
1386 References <a class="el" href="modules_8cpp.html#module_5Fsockets">module_sockets</a>.<div class="fragment"><pre class="fragment"><a name="l00330"></a>00330 {
1387 <a name="l00331"></a>00331         <span class="keywordflow">for</span> (std::vector&lt;InspSocket*&gt;::iterator a = <a class="code" href="modules_8cpp.html#module_5Fsockets">module_sockets</a>.begin(); a &lt; <a class="code" href="modules_8cpp.html#module_5Fsockets">module_sockets</a>.end(); a++)
1388 <a name="l00332"></a>00332         {
1389 <a name="l00333"></a>00333                 <span class="keywordflow">if</span> (*a == sock)
1390 <a name="l00334"></a>00334                 {
1391 <a name="l00335"></a>00335                         <a class="code" href="modules_8cpp.html#module_5Fsockets">module_sockets</a>.erase(a);
1392 <a name="l00336"></a>00336                         <span class="keywordflow">return</span>;
1393 <a name="l00337"></a>00337                 }
1394 <a name="l00338"></a>00338         }
1395 <a name="l00339"></a>00339 }
1396 </pre></div>
1397 <p>
1398     </td>
1399   </tr>
1400 </table>
1401 <a class="anchor" name="DelZLine_28std_3A_3Astring_20ipaddr_29"></a><!-- doxytag: member="Server::DelZLine" ref="DelZLine_28std_3A_3Astring_20ipaddr_29" args="(std::string ipaddr)" --><p>
1402 <table class="mdTable" cellpadding="2" cellspacing="0">
1403   <tr>
1404     <td class="mdRow">
1405       <table cellpadding="0" cellspacing="0" border="0">
1406         <tr>
1407           <td class="md" nowrap valign="top">bool Server::DelZLine           </td>
1408           <td class="md" valign="top">(&nbsp;</td>
1409           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1410           <td class="mdname1" valign="top" nowrap> <em>ipaddr</em>          </td>
1411           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1412           <td class="md" nowrap><code> [virtual]</code></td>
1413         </tr>
1414       </table>
1415     </td>
1416   </tr>
1417 </table>
1418 <table cellspacing="5" cellpadding="0" border="0">
1419   <tr>
1420     <td>
1421       &nbsp;
1422     </td>
1423     <td>
1424
1425 <p>
1426 Deletes a Z-Line from all servers on the mesh. 
1427 <p>
1428
1429 <p>
1430 Definition at line <a class="el" href="modules_8cpp-source.html#l00670">670</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1431 <p>
1432 References <a class="el" href="xline_8h.html#del_5Fzline_28const_20char_20_2Aipaddr_29">del_zline()</a>.<div class="fragment"><pre class="fragment"><a name="l00671"></a>00671 {
1433 <a name="l00672"></a>00672         <span class="keywordflow">return</span> <a class="code" href="xline_8h.html#del_5Fzline_28const_20char_20_2Aipaddr_29">del_zline</a>(ipaddr.c_str());
1434 <a name="l00673"></a>00673 }
1435 </pre></div>
1436 <p>
1437     </td>
1438   </tr>
1439 </table>
1440 <a class="anchor" name="FindChannel_28std_3A_3Astring_20channel_29"></a><!-- doxytag: member="Server::FindChannel" ref="FindChannel_28std_3A_3Astring_20channel_29" args="(std::string channel)" --><p>
1441 <table class="mdTable" cellpadding="2" cellspacing="0">
1442   <tr>
1443     <td class="mdRow">
1444       <table cellpadding="0" cellspacing="0" border="0">
1445         <tr>
1446           <td class="md" nowrap valign="top"><a class="el" href="classchanrec.html">chanrec</a> * Server::FindChannel           </td>
1447           <td class="md" valign="top">(&nbsp;</td>
1448           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1449           <td class="mdname1" valign="top" nowrap> <em>channel</em>          </td>
1450           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1451           <td class="md" nowrap><code> [virtual]</code></td>
1452         </tr>
1453       </table>
1454     </td>
1455   </tr>
1456 </table>
1457 <table cellspacing="5" cellpadding="0" border="0">
1458   <tr>
1459     <td>
1460       &nbsp;
1461     </td>
1462     <td>
1463
1464 <p>
1465 Attempts to look up a channel and return a pointer to it. 
1466 <p>
1467 This function will return NULL if the channel does not exist.
1468 <p>
1469 Definition at line <a class="el" href="modules_8cpp-source.html#l00514">514</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1470 <p>
1471 References <a class="el" href="globals_8h.html#FindChan_28const_20char_20_2Achan_29">FindChan()</a>.<div class="fragment"><pre class="fragment"><a name="l00515"></a>00515 {
1472 <a name="l00516"></a>00516         <span class="keywordflow">return</span> <a class="code" href="globals_8h.html#FindChan_28const_20char_20_2Achan_29">FindChan</a>(channel.c_str());
1473 <a name="l00517"></a>00517 }
1474 </pre></div>
1475 <p>
1476     </td>
1477   </tr>
1478 </table>
1479 <a class="anchor" name="FindDescriptor_28int_20socket_29"></a><!-- doxytag: member="Server::FindDescriptor" ref="FindDescriptor_28int_20socket_29" args="(int socket)" --><p>
1480 <table class="mdTable" cellpadding="2" cellspacing="0">
1481   <tr>
1482     <td class="mdRow">
1483       <table cellpadding="0" cellspacing="0" border="0">
1484         <tr>
1485           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * Server::FindDescriptor           </td>
1486           <td class="md" valign="top">(&nbsp;</td>
1487           <td class="md" nowrap valign="top">int&nbsp;</td>
1488           <td class="mdname1" valign="top" nowrap> <em>socket</em>          </td>
1489           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1490           <td class="md" nowrap><code> [virtual]</code></td>
1491         </tr>
1492       </table>
1493     </td>
1494   </tr>
1495 </table>
1496 <table cellspacing="5" cellpadding="0" border="0">
1497   <tr>
1498     <td>
1499       &nbsp;
1500     </td>
1501     <td>
1502
1503 <p>
1504 Attempts to look up a nick using the file descriptor associated with that nick. 
1505 <p>
1506 This function will return NULL if the file descriptor is not associated with a valid user.
1507 <p>
1508 Definition at line <a class="el" href="modules_8cpp-source.html#l00509">509</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00510"></a>00510 {
1509 <a name="l00511"></a>00511         <span class="keywordflow">return</span> (socket &lt; 65536 ? fd_ref_table[socket] : NULL);
1510 <a name="l00512"></a>00512 }
1511 </pre></div>
1512 <p>
1513     </td>
1514   </tr>
1515 </table>
1516 <a class="anchor" name="FindModule_28std_3A_3Astring_20name_29"></a><!-- doxytag: member="Server::FindModule" ref="FindModule_28std_3A_3Astring_20name_29" args="(std::string name)" --><p>
1517 <table class="mdTable" cellpadding="2" cellspacing="0">
1518   <tr>
1519     <td class="mdRow">
1520       <table cellpadding="0" cellspacing="0" border="0">
1521         <tr>
1522           <td class="md" nowrap valign="top"><a class="el" href="classModule.html">Module</a> * Server::FindModule           </td>
1523           <td class="md" valign="top">(&nbsp;</td>
1524           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1525           <td class="mdname1" valign="top" nowrap> <em>name</em>          </td>
1526           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1527           <td class="md" nowrap><code> [virtual]</code></td>
1528         </tr>
1529       </table>
1530     </td>
1531   </tr>
1532 </table>
1533 <table cellspacing="5" cellpadding="0" border="0">
1534   <tr>
1535     <td>
1536       &nbsp;
1537     </td>
1538     <td>
1539
1540 <p>
1541 This function finds a module by name. 
1542 <p>
1543 You must provide the filename of the module. If the module cannot be found (is not loaded) the function will return NULL.
1544 <p>
1545 Definition at line <a class="el" href="modules_8cpp-source.html#l00719">719</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1546 <p>
1547 References <a class="el" href="modules_8cpp-source.html#l00930">MODCOUNT</a>, <a class="el" href="inspircd__io_8h-source.html#l00247">ServerConfig::module_names</a>, and <a class="el" href="channels_8cpp.html#modules">modules</a>.<div class="fragment"><pre class="fragment"><a name="l00720"></a>00720 {
1548 <a name="l00721"></a>00721         <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i &lt;= <a class="code" href="channels_8cpp.html#MODCOUNT">MODCOUNT</a>; i++)
1549 <a name="l00722"></a>00722         {
1550 <a name="l00723"></a>00723                 <span class="keywordflow">if</span> (<a class="code" href="channels_8cpp.html#Config">Config</a>-&gt;<a class="code" href="classServerConfig.html#module_5Fnames">module_names</a>[i] == name)
1551 <a name="l00724"></a>00724                 {
1552 <a name="l00725"></a>00725                         <span class="keywordflow">return</span> <a class="code" href="channels_8cpp.html#modules">modules</a>[i];
1553 <a name="l00726"></a>00726                 }
1554 <a name="l00727"></a>00727         }
1555 <a name="l00728"></a>00728         <span class="keywordflow">return</span> NULL;
1556 <a name="l00729"></a>00729 }
1557 </pre></div>
1558 <p>
1559     </td>
1560   </tr>
1561 </table>
1562 <a class="anchor" name="FindNick_28std_3A_3Astring_20nick_29"></a><!-- doxytag: member="Server::FindNick" ref="FindNick_28std_3A_3Astring_20nick_29" args="(std::string nick)" --><p>
1563 <table class="mdTable" cellpadding="2" cellspacing="0">
1564   <tr>
1565     <td class="mdRow">
1566       <table cellpadding="0" cellspacing="0" border="0">
1567         <tr>
1568           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * Server::FindNick           </td>
1569           <td class="md" valign="top">(&nbsp;</td>
1570           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1571           <td class="mdname1" valign="top" nowrap> <em>nick</em>          </td>
1572           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1573           <td class="md" nowrap><code> [virtual]</code></td>
1574         </tr>
1575       </table>
1576     </td>
1577   </tr>
1578 </table>
1579 <table cellspacing="5" cellpadding="0" border="0">
1580   <tr>
1581     <td>
1582       &nbsp;
1583     </td>
1584     <td>
1585
1586 <p>
1587 Attempts to look up a nick and return a pointer to it. 
1588 <p>
1589 This function will return NULL if the nick does not exist.
1590 <p>
1591 Definition at line <a class="el" href="modules_8cpp-source.html#l00504">504</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1592 <p>
1593 References <a class="el" href="globals_8h.html#Find_28std_3A_3Astring_20nick_29">Find()</a>.<div class="fragment"><pre class="fragment"><a name="l00505"></a>00505 {
1594 <a name="l00506"></a>00506         <span class="keywordflow">return</span> <a class="code" href="globals_8h.html#Find_28std_3A_3Astring_20nick_29">Find</a>(nick);
1595 <a name="l00507"></a>00507 }
1596 </pre></div>
1597 <p>
1598     </td>
1599   </tr>
1600 </table>
1601 <a class="anchor" name="GetAdmin_28_29"></a><!-- doxytag: member="Server::GetAdmin" ref="GetAdmin_28_29" args="()" --><p>
1602 <table class="mdTable" cellpadding="2" cellspacing="0">
1603   <tr>
1604     <td class="mdRow">
1605       <table cellpadding="0" cellspacing="0" border="0">
1606         <tr>
1607           <td class="md" nowrap valign="top"><a class="el" href="classAdmin.html">Admin</a> Server::GetAdmin           </td>
1608           <td class="md" valign="top">(&nbsp;</td>
1609           <td class="mdname1" valign="top" nowrap>          </td>
1610           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1611           <td class="md" nowrap><code> [virtual]</code></td>
1612         </tr>
1613       </table>
1614     </td>
1615   </tr>
1616 </table>
1617 <table cellspacing="5" cellpadding="0" border="0">
1618   <tr>
1619     <td>
1620       &nbsp;
1621     </td>
1622     <td>
1623
1624 <p>
1625 Returns the information of the server as returned by the /ADMIN command. 
1626 <p>
1627 See the <a class="el" href="classAdmin.html">Admin</a> class for further information of the return value. The members <a class="el" href="classAdmin.html#Nick">Admin::Nick</a>, <a class="el" href="classAdmin.html#Email">Admin::Email</a> and <a class="el" href="classAdmin.html#Name">Admin::Name</a> contain the information for the server where the module is loaded.
1628 <p>
1629 Definition at line <a class="el" href="modules_8cpp-source.html#l00544">544</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1630 <p>
1631 References <a class="el" href="inspircd__io_8h-source.html#l00089">ServerConfig::AdminEmail</a>, <a class="el" href="inspircd__io_8h-source.html#l00084">ServerConfig::AdminName</a>, and <a class="el" href="inspircd__io_8h-source.html#l00094">ServerConfig::AdminNick</a>.<div class="fragment"><pre class="fragment"><a name="l00545"></a>00545 {
1632 <a name="l00546"></a>00546         <span class="keywordflow">return</span> <a class="code" href="classAdmin.html">Admin</a>(<a class="code" href="channels_8cpp.html#Config">Config</a>-&gt;<a class="code" href="classServerConfig.html#AdminName_5BMAXBUF_5D">AdminName</a>,<a class="code" href="channels_8cpp.html#Config">Config</a>-&gt;<a class="code" href="classServerConfig.html#AdminEmail_5BMAXBUF_5D">AdminEmail</a>,<a class="code" href="channels_8cpp.html#Config">Config</a>-&gt;<a class="code" href="classServerConfig.html#AdminNick_5BMAXBUF_5D">AdminNick</a>);
1633 <a name="l00547"></a>00547 }
1634 </pre></div>
1635 <p>
1636     </td>
1637   </tr>
1638 </table>
1639 <a class="anchor" name="GetConfig_28_29"></a><!-- doxytag: member="Server::GetConfig" ref="GetConfig_28_29" args="()" --><p>
1640 <table class="mdTable" cellpadding="2" cellspacing="0">
1641   <tr>
1642     <td class="mdRow">
1643       <table cellpadding="0" cellspacing="0" border="0">
1644         <tr>
1645           <td class="md" nowrap valign="top"><a class="el" href="classServerConfig.html">ServerConfig</a> * Server::GetConfig           </td>
1646           <td class="md" valign="top">(&nbsp;</td>
1647           <td class="mdname1" valign="top" nowrap>          </td>
1648           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1649           <td class="md" nowrap></td>
1650         </tr>
1651       </table>
1652     </td>
1653   </tr>
1654 </table>
1655 <table cellspacing="5" cellpadding="0" border="0">
1656   <tr>
1657     <td>
1658       &nbsp;
1659     </td>
1660     <td>
1661
1662 <p>
1663 Obtains a pointer to the server's <a class="el" href="classServerConfig.html">ServerConfig</a> object. 
1664 <p>
1665 The <a class="el" href="classServerConfig.html">ServerConfig</a> object contains most of the configuration data of the IRC server, as read from the config file by the core.
1666 <p>
1667 Definition at line <a class="el" href="modules_8cpp-source.html#l00324">324</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00325"></a>00325 {
1668 <a name="l00326"></a>00326         <span class="keywordflow">return</span> <a class="code" href="channels_8cpp.html#Config">Config</a>;
1669 <a name="l00327"></a>00327 }
1670 </pre></div>
1671 <p>
1672     </td>
1673   </tr>
1674 </table>
1675 <a class="anchor" name="GetNetworkName_28_29"></a><!-- doxytag: member="Server::GetNetworkName" ref="GetNetworkName_28_29" args="()" --><p>
1676 <table class="mdTable" cellpadding="2" cellspacing="0">
1677   <tr>
1678     <td class="mdRow">
1679       <table cellpadding="0" cellspacing="0" border="0">
1680         <tr>
1681           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a> Server::GetNetworkName           </td>
1682           <td class="md" valign="top">(&nbsp;</td>
1683           <td class="mdname1" valign="top" nowrap>          </td>
1684           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1685           <td class="md" nowrap><code> [virtual]</code></td>
1686         </tr>
1687       </table>
1688     </td>
1689   </tr>
1690 </table>
1691 <table cellspacing="5" cellpadding="0" border="0">
1692   <tr>
1693     <td>
1694       &nbsp;
1695     </td>
1696     <td>
1697
1698 <p>
1699 Returns the network name, global to all linked servers. 
1700 <p>
1701
1702 <p>
1703 Definition at line <a class="el" href="modules_8cpp-source.html#l00534">534</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1704 <p>
1705 References <a class="el" href="inspircd__io_8h-source.html#l00074">ServerConfig::Network</a>.<div class="fragment"><pre class="fragment"><a name="l00535"></a>00535 {
1706 <a name="l00536"></a>00536         <span class="keywordflow">return</span> <a class="code" href="channels_8cpp.html#Config">Config</a>-&gt;<a class="code" href="classServerConfig.html#Network_5BMAXBUF_5D">Network</a>;
1707 <a name="l00537"></a>00537 }
1708 </pre></div>
1709 <p>
1710     </td>
1711   </tr>
1712 </table>
1713 <a class="anchor" name="GetServerDescription_28_29"></a><!-- doxytag: member="Server::GetServerDescription" ref="GetServerDescription_28_29" args="()" --><p>
1714 <table class="mdTable" cellpadding="2" cellspacing="0">
1715   <tr>
1716     <td class="mdRow">
1717       <table cellpadding="0" cellspacing="0" border="0">
1718         <tr>
1719           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a> Server::GetServerDescription           </td>
1720           <td class="md" valign="top">(&nbsp;</td>
1721           <td class="mdname1" valign="top" nowrap>          </td>
1722           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1723           <td class="md" nowrap><code> [virtual]</code></td>
1724         </tr>
1725       </table>
1726     </td>
1727   </tr>
1728 </table>
1729 <table cellspacing="5" cellpadding="0" border="0">
1730   <tr>
1731     <td>
1732       &nbsp;
1733     </td>
1734     <td>
1735
1736 <p>
1737 Returns the server description string of the local server. 
1738 <p>
1739
1740 <p>
1741 Definition at line <a class="el" href="modules_8cpp-source.html#l00539">539</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1742 <p>
1743 References <a class="el" href="inspircd__io_8h-source.html#l00079">ServerConfig::ServerDesc</a>.<div class="fragment"><pre class="fragment"><a name="l00540"></a>00540 {
1744 <a name="l00541"></a>00541         <span class="keywordflow">return</span> <a class="code" href="channels_8cpp.html#Config">Config</a>-&gt;<a class="code" href="classServerConfig.html#ServerDesc_5BMAXBUF_5D">ServerDesc</a>;
1745 <a name="l00542"></a>00542 }
1746 </pre></div>
1747 <p>
1748     </td>
1749   </tr>
1750 </table>
1751 <a class="anchor" name="GetServerName_28_29"></a><!-- doxytag: member="Server::GetServerName" ref="GetServerName_28_29" args="()" --><p>
1752 <table class="mdTable" cellpadding="2" cellspacing="0">
1753   <tr>
1754     <td class="mdRow">
1755       <table cellpadding="0" cellspacing="0" border="0">
1756         <tr>
1757           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a> Server::GetServerName           </td>
1758           <td class="md" valign="top">(&nbsp;</td>
1759           <td class="mdname1" valign="top" nowrap>          </td>
1760           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1761           <td class="md" nowrap><code> [virtual]</code></td>
1762         </tr>
1763       </table>
1764     </td>
1765   </tr>
1766 </table>
1767 <table cellspacing="5" cellpadding="0" border="0">
1768   <tr>
1769     <td>
1770       &nbsp;
1771     </td>
1772     <td>
1773
1774 <p>
1775 Returns the server name of the server where the module is loaded. 
1776 <p>
1777
1778 <p>
1779 Definition at line <a class="el" href="modules_8cpp-source.html#l00529">529</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1780 <p>
1781 References <a class="el" href="inspircd__io_8h-source.html#l00068">ServerConfig::ServerName</a>.<div class="fragment"><pre class="fragment"><a name="l00530"></a>00530 {
1782 <a name="l00531"></a>00531         <span class="keywordflow">return</span> <a class="code" href="channels_8cpp.html#Config">Config</a>-&gt;<a class="code" href="classServerConfig.html#ServerName_5BMAXBUF_5D">ServerName</a>;
1783 <a name="l00532"></a>00532 }
1784 </pre></div>
1785 <p>
1786     </td>
1787   </tr>
1788 </table>
1789 <a class="anchor" name="GetUsers_28chanrec_20_2Achan_29"></a><!-- doxytag: member="Server::GetUsers" ref="GetUsers_28chanrec_20_2Achan_29" args="(chanrec *chan)" --><p>
1790 <table class="mdTable" cellpadding="2" cellspacing="0">
1791   <tr>
1792     <td class="mdRow">
1793       <table cellpadding="0" cellspacing="0" border="0">
1794         <tr>
1795           <td class="md" nowrap valign="top"><a class="el" href="modules_8h.html#chanuserlist">chanuserlist</a> Server::GetUsers           </td>
1796           <td class="md" valign="top">(&nbsp;</td>
1797           <td class="md" nowrap valign="top"><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
1798           <td class="mdname1" valign="top" nowrap> <em>chan</em>          </td>
1799           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1800           <td class="md" nowrap><code> [virtual]</code></td>
1801         </tr>
1802       </table>
1803     </td>
1804   </tr>
1805 </table>
1806 <table cellspacing="5" cellpadding="0" border="0">
1807   <tr>
1808     <td>
1809       &nbsp;
1810     </td>
1811     <td>
1812
1813 <p>
1814 Fetches the userlist of a channel. 
1815 <p>
1816 This function must be here and not a member of userrec or chanrec due to include constraints.
1817 <p>
1818 Definition at line <a class="el" href="modules_8cpp-source.html#l00369">369</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1819 <p>
1820 References <a class="el" href="channels_8cpp-source.html#l00187">chanrec::GetUsers()</a>.<div class="fragment"><pre class="fragment"><a name="l00370"></a>00370 {
1821 <a name="l00371"></a>00371         <a class="code" href="modules_8h.html#chanuserlist">chanuserlist</a> userl;
1822 <a name="l00372"></a>00372         userl.clear();
1823 <a name="l00373"></a>00373         std::vector&lt;char*&gt; *list = chan-&gt;<a class="code" href="classchanrec.html#GetUsers_28_29">GetUsers</a>();
1824 <a name="l00374"></a>00374         <span class="keywordflow">for</span> (std::vector&lt;char*&gt;::iterator i = list-&gt;begin(); i != list-&gt;end(); i++)
1825 <a name="l00375"></a>00375         {
1826 <a name="l00376"></a>00376                 <span class="keywordtype">char</span>* o = *i;
1827 <a name="l00377"></a>00377                 userl.push_back((<a class="code" href="classuserrec.html">userrec</a>*)o);
1828 <a name="l00378"></a>00378         }
1829 <a name="l00379"></a>00379         <span class="keywordflow">return</span> userl;
1830 <a name="l00380"></a>00380 }
1831 </pre></div>
1832 <p>
1833     </td>
1834   </tr>
1835 </table>
1836 <a class="anchor" name="IsNick_28std_3A_3Astring_20nick_29"></a><!-- doxytag: member="Server::IsNick" ref="IsNick_28std_3A_3Astring_20nick_29" args="(std::string nick)" --><p>
1837 <table class="mdTable" cellpadding="2" cellspacing="0">
1838   <tr>
1839     <td class="mdRow">
1840       <table cellpadding="0" cellspacing="0" border="0">
1841         <tr>
1842           <td class="md" nowrap valign="top">bool Server::IsNick           </td>
1843           <td class="md" valign="top">(&nbsp;</td>
1844           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1845           <td class="mdname1" valign="top" nowrap> <em>nick</em>          </td>
1846           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1847           <td class="md" nowrap><code> [virtual]</code></td>
1848         </tr>
1849       </table>
1850     </td>
1851   </tr>
1852 </table>
1853 <table cellspacing="5" cellpadding="0" border="0">
1854   <tr>
1855     <td>
1856       &nbsp;
1857     </td>
1858     <td>
1859
1860 <p>
1861 Returns true if a nick is valid. 
1862 <p>
1863 Nicks for unregistered connections will return false.
1864 <p>
1865 Definition at line <a class="el" href="modules_8cpp-source.html#l00499">499</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1866 <p>
1867 References <a class="el" href="globals_8h.html#isnick_28const_20char_20_2An_29">isnick()</a>.<div class="fragment"><pre class="fragment"><a name="l00500"></a>00500 {
1868 <a name="l00501"></a>00501         <span class="keywordflow">return</span> (<a class="code" href="globals_8h.html#isnick_28const_20char_20_2An_29">isnick</a>(nick.c_str()) != 0);
1869 <a name="l00502"></a>00502 }
1870 </pre></div>
1871 <p>
1872     </td>
1873   </tr>
1874 </table>
1875 <a class="anchor" name="IsOnChannel_28userrec_20_2AUser_2C_20chanrec_20_2AChan_29"></a><!-- doxytag: member="Server::IsOnChannel" ref="IsOnChannel_28userrec_20_2AUser_2C_20chanrec_20_2AChan_29" args="(userrec *User, chanrec *Chan)" --><p>
1876 <table class="mdTable" cellpadding="2" cellspacing="0">
1877   <tr>
1878     <td class="mdRow">
1879       <table cellpadding="0" cellspacing="0" border="0">
1880         <tr>
1881           <td class="md" nowrap valign="top">bool Server::IsOnChannel           </td>
1882           <td class="md" valign="top">(&nbsp;</td>
1883           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1884           <td class="mdname" nowrap> <em>User</em>, </td>
1885         </tr>
1886         <tr>
1887           <td class="md" nowrap align="right"></td>
1888           <td class="md"></td>
1889           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
1890           <td class="mdname" nowrap> <em>Chan</em></td>
1891         </tr>
1892         <tr>
1893           <td class="md"></td>
1894           <td class="md">)&nbsp;</td>
1895           <td class="md" colspan="2"><code> [virtual]</code></td>
1896         </tr>
1897       </table>
1898     </td>
1899   </tr>
1900 </table>
1901 <table cellspacing="5" cellpadding="0" border="0">
1902   <tr>
1903     <td>
1904       &nbsp;
1905     </td>
1906     <td>
1907
1908 <p>
1909 Checks if a user is on a channel. 
1910 <p>
1911 This function will return true or false to indicate if user 'User' is on channel 'Chan'.
1912 <p>
1913 Definition at line <a class="el" href="modules_8cpp-source.html#l00524">524</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1914 <p>
1915 References <a class="el" href="message_8h.html#has_5Fchannel_28userrec_20_2Au_2C_20chanrec_20_2Ac_29">has_channel()</a>.<div class="fragment"><pre class="fragment"><a name="l00525"></a>00525 {
1916 <a name="l00526"></a>00526         <span class="keywordflow">return</span> <a class="code" href="message_8h.html#has_5Fchannel_28userrec_20_2Au_2C_20chanrec_20_2Ac_29">has_channel</a>(User,Chan);
1917 <a name="l00527"></a>00527 }
1918 </pre></div>
1919 <p>
1920     </td>
1921   </tr>
1922 </table>
1923 <a class="anchor" name="IsUlined_28std_3A_3Astring_20server_29"></a><!-- doxytag: member="Server::IsUlined" ref="IsUlined_28std_3A_3Astring_20server_29" args="(std::string server)" --><p>
1924 <table class="mdTable" cellpadding="2" cellspacing="0">
1925   <tr>
1926     <td class="mdRow">
1927       <table cellpadding="0" cellspacing="0" border="0">
1928         <tr>
1929           <td class="md" nowrap valign="top">bool Server::IsUlined           </td>
1930           <td class="md" valign="top">(&nbsp;</td>
1931           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1932           <td class="mdname1" valign="top" nowrap> <em>server</em>          </td>
1933           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1934           <td class="md" nowrap><code> [virtual]</code></td>
1935         </tr>
1936       </table>
1937     </td>
1938   </tr>
1939 </table>
1940 <table cellspacing="5" cellpadding="0" border="0">
1941   <tr>
1942     <td>
1943       &nbsp;
1944     </td>
1945     <td>
1946
1947 <p>
1948 Returns true if the servername you give is ulined. 
1949 <p>
1950 ULined servers have extra privilages. They are allowed to change nicknames on remote servers, change modes of clients which are on remote servers and set modes of channels where there are no channel operators for that channel on the ulined server, amongst other things. Ulined server data is also broadcast across the mesh at all times as opposed to selectively messaged in the case of normal servers, as many ulined server types (such as services) do not support meshed links and must operate in this manner.
1951 <p>
1952 Definition at line <a class="el" href="modules_8cpp-source.html#l00391">391</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1953 <p>
1954 References <a class="el" href="commands_8h.html#is_5Fuline_28const_20char_20_2Aserver_29">is_uline()</a>.<div class="fragment"><pre class="fragment"><a name="l00392"></a>00392 {
1955 <a name="l00393"></a>00393         <span class="keywordflow">return</span> <a class="code" href="commands_8h.html#is_5Fuline_28const_20char_20_2Aserver_29">is_uline</a>(server.c_str());
1956 <a name="l00394"></a>00394 }
1957 </pre></div>
1958 <p>
1959     </td>
1960   </tr>
1961 </table>
1962 <a class="anchor" name="IsValidMask_28std_3A_3Astring_20mask_29"></a><!-- doxytag: member="Server::IsValidMask" ref="IsValidMask_28std_3A_3Astring_20mask_29" args="(std::string mask)" --><p>
1963 <table class="mdTable" cellpadding="2" cellspacing="0">
1964   <tr>
1965     <td class="mdRow">
1966       <table cellpadding="0" cellspacing="0" border="0">
1967         <tr>
1968           <td class="md" nowrap valign="top">bool Server::IsValidMask           </td>
1969           <td class="md" valign="top">(&nbsp;</td>
1970           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
1971           <td class="mdname1" valign="top" nowrap> <em>mask</em>          </td>
1972           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1973           <td class="md" nowrap><code> [virtual]</code></td>
1974         </tr>
1975       </table>
1976     </td>
1977   </tr>
1978 </table>
1979 <table cellspacing="5" cellpadding="0" border="0">
1980   <tr>
1981     <td>
1982       &nbsp;
1983     </td>
1984     <td>
1985
1986 <p>
1987 Returns true if a nick!ident string is correctly formatted, false if otherwise. 
1988 <p>
1989
1990 <p>
1991 Definition at line <a class="el" href="modules_8cpp-source.html#l00690">690</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00691"></a>00691 {
1992 <a name="l00692"></a>00692         <span class="keyword">const</span> <span class="keywordtype">char</span>* dest = mask.c_str();
1993 <a name="l00693"></a>00693         <span class="keywordflow">if</span> (strchr(dest,<span class="charliteral">'!'</span>)==0)
1994 <a name="l00694"></a>00694                 <span class="keywordflow">return</span> <span class="keyword">false</span>;
1995 <a name="l00695"></a>00695         <span class="keywordflow">if</span> (strchr(dest,<span class="charliteral">'@'</span>)==0)
1996 <a name="l00696"></a>00696                 <span class="keywordflow">return</span> <span class="keyword">false</span>;
1997 <a name="l00697"></a>00697         <span class="keywordflow">for</span> (<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> i = 0; i &lt; strlen(dest); i++)
1998 <a name="l00698"></a>00698                 <span class="keywordflow">if</span> (dest[i] &lt; 32)
1999 <a name="l00699"></a>00699                         <span class="keywordflow">return</span> <span class="keyword">false</span>;
2000 <a name="l00700"></a>00700         <span class="keywordflow">for</span> (<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> i = 0; i &lt; strlen(dest); i++)
2001 <a name="l00701"></a>00701                 <span class="keywordflow">if</span> (dest[i] &gt; 126)
2002 <a name="l00702"></a>00702                         <span class="keywordflow">return</span> <span class="keyword">false</span>;
2003 <a name="l00703"></a>00703         <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> c = 0;
2004 <a name="l00704"></a>00704         <span class="keywordflow">for</span> (<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> i = 0; i &lt; strlen(dest); i++)
2005 <a name="l00705"></a>00705                 <span class="keywordflow">if</span> (dest[i] == <span class="charliteral">'!'</span>)
2006 <a name="l00706"></a>00706                         c++;
2007 <a name="l00707"></a>00707         <span class="keywordflow">if</span> (c&gt;1)
2008 <a name="l00708"></a>00708                 <span class="keywordflow">return</span> <span class="keyword">false</span>;
2009 <a name="l00709"></a>00709         c = 0;
2010 <a name="l00710"></a>00710         <span class="keywordflow">for</span> (<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> i = 0; i &lt; strlen(dest); i++)
2011 <a name="l00711"></a>00711                 <span class="keywordflow">if</span> (dest[i] == <span class="charliteral">'@'</span>)
2012 <a name="l00712"></a>00712                         c++;
2013 <a name="l00713"></a>00713         <span class="keywordflow">if</span> (c&gt;1)
2014 <a name="l00714"></a>00714                 <span class="keywordflow">return</span> <span class="keyword">false</span>;
2015 <a name="l00715"></a>00715 
2016 <a name="l00716"></a>00716         <span class="keywordflow">return</span> <span class="keyword">true</span>;
2017 <a name="l00717"></a>00717 }
2018 </pre></div>
2019 <p>
2020     </td>
2021   </tr>
2022 </table>
2023 <a class="anchor" name="IsValidModuleCommand_28std_3A_3Astring_20commandname_2C_20int_20pcnt_2C_20userrec_20_2Auser_29"></a><!-- doxytag: member="Server::IsValidModuleCommand" ref="IsValidModuleCommand_28std_3A_3Astring_20commandname_2C_20int_20pcnt_2C_20userrec_20_2Auser_29" args="(std::string commandname, int pcnt, userrec *user)" --><p>
2024 <table class="mdTable" cellpadding="2" cellspacing="0">
2025   <tr>
2026     <td class="mdRow">
2027       <table cellpadding="0" cellspacing="0" border="0">
2028         <tr>
2029           <td class="md" nowrap valign="top">bool Server::IsValidModuleCommand           </td>
2030           <td class="md" valign="top">(&nbsp;</td>
2031           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2032           <td class="mdname" nowrap> <em>commandname</em>, </td>
2033         </tr>
2034         <tr>
2035           <td class="md" nowrap align="right"></td>
2036           <td class="md"></td>
2037           <td class="md" nowrap>int&nbsp;</td>
2038           <td class="mdname" nowrap> <em>pcnt</em>, </td>
2039         </tr>
2040         <tr>
2041           <td class="md" nowrap align="right"></td>
2042           <td class="md"></td>
2043           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2044           <td class="mdname" nowrap> <em>user</em></td>
2045         </tr>
2046         <tr>
2047           <td class="md"></td>
2048           <td class="md">)&nbsp;</td>
2049           <td class="md" colspan="2"><code> [virtual]</code></td>
2050         </tr>
2051       </table>
2052     </td>
2053   </tr>
2054 </table>
2055 <table cellspacing="5" cellpadding="0" border="0">
2056   <tr>
2057     <td>
2058       &nbsp;
2059     </td>
2060     <td>
2061
2062 <p>
2063
2064 <p>
2065 Definition at line <a class="el" href="modules_8cpp-source.html#l00401">401</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2066 <p>
2067 References <a class="el" href="inspircd_8h.html#is_5Fvalid_5Fcmd_28const_20char_20_2Acommandname_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">is_valid_cmd()</a>.<div class="fragment"><pre class="fragment"><a name="l00402"></a>00402 {
2068 <a name="l00403"></a>00403         <span class="keywordflow">return</span> <a class="code" href="inspircd_8h.html#is_5Fvalid_5Fcmd_28const_20char_20_2Acommandname_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">is_valid_cmd</a>(commandname.c_str(), pcnt, user);
2069 <a name="l00404"></a>00404 }
2070 </pre></div>
2071 <p>
2072     </td>
2073   </tr>
2074 </table>
2075 <a class="anchor" name="JoinUserToChannel_28userrec_20_2Auser_2C_20std_3A_3Astring_20cname_2C_20std_3A_3Astring_20key_29"></a><!-- doxytag: member="Server::JoinUserToChannel" ref="JoinUserToChannel_28userrec_20_2Auser_2C_20std_3A_3Astring_20cname_2C_20std_3A_3Astring_20key_29" args="(userrec *user, std::string cname, std::string key)" --><p>
2076 <table class="mdTable" cellpadding="2" cellspacing="0">
2077   <tr>
2078     <td class="mdRow">
2079       <table cellpadding="0" cellspacing="0" border="0">
2080         <tr>
2081           <td class="md" nowrap valign="top"><a class="el" href="classchanrec.html">chanrec</a> * Server::JoinUserToChannel           </td>
2082           <td class="md" valign="top">(&nbsp;</td>
2083           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2084           <td class="mdname" nowrap> <em>user</em>, </td>
2085         </tr>
2086         <tr>
2087           <td class="md" nowrap align="right"></td>
2088           <td class="md"></td>
2089           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2090           <td class="mdname" nowrap> <em>cname</em>, </td>
2091         </tr>
2092         <tr>
2093           <td class="md" nowrap align="right"></td>
2094           <td class="md"></td>
2095           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2096           <td class="mdname" nowrap> <em>key</em></td>
2097         </tr>
2098         <tr>
2099           <td class="md"></td>
2100           <td class="md">)&nbsp;</td>
2101           <td class="md" colspan="2"><code> [virtual]</code></td>
2102         </tr>
2103       </table>
2104     </td>
2105   </tr>
2106 </table>
2107 <table cellspacing="5" cellpadding="0" border="0">
2108   <tr>
2109     <td>
2110       &nbsp;
2111     </td>
2112     <td>
2113
2114 <p>
2115 Forces a user to join a channel. 
2116 <p>
2117 This is similar to svsjoin and can be used to implement redirection, etc. On success, the return value is a valid pointer to a chanrec* of the channel the user was joined to. On failure, the result is NULL.
2118 <p>
2119 Definition at line <a class="el" href="modules_8cpp-source.html#l00359">359</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2120 <p>
2121 References <a class="el" href="channels_8cpp-source.html#l00195">add_channel()</a>.<div class="fragment"><pre class="fragment"><a name="l00360"></a>00360 {
2122 <a name="l00361"></a>00361         <span class="keywordflow">return</span> <a class="code" href="channels_8cpp.html#add_5Fchannel_28userrec_20_2Auser_2C_20const_20char_20_2Acn_2C_20const_20char_20_2Akey_2C_20bool_20override_29">add_channel</a>(user,cname.c_str(),key.c_str(),<span class="keyword">false</span>);
2123 <a name="l00362"></a>00362 }
2124 </pre></div>
2125 <p>
2126     </td>
2127   </tr>
2128 </table>
2129 <a class="anchor" name="Log_28int_20level_2C_20std_3A_3Astring_20s_29"></a><!-- doxytag: member="Server::Log" ref="Log_28int_20level_2C_20std_3A_3Astring_20s_29" args="(int level, std::string s)" --><p>
2130 <table class="mdTable" cellpadding="2" cellspacing="0">
2131   <tr>
2132     <td class="mdRow">
2133       <table cellpadding="0" cellspacing="0" border="0">
2134         <tr>
2135           <td class="md" nowrap valign="top">void Server::Log           </td>
2136           <td class="md" valign="top">(&nbsp;</td>
2137           <td class="md" nowrap valign="top">int&nbsp;</td>
2138           <td class="mdname" nowrap> <em>level</em>, </td>
2139         </tr>
2140         <tr>
2141           <td class="md" nowrap align="right"></td>
2142           <td class="md"></td>
2143           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2144           <td class="mdname" nowrap> <em>s</em></td>
2145         </tr>
2146         <tr>
2147           <td class="md"></td>
2148           <td class="md">)&nbsp;</td>
2149           <td class="md" colspan="2"><code> [virtual]</code></td>
2150         </tr>
2151       </table>
2152     </td>
2153   </tr>
2154 </table>
2155 <table cellspacing="5" cellpadding="0" border="0">
2156   <tr>
2157     <td>
2158       &nbsp;
2159     </td>
2160     <td>
2161
2162 <p>
2163 Writes a log string. 
2164 <p>
2165 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.
2166 <p>
2167 Definition at line <a class="el" href="modules_8cpp-source.html#l00406">406</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2168 <p>
2169 References <a class="el" href="globals_8h.html#log_28int_20level_2C_20char_20_2Atext_2C_2E_2E_2E_29">log()</a>.<div class="fragment"><pre class="fragment"><a name="l00407"></a>00407 {
2170 <a name="l00408"></a>00408         <a class="code" href="globals_8h.html#log_28int_20level_2C_20char_20_2Atext_2C_2E_2E_2E_29">log</a>(level,<span class="stringliteral">"%s"</span>,s.c_str());
2171 <a name="l00409"></a>00409 }
2172 </pre></div>
2173 <p>
2174     </td>
2175   </tr>
2176 </table>
2177 <a class="anchor" name="MatchText_28std_3A_3Astring_20sliteral_2C_20std_3A_3Astring_20spattern_29"></a><!-- doxytag: member="Server::MatchText" ref="MatchText_28std_3A_3Astring_20sliteral_2C_20std_3A_3Astring_20spattern_29" args="(std::string sliteral, std::string spattern)" --><p>
2178 <table class="mdTable" cellpadding="2" cellspacing="0">
2179   <tr>
2180     <td class="mdRow">
2181       <table cellpadding="0" cellspacing="0" border="0">
2182         <tr>
2183           <td class="md" nowrap valign="top">bool Server::MatchText           </td>
2184           <td class="md" valign="top">(&nbsp;</td>
2185           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2186           <td class="mdname" nowrap> <em>sliteral</em>, </td>
2187         </tr>
2188         <tr>
2189           <td class="md" nowrap align="right"></td>
2190           <td class="md"></td>
2191           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2192           <td class="mdname" nowrap> <em>spattern</em></td>
2193         </tr>
2194         <tr>
2195           <td class="md"></td>
2196           <td class="md">)&nbsp;</td>
2197           <td class="md" colspan="2"><code> [virtual]</code></td>
2198         </tr>
2199       </table>
2200     </td>
2201   </tr>
2202 </table>
2203 <table cellspacing="5" cellpadding="0" border="0">
2204   <tr>
2205     <td>
2206       &nbsp;
2207     </td>
2208     <td>
2209
2210 <p>
2211 Matches text against a glob pattern. 
2212 <p>
2213 Uses the ircd's internal matching function to match string against a globbing pattern, e.g. *!*@*.com Returns true if the literal successfully matches the pattern, false if otherwise.
2214 <p>
2215 Definition at line <a class="el" href="modules_8cpp-source.html#l00346">346</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00347"></a>00347 {
2216 <a name="l00348"></a>00348         <span class="keywordtype">char</span> literal[MAXBUF],pattern[MAXBUF];
2217 <a name="l00349"></a>00349         strlcpy(literal,sliteral.c_str(),MAXBUF);
2218 <a name="l00350"></a>00350         strlcpy(pattern,spattern.c_str(),MAXBUF);
2219 <a name="l00351"></a>00351         <span class="keywordflow">return</span> match(literal,pattern);
2220 <a name="l00352"></a>00352 }
2221 </pre></div>
2222 <p>
2223     </td>
2224   </tr>
2225 </table>
2226 <a class="anchor" name="PartUserFromChannel_28userrec_20_2Auser_2C_20std_3A_3Astring_20cname_2C_20std_3A_3Astring_20reason_29"></a><!-- doxytag: member="Server::PartUserFromChannel" ref="PartUserFromChannel_28userrec_20_2Auser_2C_20std_3A_3Astring_20cname_2C_20std_3A_3Astring_20reason_29" args="(userrec *user, std::string cname, std::string reason)" --><p>
2227 <table class="mdTable" cellpadding="2" cellspacing="0">
2228   <tr>
2229     <td class="mdRow">
2230       <table cellpadding="0" cellspacing="0" border="0">
2231         <tr>
2232           <td class="md" nowrap valign="top"><a class="el" href="classchanrec.html">chanrec</a> * Server::PartUserFromChannel           </td>
2233           <td class="md" valign="top">(&nbsp;</td>
2234           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2235           <td class="mdname" nowrap> <em>user</em>, </td>
2236         </tr>
2237         <tr>
2238           <td class="md" nowrap align="right"></td>
2239           <td class="md"></td>
2240           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2241           <td class="mdname" nowrap> <em>cname</em>, </td>
2242         </tr>
2243         <tr>
2244           <td class="md" nowrap align="right"></td>
2245           <td class="md"></td>
2246           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2247           <td class="mdname" nowrap> <em>reason</em></td>
2248         </tr>
2249         <tr>
2250           <td class="md"></td>
2251           <td class="md">)&nbsp;</td>
2252           <td class="md" colspan="2"><code> [virtual]</code></td>
2253         </tr>
2254       </table>
2255     </td>
2256   </tr>
2257 </table>
2258 <table cellspacing="5" cellpadding="0" border="0">
2259   <tr>
2260     <td>
2261       &nbsp;
2262     </td>
2263     <td>
2264
2265 <p>
2266 Forces a user to part a channel. 
2267 <p>
2268 This is similar to svspart and can be used to implement redirection, etc. Although the return value of this function is a pointer to a channel record, the returned data is undefined and should not be read or written to. This behaviour may be changed in a future version.
2269 <p>
2270 Definition at line <a class="el" href="modules_8cpp-source.html#l00364">364</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2271 <p>
2272 References <a class="el" href="channels_8cpp-source.html#l00401">del_channel()</a>.<div class="fragment"><pre class="fragment"><a name="l00365"></a>00365 {
2273 <a name="l00366"></a>00366         <span class="keywordflow">return</span> <a class="code" href="channels_8cpp.html#del_5Fchannel_28userrec_20_2Auser_2C_20const_20char_20_2Acname_2C_20const_20char_20_2Areason_2C_20bool_20local_29">del_channel</a>(user,cname.c_str(),reason.c_str(),<span class="keyword">false</span>);
2274 <a name="l00367"></a>00367 }
2275 </pre></div>
2276 <p>
2277     </td>
2278   </tr>
2279 </table>
2280 <a class="anchor" name="PseudoToUser_28userrec_20_2Aalive_2C_20userrec_20_2Azombie_2C_20std_3A_3Astring_20message_29"></a><!-- doxytag: member="Server::PseudoToUser" ref="PseudoToUser_28userrec_20_2Aalive_2C_20userrec_20_2Azombie_2C_20std_3A_3Astring_20message_29" args="(userrec *alive, userrec *zombie, std::string message)" --><p>
2281 <table class="mdTable" cellpadding="2" cellspacing="0">
2282   <tr>
2283     <td class="mdRow">
2284       <table cellpadding="0" cellspacing="0" border="0">
2285         <tr>
2286           <td class="md" nowrap valign="top">bool Server::PseudoToUser           </td>
2287           <td class="md" valign="top">(&nbsp;</td>
2288           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2289           <td class="mdname" nowrap> <em>alive</em>, </td>
2290         </tr>
2291         <tr>
2292           <td class="md" nowrap align="right"></td>
2293           <td class="md"></td>
2294           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2295           <td class="mdname" nowrap> <em>zombie</em>, </td>
2296         </tr>
2297         <tr>
2298           <td class="md" nowrap align="right"></td>
2299           <td class="md"></td>
2300           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2301           <td class="mdname" nowrap> <em>message</em></td>
2302         </tr>
2303         <tr>
2304           <td class="md"></td>
2305           <td class="md">)&nbsp;</td>
2306           <td class="md" colspan="2"><code> [virtual]</code></td>
2307         </tr>
2308       </table>
2309     </td>
2310   </tr>
2311 </table>
2312 <table cellspacing="5" cellpadding="0" border="0">
2313   <tr>
2314     <td>
2315       &nbsp;
2316     </td>
2317     <td>
2318
2319 <p>
2320 This user takes one user, and switches their file descriptor with another user, so that one user "becomes" the other. 
2321 <p>
2322 The user in 'alive' is booted off the server with the given message. The user referred to by 'zombie' should have previously been locked with Server::ZombifyUser, otherwise stale sockets and file descriptor leaks can occur. After this call, the pointer to alive will be invalid, and the pointer to zombie will be equivalent in effect to the old pointer to alive.
2323 <p>
2324 Definition at line <a class="el" href="modules_8cpp-source.html#l00605">605</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2325 <p>
2326 References <a class="el" href="users_8h-source.html#l00149">userrec::chans</a>, <a class="el" href="users_8cpp-source.html#l00232">userrec::ClearBuffer()</a>, <a class="el" href="connection_8h-source.html#l00042">connection::fd</a>, <a class="el" href="modules_8h-source.html#l00101">FD_MAGIC_NUMBER</a>, <a class="el" href="connection_8h-source.html#l00046">connection::host</a>, <a class="el" href="users_8h-source.html#l00129">userrec::ident</a>, <a class="el" href="inspircd_8h.html#kill_5Flink_28userrec_20_2Auser_2C_20const_20char_20_2Ar_29">kill_link()</a>, <a class="el" href="channels_8h-source.html#l00108">chanrec::name</a>, <a class="el" href="users_8h-source.html#l00124">userrec::nick</a>, <a class="el" href="channels_8h-source.html#l00133">chanrec::setby</a>, <a class="el" href="channels_8h-source.html#l00122">chanrec::topic</a>, <a class="el" href="channels_8h-source.html#l00129">chanrec::topicset</a>, <a class="el" href="globals_8h.html#Write_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">Write()</a>, <a class="el" href="globals_8h.html#WriteFrom_28int_20sock_2C_20userrec_20_2Auser_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteFrom()</a>, and <a class="el" href="globals_8h.html#WriteServ_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteServ()</a>.<div class="fragment"><pre class="fragment"><a name="l00606"></a>00606 {
2327 <a name="l00607"></a>00607         zombie-&gt;<a class="code" href="classconnection.html#fd">fd</a> = alive-&gt;<a class="code" href="classconnection.html#fd">fd</a>;
2328 <a name="l00608"></a>00608         alive-&gt;<a class="code" href="classconnection.html#fd">fd</a> = <a class="code" href="modules_8h.html#FD_5FMAGIC_5FNUMBER">FD_MAGIC_NUMBER</a>;
2329 <a name="l00609"></a>00609         alive-&gt;<a class="code" href="classuserrec.html#ClearBuffer_28_29">ClearBuffer</a>();
2330 <a name="l00610"></a>00610         <a class="code" href="globals_8h.html#Write_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">Write</a>(zombie-&gt;<a class="code" href="classconnection.html#fd">fd</a>,<span class="stringliteral">":%s!%s@%s NICK %s"</span>,alive-&gt;<a class="code" href="classuserrec.html#nick_5BNICKMAX_5D">nick</a>,alive-&gt;<a class="code" href="classuserrec.html#ident_5BIDENTMAX_2B_32_5D">ident</a>,alive-&gt;<a class="code" href="classconnection.html#host_5B_31_36_30_5D">host</a>,zombie-&gt;<a class="code" href="classuserrec.html#nick_5BNICKMAX_5D">nick</a>);
2331 <a name="l00611"></a>00611         <a class="code" href="inspircd_8h.html#kill_5Flink_28userrec_20_2Auser_2C_20const_20char_20_2Ar_29">kill_link</a>(alive,message.c_str());
2332 <a name="l00612"></a>00612         <a class="code" href="modules_8cpp.html#fd_5Fref_5Ftable_5B_36_35_35_33_36_5D">fd_ref_table</a>[zombie-&gt;<a class="code" href="classconnection.html#fd">fd</a>] = zombie;
2333 <a name="l00613"></a>00613         <span class="keywordflow">for</span> (<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> i = 0; i &lt; zombie-&gt;chans.size(); i++)
2334 <a name="l00614"></a>00614         {
2335 <a name="l00615"></a>00615                 <span class="keywordflow">if</span> (zombie-&gt;<a class="code" href="classuserrec.html#chans">chans</a>[i].channel != NULL)
2336 <a name="l00616"></a>00616                 {
2337 <a name="l00617"></a>00617                         <span class="keywordflow">if</span> (zombie-&gt;<a class="code" href="classuserrec.html#chans">chans</a>[i].channel-&gt;name)
2338 <a name="l00618"></a>00618                         {
2339 <a name="l00619"></a>00619                                 <a class="code" href="classchanrec.html">chanrec</a>* Ptr = zombie-&gt;<a class="code" href="classuserrec.html#chans">chans</a>[i].channel;
2340 <a name="l00620"></a>00620                                 <a class="code" href="globals_8h.html#WriteFrom_28int_20sock_2C_20userrec_20_2Auser_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteFrom</a>(zombie-&gt;<a class="code" href="classconnection.html#fd">fd</a>,zombie,<span class="stringliteral">"JOIN %s"</span>,Ptr-&gt;<a class="code" href="classchanrec.html#name_5BCHANMAX_5D">name</a>);
2341 <a name="l00621"></a>00621                                 <span class="keywordflow">if</span> (Ptr-&gt;<a class="code" href="classchanrec.html#topicset">topicset</a>)
2342 <a name="l00622"></a>00622                                 {
2343 <a name="l00623"></a>00623                                         <a class="code" href="globals_8h.html#WriteServ_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteServ</a>(zombie-&gt;<a class="code" href="classconnection.html#fd">fd</a>,<span class="stringliteral">"332 %s %s :%s"</span>, zombie-&gt;<a class="code" href="classuserrec.html#nick_5BNICKMAX_5D">nick</a>, Ptr-&gt;<a class="code" href="classchanrec.html#name_5BCHANMAX_5D">name</a>, Ptr-&gt;<a class="code" href="classchanrec.html#topic_5BMAXBUF_5D">topic</a>);
2344 <a name="l00624"></a>00624                                         <a class="code" href="globals_8h.html#WriteServ_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteServ</a>(zombie-&gt;<a class="code" href="classconnection.html#fd">fd</a>,<span class="stringliteral">"333 %s %s %s %d"</span>, zombie-&gt;<a class="code" href="classuserrec.html#nick_5BNICKMAX_5D">nick</a>, Ptr-&gt;<a class="code" href="classchanrec.html#name_5BCHANMAX_5D">name</a>, Ptr-&gt;<a class="code" href="classchanrec.html#setby_5BNICKMAX_5D">setby</a>, Ptr-&gt;<a class="code" href="classchanrec.html#topicset">topicset</a>);
2345 <a name="l00625"></a>00625                                 }
2346 <a name="l00626"></a>00626                                 userlist(zombie,Ptr);
2347 <a name="l00627"></a>00627                                 <a class="code" href="globals_8h.html#WriteServ_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteServ</a>(zombie-&gt;<a class="code" href="classconnection.html#fd">fd</a>,<span class="stringliteral">"366 %s %s :End of /NAMES list."</span>, zombie-&gt;<a class="code" href="classuserrec.html#nick_5BNICKMAX_5D">nick</a>, Ptr-&gt;<a class="code" href="classchanrec.html#name_5BCHANMAX_5D">name</a>);
2348 <a name="l00628"></a>00628 
2349 <a name="l00629"></a>00629                         }
2350 <a name="l00630"></a>00630                 }
2351 <a name="l00631"></a>00631         }
2352 <a name="l00632"></a>00632         <span class="keywordflow">return</span> <span class="keyword">true</span>;
2353 <a name="l00633"></a>00633 }
2354 </pre></div>
2355 <p>
2356     </td>
2357   </tr>
2358 </table>
2359 <a class="anchor" name="QuitUser_28userrec_20_2Auser_2C_20std_3A_3Astring_20reason_29"></a><!-- doxytag: member="Server::QuitUser" ref="QuitUser_28userrec_20_2Auser_2C_20std_3A_3Astring_20reason_29" args="(userrec *user, std::string reason)" --><p>
2360 <table class="mdTable" cellpadding="2" cellspacing="0">
2361   <tr>
2362     <td class="mdRow">
2363       <table cellpadding="0" cellspacing="0" border="0">
2364         <tr>
2365           <td class="md" nowrap valign="top">void Server::QuitUser           </td>
2366           <td class="md" valign="top">(&nbsp;</td>
2367           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2368           <td class="mdname" nowrap> <em>user</em>, </td>
2369         </tr>
2370         <tr>
2371           <td class="md" nowrap align="right"></td>
2372           <td class="md"></td>
2373           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2374           <td class="mdname" nowrap> <em>reason</em></td>
2375         </tr>
2376         <tr>
2377           <td class="md"></td>
2378           <td class="md">)&nbsp;</td>
2379           <td class="md" colspan="2"><code> [virtual]</code></td>
2380         </tr>
2381       </table>
2382     </td>
2383   </tr>
2384 </table>
2385 <table cellspacing="5" cellpadding="0" border="0">
2386   <tr>
2387     <td>
2388       &nbsp;
2389     </td>
2390     <td>
2391
2392 <p>
2393 Forces a user to quit with the specified reason. 
2394 <p>
2395 To the user, it will appear as if they typed /QUIT themselves, except for the fact that this function may bypass the quit prefix specified in the config file.<p>
2396 WARNING!<p>
2397 Once you call this function, userrec* user will immediately become INVALID. You MUST NOT write to, or read from this pointer after calling the QuitUser method UNDER ANY CIRCUMSTANCES! The best course of action after calling this method is to immediately bail from your handler.
2398 <p>
2399 Definition at line <a class="el" href="modules_8cpp-source.html#l00386">386</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2400 <p>
2401 References <a class="el" href="inspircd_8h.html#kill_5Flink_28userrec_20_2Auser_2C_20const_20char_20_2Ar_29">kill_link()</a>.<div class="fragment"><pre class="fragment"><a name="l00387"></a>00387 {
2402 <a name="l00388"></a>00388         <a class="code" href="inspircd_8h.html#kill_5Flink_28userrec_20_2Auser_2C_20const_20char_20_2Ar_29">kill_link</a>(user,reason.c_str());
2403 <a name="l00389"></a>00389 }
2404 </pre></div>
2405 <p>
2406     </td>
2407   </tr>
2408 </table>
2409 <a class="anchor" name="RehashServer_28_29"></a><!-- doxytag: member="Server::RehashServer" ref="RehashServer_28_29" args="()" --><p>
2410 <table class="mdTable" cellpadding="2" cellspacing="0">
2411   <tr>
2412     <td class="mdRow">
2413       <table cellpadding="0" cellspacing="0" border="0">
2414         <tr>
2415           <td class="md" nowrap valign="top">void Server::RehashServer           </td>
2416           <td class="md" valign="top">(&nbsp;</td>
2417           <td class="mdname1" valign="top" nowrap>          </td>
2418           <td class="md" valign="top">&nbsp;)&nbsp;</td>
2419           <td class="md" nowrap><code> [virtual]</code></td>
2420         </tr>
2421       </table>
2422     </td>
2423   </tr>
2424 </table>
2425 <table cellspacing="5" cellpadding="0" border="0">
2426   <tr>
2427     <td>
2428       &nbsp;
2429     </td>
2430     <td>
2431
2432 <p>
2433
2434 <p>
2435 Definition at line <a class="el" href="modules_8cpp-source.html#l00318">318</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2436 <p>
2437 References <a class="el" href="classServerConfig.html#Read_28bool_20bail_2C_20userrec_20_2Auser_29">ServerConfig::Read()</a>, and <a class="el" href="globals_8h.html#WriteOpers_28char_20_2Atext_2C_2E_2E_2E_29">WriteOpers()</a>.<div class="fragment"><pre class="fragment"><a name="l00319"></a>00319 {
2438 <a name="l00320"></a>00320         <a class="code" href="globals_8h.html#WriteOpers_28char_20_2Atext_2C_2E_2E_2E_29">WriteOpers</a>(<span class="stringliteral">"*** Rehashing config file"</span>);
2439 <a name="l00321"></a>00321         <a class="code" href="channels_8cpp.html#Config">Config</a>-&gt;<a class="code" href="classServerConfig.html#Read_28bool_20bail_2C_20userrec_20_2Auser_29">Read</a>(<span class="keyword">false</span>,NULL);
2440 <a name="l00322"></a>00322 }
2441 </pre></div>
2442 <p>
2443     </td>
2444   </tr>
2445 </table>
2446 <a class="anchor" name="Send_28int_20Socket_2C_20std_3A_3Astring_20s_29"></a><!-- doxytag: member="Server::Send" ref="Send_28int_20Socket_2C_20std_3A_3Astring_20s_29" args="(int Socket, std::string s)" --><p>
2447 <table class="mdTable" cellpadding="2" cellspacing="0">
2448   <tr>
2449     <td class="mdRow">
2450       <table cellpadding="0" cellspacing="0" border="0">
2451         <tr>
2452           <td class="md" nowrap valign="top">void Server::Send           </td>
2453           <td class="md" valign="top">(&nbsp;</td>
2454           <td class="md" nowrap valign="top">int&nbsp;</td>
2455           <td class="mdname" nowrap> <em>Socket</em>, </td>
2456         </tr>
2457         <tr>
2458           <td class="md" nowrap align="right"></td>
2459           <td class="md"></td>
2460           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2461           <td class="mdname" nowrap> <em>s</em></td>
2462         </tr>
2463         <tr>
2464           <td class="md"></td>
2465           <td class="md">)&nbsp;</td>
2466           <td class="md" colspan="2"><code> [virtual]</code></td>
2467         </tr>
2468       </table>
2469     </td>
2470   </tr>
2471 </table>
2472 <table cellspacing="5" cellpadding="0" border="0">
2473   <tr>
2474     <td>
2475       &nbsp;
2476     </td>
2477     <td>
2478
2479 <p>
2480 Sends a line of text down a TCP/IP socket. 
2481 <p>
2482 This method writes a line of text to an established socket, cutting it to 510 characters plus a carriage return and linefeed if required.
2483 <p>
2484 Definition at line <a class="el" href="modules_8cpp-source.html#l00421">421</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2485 <p>
2486 References <a class="el" href="globals_8h.html#Write_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">Write()</a>.<div class="fragment"><pre class="fragment"><a name="l00422"></a>00422 {
2487 <a name="l00423"></a>00423         <a class="code" href="globals_8h.html#Write_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">Write</a>(Socket,<span class="stringliteral">"%s"</span>,s.c_str());
2488 <a name="l00424"></a>00424 }
2489 </pre></div>
2490 <p>
2491     </td>
2492   </tr>
2493 </table>
2494 <a class="anchor" name="SendChannel_28userrec_20_2AUser_2C_20chanrec_20_2AChannel_2C_20std_3A_3Astring_20s_2C_20bool_20IncludeSender_29"></a><!-- doxytag: member="Server::SendChannel" ref="SendChannel_28userrec_20_2AUser_2C_20chanrec_20_2AChannel_2C_20std_3A_3Astring_20s_2C_20bool_20IncludeSender_29" args="(userrec *User, chanrec *Channel, std::string s, bool IncludeSender)" --><p>
2495 <table class="mdTable" cellpadding="2" cellspacing="0">
2496   <tr>
2497     <td class="mdRow">
2498       <table cellpadding="0" cellspacing="0" border="0">
2499         <tr>
2500           <td class="md" nowrap valign="top">void Server::SendChannel           </td>
2501           <td class="md" valign="top">(&nbsp;</td>
2502           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2503           <td class="mdname" nowrap> <em>User</em>, </td>
2504         </tr>
2505         <tr>
2506           <td class="md" nowrap align="right"></td>
2507           <td class="md"></td>
2508           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
2509           <td class="mdname" nowrap> <em>Channel</em>, </td>
2510         </tr>
2511         <tr>
2512           <td class="md" nowrap align="right"></td>
2513           <td class="md"></td>
2514           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2515           <td class="mdname" nowrap> <em>s</em>, </td>
2516         </tr>
2517         <tr>
2518           <td class="md" nowrap align="right"></td>
2519           <td class="md"></td>
2520           <td class="md" nowrap>bool&nbsp;</td>
2521           <td class="mdname" nowrap> <em>IncludeSender</em></td>
2522         </tr>
2523         <tr>
2524           <td class="md"></td>
2525           <td class="md">)&nbsp;</td>
2526           <td class="md" colspan="2"><code> [virtual]</code></td>
2527         </tr>
2528       </table>
2529     </td>
2530   </tr>
2531 </table>
2532 <table cellspacing="5" cellpadding="0" border="0">
2533   <tr>
2534     <td>
2535       &nbsp;
2536     </td>
2537     <td>
2538
2539 <p>
2540 Sends text from a user to a channel (mulicast). 
2541 <p>
2542 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).
2543 <p>
2544 Definition at line <a class="el" href="modules_8cpp-source.html#l00455">455</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2545 <p>
2546 References <a class="el" href="globals_8h.html#ChanExceptSender_28chanrec_20_2APtr_2C_20userrec_20_2Auser_2C_20char_20_2Atext_2C_2E_2E_2E_29">ChanExceptSender()</a>, and <a class="el" href="globals_8h.html#WriteChannel_28chanrec_20_2APtr_2C_20userrec_20_2Auser_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteChannel()</a>.<div class="fragment"><pre class="fragment"><a name="l00456"></a>00456 {
2547 <a name="l00457"></a>00457         <span class="keywordflow">if</span> (IncludeSender)
2548 <a name="l00458"></a>00458         {
2549 <a name="l00459"></a>00459                 <a class="code" href="globals_8h.html#WriteChannel_28chanrec_20_2APtr_2C_20userrec_20_2Auser_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteChannel</a>(Channel,User,<span class="stringliteral">"%s"</span>,s.c_str());
2550 <a name="l00460"></a>00460         }
2551 <a name="l00461"></a>00461         <span class="keywordflow">else</span>
2552 <a name="l00462"></a>00462         {
2553 <a name="l00463"></a>00463                 <a class="code" href="globals_8h.html#ChanExceptSender_28chanrec_20_2APtr_2C_20userrec_20_2Auser_2C_20char_20_2Atext_2C_2E_2E_2E_29">ChanExceptSender</a>(Channel,User,<span class="stringliteral">"%s"</span>,s.c_str());
2554 <a name="l00464"></a>00464         }
2555 <a name="l00465"></a>00465 }
2556 </pre></div>
2557 <p>
2558     </td>
2559   </tr>
2560 </table>
2561 <a class="anchor" name="SendChannelServerNotice_28std_3A_3Astring_20ServName_2C_20chanrec_20_2AChannel_2C_20std_3A_3Astring_20text_29"></a><!-- doxytag: member="Server::SendChannelServerNotice" ref="SendChannelServerNotice_28std_3A_3Astring_20ServName_2C_20chanrec_20_2AChannel_2C_20std_3A_3Astring_20text_29" args="(std::string ServName, chanrec *Channel, std::string text)" --><p>
2562 <table class="mdTable" cellpadding="2" cellspacing="0">
2563   <tr>
2564     <td class="mdRow">
2565       <table cellpadding="0" cellspacing="0" border="0">
2566         <tr>
2567           <td class="md" nowrap valign="top">void Server::SendChannelServerNotice           </td>
2568           <td class="md" valign="top">(&nbsp;</td>
2569           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2570           <td class="mdname" nowrap> <em>ServName</em>, </td>
2571         </tr>
2572         <tr>
2573           <td class="md" nowrap align="right"></td>
2574           <td class="md"></td>
2575           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
2576           <td class="mdname" nowrap> <em>Channel</em>, </td>
2577         </tr>
2578         <tr>
2579           <td class="md" nowrap align="right"></td>
2580           <td class="md"></td>
2581           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2582           <td class="mdname" nowrap> <em>text</em></td>
2583         </tr>
2584         <tr>
2585           <td class="md"></td>
2586           <td class="md">)&nbsp;</td>
2587           <td class="md" colspan="2"><code> [virtual]</code></td>
2588         </tr>
2589       </table>
2590     </td>
2591   </tr>
2592 </table>
2593 <table cellspacing="5" cellpadding="0" border="0">
2594   <tr>
2595     <td>
2596       &nbsp;
2597     </td>
2598     <td>
2599
2600 <p>
2601 Writes text to a channel, but from a server, including all. 
2602 <p>
2603 This can be used to send server notices to a group of users.
2604 <p>
2605 Definition at line <a class="el" href="modules_8cpp-source.html#l00450">450</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00451"></a>00451 {
2606 <a name="l00452"></a>00452         WriteChannelWithServ((<span class="keywordtype">char</span>*)ServName.c_str(), Channel, <span class="stringliteral">"%s"</span>, text.c_str());
2607 <a name="l00453"></a>00453 }
2608 </pre></div>
2609 <p>
2610     </td>
2611   </tr>
2612 </table>
2613 <a class="anchor" name="SendCommon_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_2C_20bool_20IncludeSender_29"></a><!-- doxytag: member="Server::SendCommon" ref="SendCommon_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_2C_20bool_20IncludeSender_29" args="(userrec *User, std::string text, bool IncludeSender)" --><p>
2614 <table class="mdTable" cellpadding="2" cellspacing="0">
2615   <tr>
2616     <td class="mdRow">
2617       <table cellpadding="0" cellspacing="0" border="0">
2618         <tr>
2619           <td class="md" nowrap valign="top">void Server::SendCommon           </td>
2620           <td class="md" valign="top">(&nbsp;</td>
2621           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2622           <td class="mdname" nowrap> <em>User</em>, </td>
2623         </tr>
2624         <tr>
2625           <td class="md" nowrap align="right"></td>
2626           <td class="md"></td>
2627           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2628           <td class="mdname" nowrap> <em>text</em>, </td>
2629         </tr>
2630         <tr>
2631           <td class="md" nowrap align="right"></td>
2632           <td class="md"></td>
2633           <td class="md" nowrap>bool&nbsp;</td>
2634           <td class="mdname" nowrap> <em>IncludeSender</em></td>
2635         </tr>
2636         <tr>
2637           <td class="md"></td>
2638           <td class="md">)&nbsp;</td>
2639           <td class="md" colspan="2"><code> [virtual]</code></td>
2640         </tr>
2641       </table>
2642     </td>
2643   </tr>
2644 </table>
2645 <table cellspacing="5" cellpadding="0" border="0">
2646   <tr>
2647     <td>
2648       &nbsp;
2649     </td>
2650     <td>
2651
2652 <p>
2653 Sends text from a user to one or more channels (mulicast). 
2654 <p>
2655 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.
2656 <p>
2657 Definition at line <a class="el" href="modules_8cpp-source.html#l00472">472</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2658 <p>
2659 References <a class="el" href="globals_8h.html#WriteCommon_28userrec_20_2Au_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteCommon()</a>, and <a class="el" href="globals_8h.html#WriteCommonExcept_28userrec_20_2Au_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteCommonExcept()</a>.<div class="fragment"><pre class="fragment"><a name="l00473"></a>00473 {
2660 <a name="l00474"></a>00474         <span class="keywordflow">if</span> (IncludeSender)
2661 <a name="l00475"></a>00475         {
2662 <a name="l00476"></a>00476                 <a class="code" href="globals_8h.html#WriteCommon_28userrec_20_2Au_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteCommon</a>(User,<span class="stringliteral">"%s"</span>,text.c_str());
2663 <a name="l00477"></a>00477         }
2664 <a name="l00478"></a>00478         <span class="keywordflow">else</span>
2665 <a name="l00479"></a>00479         {
2666 <a name="l00480"></a>00480                 <a class="code" href="globals_8h.html#WriteCommonExcept_28userrec_20_2Au_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteCommonExcept</a>(User,<span class="stringliteral">"%s"</span>,text.c_str());
2667 <a name="l00481"></a>00481         }
2668 <a name="l00482"></a>00482 }
2669 </pre></div>
2670 <p>
2671     </td>
2672   </tr>
2673 </table>
2674 <a class="anchor" name="SendFrom_28int_20Socket_2C_20userrec_20_2AUser_2C_20std_3A_3Astring_20s_29"></a><!-- doxytag: member="Server::SendFrom" ref="SendFrom_28int_20Socket_2C_20userrec_20_2AUser_2C_20std_3A_3Astring_20s_29" args="(int Socket, userrec *User, std::string s)" --><p>
2675 <table class="mdTable" cellpadding="2" cellspacing="0">
2676   <tr>
2677     <td class="mdRow">
2678       <table cellpadding="0" cellspacing="0" border="0">
2679         <tr>
2680           <td class="md" nowrap valign="top">void Server::SendFrom           </td>
2681           <td class="md" valign="top">(&nbsp;</td>
2682           <td class="md" nowrap valign="top">int&nbsp;</td>
2683           <td class="mdname" nowrap> <em>Socket</em>, </td>
2684         </tr>
2685         <tr>
2686           <td class="md" nowrap align="right"></td>
2687           <td class="md"></td>
2688           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2689           <td class="mdname" nowrap> <em>User</em>, </td>
2690         </tr>
2691         <tr>
2692           <td class="md" nowrap align="right"></td>
2693           <td class="md"></td>
2694           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2695           <td class="mdname" nowrap> <em>s</em></td>
2696         </tr>
2697         <tr>
2698           <td class="md"></td>
2699           <td class="md">)&nbsp;</td>
2700           <td class="md" colspan="2"><code> [virtual]</code></td>
2701         </tr>
2702       </table>
2703     </td>
2704   </tr>
2705 </table>
2706 <table cellspacing="5" cellpadding="0" border="0">
2707   <tr>
2708     <td>
2709       &nbsp;
2710     </td>
2711     <td>
2712
2713 <p>
2714 Sends text from a user to a socket. 
2715 <p>
2716 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)
2717 <p>
2718 Definition at line <a class="el" href="modules_8cpp-source.html#l00431">431</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2719 <p>
2720 References <a class="el" href="globals_8h.html#WriteFrom_28int_20sock_2C_20userrec_20_2Auser_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteFrom()</a>.<div class="fragment"><pre class="fragment"><a name="l00432"></a>00432 {
2721 <a name="l00433"></a>00433         <a class="code" href="globals_8h.html#WriteFrom_28int_20sock_2C_20userrec_20_2Auser_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteFrom</a>(Socket,User,<span class="stringliteral">"%s"</span>,s.c_str());
2722 <a name="l00434"></a>00434 }
2723 </pre></div>
2724 <p>
2725     </td>
2726   </tr>
2727 </table>
2728 <a class="anchor" name="SendMode_28char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29"></a><!-- doxytag: member="Server::SendMode" ref="SendMode_28char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29" args="(char **parameters, int pcnt, userrec *user)" --><p>
2729 <table class="mdTable" cellpadding="2" cellspacing="0">
2730   <tr>
2731     <td class="mdRow">
2732       <table cellpadding="0" cellspacing="0" border="0">
2733         <tr>
2734           <td class="md" nowrap valign="top">void Server::SendMode           </td>
2735           <td class="md" valign="top">(&nbsp;</td>
2736           <td class="md" nowrap valign="top">char **&nbsp;</td>
2737           <td class="mdname" nowrap> <em>parameters</em>, </td>
2738         </tr>
2739         <tr>
2740           <td class="md" nowrap align="right"></td>
2741           <td class="md"></td>
2742           <td class="md" nowrap>int&nbsp;</td>
2743           <td class="mdname" nowrap> <em>pcnt</em>, </td>
2744         </tr>
2745         <tr>
2746           <td class="md" nowrap align="right"></td>
2747           <td class="md"></td>
2748           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2749           <td class="mdname" nowrap> <em>user</em></td>
2750         </tr>
2751         <tr>
2752           <td class="md"></td>
2753           <td class="md">)&nbsp;</td>
2754           <td class="md" colspan="2"><code> [virtual]</code></td>
2755         </tr>
2756       </table>
2757     </td>
2758   </tr>
2759 </table>
2760 <table cellspacing="5" cellpadding="0" border="0">
2761   <tr>
2762     <td>
2763       &nbsp;
2764     </td>
2765     <td>
2766
2767 <p>
2768 Sends a servermode. 
2769 <p>
2770 you must format the parameters array with the target, modes and parameters for those modes.<p>
2771 For example:<p>
2772 char *modes[3];<p>
2773 modes[0] = ChannelName;<p>
2774 modes[1] = "+o";<p>
2775 modes[2] = user-&gt;nick;<p>
2776 Srv-&gt;SendMode(modes,3,user);<p>
2777 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!
2778 <p>
2779 Definition at line <a class="el" href="modules_8cpp-source.html#l00416">416</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2780 <p>
2781 References <a class="el" href="mode_8h.html#server_5Fmode_28char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">server_mode()</a>.<div class="fragment"><pre class="fragment"><a name="l00417"></a>00417 {
2782 <a name="l00418"></a>00418         <a class="code" href="mode_8h.html#server_5Fmode_28char_20_2A_2Aparameters_2C_20int_20pcnt_2C_20userrec_20_2Auser_29">server_mode</a>(parameters,pcnt,user);
2783 <a name="l00419"></a>00419 }
2784 </pre></div>
2785 <p>
2786     </td>
2787   </tr>
2788 </table>
2789 <a class="anchor" name="SendOpers_28std_3A_3Astring_20s_29"></a><!-- doxytag: member="Server::SendOpers" ref="SendOpers_28std_3A_3Astring_20s_29" args="(std::string s)" --><p>
2790 <table class="mdTable" cellpadding="2" cellspacing="0">
2791   <tr>
2792     <td class="mdRow">
2793       <table cellpadding="0" cellspacing="0" border="0">
2794         <tr>
2795           <td class="md" nowrap valign="top">void Server::SendOpers           </td>
2796           <td class="md" valign="top">(&nbsp;</td>
2797           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2798           <td class="mdname1" valign="top" nowrap> <em>s</em>          </td>
2799           <td class="md" valign="top">&nbsp;)&nbsp;</td>
2800           <td class="md" nowrap><code> [virtual]</code></td>
2801         </tr>
2802       </table>
2803     </td>
2804   </tr>
2805 </table>
2806 <table cellspacing="5" cellpadding="0" border="0">
2807   <tr>
2808     <td>
2809       &nbsp;
2810     </td>
2811     <td>
2812
2813 <p>
2814 Sends text to all opers. 
2815 <p>
2816 This method sends a server notice to all opers with the usermode +s.
2817 <p>
2818 Definition at line <a class="el" href="modules_8cpp-source.html#l00341">341</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2819 <p>
2820 References <a class="el" href="globals_8h.html#WriteOpers_28char_20_2Atext_2C_2E_2E_2E_29">WriteOpers()</a>.<div class="fragment"><pre class="fragment"><a name="l00342"></a>00342 {
2821 <a name="l00343"></a>00343         <a class="code" href="globals_8h.html#WriteOpers_28char_20_2Atext_2C_2E_2E_2E_29">WriteOpers</a>(<span class="stringliteral">"%s"</span>,s.c_str());
2822 <a name="l00344"></a>00344 }
2823 </pre></div>
2824 <p>
2825     </td>
2826   </tr>
2827 </table>
2828 <a class="anchor" name="SendServ_28int_20Socket_2C_20std_3A_3Astring_20s_29"></a><!-- doxytag: member="Server::SendServ" ref="SendServ_28int_20Socket_2C_20std_3A_3Astring_20s_29" args="(int Socket, std::string s)" --><p>
2829 <table class="mdTable" cellpadding="2" cellspacing="0">
2830   <tr>
2831     <td class="mdRow">
2832       <table cellpadding="0" cellspacing="0" border="0">
2833         <tr>
2834           <td class="md" nowrap valign="top">void Server::SendServ           </td>
2835           <td class="md" valign="top">(&nbsp;</td>
2836           <td class="md" nowrap valign="top">int&nbsp;</td>
2837           <td class="mdname" nowrap> <em>Socket</em>, </td>
2838         </tr>
2839         <tr>
2840           <td class="md" nowrap align="right"></td>
2841           <td class="md"></td>
2842           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2843           <td class="mdname" nowrap> <em>s</em></td>
2844         </tr>
2845         <tr>
2846           <td class="md"></td>
2847           <td class="md">)&nbsp;</td>
2848           <td class="md" colspan="2"><code> [virtual]</code></td>
2849         </tr>
2850       </table>
2851     </td>
2852   </tr>
2853 </table>
2854 <table cellspacing="5" cellpadding="0" border="0">
2855   <tr>
2856     <td>
2857       &nbsp;
2858     </td>
2859     <td>
2860
2861 <p>
2862 Sends text from the server to a socket. 
2863 <p>
2864 This method writes a line of text to an established socket, with the servername prepended as used by numerics (see RFC 1459)
2865 <p>
2866 Definition at line <a class="el" href="modules_8cpp-source.html#l00426">426</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2867 <p>
2868 References <a class="el" href="globals_8h.html#WriteServ_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteServ()</a>.<div class="fragment"><pre class="fragment"><a name="l00427"></a>00427 {
2869 <a name="l00428"></a>00428         <a class="code" href="globals_8h.html#WriteServ_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteServ</a>(Socket,<span class="stringliteral">"%s"</span>,s.c_str());
2870 <a name="l00429"></a>00429 }
2871 </pre></div>
2872 <p>
2873     </td>
2874   </tr>
2875 </table>
2876 <a class="anchor" name="SendTo_28userrec_20_2ASource_2C_20userrec_20_2ADest_2C_20std_3A_3Astring_20s_29"></a><!-- doxytag: member="Server::SendTo" ref="SendTo_28userrec_20_2ASource_2C_20userrec_20_2ADest_2C_20std_3A_3Astring_20s_29" args="(userrec *Source, userrec *Dest, std::string s)" --><p>
2877 <table class="mdTable" cellpadding="2" cellspacing="0">
2878   <tr>
2879     <td class="mdRow">
2880       <table cellpadding="0" cellspacing="0" border="0">
2881         <tr>
2882           <td class="md" nowrap valign="top">void Server::SendTo           </td>
2883           <td class="md" valign="top">(&nbsp;</td>
2884           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2885           <td class="mdname" nowrap> <em>Source</em>, </td>
2886         </tr>
2887         <tr>
2888           <td class="md" nowrap align="right"></td>
2889           <td class="md"></td>
2890           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
2891           <td class="mdname" nowrap> <em>Dest</em>, </td>
2892         </tr>
2893         <tr>
2894           <td class="md" nowrap align="right"></td>
2895           <td class="md"></td>
2896           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2897           <td class="mdname" nowrap> <em>s</em></td>
2898         </tr>
2899         <tr>
2900           <td class="md"></td>
2901           <td class="md">)&nbsp;</td>
2902           <td class="md" colspan="2"><code> [virtual]</code></td>
2903         </tr>
2904       </table>
2905     </td>
2906   </tr>
2907 </table>
2908 <table cellspacing="5" cellpadding="0" border="0">
2909   <tr>
2910     <td>
2911       &nbsp;
2912     </td>
2913     <td>
2914
2915 <p>
2916 Sends text from a user to another user. 
2917 <p>
2918 This method writes a line of text to a user, with a user's nick/ident /host combination prepended, as used in PRIVMSG etc commands (see RFC 1459) If you specify NULL as the source, then the data will originate from the local server, e.g. instead of:<p>
2919 :user!ident TEXT<p>
2920 The format will become:<p>
2921 :localserver TEXT<p>
2922 Which is useful for numerics and server notices to single users, etc.
2923 <p>
2924 Definition at line <a class="el" href="modules_8cpp-source.html#l00436">436</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
2925 <p>
2926 References <a class="el" href="connection_8h-source.html#l00042">connection::fd</a>, <a class="el" href="globals_8h.html#Write_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">Write()</a>, and <a class="el" href="globals_8h.html#WriteTo_28userrec_20_2Asource_2C_20userrec_20_2Adest_2C_20char_20_2Adata_2C_2E_2E_2E_29">WriteTo()</a>.<div class="fragment"><pre class="fragment"><a name="l00437"></a>00437 {
2927 <a name="l00438"></a>00438         <span class="keywordflow">if</span> (!Source)
2928 <a name="l00439"></a>00439         {
2929 <a name="l00440"></a>00440                 <span class="comment">// if source is NULL, then the message originates from the local server</span>
2930 <a name="l00441"></a>00441                 <a class="code" href="globals_8h.html#Write_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">Write</a>(Dest-&gt;<a class="code" href="classconnection.html#fd">fd</a>,<span class="stringliteral">":%s %s"</span>,this-&gt;GetServerName().c_str(),s.c_str());
2931 <a name="l00442"></a>00442         }
2932 <a name="l00443"></a>00443         <span class="keywordflow">else</span>
2933 <a name="l00444"></a>00444         {
2934 <a name="l00445"></a>00445                 <span class="comment">// otherwise it comes from the user specified</span>
2935 <a name="l00446"></a>00446                 <a class="code" href="globals_8h.html#WriteTo_28userrec_20_2Asource_2C_20userrec_20_2Adest_2C_20char_20_2Adata_2C_2E_2E_2E_29">WriteTo</a>(Source,Dest,<span class="stringliteral">"%s"</span>,s.c_str());
2936 <a name="l00447"></a>00447         }
2937 <a name="l00448"></a>00448 }
2938 </pre></div>
2939 <p>
2940     </td>
2941   </tr>
2942 </table>
2943 <a class="anchor" name="SendToModeMask_28std_3A_3Astring_20modes_2C_20int_20flags_2C_20std_3A_3Astring_20text_29"></a><!-- doxytag: member="Server::SendToModeMask" ref="SendToModeMask_28std_3A_3Astring_20modes_2C_20int_20flags_2C_20std_3A_3Astring_20text_29" args="(std::string modes, int flags, std::string text)" --><p>
2944 <table class="mdTable" cellpadding="2" cellspacing="0">
2945   <tr>
2946     <td class="mdRow">
2947       <table cellpadding="0" cellspacing="0" border="0">
2948         <tr>
2949           <td class="md" nowrap valign="top">void Server::SendToModeMask           </td>
2950           <td class="md" valign="top">(&nbsp;</td>
2951           <td class="md" nowrap valign="top"><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2952           <td class="mdname" nowrap> <em>modes</em>, </td>
2953         </tr>
2954         <tr>
2955           <td class="md" nowrap align="right"></td>
2956           <td class="md"></td>
2957           <td class="md" nowrap>int&nbsp;</td>
2958           <td class="mdname" nowrap> <em>flags</em>, </td>
2959         </tr>
2960         <tr>
2961           <td class="md" nowrap align="right"></td>
2962           <td class="md"></td>
2963           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
2964           <td class="mdname" nowrap> <em>text</em></td>
2965         </tr>
2966         <tr>
2967           <td class="md"></td>
2968           <td class="md">)&nbsp;</td>
2969           <td class="md" colspan="2"><code> [virtual]</code></td>
2970         </tr>
2971       </table>
2972     </td>
2973   </tr>
2974 </table>
2975 <table cellspacing="5" cellpadding="0" border="0">
2976   <tr>
2977     <td>
2978       &nbsp;
2979     </td>
2980     <td>
2981
2982 <p>
2983 Sends to all users matching a mode mask You must specify one or more usermodes as the first parameter. 
2984 <p>
2985 These can be RFC specified modes such as +i, or module provided modes, including ones provided by your own module. In the second parameter you must place a flag value which indicates wether the modes you have given will be logically ANDed or OR'ed. You may use one of either WM_AND or WM_OR. for example, if you were to use:<p>
2986 Serv-&gt;SendToModeMask("xi", WM_OR, "m00");<p>
2987 Then the text 'm00' will be sent to all users with EITHER mode x or i. Conversely if you used WM_AND, the user must have both modes set to receive the message.
2988 <p>
2989 Definition at line <a class="el" href="modules_8cpp-source.html#l00354">354</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.<div class="fragment"><pre class="fragment"><a name="l00355"></a>00355 {
2990 <a name="l00356"></a>00356         WriteMode(modes.c_str(),flags,<span class="stringliteral">"%s"</span>,text.c_str());
2991 <a name="l00357"></a>00357 }
2992 </pre></div>
2993 <p>
2994     </td>
2995   </tr>
2996 </table>
2997 <a class="anchor" name="SendWallops_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_29"></a><!-- doxytag: member="Server::SendWallops" ref="SendWallops_28userrec_20_2AUser_2C_20std_3A_3Astring_20text_29" args="(userrec *User, std::string text)" --><p>
2998 <table class="mdTable" cellpadding="2" cellspacing="0">
2999   <tr>
3000     <td class="mdRow">
3001       <table cellpadding="0" cellspacing="0" border="0">
3002         <tr>
3003           <td class="md" nowrap valign="top">void Server::SendWallops           </td>
3004           <td class="md" valign="top">(&nbsp;</td>
3005           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
3006           <td class="mdname" nowrap> <em>User</em>, </td>
3007         </tr>
3008         <tr>
3009           <td class="md" nowrap align="right"></td>
3010           <td class="md"></td>
3011           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
3012           <td class="mdname" nowrap> <em>text</em></td>
3013         </tr>
3014         <tr>
3015           <td class="md"></td>
3016           <td class="md">)&nbsp;</td>
3017           <td class="md" colspan="2"><code> [virtual]</code></td>
3018         </tr>
3019       </table>
3020     </td>
3021   </tr>
3022 </table>
3023 <table cellspacing="5" cellpadding="0" border="0">
3024   <tr>
3025     <td>
3026       &nbsp;
3027     </td>
3028     <td>
3029
3030 <p>
3031 Sends a WALLOPS message. 
3032 <p>
3033 This method writes a WALLOPS message to all users with the +w flag, originating from the specified user.
3034 <p>
3035 Definition at line <a class="el" href="modules_8cpp-source.html#l00484">484</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
3036 <p>
3037 References <a class="el" href="globals_8h.html#WriteWallOps_28userrec_20_2Asource_2C_20bool_20local_5Fonly_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteWallOps()</a>.<div class="fragment"><pre class="fragment"><a name="l00485"></a>00485 {
3038 <a name="l00486"></a>00486         <a class="code" href="globals_8h.html#WriteWallOps_28userrec_20_2Asource_2C_20bool_20local_5Fonly_2C_20char_20_2Atext_2C_2E_2E_2E_29">WriteWallOps</a>(User,<span class="keyword">false</span>,<span class="stringliteral">"%s"</span>,text.c_str());
3039 <a name="l00487"></a>00487 }
3040 </pre></div>
3041 <p>
3042     </td>
3043   </tr>
3044 </table>
3045 <a class="anchor" name="UserToPseudo_28userrec_20_2Auser_2C_20std_3A_3Astring_20message_29"></a><!-- doxytag: member="Server::UserToPseudo" ref="UserToPseudo_28userrec_20_2Auser_2C_20std_3A_3Astring_20message_29" args="(userrec *user, std::string message)" --><p>
3046 <table class="mdTable" cellpadding="2" cellspacing="0">
3047   <tr>
3048     <td class="mdRow">
3049       <table cellpadding="0" cellspacing="0" border="0">
3050         <tr>
3051           <td class="md" nowrap valign="top">bool Server::UserToPseudo           </td>
3052           <td class="md" valign="top">(&nbsp;</td>
3053           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
3054           <td class="mdname" nowrap> <em>user</em>, </td>
3055         </tr>
3056         <tr>
3057           <td class="md" nowrap align="right"></td>
3058           <td class="md"></td>
3059           <td class="md" nowrap><a class="el" href="namespaceirc.html#string">std::string</a>&nbsp;</td>
3060           <td class="mdname" nowrap> <em>message</em></td>
3061         </tr>
3062         <tr>
3063           <td class="md"></td>
3064           <td class="md">)&nbsp;</td>
3065           <td class="md" colspan="2"><code> [virtual]</code></td>
3066         </tr>
3067       </table>
3068     </td>
3069   </tr>
3070 </table>
3071 <table cellspacing="5" cellpadding="0" border="0">
3072   <tr>
3073     <td>
3074       &nbsp;
3075     </td>
3076     <td>
3077
3078 <p>
3079 Remove a user's connection to the irc server, but leave their client in existence in the user hash. 
3080 <p>
3081 When you call this function, the user's file descriptor will be replaced with the value of FD_MAGIC_NUMBER and their old file descriptor will be closed. This idle client will remain until it is restored with a valid file descriptor, or is removed from IRC by an operator After this call, the pointer to user will be invalid.
3082 <p>
3083 Definition at line <a class="el" href="modules_8cpp-source.html#l00593">593</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
3084 <p>
3085 References <a class="el" href="users_8cpp-source.html#l00232">userrec::ClearBuffer()</a>, <a class="el" href="socketengine_8cpp-source.html#l00103">SocketEngine::DelFd()</a>, <a class="el" href="connection_8h-source.html#l00042">connection::fd</a>, <a class="el" href="modules_8h-source.html#l00101">FD_MAGIC_NUMBER</a>, <a class="el" href="connection_8h-source.html#l00046">connection::host</a>, <a class="el" href="users_8h-source.html#l00129">userrec::ident</a>, and <a class="el" href="globals_8h.html#Write_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">Write()</a>.<div class="fragment"><pre class="fragment"><a name="l00594"></a>00594 {
3086 <a name="l00595"></a>00595         <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> old_fd = user-&gt;<a class="code" href="classconnection.html#fd">fd</a>;
3087 <a name="l00596"></a>00596         user-&gt;<a class="code" href="classconnection.html#fd">fd</a> = <a class="code" href="modules_8h.html#FD_5FMAGIC_5FNUMBER">FD_MAGIC_NUMBER</a>;
3088 <a name="l00597"></a>00597         user-&gt;<a class="code" href="classuserrec.html#ClearBuffer_28_29">ClearBuffer</a>();
3089 <a name="l00598"></a>00598         <a class="code" href="globals_8h.html#Write_28int_20sock_2C_20char_20_2Atext_2C_2E_2E_2E_29">Write</a>(old_fd,<span class="stringliteral">"ERROR :Closing link (%s@%s) [%s]"</span>,user-&gt;<a class="code" href="classuserrec.html#ident_5BIDENTMAX_2B_32_5D">ident</a>,user-&gt;<a class="code" href="classconnection.html#host_5B_31_36_30_5D">host</a>,message.c_str());
3090 <a name="l00599"></a>00599         <a class="code" href="modules_8cpp.html#SE">SE</a>-&gt;<a class="code" href="classSocketEngine.html#DelFd_28int_20fd_29">DelFd</a>(old_fd);
3091 <a name="l00600"></a>00600         shutdown(old_fd,2);
3092 <a name="l00601"></a>00601         close(old_fd);
3093 <a name="l00602"></a>00602         <span class="keywordflow">return</span> <span class="keyword">true</span>;
3094 <a name="l00603"></a>00603 }
3095 </pre></div>
3096 <p>
3097     </td>
3098   </tr>
3099 </table>
3100 <hr>The documentation for this class was generated from the following files:<ul>
3101 <li><a class="el" href="modules_8h-source.html">modules.h</a><li><a class="el" href="modules_8cpp-source.html">modules.cpp</a></ul>
3102 <hr size="1"><address style="align: right;"><small>Generated on Wed Dec 14 19:16:27 2005 for InspIRCd by&nbsp;
3103 <a href="http://www.doxygen.org/index.html">
3104 <img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.4.4-20050815 </small></address>
3105 </body>
3106 </html>