]> git.netwichtig.de Git - user/henk/code/inspircd.git/blob - docs/module-doc/classModule.html
Documentation update
[user/henk/code/inspircd.git] / docs / module-doc / classModule.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2 <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
3 <title>InspIRCd: Module class Reference</title>
4 <link href="inspircd.css" rel="stylesheet" type="text/css">
5 </head><body>
6 <!-- Generated by Doxygen 1.3.3 -->
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">Compound&nbsp;List</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="functions.html">Compound&nbsp;Members</a> | <a class="qindex" href="globals.html">File&nbsp;Members</a></div>
8 <h1>Module Class Reference</h1>Base class for all InspIRCd modules This class is the base class for InspIRCd modules.  
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 Inherits <a class="el" href="classclassbase.html">classbase</a>.
14 <p>
15 <a href="classModule-members.html">List of all members.</a><table border=0 cellpadding=0 cellspacing=0>
16 <tr><td></td></tr>
17 <tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr>
18 <tr><td class="memItemLeft" nowrap align=right valign=top>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a0">Module</a> ()</td></tr>
19
20 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Default constructor creates a module class. </em> <a href="#a0"></a><em><br><br></td></tr>
21 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a1">~Module</a> ()</td></tr>
22
23 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Default destructor destroys a module class. </em> <a href="#a1"></a><em><br><br></td></tr>
24 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual <a class="el" href="classVersion.html">Version</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a2">GetVersion</a> ()</td></tr>
25
26 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the version number of a Module. </em> <a href="#a2"></a><em><br><br></td></tr>
27 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a3">OnUserConnect</a> (<a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
28
29 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called when a user connects. </em> <a href="#a3"></a><em><br><br></td></tr>
30 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a4">OnUserQuit</a> (<a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
31
32 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called when a user quits. </em> <a href="#a4"></a><em><br><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="classModule.html#a5">OnUserJoin</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="classchanrec.html">chanrec</a> *channel)</td></tr>
34
35 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called when a user joins a channel. </em> <a href="#a5"></a><em><br><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="classModule.html#a6">OnUserPart</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="classchanrec.html">chanrec</a> *channel)</td></tr>
37
38 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called when a user parts a channel. </em> <a href="#a6"></a><em><br><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="classModule.html#a7">OnPacketTransmit</a> (char *p)</td></tr>
40
41 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called before a packet is transmitted across the irc network between two irc servers. </em> <a href="#a7"></a><em><br><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="classModule.html#a8">OnPacketReceive</a> (char *p)</td></tr>
43
44 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called after a packet is received from another irc server. </em> <a href="#a8"></a><em><br><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="classModule.html#a9">OnRehash</a> ()</td></tr>
46
47 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called on rehash. </em> <a href="#a9"></a><em><br><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="classModule.html#a10">OnServerRaw</a> (std::string &amp;raw, bool inbound, <a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
49
50 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called when a raw command is transmitted or received. </em> <a href="#a10"></a><em><br><br></td></tr>
51 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual int&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a11">OnExtendedMode</a> (<a class="el" href="classuserrec.html">userrec</a> *user, void *target, char modechar, int type, bool mode_on, <a class="el" href="modules_8h.html#a27">string_list</a> &amp;params)</td></tr>
52
53 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called whenever an extended mode is to be processed. </em> <a href="#a11"></a><em><br><br></td></tr>
54 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual int&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a12">OnUserPreJoin</a> (<a class="el" href="classuserrec.html">userrec</a> *user, <a class="el" href="classchanrec.html">chanrec</a> *chan, const char *cname)</td></tr>
55
56 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called whenever a user is about to join a channel, before any processing is done. </em> <a href="#a12"></a><em><br><br></td></tr>
57 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a13">OnOper</a> (<a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
58
59 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called whenever a user opers locally. </em> <a href="#a13"></a><em><br><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="classModule.html#a14">OnInfo</a> (<a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
61
62 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called whenever a user types /INFO. </em> <a href="#a14"></a><em><br><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="classModule.html#a15">OnWhois</a> (<a class="el" href="classuserrec.html">userrec</a> *source, <a class="el" href="classuserrec.html">userrec</a> *dest)</td></tr>
64
65 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called whenever a /WHOIS is performed on a local user. </em> <a href="#a15"></a><em><br><br></td></tr>
66 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual int&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a16">OnUserPreInvite</a> (<a class="el" href="classuserrec.html">userrec</a> *source, <a class="el" href="classuserrec.html">userrec</a> *dest, <a class="el" href="classchanrec.html">chanrec</a> *channel)</td></tr>
67
68 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called whenever a user is about to invite another user into a channel, before any processing is done. </em> <a href="#a16"></a><em><br><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="classModule.html#a17">OnUserPreMessage</a> (<a class="el" href="classuserrec.html">userrec</a> *user, void *dest, int target_type, std::string &amp;text)</td></tr>
70
71 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called whenever a user is about to PRIVMSG A user or a channel, before any processing is done. </em> <a href="#a17"></a><em><br><br></td></tr>
72 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual int&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a18">OnUserPreNotice</a> (<a class="el" href="classuserrec.html">userrec</a> *user, void *dest, int target_type, std::string &amp;text)</td></tr>
73
74 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called whenever a user is about to NOTICE A user or a channel, before any processing is done. </em> <a href="#a18"></a><em><br><br></td></tr>
75 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual int&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a19">OnUserPreNick</a> (<a class="el" href="classuserrec.html">userrec</a> *user, std::string newnick)</td></tr>
76
77 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called before any nickchange, local or remote. </em> <a href="#a19"></a><em><br><br></td></tr>
78 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual int&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a20">OnAccessCheck</a> (<a class="el" href="classuserrec.html">userrec</a> *source, <a class="el" href="classuserrec.html">userrec</a> *dest, <a class="el" href="classchanrec.html">chanrec</a> *channel, int access_type)</td></tr>
79
80 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called before an action which requires a channel privilage check. </em> <a href="#a20"></a><em><br><br></td></tr>
81 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual <a class="el" href="modules_8h.html#a27">string_list</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a21">OnUserSync</a> (<a class="el" href="classuserrec.html">userrec</a> *user)</td></tr>
82
83 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called during a netburst to sync user data. </em> <a href="#a21"></a><em><br><br></td></tr>
84 <tr><td class="memItemLeft" nowrap align=right valign=top>virtual <a class="el" href="modules_8h.html#a27">string_list</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classModule.html#a22">OnChannelSync</a> (<a class="el" href="classchanrec.html">chanrec</a> *chan)</td></tr>
85
86 <tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Called during a netburst to sync channel data. </em> <a href="#a22"></a><em><br><br></td></tr>
87 </table>
88 <hr><a name="_details"></a><h2>Detailed Description</h2>
89 Base class for all InspIRCd modules This class is the base class for InspIRCd modules. 
90 <p>
91 All modules must inherit from this class, its methods will be called when irc server events occur. class inherited from module must be instantiated by the <a class="el" href="classModuleFactory.html">ModuleFactory</a> class (see relevent section) for the plugin to be initialised. 
92 <p>
93
94 <p>
95 Definition at line <a class="el" href="modules_8h-source.html#l00126">126</a> of file <a class="el" href="modules_8h-source.html">modules.h</a>.<hr><h2>Constructor &amp; Destructor Documentation</h2>
96 <a name="a0" doxytag="Module::Module"></a><p>
97 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
98   <tr>
99     <td class="mdRow">
100       <table cellpadding="0" cellspacing="0" border="0">
101         <tr>
102           <td class="md" nowrap valign="top"> Module::Module </td>
103           <td class="md" valign="top">(&nbsp;</td>
104           <td class="mdname1" valign="top" nowrap>          </td>
105           <td class="md" valign="top">&nbsp;)&nbsp;</td>
106           <td class="md" nowrap></td>
107         </tr>
108
109       </table>
110     </td>
111   </tr>
112 </table>
113 <table cellspacing=5 cellpadding=0 border=0>
114   <tr>
115     <td>
116       &nbsp;
117     </td>
118     <td>
119
120 <p>
121 Default constructor creates a module class. 
122 <p>
123
124 <p>
125 Definition at line <a class="el" href="modules_8cpp-source.html#l00297">297</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
126 <p>
127 <div class="fragment"><pre>00297 { }
128 </pre></div>    </td>
129   </tr>
130 </table>
131 <a name="a1" doxytag="Module::~Module"></a><p>
132 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
133   <tr>
134     <td class="mdRow">
135       <table cellpadding="0" cellspacing="0" border="0">
136         <tr>
137           <td class="md" nowrap valign="top"> Module::~<a class="el" href="classModule.html">Module</a> </td>
138           <td class="md" valign="top">(&nbsp;</td>
139           <td class="mdname1" valign="top" nowrap>          </td>
140           <td class="md" valign="top">&nbsp;)&nbsp;</td>
141           <td class="md" nowrap><code> [virtual]</code></td>
142         </tr>
143
144       </table>
145     </td>
146   </tr>
147 </table>
148 <table cellspacing=5 cellpadding=0 border=0>
149   <tr>
150     <td>
151       &nbsp;
152     </td>
153     <td>
154
155 <p>
156 Default destructor destroys a module class. 
157 <p>
158
159 <p>
160 Definition at line <a class="el" href="modules_8cpp-source.html#l00298">298</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
161 <p>
162 <div class="fragment"><pre>00298 { }
163 </pre></div>    </td>
164   </tr>
165 </table>
166 <hr><h2>Member Function Documentation</h2>
167 <a name="a2" doxytag="Module::GetVersion"></a><p>
168 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
169   <tr>
170     <td class="mdRow">
171       <table cellpadding="0" cellspacing="0" border="0">
172         <tr>
173           <td class="md" nowrap valign="top"> <a class="el" href="classVersion.html">Version</a> Module::GetVersion </td>
174           <td class="md" valign="top">(&nbsp;</td>
175           <td class="mdname1" valign="top" nowrap>          </td>
176           <td class="md" valign="top">&nbsp;)&nbsp;</td>
177           <td class="md" nowrap><code> [virtual]</code></td>
178         </tr>
179
180       </table>
181     </td>
182   </tr>
183 </table>
184 <table cellspacing=5 cellpadding=0 border=0>
185   <tr>
186     <td>
187       &nbsp;
188     </td>
189     <td>
190
191 <p>
192 Returns the version number of a Module. 
193 <p>
194 The method should return a <a class="el" href="classVersion.html">Version</a> object with its version information assigned via <a class="el" href="classVersion.html#a0">Version::Version</a>
195 <p>
196 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>.
197 <p>
198 <div class="fragment"><pre>00309 { <span class="keywordflow">return</span> <a class="code" href="classVersion.html">Version</a>(1,0,0,0); }
199 </pre></div>    </td>
200   </tr>
201 </table>
202 <a name="a20" doxytag="Module::OnAccessCheck"></a><p>
203 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
204   <tr>
205     <td class="mdRow">
206       <table cellpadding="0" cellspacing="0" border="0">
207         <tr>
208           <td class="md" nowrap valign="top"> int Module::OnAccessCheck </td>
209           <td class="md" valign="top">(&nbsp;</td>
210           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
211           <td class="mdname" nowrap> <em>source</em>, </td>
212         </tr>
213         <tr>
214           <td></td>
215           <td></td>
216           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
217           <td class="mdname" nowrap> <em>dest</em>, </td>
218         </tr>
219         <tr>
220           <td></td>
221           <td></td>
222           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
223           <td class="mdname" nowrap> <em>channel</em>, </td>
224         </tr>
225         <tr>
226           <td></td>
227           <td></td>
228           <td class="md" nowrap>int&nbsp;</td>
229           <td class="mdname" nowrap> <em>access_type</em></td>
230         </tr>
231         <tr>
232           <td></td>
233           <td class="md">)&nbsp;</td>
234           <td class="md" colspan="2"><code> [virtual]</code></td>
235         </tr>
236
237       </table>
238     </td>
239   </tr>
240 </table>
241 <table cellspacing=5 cellpadding=0 border=0>
242   <tr>
243     <td>
244       &nbsp;
245     </td>
246     <td>
247
248 <p>
249 Called before an action which requires a channel privilage check. 
250 <p>
251 This function is called before many functions which check a users status on a channel, for example before opping a user, deopping a user, kicking a user, etc. There are several values for access_type which indicate for what reason access is being checked. These are:<br>
252 <br>
253  AC_KICK (0) - A user is being kicked<br>
254  AC_DEOP (1) - a user is being deopped<br>
255  AC_OP (2) - a user is being opped<br>
256  AC_VOICE (3) - a user is being voiced<br>
257  AC_DEVOICE (4) - a user is being devoiced<br>
258  AC_HALFOP (5) - a user is being halfopped<br>
259  AC_DEHALFOP (6) - a user is being dehalfopped<br>
260  AC_INVITE (7) - a user is being invited<br>
261  AC_GENERAL_MODE (8) - a user channel mode is being changed<br>
262 <br>
263  Upon returning from your function you must return either ACR_DEFAULT, to indicate the module wishes to do nothing, or ACR_DENY where approprate to deny the action, and ACR_ALLOW where appropriate to allow the action. Please note that in the case of some access checks (such as AC_GENERAL_MODE) access may be denied 'upstream' causing other checks such as AC_DEOP to not be reached. Be very careful with use of the AC_GENERAL_MODE type, as it may inadvertently override the behaviour of other modules. When the access_type is AC_GENERAL_MODE, the destination of the mode will be NULL (as it has not yet been determined).
264 <p>
265 Definition at line <a class="el" href="modules_8cpp-source.html#l00317">317</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
266 <p>
267 References <a class="el" href="modules_8h-source.html#l00037">ACR_DEFAULT</a>.
268 <p>
269 <div class="fragment"><pre>00317 { <span class="keywordflow">return</span> <a class="code" href="modules_8h.html#a8">ACR_DEFAULT</a>; };
270 </pre></div>    </td>
271   </tr>
272 </table>
273 <a name="a22" doxytag="Module::OnChannelSync"></a><p>
274 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
275   <tr>
276     <td class="mdRow">
277       <table cellpadding="0" cellspacing="0" border="0">
278         <tr>
279           <td class="md" nowrap valign="top"> <a class="el" href="modules_8h.html#a27">string_list</a> Module::OnChannelSync </td>
280           <td class="md" valign="top">(&nbsp;</td>
281           <td class="md" nowrap valign="top"><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
282           <td class="mdname1" valign="top" nowrap> <em>chan</em>          </td>
283           <td class="md" valign="top">&nbsp;)&nbsp;</td>
284           <td class="md" nowrap><code> [virtual]</code></td>
285         </tr>
286
287       </table>
288     </td>
289   </tr>
290 </table>
291 <table cellspacing=5 cellpadding=0 border=0>
292   <tr>
293     <td>
294       &nbsp;
295     </td>
296     <td>
297
298 <p>
299 Called during a netburst to sync channel data. 
300 <p>
301 This is called during the netburst on a per-channel basis. You should use this call to up any special channel-related things which are implemented by your module, e.g. sending listmodes. You may return multiple commands in the string_list.
302 <p>
303 Definition at line <a class="el" href="modules_8cpp-source.html#l00319">319</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
304 <p>
305 References <a class="el" href="modules_8h-source.html#l00061">string_list</a>.
306 <p>
307 <div class="fragment"><pre>00319 { <a class="code" href="modules_8h.html#a27">string_list</a> empty; <span class="keywordflow">return</span> empty; }
308 </pre></div>    </td>
309   </tr>
310 </table>
311 <a name="a11" doxytag="Module::OnExtendedMode"></a><p>
312 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
313   <tr>
314     <td class="mdRow">
315       <table cellpadding="0" cellspacing="0" border="0">
316         <tr>
317           <td class="md" nowrap valign="top"> int Module::OnExtendedMode </td>
318           <td class="md" valign="top">(&nbsp;</td>
319           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
320           <td class="mdname" nowrap> <em>user</em>, </td>
321         </tr>
322         <tr>
323           <td></td>
324           <td></td>
325           <td class="md" nowrap>void *&nbsp;</td>
326           <td class="mdname" nowrap> <em>target</em>, </td>
327         </tr>
328         <tr>
329           <td></td>
330           <td></td>
331           <td class="md" nowrap>char&nbsp;</td>
332           <td class="mdname" nowrap> <em>modechar</em>, </td>
333         </tr>
334         <tr>
335           <td></td>
336           <td></td>
337           <td class="md" nowrap>int&nbsp;</td>
338           <td class="mdname" nowrap> <em>type</em>, </td>
339         </tr>
340         <tr>
341           <td></td>
342           <td></td>
343           <td class="md" nowrap>bool&nbsp;</td>
344           <td class="mdname" nowrap> <em>mode_on</em>, </td>
345         </tr>
346         <tr>
347           <td></td>
348           <td></td>
349           <td class="md" nowrap><a class="el" href="modules_8h.html#a27">string_list</a> &amp;&nbsp;</td>
350           <td class="mdname" nowrap> <em>params</em></td>
351         </tr>
352         <tr>
353           <td></td>
354           <td class="md">)&nbsp;</td>
355           <td class="md" colspan="2"><code> [virtual]</code></td>
356         </tr>
357
358       </table>
359     </td>
360   </tr>
361 </table>
362 <table cellspacing=5 cellpadding=0 border=0>
363   <tr>
364     <td>
365       &nbsp;
366     </td>
367     <td>
368
369 <p>
370 Called whenever an extended mode is to be processed. 
371 <p>
372 The type parameter is MT_SERVER, MT_CLIENT or MT_CHANNEL, dependent on where the mode is being changed. mode_on is set when the mode is being set, in which case params contains a list of parameters for the mode as strings. If mode_on is false, the mode is being removed, and parameters may contain the parameters for the mode, dependent on wether they were defined when a mode handler was set up with <a class="el" href="classServer.html#a21">Server::AddExtendedMode</a> If the mode is a channel mode, target is a chanrec*, and if it is a user mode, target is a userrec*. You must cast this value yourself to make use of it.
373 <p>
374 Definition at line <a class="el" href="modules_8cpp-source.html#l00308">308</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
375 <p>
376 <div class="fragment"><pre>00308 { <span class="keywordflow">return</span> <span class="keyword">false</span>; }
377 </pre></div>    </td>
378   </tr>
379 </table>
380 <a name="a14" doxytag="Module::OnInfo"></a><p>
381 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
382   <tr>
383     <td class="mdRow">
384       <table cellpadding="0" cellspacing="0" border="0">
385         <tr>
386           <td class="md" nowrap valign="top"> void Module::OnInfo </td>
387           <td class="md" valign="top">(&nbsp;</td>
388           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
389           <td class="mdname1" valign="top" nowrap> <em>user</em>          </td>
390           <td class="md" valign="top">&nbsp;)&nbsp;</td>
391           <td class="md" nowrap><code> [virtual]</code></td>
392         </tr>
393
394       </table>
395     </td>
396   </tr>
397 </table>
398 <table cellspacing=5 cellpadding=0 border=0>
399   <tr>
400     <td>
401       &nbsp;
402     </td>
403     <td>
404
405 <p>
406 Called whenever a user types /INFO. 
407 <p>
408 The userrec will contain the information of the user who typed the command. Modules may use this method to output their own credits in /INFO (which is the ircd's version of an about box). It is purposefully not possible to modify any info that has already been output, or halt the list. You must write a 371 numeric to the user, containing your info in the following format:<p>
409 &lt;nick&gt; :information here
410 <p>
411 Definition at line <a class="el" href="modules_8cpp-source.html#l00311">311</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
412 <p>
413 <div class="fragment"><pre>00311 { };
414 </pre></div>    </td>
415   </tr>
416 </table>
417 <a name="a13" doxytag="Module::OnOper"></a><p>
418 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
419   <tr>
420     <td class="mdRow">
421       <table cellpadding="0" cellspacing="0" border="0">
422         <tr>
423           <td class="md" nowrap valign="top"> void Module::OnOper </td>
424           <td class="md" valign="top">(&nbsp;</td>
425           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
426           <td class="mdname1" valign="top" nowrap> <em>user</em>          </td>
427           <td class="md" valign="top">&nbsp;)&nbsp;</td>
428           <td class="md" nowrap><code> [virtual]</code></td>
429         </tr>
430
431       </table>
432     </td>
433   </tr>
434 </table>
435 <table cellspacing=5 cellpadding=0 border=0>
436   <tr>
437     <td>
438       &nbsp;
439     </td>
440     <td>
441
442 <p>
443 Called whenever a user opers locally. 
444 <p>
445 The userrec will contain the oper mode 'o' as this function is called after any modifications are made to the user's structure by the core.
446 <p>
447 Definition at line <a class="el" href="modules_8cpp-source.html#l00310">310</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
448 <p>
449 <div class="fragment"><pre>00310 { };
450 </pre></div>    </td>
451   </tr>
452 </table>
453 <a name="a8" doxytag="Module::OnPacketReceive"></a><p>
454 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
455   <tr>
456     <td class="mdRow">
457       <table cellpadding="0" cellspacing="0" border="0">
458         <tr>
459           <td class="md" nowrap valign="top"> void Module::OnPacketReceive </td>
460           <td class="md" valign="top">(&nbsp;</td>
461           <td class="md" nowrap valign="top">char *&nbsp;</td>
462           <td class="mdname1" valign="top" nowrap> <em>p</em>          </td>
463           <td class="md" valign="top">&nbsp;)&nbsp;</td>
464           <td class="md" nowrap><code> [virtual]</code></td>
465         </tr>
466
467       </table>
468     </td>
469   </tr>
470 </table>
471 <table cellspacing=5 cellpadding=0 border=0>
472   <tr>
473     <td>
474       &nbsp;
475     </td>
476     <td>
477
478 <p>
479 Called after a packet is received from another irc server. 
480 <p>
481 The packet is represented as a char*, as it should be regarded as a buffer, and not a string. This allows you to easily represent it in the correct ways to implement encryption, compression, digital signatures and anything else you may want to add. This should be regarded as a pre-processor and will be called immediately after the packet is received but before any other operations with the core of the ircd.
482 <p>
483 Definition at line <a class="el" href="modules_8cpp-source.html#l00304">304</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
484 <p>
485 <div class="fragment"><pre>00304 { }
486 </pre></div>    </td>
487   </tr>
488 </table>
489 <a name="a7" doxytag="Module::OnPacketTransmit"></a><p>
490 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
491   <tr>
492     <td class="mdRow">
493       <table cellpadding="0" cellspacing="0" border="0">
494         <tr>
495           <td class="md" nowrap valign="top"> void Module::OnPacketTransmit </td>
496           <td class="md" valign="top">(&nbsp;</td>
497           <td class="md" nowrap valign="top">char *&nbsp;</td>
498           <td class="mdname1" valign="top" nowrap> <em>p</em>          </td>
499           <td class="md" valign="top">&nbsp;)&nbsp;</td>
500           <td class="md" nowrap><code> [virtual]</code></td>
501         </tr>
502
503       </table>
504     </td>
505   </tr>
506 </table>
507 <table cellspacing=5 cellpadding=0 border=0>
508   <tr>
509     <td>
510       &nbsp;
511     </td>
512     <td>
513
514 <p>
515 Called before a packet is transmitted across the irc network between two irc servers. 
516 <p>
517 The packet is represented as a char*, as it should be regarded as a buffer, and not a string. This allows you to easily represent it in the correct ways to implement encryption, compression, digital signatures and anything else you may want to add. This should be regarded as a pre-processor and will be called before ANY other operations within the ircd core program.
518 <p>
519 Definition at line <a class="el" href="modules_8cpp-source.html#l00303">303</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
520 <p>
521 <div class="fragment"><pre>00303 { }
522 </pre></div>    </td>
523   </tr>
524 </table>
525 <a name="a9" doxytag="Module::OnRehash"></a><p>
526 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
527   <tr>
528     <td class="mdRow">
529       <table cellpadding="0" cellspacing="0" border="0">
530         <tr>
531           <td class="md" nowrap valign="top"> void Module::OnRehash </td>
532           <td class="md" valign="top">(&nbsp;</td>
533           <td class="mdname1" valign="top" nowrap>          </td>
534           <td class="md" valign="top">&nbsp;)&nbsp;</td>
535           <td class="md" nowrap><code> [virtual]</code></td>
536         </tr>
537
538       </table>
539     </td>
540   </tr>
541 </table>
542 <table cellspacing=5 cellpadding=0 border=0>
543   <tr>
544     <td>
545       &nbsp;
546     </td>
547     <td>
548
549 <p>
550 Called on rehash. 
551 <p>
552 This method is called prior to a /REHASH or when a SIGHUP is received from the operating system. You should use it to reload any files so that your module keeps in step with the rest of the application.
553 <p>
554 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>.
555 <p>
556 <div class="fragment"><pre>00305 { }
557 </pre></div>    </td>
558   </tr>
559 </table>
560 <a name="a10" doxytag="Module::OnServerRaw"></a><p>
561 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
562   <tr>
563     <td class="mdRow">
564       <table cellpadding="0" cellspacing="0" border="0">
565         <tr>
566           <td class="md" nowrap valign="top"> void Module::OnServerRaw </td>
567           <td class="md" valign="top">(&nbsp;</td>
568           <td class="md" nowrap valign="top">std::string &amp;&nbsp;</td>
569           <td class="mdname" nowrap> <em>raw</em>, </td>
570         </tr>
571         <tr>
572           <td></td>
573           <td></td>
574           <td class="md" nowrap>bool&nbsp;</td>
575           <td class="mdname" nowrap> <em>inbound</em>, </td>
576         </tr>
577         <tr>
578           <td></td>
579           <td></td>
580           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
581           <td class="mdname" nowrap> <em>user</em></td>
582         </tr>
583         <tr>
584           <td></td>
585           <td class="md">)&nbsp;</td>
586           <td class="md" colspan="2"><code> [virtual]</code></td>
587         </tr>
588
589       </table>
590     </td>
591   </tr>
592 </table>
593 <table cellspacing=5 cellpadding=0 border=0>
594   <tr>
595     <td>
596       &nbsp;
597     </td>
598     <td>
599
600 <p>
601 Called when a raw command is transmitted or received. 
602 <p>
603 This method is the lowest level of handler available to a module. It will be called with raw data which is passing through a connected socket. If you wish, you may munge this data by changing the string parameter "raw". If you do this, after your function exits it will immediately be cut down to 510 characters plus a carriage return and linefeed. For INBOUND messages only (where inbound is set to true) the value of user will be the userrec of the connection sending the data. This is not possible for outbound data because the data may be being routed to multiple targets.
604 <p>
605 Definition at line <a class="el" href="modules_8cpp-source.html#l00306">306</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
606 <p>
607 <div class="fragment"><pre>00306 { }
608 </pre></div>    </td>
609   </tr>
610 </table>
611 <a name="a3" doxytag="Module::OnUserConnect"></a><p>
612 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
613   <tr>
614     <td class="mdRow">
615       <table cellpadding="0" cellspacing="0" border="0">
616         <tr>
617           <td class="md" nowrap valign="top"> void Module::OnUserConnect </td>
618           <td class="md" valign="top">(&nbsp;</td>
619           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
620           <td class="mdname1" valign="top" nowrap> <em>user</em>          </td>
621           <td class="md" valign="top">&nbsp;)&nbsp;</td>
622           <td class="md" nowrap><code> [virtual]</code></td>
623         </tr>
624
625       </table>
626     </td>
627   </tr>
628 </table>
629 <table cellspacing=5 cellpadding=0 border=0>
630   <tr>
631     <td>
632       &nbsp;
633     </td>
634     <td>
635
636 <p>
637 Called when a user connects. 
638 <p>
639 The details of the connecting user are available to you in the parameter userrec *user
640 <p>
641 Definition at line <a class="el" href="modules_8cpp-source.html#l00299">299</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
642 <p>
643 <div class="fragment"><pre>00299 { }
644 </pre></div>    </td>
645   </tr>
646 </table>
647 <a name="a5" doxytag="Module::OnUserJoin"></a><p>
648 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
649   <tr>
650     <td class="mdRow">
651       <table cellpadding="0" cellspacing="0" border="0">
652         <tr>
653           <td class="md" nowrap valign="top"> void Module::OnUserJoin </td>
654           <td class="md" valign="top">(&nbsp;</td>
655           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
656           <td class="mdname" nowrap> <em>user</em>, </td>
657         </tr>
658         <tr>
659           <td></td>
660           <td></td>
661           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
662           <td class="mdname" nowrap> <em>channel</em></td>
663         </tr>
664         <tr>
665           <td></td>
666           <td class="md">)&nbsp;</td>
667           <td class="md" colspan="2"><code> [virtual]</code></td>
668         </tr>
669
670       </table>
671     </td>
672   </tr>
673 </table>
674 <table cellspacing=5 cellpadding=0 border=0>
675   <tr>
676     <td>
677       &nbsp;
678     </td>
679     <td>
680
681 <p>
682 Called when a user joins a channel. 
683 <p>
684 The details of the joining user are available to you in the parameter userrec *user, and the details of the channel they have joined is available in the variable chanrec *channel
685 <p>
686 Definition at line <a class="el" href="modules_8cpp-source.html#l00301">301</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
687 <p>
688 <div class="fragment"><pre>00301 { }
689 </pre></div>    </td>
690   </tr>
691 </table>
692 <a name="a6" doxytag="Module::OnUserPart"></a><p>
693 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
694   <tr>
695     <td class="mdRow">
696       <table cellpadding="0" cellspacing="0" border="0">
697         <tr>
698           <td class="md" nowrap valign="top"> void Module::OnUserPart </td>
699           <td class="md" valign="top">(&nbsp;</td>
700           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
701           <td class="mdname" nowrap> <em>user</em>, </td>
702         </tr>
703         <tr>
704           <td></td>
705           <td></td>
706           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
707           <td class="mdname" nowrap> <em>channel</em></td>
708         </tr>
709         <tr>
710           <td></td>
711           <td class="md">)&nbsp;</td>
712           <td class="md" colspan="2"><code> [virtual]</code></td>
713         </tr>
714
715       </table>
716     </td>
717   </tr>
718 </table>
719 <table cellspacing=5 cellpadding=0 border=0>
720   <tr>
721     <td>
722       &nbsp;
723     </td>
724     <td>
725
726 <p>
727 Called when a user parts a channel. 
728 <p>
729 The details of the leaving user are available to you in the parameter userrec *user, and the details of the channel they have left is available in the variable chanrec *channel
730 <p>
731 Definition at line <a class="el" href="modules_8cpp-source.html#l00302">302</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
732 <p>
733 <div class="fragment"><pre>00302 { }
734 </pre></div>    </td>
735   </tr>
736 </table>
737 <a name="a16" doxytag="Module::OnUserPreInvite"></a><p>
738 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
739   <tr>
740     <td class="mdRow">
741       <table cellpadding="0" cellspacing="0" border="0">
742         <tr>
743           <td class="md" nowrap valign="top"> int Module::OnUserPreInvite </td>
744           <td class="md" valign="top">(&nbsp;</td>
745           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
746           <td class="mdname" nowrap> <em>source</em>, </td>
747         </tr>
748         <tr>
749           <td></td>
750           <td></td>
751           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
752           <td class="mdname" nowrap> <em>dest</em>, </td>
753         </tr>
754         <tr>
755           <td></td>
756           <td></td>
757           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
758           <td class="mdname" nowrap> <em>channel</em></td>
759         </tr>
760         <tr>
761           <td></td>
762           <td class="md">)&nbsp;</td>
763           <td class="md" colspan="2"><code> [virtual]</code></td>
764         </tr>
765
766       </table>
767     </td>
768   </tr>
769 </table>
770 <table cellspacing=5 cellpadding=0 border=0>
771   <tr>
772     <td>
773       &nbsp;
774     </td>
775     <td>
776
777 <p>
778 Called whenever a user is about to invite another user into a channel, before any processing is done. 
779 <p>
780 Returning 1 from this function stops the process immediately, causing no output to be sent to the user by the core. If you do this you must produce your own numerics, notices etc. This is useful for modules which may want to filter invites to channels.
781 <p>
782 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>.
783 <p>
784 <div class="fragment"><pre>00313 { <span class="keywordflow">return</span> 0; };
785 </pre></div>    </td>
786   </tr>
787 </table>
788 <a name="a12" doxytag="Module::OnUserPreJoin"></a><p>
789 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
790   <tr>
791     <td class="mdRow">
792       <table cellpadding="0" cellspacing="0" border="0">
793         <tr>
794           <td class="md" nowrap valign="top"> int Module::OnUserPreJoin </td>
795           <td class="md" valign="top">(&nbsp;</td>
796           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
797           <td class="mdname" nowrap> <em>user</em>, </td>
798         </tr>
799         <tr>
800           <td></td>
801           <td></td>
802           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
803           <td class="mdname" nowrap> <em>chan</em>, </td>
804         </tr>
805         <tr>
806           <td></td>
807           <td></td>
808           <td class="md" nowrap>const char *&nbsp;</td>
809           <td class="mdname" nowrap> <em>cname</em></td>
810         </tr>
811         <tr>
812           <td></td>
813           <td class="md">)&nbsp;</td>
814           <td class="md" colspan="2"><code> [virtual]</code></td>
815         </tr>
816
817       </table>
818     </td>
819   </tr>
820 </table>
821 <table cellspacing=5 cellpadding=0 border=0>
822   <tr>
823     <td>
824       &nbsp;
825     </td>
826     <td>
827
828 <p>
829 Called whenever a user is about to join a channel, before any processing is done. 
830 <p>
831 Returning a value of 1 from this function stops the process immediately, causing no output to be sent to the user by the core. If you do this you must produce your own numerics, notices etc. This is useful for modules which may want to mimic +b, +k, +l etc. Returning -1 from this function forces the join to be allowed, bypassing restrictions such as banlists, invite, keys etc.<p>
832 IMPORTANT NOTE!<p>
833 If the user joins a NEW channel which does not exist yet, OnUserPreJoin will be called BEFORE the channel record is created. This will cause chanrec* chan to be NULL. There is very little you can do in form of processing on the actual channel record at this point, however the channel NAME will still be passed in char* cname, so that you could for example implement a channel blacklist or whitelist, etc.
834 <p>
835 Definition at line <a class="el" href="modules_8cpp-source.html#l00307">307</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
836 <p>
837 <div class="fragment"><pre>00307 { <span class="keywordflow">return</span> 0; }
838 </pre></div>    </td>
839   </tr>
840 </table>
841 <a name="a17" doxytag="Module::OnUserPreMessage"></a><p>
842 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
843   <tr>
844     <td class="mdRow">
845       <table cellpadding="0" cellspacing="0" border="0">
846         <tr>
847           <td class="md" nowrap valign="top"> int Module::OnUserPreMessage </td>
848           <td class="md" valign="top">(&nbsp;</td>
849           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
850           <td class="mdname" nowrap> <em>user</em>, </td>
851         </tr>
852         <tr>
853           <td></td>
854           <td></td>
855           <td class="md" nowrap>void *&nbsp;</td>
856           <td class="mdname" nowrap> <em>dest</em>, </td>
857         </tr>
858         <tr>
859           <td></td>
860           <td></td>
861           <td class="md" nowrap>int&nbsp;</td>
862           <td class="mdname" nowrap> <em>target_type</em>, </td>
863         </tr>
864         <tr>
865           <td></td>
866           <td></td>
867           <td class="md" nowrap>std::string &amp;&nbsp;</td>
868           <td class="mdname" nowrap> <em>text</em></td>
869         </tr>
870         <tr>
871           <td></td>
872           <td class="md">)&nbsp;</td>
873           <td class="md" colspan="2"><code> [virtual]</code></td>
874         </tr>
875
876       </table>
877     </td>
878   </tr>
879 </table>
880 <table cellspacing=5 cellpadding=0 border=0>
881   <tr>
882     <td>
883       &nbsp;
884     </td>
885     <td>
886
887 <p>
888 Called whenever a user is about to PRIVMSG A user or a channel, before any processing is done. 
889 <p>
890 Returning any nonzero value from this function stops the process immediately, causing no output to be sent to the user by the core. If you do this you must produce your own numerics, notices etc. This is useful for modules which may want to filter or redirect messages. target_type can be one of TYPE_USER or TYPE_CHANNEL. If the target_type value is a user, you must cast dest to a userrec* otherwise you must cast it to a chanrec*, this is the details of where the message is destined to be sent.
891 <p>
892 Definition at line <a class="el" href="modules_8cpp-source.html#l00314">314</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
893 <p>
894 <div class="fragment"><pre>00314 { <span class="keywordflow">return</span> 0; };
895 </pre></div>    </td>
896   </tr>
897 </table>
898 <a name="a19" doxytag="Module::OnUserPreNick"></a><p>
899 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
900   <tr>
901     <td class="mdRow">
902       <table cellpadding="0" cellspacing="0" border="0">
903         <tr>
904           <td class="md" nowrap valign="top"> int Module::OnUserPreNick </td>
905           <td class="md" valign="top">(&nbsp;</td>
906           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
907           <td class="mdname" nowrap> <em>user</em>, </td>
908         </tr>
909         <tr>
910           <td></td>
911           <td></td>
912           <td class="md" nowrap>std::string&nbsp;</td>
913           <td class="mdname" nowrap> <em>newnick</em></td>
914         </tr>
915         <tr>
916           <td></td>
917           <td class="md">)&nbsp;</td>
918           <td class="md" colspan="2"><code> [virtual]</code></td>
919         </tr>
920
921       </table>
922     </td>
923   </tr>
924 </table>
925 <table cellspacing=5 cellpadding=0 border=0>
926   <tr>
927     <td>
928       &nbsp;
929     </td>
930     <td>
931
932 <p>
933 Called before any nickchange, local or remote. 
934 <p>
935 This can be used to implement Q-lines etc. Please note that although you can see remote nickchanges through this function, you should NOT make any changes to the userrec if the user is a remote user as this may cause a desnyc. check user-&gt;server before taking any action (including returning nonzero from the method). If your method returns nonzero, the nickchange is silently forbidden, and it is down to your module to generate some meaninful output. You may alter the message text as you wish before relinquishing control to the next module in the chain, and if no other modules block the text this altered form of the text will be sent out to the user and possibly to other servers.
936 <p>
937 Definition at line <a class="el" href="modules_8cpp-source.html#l00316">316</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
938 <p>
939 <div class="fragment"><pre>00316 { <span class="keywordflow">return</span> 0; };
940 </pre></div>    </td>
941   </tr>
942 </table>
943 <a name="a18" doxytag="Module::OnUserPreNotice"></a><p>
944 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
945   <tr>
946     <td class="mdRow">
947       <table cellpadding="0" cellspacing="0" border="0">
948         <tr>
949           <td class="md" nowrap valign="top"> int Module::OnUserPreNotice </td>
950           <td class="md" valign="top">(&nbsp;</td>
951           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
952           <td class="mdname" nowrap> <em>user</em>, </td>
953         </tr>
954         <tr>
955           <td></td>
956           <td></td>
957           <td class="md" nowrap>void *&nbsp;</td>
958           <td class="mdname" nowrap> <em>dest</em>, </td>
959         </tr>
960         <tr>
961           <td></td>
962           <td></td>
963           <td class="md" nowrap>int&nbsp;</td>
964           <td class="mdname" nowrap> <em>target_type</em>, </td>
965         </tr>
966         <tr>
967           <td></td>
968           <td></td>
969           <td class="md" nowrap>std::string &amp;&nbsp;</td>
970           <td class="mdname" nowrap> <em>text</em></td>
971         </tr>
972         <tr>
973           <td></td>
974           <td class="md">)&nbsp;</td>
975           <td class="md" colspan="2"><code> [virtual]</code></td>
976         </tr>
977
978       </table>
979     </td>
980   </tr>
981 </table>
982 <table cellspacing=5 cellpadding=0 border=0>
983   <tr>
984     <td>
985       &nbsp;
986     </td>
987     <td>
988
989 <p>
990 Called whenever a user is about to NOTICE A user or a channel, before any processing is done. 
991 <p>
992 Returning any nonzero value from this function stops the process immediately, causing no output to be sent to the user by the core. If you do this you must produce your own numerics, notices etc. This is useful for modules which may want to filter or redirect messages. target_type can be one of TYPE_USER or TYPE_CHANNEL. If the target_type value is a user, you must cast dest to a userrec* otherwise you must cast it to a chanrec*, this is the details of where the message is destined to be sent. You may alter the message text as you wish before relinquishing control to the next module in the chain, and if no other modules block the text this altered form of the text will be sent out to the user and possibly to other servers.
993 <p>
994 Definition at line <a class="el" href="modules_8cpp-source.html#l00315">315</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
995 <p>
996 <div class="fragment"><pre>00315 { <span class="keywordflow">return</span> 0; };
997 </pre></div>    </td>
998   </tr>
999 </table>
1000 <a name="a4" doxytag="Module::OnUserQuit"></a><p>
1001 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
1002   <tr>
1003     <td class="mdRow">
1004       <table cellpadding="0" cellspacing="0" border="0">
1005         <tr>
1006           <td class="md" nowrap valign="top"> void Module::OnUserQuit </td>
1007           <td class="md" valign="top">(&nbsp;</td>
1008           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1009           <td class="mdname1" valign="top" nowrap> <em>user</em>          </td>
1010           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1011           <td class="md" nowrap><code> [virtual]</code></td>
1012         </tr>
1013
1014       </table>
1015     </td>
1016   </tr>
1017 </table>
1018 <table cellspacing=5 cellpadding=0 border=0>
1019   <tr>
1020     <td>
1021       &nbsp;
1022     </td>
1023     <td>
1024
1025 <p>
1026 Called when a user quits. 
1027 <p>
1028 The details of the exiting user are available to you in the parameter userrec *user
1029 <p>
1030 Definition at line <a class="el" href="modules_8cpp-source.html#l00300">300</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1031 <p>
1032 <div class="fragment"><pre>00300 { }
1033 </pre></div>    </td>
1034   </tr>
1035 </table>
1036 <a name="a21" doxytag="Module::OnUserSync"></a><p>
1037 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
1038   <tr>
1039     <td class="mdRow">
1040       <table cellpadding="0" cellspacing="0" border="0">
1041         <tr>
1042           <td class="md" nowrap valign="top"> <a class="el" href="modules_8h.html#a27">string_list</a> Module::OnUserSync </td>
1043           <td class="md" valign="top">(&nbsp;</td>
1044           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1045           <td class="mdname1" valign="top" nowrap> <em>user</em>          </td>
1046           <td class="md" valign="top">&nbsp;)&nbsp;</td>
1047           <td class="md" nowrap><code> [virtual]</code></td>
1048         </tr>
1049
1050       </table>
1051     </td>
1052   </tr>
1053 </table>
1054 <table cellspacing=5 cellpadding=0 border=0>
1055   <tr>
1056     <td>
1057       &nbsp;
1058     </td>
1059     <td>
1060
1061 <p>
1062 Called during a netburst to sync user data. 
1063 <p>
1064 This is called during the netburst on a per-user basis. You should use this call to up any special user-related things which are implemented by your module, e.g. sending listmodes. You may return multiple commands in the string_list.
1065 <p>
1066 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>.
1067 <p>
1068 References <a class="el" href="modules_8h-source.html#l00061">string_list</a>.
1069 <p>
1070 <div class="fragment"><pre>00318 { <a class="code" href="modules_8h.html#a27">string_list</a> empty; <span class="keywordflow">return</span> empty; }
1071 </pre></div>    </td>
1072   </tr>
1073 </table>
1074 <a name="a15" doxytag="Module::OnWhois"></a><p>
1075 <table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
1076   <tr>
1077     <td class="mdRow">
1078       <table cellpadding="0" cellspacing="0" border="0">
1079         <tr>
1080           <td class="md" nowrap valign="top"> void Module::OnWhois </td>
1081           <td class="md" valign="top">(&nbsp;</td>
1082           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1083           <td class="mdname" nowrap> <em>source</em>, </td>
1084         </tr>
1085         <tr>
1086           <td></td>
1087           <td></td>
1088           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
1089           <td class="mdname" nowrap> <em>dest</em></td>
1090         </tr>
1091         <tr>
1092           <td></td>
1093           <td class="md">)&nbsp;</td>
1094           <td class="md" colspan="2"><code> [virtual]</code></td>
1095         </tr>
1096
1097       </table>
1098     </td>
1099   </tr>
1100 </table>
1101 <table cellspacing=5 cellpadding=0 border=0>
1102   <tr>
1103     <td>
1104       &nbsp;
1105     </td>
1106     <td>
1107
1108 <p>
1109 Called whenever a /WHOIS is performed on a local user. 
1110 <p>
1111 The source parameter contains the details of the user who issued the WHOIS command, and the dest parameter contains the information of the user they are whoising.
1112 <p>
1113 Definition at line <a class="el" href="modules_8cpp-source.html#l00312">312</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
1114 <p>
1115 <div class="fragment"><pre>00312 { };
1116 </pre></div>    </td>
1117   </tr>
1118 </table>
1119 <hr>The documentation for this class was generated from the following files:<ul>
1120 <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>
1121 <hr size="1"><address style="align: right;"><small>Generated on Fri Mar 25 03:49:33 2005 for InspIRCd by
1122 <a href="http://www.doxygen.org/index.html">
1123 <img src="doxygen.png" alt="doxygen" align="middle" border=0 > 
1124 </a>1.3.3 </small></address>
1125 </body>
1126 </html>