]> git.netwichtig.de Git - user/henk/code/inspircd.git/blob - docs/module-doc/classServer.html
Initial revision
[user/henk/code/inspircd.git] / docs / module-doc / classServer.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>Server class Reference</title>
4 <link href="doxygen.css" rel="stylesheet" type="text/css">
5 </head><body>
6 <!-- Generated by Doxygen 1.3-rc2 -->
7 <center>
8 <a class="qindex" href="main.html">Main Page</a> &nbsp; <a class="qindex" href="hierarchy.html">Class Hierarchy</a> &nbsp; <a class="qindex" href="classes.html">Alphabetical List</a> &nbsp; <a class="qindex" href="annotated.html">Compound List</a> &nbsp; <a class="qindex" href="files.html">File List</a> &nbsp; <a class="qindex" href="functions.html">Compound Members</a> &nbsp; <a class="qindex" href="globals.html">File Members</a> &nbsp; </center>
9 <hr><h1>Server Class Reference</h1>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. 
10 <a href="#_details">More...</a>
11 <p>
12 <code>#include &lt;<a class="el" href="modules_8h-source.html">modules.h</a>&gt;</code>
13 <p>
14 <a href="classServer-members.html">List of all members.</a><table border=0 cellpadding=0 cellspacing=0>
15 <tr><td></td></tr>
16 <tr><td colspan=2><br><h2>Public Methods</h2></td></tr>
17 <tr><td nowrap align=right valign=top>&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a0">Server</a> ()</td></tr>
18 <tr><td>&nbsp;</td><td><font size=-1><em>Default constructor.</em> <a href="#a0"></a><em></em></font><br><br></td></tr>
19 <tr><td nowrap align=right valign=top>virtual&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a1">~Server</a> ()</td></tr>
20 <tr><td>&nbsp;</td><td><font size=-1><em>Default destructor.</em> <a href="#a1"></a><em></em></font><br><br></td></tr>
21 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a2">SendOpers</a> (string s)</td></tr>
22 <tr><td>&nbsp;</td><td><font size=-1><em>Sends text to all opers.</em> <a href="#a2"></a><em></em></font><br><br></td></tr>
23 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a3">Debug</a> (string s)</td></tr>
24 <tr><td>&nbsp;</td><td><font size=-1><em>Sends a debug string.</em> <a href="#a3"></a><em></em></font><br><br></td></tr>
25 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a4">Send</a> (int Socket, string s)</td></tr>
26 <tr><td>&nbsp;</td><td><font size=-1><em>Sends a line of text down a TCP/IP socket.</em> <a href="#a4"></a><em></em></font><br><br></td></tr>
27 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a5">SendServ</a> (int Socket, string s)</td></tr>
28 <tr><td>&nbsp;</td><td><font size=-1><em>Sends text from the server to a socket.</em> <a href="#a5"></a><em></em></font><br><br></td></tr>
29 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a6">SendFrom</a> (int Socket, <a class="el" href="classuserrec.html">userrec</a> *User, string s)</td></tr>
30 <tr><td>&nbsp;</td><td><font size=-1><em>Sends text from a user to a socket.</em> <a href="#a6"></a><em></em></font><br><br></td></tr>
31 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a7">SendTo</a> (<a class="el" href="classuserrec.html">userrec</a> *Source, <a class="el" href="classuserrec.html">userrec</a> *Dest, string s)</td></tr>
32 <tr><td>&nbsp;</td><td><font size=-1><em>Sends text from a user to another user.</em> <a href="#a7"></a><em></em></font><br><br></td></tr>
33 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a8">SendChannel</a> (<a class="el" href="classuserrec.html">userrec</a> *User, <a class="el" href="classchanrec.html">chanrec</a> *Channel, string s, bool IncludeSender)</td></tr>
34 <tr><td>&nbsp;</td><td><font size=-1><em>Sends text from a user to a channel (mulicast).</em> <a href="#a8"></a><em></em></font><br><br></td></tr>
35 <tr><td nowrap align=right valign=top>virtual bool&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a9">CommonChannels</a> (<a class="el" href="classuserrec.html">userrec</a> *u1, <a class="el" href="classuserrec.html">userrec</a> *u2)</td></tr>
36 <tr><td>&nbsp;</td><td><font size=-1><em>Returns true if two users share a common channel.</em> <a href="#a9"></a><em></em></font><br><br></td></tr>
37 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a10">SendCommon</a> (<a class="el" href="classuserrec.html">userrec</a> *User, string text, bool IncludeSender)</td></tr>
38 <tr><td>&nbsp;</td><td><font size=-1><em>Sends text from a user to one or more channels (mulicast).</em> <a href="#a10"></a><em></em></font><br><br></td></tr>
39 <tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a11">SendWallops</a> (<a class="el" href="classuserrec.html">userrec</a> *User, string text)</td></tr>
40 <tr><td>&nbsp;</td><td><font size=-1><em>Sends a WALLOPS message.</em> <a href="#a11"></a><em></em></font><br><br></td></tr>
41 <tr><td nowrap align=right valign=top>virtual bool&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a12">IsNick</a> (string nick)</td></tr>
42 <tr><td>&nbsp;</td><td><font size=-1><em>Returns true if a nick is valid.</em> <a href="#a12"></a><em></em></font><br><br></td></tr>
43 <tr><td nowrap align=right valign=top>virtual <a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a13">FindNick</a> (string nick)</td></tr>
44 <tr><td>&nbsp;</td><td><font size=-1><em>Attempts to look up a nick and return a pointer to it.</em> <a href="#a13"></a><em></em></font><br><br></td></tr>
45 <tr><td nowrap align=right valign=top>virtual <a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a14">FindChannel</a> (string channel)</td></tr>
46 <tr><td>&nbsp;</td><td><font size=-1><em>Attempts to look up a channel and return a pointer to it.</em> <a href="#a14"></a><em></em></font><br><br></td></tr>
47 <tr><td nowrap align=right valign=top>virtual string&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a15">ChanMode</a> (<a class="el" href="classuserrec.html">userrec</a> *User, <a class="el" href="classchanrec.html">chanrec</a> *Chan)</td></tr>
48 <tr><td>&nbsp;</td><td><font size=-1><em>Attempts to look up a user's privilages on a channel.</em> <a href="#a15"></a><em></em></font><br><br></td></tr>
49 <tr><td nowrap align=right valign=top>virtual string&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a16">GetServerName</a> ()</td></tr>
50 <tr><td>&nbsp;</td><td><font size=-1><em>Returns the server name of the server where the module is loaded.</em> <a href="#a16"></a><em></em></font><br><br></td></tr>
51 <tr><td nowrap align=right valign=top>virtual string&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a17">GetNetworkName</a> ()</td></tr>
52 <tr><td>&nbsp;</td><td><font size=-1><em>Returns the network name, global to all linked servers.</em> <a href="#a17"></a><em></em></font><br><br></td></tr>
53 <tr><td nowrap align=right valign=top>virtual <a class="el" href="classAdmin.html">Admin</a>&nbsp;</td><td valign=bottom><a class="el" href="classServer.html#a18">GetAdmin</a> ()</td></tr>
54 <tr><td>&nbsp;</td><td><font size=-1><em>Returns the information of the server as returned by the /ADMIN command.</em> <a href="#a18"></a><em></em></font><br><br></td></tr>
55 </table>
56 <hr><a name="_details"></a><h2>Detailed Description</h2>
57 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.
58 <p>
59 All modules should instantiate at least one copy of this class, and use its member functions to perform their tasks. 
60 <p>
61
62 <p>
63 Definition at line <a class="el" href="modules_8h-source.html#l00121">121</a> of file <a class="el" href="modules_8h-source.html">modules.h</a>.<hr><h2>Constructor &amp; Destructor Documentation</h2>
64 <a name="a0" doxytag="Server::Server"></a><p>
65 <table width="100%" cellpadding="2" cellspacing="0" border="0">
66   <tr>
67     <td class="md">
68       <table cellpadding="0" cellspacing="0" border="0">
69         <tr>
70           <td class="md" nowrap valign="top"> Server::Server </td>
71           <td class="md" valign="top">(&nbsp;</td>
72           <td class="mdname1" valign="top" nowrap>&nbsp;          </td>
73           <td class="md" valign="top">)&nbsp;</td>
74           <td class="md" nowrap></td>
75         </tr>
76
77       </table>
78     </td>
79   </tr>
80 </table>
81 <table cellspacing=5 cellpadding=0 border=0>
82   <tr>
83     <td>
84       &nbsp;
85     </td>
86     <td>
87
88 <p>
89 Default constructor.
90 <p>
91 Creates a Server object.
92 <p>
93 Definition at line <a class="el" href="modules_8cpp-source.html#l00052">52</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
94 <p>
95 <div class="fragment"><pre>00053 {
96 00054 }
97 </pre></div>    </td>
98   </tr>
99 </table>
100 <a name="a1" doxytag="Server::~Server"></a><p>
101 <table width="100%" cellpadding="2" cellspacing="0" border="0">
102   <tr>
103     <td class="md">
104       <table cellpadding="0" cellspacing="0" border="0">
105         <tr>
106           <td class="md" nowrap valign="top"> Server::~Server </td>
107           <td class="md" valign="top">(&nbsp;</td>
108           <td class="mdname1" valign="top" nowrap>&nbsp;          </td>
109           <td class="md" valign="top">)&nbsp;</td>
110           <td class="md" nowrap><code> [virtual]</code></td>
111         </tr>
112
113       </table>
114     </td>
115   </tr>
116 </table>
117 <table cellspacing=5 cellpadding=0 border=0>
118   <tr>
119     <td>
120       &nbsp;
121     </td>
122     <td>
123
124 <p>
125 Default destructor.
126 <p>
127 Destroys a Server object.
128 <p>
129 Definition at line <a class="el" href="modules_8cpp-source.html#l00056">56</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
130 <p>
131 <div class="fragment"><pre>00057 {
132 00058 }
133 </pre></div>    </td>
134   </tr>
135 </table>
136 <hr><h2>Member Function Documentation</h2>
137 <a name="a15" doxytag="Server::ChanMode"></a><p>
138 <table width="100%" cellpadding="2" cellspacing="0" border="0">
139   <tr>
140     <td class="md">
141       <table cellpadding="0" cellspacing="0" border="0">
142         <tr>
143           <td class="md" nowrap valign="top"> string Server::ChanMode </td>
144           <td class="md" valign="top">(&nbsp;</td>
145           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
146           <td class="mdname" nowrap>&nbsp; <em>User</em>, </td>
147         </tr>
148         <tr>
149           <td></td>
150           <td></td>
151           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
152           <td class="mdname" nowrap>&nbsp; <em>Chan</em></td>
153         </tr>
154         <tr>
155           <td></td>
156           <td class="md">)&nbsp;</td>
157           <td class="md" colspan="2"><code> [virtual]</code></td>
158         </tr>
159
160       </table>
161     </td>
162   </tr>
163 </table>
164 <table cellspacing=5 cellpadding=0 border=0>
165   <tr>
166     <td>
167       &nbsp;
168     </td>
169     <td>
170
171 <p>
172 Attempts to look up a user's privilages on a channel.
173 <p>
174 This function will return a string containing either @, , +, or an empty string, representing the user's privilages upon the channel you specify.
175 <p>
176 Definition at line <a class="el" href="modules_8cpp-source.html#l00139">139</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
177 <p>
178 <div class="fragment"><pre>00140 {
179 00141         string mode = cmode(User,Chan);
180 00142         <span class="keywordflow">return</span> mode;
181 00143 }
182 </pre></div>    </td>
183   </tr>
184 </table>
185 <a name="a9" doxytag="Server::CommonChannels"></a><p>
186 <table width="100%" cellpadding="2" cellspacing="0" border="0">
187   <tr>
188     <td class="md">
189       <table cellpadding="0" cellspacing="0" border="0">
190         <tr>
191           <td class="md" nowrap valign="top"> bool Server::CommonChannels </td>
192           <td class="md" valign="top">(&nbsp;</td>
193           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
194           <td class="mdname" nowrap>&nbsp; <em>u1</em>, </td>
195         </tr>
196         <tr>
197           <td></td>
198           <td></td>
199           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
200           <td class="mdname" nowrap>&nbsp; <em>u2</em></td>
201         </tr>
202         <tr>
203           <td></td>
204           <td class="md">)&nbsp;</td>
205           <td class="md" colspan="2"><code> [virtual]</code></td>
206         </tr>
207
208       </table>
209     </td>
210   </tr>
211 </table>
212 <table cellspacing=5 cellpadding=0 border=0>
213   <tr>
214     <td>
215       &nbsp;
216     </td>
217     <td>
218
219 <p>
220 Returns true if two users share a common channel.
221 <p>
222 This method is used internally by the NICK and QUIT commands, and the <a class="el" href="classServer.html#a10">Server::SendCommon</a> method.
223 <p>
224 Definition at line <a class="el" href="modules_8cpp-source.html#l00102">102</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
225 <p>
226 <div class="fragment"><pre>00103 {
227 00104         <span class="keywordflow">return</span> (common_channels(u1,u2) != 0);
228 00105 }
229 </pre></div>    </td>
230   </tr>
231 </table>
232 <a name="a3" doxytag="Server::Debug"></a><p>
233 <table width="100%" cellpadding="2" cellspacing="0" border="0">
234   <tr>
235     <td class="md">
236       <table cellpadding="0" cellspacing="0" border="0">
237         <tr>
238           <td class="md" nowrap valign="top"> void Server::Debug </td>
239           <td class="md" valign="top">(&nbsp;</td>
240           <td class="md" nowrap valign="top">string&nbsp;</td>
241           <td class="mdname1" valign="top" nowrap>&nbsp; <em>s</em>          </td>
242           <td class="md" valign="top">)&nbsp;</td>
243           <td class="md" nowrap><code> [virtual]</code></td>
244         </tr>
245
246       </table>
247     </td>
248   </tr>
249 </table>
250 <table cellspacing=5 cellpadding=0 border=0>
251   <tr>
252     <td>
253       &nbsp;
254     </td>
255     <td>
256
257 <p>
258 Sends a debug string.
259 <p>
260 This method writes a line of text to the debug log. If debugging is disabled in the configuration, this command has no effect.
261 <p>
262 Definition at line <a class="el" href="modules_8cpp-source.html#l00065">65</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
263 <p>
264 <div class="fragment"><pre>00066 {
265 00067         debug(<span class="stringliteral">"%s"</span>,s.c_str());
266 00068 }
267 </pre></div>    </td>
268   </tr>
269 </table>
270 <a name="a14" doxytag="Server::FindChannel"></a><p>
271 <table width="100%" cellpadding="2" cellspacing="0" border="0">
272   <tr>
273     <td class="md">
274       <table cellpadding="0" cellspacing="0" border="0">
275         <tr>
276           <td class="md" nowrap valign="top"> <a class="el" href="classchanrec.html">chanrec</a> * Server::FindChannel </td>
277           <td class="md" valign="top">(&nbsp;</td>
278           <td class="md" nowrap valign="top">string&nbsp;</td>
279           <td class="mdname1" valign="top" nowrap>&nbsp; <em>channel</em>          </td>
280           <td class="md" valign="top">)&nbsp;</td>
281           <td class="md" nowrap><code> [virtual]</code></td>
282         </tr>
283
284       </table>
285     </td>
286   </tr>
287 </table>
288 <table cellspacing=5 cellpadding=0 border=0>
289   <tr>
290     <td>
291       &nbsp;
292     </td>
293     <td>
294
295 <p>
296 Attempts to look up a channel and return a pointer to it.
297 <p>
298 This function will return NULL if the channel does not exist.
299 <p>
300 Definition at line <a class="el" href="modules_8cpp-source.html#l00134">134</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
301 <p>
302 <div class="fragment"><pre>00135 {
303 00136         <span class="keywordflow">return</span> FindChan(channel.c_str());
304 00137 }
305 </pre></div>    </td>
306   </tr>
307 </table>
308 <a name="a13" doxytag="Server::FindNick"></a><p>
309 <table width="100%" cellpadding="2" cellspacing="0" border="0">
310   <tr>
311     <td class="md">
312       <table cellpadding="0" cellspacing="0" border="0">
313         <tr>
314           <td class="md" nowrap valign="top"> <a class="el" href="classuserrec.html">userrec</a> * Server::FindNick </td>
315           <td class="md" valign="top">(&nbsp;</td>
316           <td class="md" nowrap valign="top">string&nbsp;</td>
317           <td class="mdname1" valign="top" nowrap>&nbsp; <em>nick</em>          </td>
318           <td class="md" valign="top">)&nbsp;</td>
319           <td class="md" nowrap><code> [virtual]</code></td>
320         </tr>
321
322       </table>
323     </td>
324   </tr>
325 </table>
326 <table cellspacing=5 cellpadding=0 border=0>
327   <tr>
328     <td>
329       &nbsp;
330     </td>
331     <td>
332
333 <p>
334 Attempts to look up a nick and return a pointer to it.
335 <p>
336 This function will return NULL if the nick does not exist.
337 <p>
338 Definition at line <a class="el" href="modules_8cpp-source.html#l00129">129</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
339 <p>
340 <div class="fragment"><pre>00130 {
341 00131         <span class="keywordflow">return</span> Find(nick);
342 00132 }
343 </pre></div>    </td>
344   </tr>
345 </table>
346 <a name="a18" doxytag="Server::GetAdmin"></a><p>
347 <table width="100%" cellpadding="2" cellspacing="0" border="0">
348   <tr>
349     <td class="md">
350       <table cellpadding="0" cellspacing="0" border="0">
351         <tr>
352           <td class="md" nowrap valign="top"> <a class="el" href="classAdmin.html">Admin</a> Server::GetAdmin </td>
353           <td class="md" valign="top">(&nbsp;</td>
354           <td class="mdname1" valign="top" nowrap>&nbsp;          </td>
355           <td class="md" valign="top">)&nbsp;</td>
356           <td class="md" nowrap><code> [virtual]</code></td>
357         </tr>
358
359       </table>
360     </td>
361   </tr>
362 </table>
363 <table cellspacing=5 cellpadding=0 border=0>
364   <tr>
365     <td>
366       &nbsp;
367     </td>
368     <td>
369
370 <p>
371 Returns the information of the server as returned by the /ADMIN command.
372 <p>
373 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#m2">Admin::Nick</a>, <a class="el" href="classAdmin.html#m1">Admin::Email</a> and <a class="el" href="classAdmin.html#m0">Admin::Name</a> contain the information for the server where the module is loaded.
374 <p>
375 Definition at line <a class="el" href="modules_8cpp-source.html#l00155">155</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
376 <p>
377 <div class="fragment"><pre>00156 {
378 00157         <span class="keywordflow">return</span> <a class="code" href="classAdmin.html">Admin</a>(getadminname(),getadminemail(),getadminnick());
379 00158 }
380 </pre></div>    </td>
381   </tr>
382 </table>
383 <a name="a17" doxytag="Server::GetNetworkName"></a><p>
384 <table width="100%" cellpadding="2" cellspacing="0" border="0">
385   <tr>
386     <td class="md">
387       <table cellpadding="0" cellspacing="0" border="0">
388         <tr>
389           <td class="md" nowrap valign="top"> string Server::GetNetworkName </td>
390           <td class="md" valign="top">(&nbsp;</td>
391           <td class="mdname1" valign="top" nowrap>&nbsp;          </td>
392           <td class="md" valign="top">)&nbsp;</td>
393           <td class="md" nowrap><code> [virtual]</code></td>
394         </tr>
395
396       </table>
397     </td>
398   </tr>
399 </table>
400 <table cellspacing=5 cellpadding=0 border=0>
401   <tr>
402     <td>
403       &nbsp;
404     </td>
405     <td>
406
407 <p>
408 Returns the network name, global to all linked servers.
409 <p>
410
411 <p>
412 Definition at line <a class="el" href="modules_8cpp-source.html#l00150">150</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
413 <p>
414 <div class="fragment"><pre>00151 {
415 00152         <span class="keywordflow">return</span> getnetworkname();
416 00153 }
417 </pre></div>    </td>
418   </tr>
419 </table>
420 <a name="a16" doxytag="Server::GetServerName"></a><p>
421 <table width="100%" cellpadding="2" cellspacing="0" border="0">
422   <tr>
423     <td class="md">
424       <table cellpadding="0" cellspacing="0" border="0">
425         <tr>
426           <td class="md" nowrap valign="top"> string Server::GetServerName </td>
427           <td class="md" valign="top">(&nbsp;</td>
428           <td class="mdname1" valign="top" nowrap>&nbsp;          </td>
429           <td class="md" valign="top">)&nbsp;</td>
430           <td class="md" nowrap><code> [virtual]</code></td>
431         </tr>
432
433       </table>
434     </td>
435   </tr>
436 </table>
437 <table cellspacing=5 cellpadding=0 border=0>
438   <tr>
439     <td>
440       &nbsp;
441     </td>
442     <td>
443
444 <p>
445 Returns the server name of the server where the module is loaded.
446 <p>
447
448 <p>
449 Definition at line <a class="el" href="modules_8cpp-source.html#l00145">145</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
450 <p>
451 <div class="fragment"><pre>00146 {
452 00147         <span class="keywordflow">return</span> getservername();
453 00148 }
454 </pre></div>    </td>
455   </tr>
456 </table>
457 <a name="a12" doxytag="Server::IsNick"></a><p>
458 <table width="100%" cellpadding="2" cellspacing="0" border="0">
459   <tr>
460     <td class="md">
461       <table cellpadding="0" cellspacing="0" border="0">
462         <tr>
463           <td class="md" nowrap valign="top"> bool Server::IsNick </td>
464           <td class="md" valign="top">(&nbsp;</td>
465           <td class="md" nowrap valign="top">string&nbsp;</td>
466           <td class="mdname1" valign="top" nowrap>&nbsp; <em>nick</em>          </td>
467           <td class="md" valign="top">)&nbsp;</td>
468           <td class="md" nowrap><code> [virtual]</code></td>
469         </tr>
470
471       </table>
472     </td>
473   </tr>
474 </table>
475 <table cellspacing=5 cellpadding=0 border=0>
476   <tr>
477     <td>
478       &nbsp;
479     </td>
480     <td>
481
482 <p>
483 Returns true if a nick is valid.
484 <p>
485 Nicks for unregistered connections will return false.
486 <p>
487 Definition at line <a class="el" href="modules_8cpp-source.html#l00124">124</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
488 <p>
489 <div class="fragment"><pre>00125 {
490 00126         <span class="keywordflow">return</span> (isnick(nick.c_str()) != 0);
491 00127 }
492 </pre></div>    </td>
493   </tr>
494 </table>
495 <a name="a4" doxytag="Server::Send"></a><p>
496 <table width="100%" cellpadding="2" cellspacing="0" border="0">
497   <tr>
498     <td class="md">
499       <table cellpadding="0" cellspacing="0" border="0">
500         <tr>
501           <td class="md" nowrap valign="top"> void Server::Send </td>
502           <td class="md" valign="top">(&nbsp;</td>
503           <td class="md" nowrap valign="top">int&nbsp;</td>
504           <td class="mdname" nowrap>&nbsp; <em>Socket</em>, </td>
505         </tr>
506         <tr>
507           <td></td>
508           <td></td>
509           <td class="md" nowrap>string&nbsp;</td>
510           <td class="mdname" nowrap>&nbsp; <em>s</em></td>
511         </tr>
512         <tr>
513           <td></td>
514           <td class="md">)&nbsp;</td>
515           <td class="md" colspan="2"><code> [virtual]</code></td>
516         </tr>
517
518       </table>
519     </td>
520   </tr>
521 </table>
522 <table cellspacing=5 cellpadding=0 border=0>
523   <tr>
524     <td>
525       &nbsp;
526     </td>
527     <td>
528
529 <p>
530 Sends a line of text down a TCP/IP socket.
531 <p>
532 This method writes a line of text to an established socket, cutting it to 510 characters plus a carriage return and linefeed if required.
533 <p>
534 Definition at line <a class="el" href="modules_8cpp-source.html#l00070">70</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
535 <p>
536 <div class="fragment"><pre>00071 {
537 00072         Write(Socket,<span class="stringliteral">"%s"</span>,s.c_str());
538 00073 }
539 </pre></div>    </td>
540   </tr>
541 </table>
542 <a name="a8" doxytag="Server::SendChannel"></a><p>
543 <table width="100%" cellpadding="2" cellspacing="0" border="0">
544   <tr>
545     <td class="md">
546       <table cellpadding="0" cellspacing="0" border="0">
547         <tr>
548           <td class="md" nowrap valign="top"> void Server::SendChannel </td>
549           <td class="md" valign="top">(&nbsp;</td>
550           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
551           <td class="mdname" nowrap>&nbsp; <em>User</em>, </td>
552         </tr>
553         <tr>
554           <td></td>
555           <td></td>
556           <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> *&nbsp;</td>
557           <td class="mdname" nowrap>&nbsp; <em>Channel</em>, </td>
558         </tr>
559         <tr>
560           <td></td>
561           <td></td>
562           <td class="md" nowrap>string&nbsp;</td>
563           <td class="mdname" nowrap>&nbsp; <em>s</em>, </td>
564         </tr>
565         <tr>
566           <td></td>
567           <td></td>
568           <td class="md" nowrap>bool&nbsp;</td>
569           <td class="mdname" nowrap>&nbsp; <em>IncludeSender</em></td>
570         </tr>
571         <tr>
572           <td></td>
573           <td class="md">)&nbsp;</td>
574           <td class="md" colspan="2"><code> [virtual]</code></td>
575         </tr>
576
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 Sends text from a user to a channel (mulicast).
590 <p>
591 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).
592 <p>
593 Definition at line <a class="el" href="modules_8cpp-source.html#l00090">90</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
594 <p>
595 <div class="fragment"><pre>00091 {
596 00092         <span class="keywordflow">if</span> (IncludeSender)
597 00093         {
598 00094                 WriteChannel(Channel,User,<span class="stringliteral">"%s"</span>,s.c_str());
599 00095         }
600 00096         <span class="keywordflow">else</span>
601 00097         {
602 00098                 ChanExceptSender(Channel,User,<span class="stringliteral">"%s"</span>,s.c_str());
603 00099         }
604 00100 }
605 </pre></div>    </td>
606   </tr>
607 </table>
608 <a name="a10" doxytag="Server::SendCommon"></a><p>
609 <table width="100%" cellpadding="2" cellspacing="0" border="0">
610   <tr>
611     <td class="md">
612       <table cellpadding="0" cellspacing="0" border="0">
613         <tr>
614           <td class="md" nowrap valign="top"> void Server::SendCommon </td>
615           <td class="md" valign="top">(&nbsp;</td>
616           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
617           <td class="mdname" nowrap>&nbsp; <em>User</em>, </td>
618         </tr>
619         <tr>
620           <td></td>
621           <td></td>
622           <td class="md" nowrap>string&nbsp;</td>
623           <td class="mdname" nowrap>&nbsp; <em>text</em>, </td>
624         </tr>
625         <tr>
626           <td></td>
627           <td></td>
628           <td class="md" nowrap>bool&nbsp;</td>
629           <td class="mdname" nowrap>&nbsp; <em>IncludeSender</em></td>
630         </tr>
631         <tr>
632           <td></td>
633           <td class="md">)&nbsp;</td>
634           <td class="md" colspan="2"><code> [virtual]</code></td>
635         </tr>
636
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 Sends text from a user to one or more channels (mulicast).
650 <p>
651 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.
652 <p>
653 Definition at line <a class="el" href="modules_8cpp-source.html#l00107">107</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
654 <p>
655 <div class="fragment"><pre>00108 {
656 00109         <span class="keywordflow">if</span> (IncludeSender)
657 00110         {
658 00111                 WriteCommon(User,<span class="stringliteral">"%s"</span>,text.c_str());
659 00112         }
660 00113         <span class="keywordflow">else</span>
661 00114         {
662 00115                 WriteCommonExcept(User,<span class="stringliteral">"%s"</span>,text.c_str());
663 00116         }
664 00117 }
665 </pre></div>    </td>
666   </tr>
667 </table>
668 <a name="a6" doxytag="Server::SendFrom"></a><p>
669 <table width="100%" cellpadding="2" cellspacing="0" border="0">
670   <tr>
671     <td class="md">
672       <table cellpadding="0" cellspacing="0" border="0">
673         <tr>
674           <td class="md" nowrap valign="top"> void Server::SendFrom </td>
675           <td class="md" valign="top">(&nbsp;</td>
676           <td class="md" nowrap valign="top">int&nbsp;</td>
677           <td class="mdname" nowrap>&nbsp; <em>Socket</em>, </td>
678         </tr>
679         <tr>
680           <td></td>
681           <td></td>
682           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
683           <td class="mdname" nowrap>&nbsp; <em>User</em>, </td>
684         </tr>
685         <tr>
686           <td></td>
687           <td></td>
688           <td class="md" nowrap>string&nbsp;</td>
689           <td class="mdname" nowrap>&nbsp; <em>s</em></td>
690         </tr>
691         <tr>
692           <td></td>
693           <td class="md">)&nbsp;</td>
694           <td class="md" colspan="2"><code> [virtual]</code></td>
695         </tr>
696
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 Sends text from a user to a socket.
710 <p>
711 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)
712 <p>
713 Definition at line <a class="el" href="modules_8cpp-source.html#l00080">80</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
714 <p>
715 <div class="fragment"><pre>00081 {
716 00082         WriteFrom(Socket,User,<span class="stringliteral">"%s"</span>,s.c_str());
717 00083 }
718 </pre></div>    </td>
719   </tr>
720 </table>
721 <a name="a2" doxytag="Server::SendOpers"></a><p>
722 <table width="100%" cellpadding="2" cellspacing="0" border="0">
723   <tr>
724     <td class="md">
725       <table cellpadding="0" cellspacing="0" border="0">
726         <tr>
727           <td class="md" nowrap valign="top"> void Server::SendOpers </td>
728           <td class="md" valign="top">(&nbsp;</td>
729           <td class="md" nowrap valign="top">string&nbsp;</td>
730           <td class="mdname1" valign="top" nowrap>&nbsp; <em>s</em>          </td>
731           <td class="md" valign="top">)&nbsp;</td>
732           <td class="md" nowrap><code> [virtual]</code></td>
733         </tr>
734
735       </table>
736     </td>
737   </tr>
738 </table>
739 <table cellspacing=5 cellpadding=0 border=0>
740   <tr>
741     <td>
742       &nbsp;
743     </td>
744     <td>
745
746 <p>
747 Sends text to all opers.
748 <p>
749 This method sends a server notice to all opers with the usermode +s.
750 <p>
751 Definition at line <a class="el" href="modules_8cpp-source.html#l00060">60</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
752 <p>
753 <div class="fragment"><pre>00061 {
754 00062         WriteOpers(<span class="stringliteral">"%s"</span>,s.c_str());
755 00063 }
756 </pre></div>    </td>
757   </tr>
758 </table>
759 <a name="a5" doxytag="Server::SendServ"></a><p>
760 <table width="100%" cellpadding="2" cellspacing="0" border="0">
761   <tr>
762     <td class="md">
763       <table cellpadding="0" cellspacing="0" border="0">
764         <tr>
765           <td class="md" nowrap valign="top"> void Server::SendServ </td>
766           <td class="md" valign="top">(&nbsp;</td>
767           <td class="md" nowrap valign="top">int&nbsp;</td>
768           <td class="mdname" nowrap>&nbsp; <em>Socket</em>, </td>
769         </tr>
770         <tr>
771           <td></td>
772           <td></td>
773           <td class="md" nowrap>string&nbsp;</td>
774           <td class="mdname" nowrap>&nbsp; <em>s</em></td>
775         </tr>
776         <tr>
777           <td></td>
778           <td class="md">)&nbsp;</td>
779           <td class="md" colspan="2"><code> [virtual]</code></td>
780         </tr>
781
782       </table>
783     </td>
784   </tr>
785 </table>
786 <table cellspacing=5 cellpadding=0 border=0>
787   <tr>
788     <td>
789       &nbsp;
790     </td>
791     <td>
792
793 <p>
794 Sends text from the server to a socket.
795 <p>
796 This method writes a line of text to an established socket, with the servername prepended as used by numerics (see RFC 1459)
797 <p>
798 Definition at line <a class="el" href="modules_8cpp-source.html#l00075">75</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
799 <p>
800 <div class="fragment"><pre>00076 {
801 00077         WriteServ(Socket,<span class="stringliteral">"%s"</span>,s.c_str());
802 00078 }
803 </pre></div>    </td>
804   </tr>
805 </table>
806 <a name="a7" doxytag="Server::SendTo"></a><p>
807 <table width="100%" cellpadding="2" cellspacing="0" border="0">
808   <tr>
809     <td class="md">
810       <table cellpadding="0" cellspacing="0" border="0">
811         <tr>
812           <td class="md" nowrap valign="top"> void Server::SendTo </td>
813           <td class="md" valign="top">(&nbsp;</td>
814           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
815           <td class="mdname" nowrap>&nbsp; <em>Source</em>, </td>
816         </tr>
817         <tr>
818           <td></td>
819           <td></td>
820           <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
821           <td class="mdname" nowrap>&nbsp; <em>Dest</em>, </td>
822         </tr>
823         <tr>
824           <td></td>
825           <td></td>
826           <td class="md" nowrap>string&nbsp;</td>
827           <td class="mdname" nowrap>&nbsp; <em>s</em></td>
828         </tr>
829         <tr>
830           <td></td>
831           <td class="md">)&nbsp;</td>
832           <td class="md" colspan="2"><code> [virtual]</code></td>
833         </tr>
834
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 Sends text from a user to another user.
848 <p>
849 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)
850 <p>
851 Definition at line <a class="el" href="modules_8cpp-source.html#l00085">85</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
852 <p>
853 <div class="fragment"><pre>00086 {
854 00087         WriteTo(Source,Dest,<span class="stringliteral">"%s"</span>,s.c_str());
855 00088 }
856 </pre></div>    </td>
857   </tr>
858 </table>
859 <a name="a11" doxytag="Server::SendWallops"></a><p>
860 <table width="100%" cellpadding="2" cellspacing="0" border="0">
861   <tr>
862     <td class="md">
863       <table cellpadding="0" cellspacing="0" border="0">
864         <tr>
865           <td class="md" nowrap valign="top"> void Server::SendWallops </td>
866           <td class="md" valign="top">(&nbsp;</td>
867           <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> *&nbsp;</td>
868           <td class="mdname" nowrap>&nbsp; <em>User</em>, </td>
869         </tr>
870         <tr>
871           <td></td>
872           <td></td>
873           <td class="md" nowrap>string&nbsp;</td>
874           <td class="mdname" nowrap>&nbsp; <em>text</em></td>
875         </tr>
876         <tr>
877           <td></td>
878           <td class="md">)&nbsp;</td>
879           <td class="md" colspan="2"><code> [virtual]</code></td>
880         </tr>
881
882       </table>
883     </td>
884   </tr>
885 </table>
886 <table cellspacing=5 cellpadding=0 border=0>
887   <tr>
888     <td>
889       &nbsp;
890     </td>
891     <td>
892
893 <p>
894 Sends a WALLOPS message.
895 <p>
896 This method writes a WALLOPS message to all users with the +w flag, originating from the specified user.
897 <p>
898 Definition at line <a class="el" href="modules_8cpp-source.html#l00119">119</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
899 <p>
900 <div class="fragment"><pre>00120 {
901 00121         WriteWallOps(User,<span class="stringliteral">"%s"</span>,text.c_str());
902 00122 }
903 </pre></div>    </td>
904   </tr>
905 </table>
906 <hr>The documentation for this class was generated from the following files:<ul>
907 <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>
908 <hr><address style="align: right;"><small>Generated on Wed Jan 22 20:56:48 2003 for InspIRCd by
909 <a href="http://www.doxygen.org/index.html">
910 <img src="doxygen.png" alt="doxygen" align="middle" border=0 
911 width=110 height=53></a>1.3-rc2 </small></address>
912 </body>
913 </html>