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">
6 <!-- Generated by Doxygen 1.3-rc2 -->
8 <a class="qindex" href="main.html">Main Page</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="classes.html">Alphabetical List</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="globals.html">File Members</a> </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>
12 <code>#include <<a class="el" href="modules_8h-source.html">modules.h</a>></code>
14 <p>Inheritance diagram for Server:
15 <p><center><img src="classServer.png" usemap="#Server_map" border="0" alt=""></center>
16 <map name="Server_map">
17 <area href="classclassbase.html" alt="classbase" shape="rect" coords="0,0,68,24">
19 <a href="classServer-members.html">List of all members.</a><table border=0 cellpadding=0 cellspacing=0>
21 <tr><td colspan=2><br><h2>Public Methods</h2></td></tr>
22 <tr><td nowrap align=right valign=top> </td><td valign=bottom><a class="el" href="classServer.html#a0">Server</a> ()</td></tr>
23 <tr><td> </td><td><font size=-1><em>Default constructor.</em> <a href="#a0"></a><em></em></font><br><br></td></tr>
24 <tr><td nowrap align=right valign=top>virtual </td><td valign=bottom><a class="el" href="classServer.html#a1">~Server</a> ()</td></tr>
25 <tr><td> </td><td><font size=-1><em>Default destructor.</em> <a href="#a1"></a><em></em></font><br><br></td></tr>
26 <tr><td nowrap align=right valign=top>virtual void </td><td valign=bottom><a class="el" href="classServer.html#a2">SendOpers</a> (string s)</td></tr>
27 <tr><td> </td><td><font size=-1><em>Sends text to all opers.</em> <a href="#a2"></a><em></em></font><br><br></td></tr>
28 <tr><td nowrap align=right valign=top>virtual void </td><td valign=bottom><a class="el" href="classServer.html#a3">Debug</a> (string s)</td></tr>
29 <tr><td> </td><td><font size=-1><em>Sends a debug string.</em> <a href="#a3"></a><em></em></font><br><br></td></tr>
30 <tr><td nowrap align=right valign=top>virtual void </td><td valign=bottom><a class="el" href="classServer.html#a4">Send</a> (int Socket, string s)</td></tr>
31 <tr><td> </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>
32 <tr><td nowrap align=right valign=top>virtual void </td><td valign=bottom><a class="el" href="classServer.html#a5">SendServ</a> (int Socket, string s)</td></tr>
33 <tr><td> </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>
34 <tr><td nowrap align=right valign=top>virtual void </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>
35 <tr><td> </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>
36 <tr><td nowrap align=right valign=top>virtual void </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>
37 <tr><td> </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>
38 <tr><td nowrap align=right valign=top>virtual void </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>
39 <tr><td> </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>
40 <tr><td nowrap align=right valign=top>virtual bool </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>
41 <tr><td> </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>
42 <tr><td nowrap align=right valign=top>virtual void </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>
43 <tr><td> </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>
44 <tr><td nowrap align=right valign=top>virtual void </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>
45 <tr><td> </td><td><font size=-1><em>Sends a WALLOPS message.</em> <a href="#a11"></a><em></em></font><br><br></td></tr>
46 <tr><td nowrap align=right valign=top>virtual bool </td><td valign=bottom><a class="el" href="classServer.html#a12">IsNick</a> (string nick)</td></tr>
47 <tr><td> </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>
48 <tr><td nowrap align=right valign=top>virtual <a class="el" href="classuserrec.html">userrec</a> * </td><td valign=bottom><a class="el" href="classServer.html#a13">FindNick</a> (string nick)</td></tr>
49 <tr><td> </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>
50 <tr><td nowrap align=right valign=top>virtual <a class="el" href="classchanrec.html">chanrec</a> * </td><td valign=bottom><a class="el" href="classServer.html#a14">FindChannel</a> (string channel)</td></tr>
51 <tr><td> </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>
52 <tr><td nowrap align=right valign=top>virtual string </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>
53 <tr><td> </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>
54 <tr><td nowrap align=right valign=top>virtual string </td><td valign=bottom><a class="el" href="classServer.html#a16">GetServerName</a> ()</td></tr>
55 <tr><td> </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>
56 <tr><td nowrap align=right valign=top>virtual string </td><td valign=bottom><a class="el" href="classServer.html#a17">GetNetworkName</a> ()</td></tr>
57 <tr><td> </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>
58 <tr><td nowrap align=right valign=top>virtual <a class="el" href="classAdmin.html">Admin</a> </td><td valign=bottom><a class="el" href="classServer.html#a18">GetAdmin</a> ()</td></tr>
59 <tr><td> </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>
61 <hr><a name="_details"></a><h2>Detailed Description</h2>
62 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.
64 All modules should instantiate at least one copy of this class, and use its member functions to perform their tasks.
68 Definition at line <a class="el" href="modules_8h-source.html#l00132">132</a> of file <a class="el" href="modules_8h-source.html">modules.h</a>.<hr><h2>Constructor & Destructor Documentation</h2>
69 <a name="a0" doxytag="Server::Server"></a><p>
70 <table width="100%" cellpadding="2" cellspacing="0" border="0">
73 <table cellpadding="0" cellspacing="0" border="0">
75 <td class="md" nowrap valign="top"> Server::Server </td>
76 <td class="md" valign="top">( </td>
77 <td class="mdname1" valign="top" nowrap> </td>
78 <td class="md" valign="top">) </td>
79 <td class="md" nowrap></td>
86 <table cellspacing=5 cellpadding=0 border=0>
96 Creates a Server object.
98 Definition at line <a class="el" href="modules_8cpp-source.html#l00055">55</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
100 <div class="fragment"><pre>00056 {
105 <a name="a1" doxytag="Server::~Server"></a><p>
106 <table width="100%" cellpadding="2" cellspacing="0" border="0">
109 <table cellpadding="0" cellspacing="0" border="0">
111 <td class="md" nowrap valign="top"> Server::~Server </td>
112 <td class="md" valign="top">( </td>
113 <td class="mdname1" valign="top" nowrap> </td>
114 <td class="md" valign="top">) </td>
115 <td class="md" nowrap><code> [virtual]</code></td>
122 <table cellspacing=5 cellpadding=0 border=0>
132 Destroys a Server object.
134 Definition at line <a class="el" href="modules_8cpp-source.html#l00059">59</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
136 <div class="fragment"><pre>00060 {
141 <hr><h2>Member Function Documentation</h2>
142 <a name="a15" doxytag="Server::ChanMode"></a><p>
143 <table width="100%" cellpadding="2" cellspacing="0" border="0">
146 <table cellpadding="0" cellspacing="0" border="0">
148 <td class="md" nowrap valign="top"> string Server::ChanMode </td>
149 <td class="md" valign="top">( </td>
150 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
151 <td class="mdname" nowrap> <em>User</em>, </td>
156 <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> * </td>
157 <td class="mdname" nowrap> <em>Chan</em></td>
161 <td class="md">) </td>
162 <td class="md" colspan="2"><code> [virtual]</code></td>
169 <table cellspacing=5 cellpadding=0 border=0>
177 Attempts to look up a user's privilages on a channel.
179 This function will return a string containing either @, , +, or an empty string, representing the user's privilages upon the channel you specify.
181 Definition at line <a class="el" href="modules_8cpp-source.html#l00142">142</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
183 <div class="fragment"><pre>00143 {
184 00144 string mode = cmode(User,Chan);
185 00145 <span class="keywordflow">return</span> mode;
190 <a name="a9" doxytag="Server::CommonChannels"></a><p>
191 <table width="100%" cellpadding="2" cellspacing="0" border="0">
194 <table cellpadding="0" cellspacing="0" border="0">
196 <td class="md" nowrap valign="top"> bool Server::CommonChannels </td>
197 <td class="md" valign="top">( </td>
198 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
199 <td class="mdname" nowrap> <em>u1</em>, </td>
204 <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> * </td>
205 <td class="mdname" nowrap> <em>u2</em></td>
209 <td class="md">) </td>
210 <td class="md" colspan="2"><code> [virtual]</code></td>
217 <table cellspacing=5 cellpadding=0 border=0>
225 Returns true if two users share a common channel.
227 This method is used internally by the NICK and QUIT commands, and the <a class="el" href="classServer.html#a10">Server::SendCommon</a> method.
229 Definition at line <a class="el" href="modules_8cpp-source.html#l00105">105</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
231 <div class="fragment"><pre>00106 {
232 00107 <span class="keywordflow">return</span> (common_channels(u1,u2) != 0);
237 <a name="a3" doxytag="Server::Debug"></a><p>
238 <table width="100%" cellpadding="2" cellspacing="0" border="0">
241 <table cellpadding="0" cellspacing="0" border="0">
243 <td class="md" nowrap valign="top"> void Server::Debug </td>
244 <td class="md" valign="top">( </td>
245 <td class="md" nowrap valign="top">string </td>
246 <td class="mdname1" valign="top" nowrap> <em>s</em> </td>
247 <td class="md" valign="top">) </td>
248 <td class="md" nowrap><code> [virtual]</code></td>
255 <table cellspacing=5 cellpadding=0 border=0>
263 Sends a debug string.
265 This method writes a line of text to the debug log. If debugging is disabled in the configuration, this command has no effect.
267 Definition at line <a class="el" href="modules_8cpp-source.html#l00068">68</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
269 <div class="fragment"><pre>00069 {
270 00070 debug(<span class="stringliteral">"%s"</span>,s.c_str());
275 <a name="a14" doxytag="Server::FindChannel"></a><p>
276 <table width="100%" cellpadding="2" cellspacing="0" border="0">
279 <table cellpadding="0" cellspacing="0" border="0">
281 <td class="md" nowrap valign="top"> <a class="el" href="classchanrec.html">chanrec</a> * Server::FindChannel </td>
282 <td class="md" valign="top">( </td>
283 <td class="md" nowrap valign="top">string </td>
284 <td class="mdname1" valign="top" nowrap> <em>channel</em> </td>
285 <td class="md" valign="top">) </td>
286 <td class="md" nowrap><code> [virtual]</code></td>
293 <table cellspacing=5 cellpadding=0 border=0>
301 Attempts to look up a channel and return a pointer to it.
303 This function will return NULL if the channel does not exist.
305 Definition at line <a class="el" href="modules_8cpp-source.html#l00137">137</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
307 <div class="fragment"><pre>00138 {
308 00139 <span class="keywordflow">return</span> FindChan(channel.c_str());
313 <a name="a13" doxytag="Server::FindNick"></a><p>
314 <table width="100%" cellpadding="2" cellspacing="0" border="0">
317 <table cellpadding="0" cellspacing="0" border="0">
319 <td class="md" nowrap valign="top"> <a class="el" href="classuserrec.html">userrec</a> * Server::FindNick </td>
320 <td class="md" valign="top">( </td>
321 <td class="md" nowrap valign="top">string </td>
322 <td class="mdname1" valign="top" nowrap> <em>nick</em> </td>
323 <td class="md" valign="top">) </td>
324 <td class="md" nowrap><code> [virtual]</code></td>
331 <table cellspacing=5 cellpadding=0 border=0>
339 Attempts to look up a nick and return a pointer to it.
341 This function will return NULL if the nick does not exist.
343 Definition at line <a class="el" href="modules_8cpp-source.html#l00132">132</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
345 <div class="fragment"><pre>00133 {
346 00134 <span class="keywordflow">return</span> Find(nick);
351 <a name="a18" doxytag="Server::GetAdmin"></a><p>
352 <table width="100%" cellpadding="2" cellspacing="0" border="0">
355 <table cellpadding="0" cellspacing="0" border="0">
357 <td class="md" nowrap valign="top"> <a class="el" href="classAdmin.html">Admin</a> Server::GetAdmin </td>
358 <td class="md" valign="top">( </td>
359 <td class="mdname1" valign="top" nowrap> </td>
360 <td class="md" valign="top">) </td>
361 <td class="md" nowrap><code> [virtual]</code></td>
368 <table cellspacing=5 cellpadding=0 border=0>
376 Returns the information of the server as returned by the /ADMIN command.
378 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.
380 Definition at line <a class="el" href="modules_8cpp-source.html#l00158">158</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
382 <div class="fragment"><pre>00159 {
383 00160 <span class="keywordflow">return</span> <a class="code" href="classAdmin.html">Admin</a>(getadminname(),getadminemail(),getadminnick());
388 <a name="a17" doxytag="Server::GetNetworkName"></a><p>
389 <table width="100%" cellpadding="2" cellspacing="0" border="0">
392 <table cellpadding="0" cellspacing="0" border="0">
394 <td class="md" nowrap valign="top"> string Server::GetNetworkName </td>
395 <td class="md" valign="top">( </td>
396 <td class="mdname1" valign="top" nowrap> </td>
397 <td class="md" valign="top">) </td>
398 <td class="md" nowrap><code> [virtual]</code></td>
405 <table cellspacing=5 cellpadding=0 border=0>
413 Returns the network name, global to all linked servers.
417 Definition at line <a class="el" href="modules_8cpp-source.html#l00153">153</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
419 <div class="fragment"><pre>00154 {
420 00155 <span class="keywordflow">return</span> getnetworkname();
425 <a name="a16" doxytag="Server::GetServerName"></a><p>
426 <table width="100%" cellpadding="2" cellspacing="0" border="0">
429 <table cellpadding="0" cellspacing="0" border="0">
431 <td class="md" nowrap valign="top"> string Server::GetServerName </td>
432 <td class="md" valign="top">( </td>
433 <td class="mdname1" valign="top" nowrap> </td>
434 <td class="md" valign="top">) </td>
435 <td class="md" nowrap><code> [virtual]</code></td>
442 <table cellspacing=5 cellpadding=0 border=0>
450 Returns the server name of the server where the module is loaded.
454 Definition at line <a class="el" href="modules_8cpp-source.html#l00148">148</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
456 <div class="fragment"><pre>00149 {
457 00150 <span class="keywordflow">return</span> getservername();
462 <a name="a12" doxytag="Server::IsNick"></a><p>
463 <table width="100%" cellpadding="2" cellspacing="0" border="0">
466 <table cellpadding="0" cellspacing="0" border="0">
468 <td class="md" nowrap valign="top"> bool Server::IsNick </td>
469 <td class="md" valign="top">( </td>
470 <td class="md" nowrap valign="top">string </td>
471 <td class="mdname1" valign="top" nowrap> <em>nick</em> </td>
472 <td class="md" valign="top">) </td>
473 <td class="md" nowrap><code> [virtual]</code></td>
480 <table cellspacing=5 cellpadding=0 border=0>
488 Returns true if a nick is valid.
490 Nicks for unregistered connections will return false.
492 Definition at line <a class="el" href="modules_8cpp-source.html#l00127">127</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
494 <div class="fragment"><pre>00128 {
495 00129 <span class="keywordflow">return</span> (isnick(nick.c_str()) != 0);
500 <a name="a4" doxytag="Server::Send"></a><p>
501 <table width="100%" cellpadding="2" cellspacing="0" border="0">
504 <table cellpadding="0" cellspacing="0" border="0">
506 <td class="md" nowrap valign="top"> void Server::Send </td>
507 <td class="md" valign="top">( </td>
508 <td class="md" nowrap valign="top">int </td>
509 <td class="mdname" nowrap> <em>Socket</em>, </td>
514 <td class="md" nowrap>string </td>
515 <td class="mdname" nowrap> <em>s</em></td>
519 <td class="md">) </td>
520 <td class="md" colspan="2"><code> [virtual]</code></td>
527 <table cellspacing=5 cellpadding=0 border=0>
535 Sends a line of text down a TCP/IP socket.
537 This method writes a line of text to an established socket, cutting it to 510 characters plus a carriage return and linefeed if required.
539 Definition at line <a class="el" href="modules_8cpp-source.html#l00073">73</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
541 <div class="fragment"><pre>00074 {
542 00075 Write(Socket,<span class="stringliteral">"%s"</span>,s.c_str());
547 <a name="a8" doxytag="Server::SendChannel"></a><p>
548 <table width="100%" cellpadding="2" cellspacing="0" border="0">
551 <table cellpadding="0" cellspacing="0" border="0">
553 <td class="md" nowrap valign="top"> void Server::SendChannel </td>
554 <td class="md" valign="top">( </td>
555 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
556 <td class="mdname" nowrap> <em>User</em>, </td>
561 <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> * </td>
562 <td class="mdname" nowrap> <em>Channel</em>, </td>
567 <td class="md" nowrap>string </td>
568 <td class="mdname" nowrap> <em>s</em>, </td>
573 <td class="md" nowrap>bool </td>
574 <td class="mdname" nowrap> <em>IncludeSender</em></td>
578 <td class="md">) </td>
579 <td class="md" colspan="2"><code> [virtual]</code></td>
586 <table cellspacing=5 cellpadding=0 border=0>
594 Sends text from a user to a channel (mulicast).
596 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).
598 Definition at line <a class="el" href="modules_8cpp-source.html#l00093">93</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
600 <div class="fragment"><pre>00094 {
601 00095 <span class="keywordflow">if</span> (IncludeSender)
603 00097 WriteChannel(Channel,User,<span class="stringliteral">"%s"</span>,s.c_str());
605 00099 <span class="keywordflow">else</span>
607 00101 ChanExceptSender(Channel,User,<span class="stringliteral">"%s"</span>,s.c_str());
613 <a name="a10" doxytag="Server::SendCommon"></a><p>
614 <table width="100%" cellpadding="2" cellspacing="0" border="0">
617 <table cellpadding="0" cellspacing="0" border="0">
619 <td class="md" nowrap valign="top"> void Server::SendCommon </td>
620 <td class="md" valign="top">( </td>
621 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
622 <td class="mdname" nowrap> <em>User</em>, </td>
627 <td class="md" nowrap>string </td>
628 <td class="mdname" nowrap> <em>text</em>, </td>
633 <td class="md" nowrap>bool </td>
634 <td class="mdname" nowrap> <em>IncludeSender</em></td>
638 <td class="md">) </td>
639 <td class="md" colspan="2"><code> [virtual]</code></td>
646 <table cellspacing=5 cellpadding=0 border=0>
654 Sends text from a user to one or more channels (mulicast).
656 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.
658 Definition at line <a class="el" href="modules_8cpp-source.html#l00110">110</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
660 <div class="fragment"><pre>00111 {
661 00112 <span class="keywordflow">if</span> (IncludeSender)
663 00114 WriteCommon(User,<span class="stringliteral">"%s"</span>,text.c_str());
665 00116 <span class="keywordflow">else</span>
667 00118 WriteCommonExcept(User,<span class="stringliteral">"%s"</span>,text.c_str());
673 <a name="a6" doxytag="Server::SendFrom"></a><p>
674 <table width="100%" cellpadding="2" cellspacing="0" border="0">
677 <table cellpadding="0" cellspacing="0" border="0">
679 <td class="md" nowrap valign="top"> void Server::SendFrom </td>
680 <td class="md" valign="top">( </td>
681 <td class="md" nowrap valign="top">int </td>
682 <td class="mdname" nowrap> <em>Socket</em>, </td>
687 <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> * </td>
688 <td class="mdname" nowrap> <em>User</em>, </td>
693 <td class="md" nowrap>string </td>
694 <td class="mdname" nowrap> <em>s</em></td>
698 <td class="md">) </td>
699 <td class="md" colspan="2"><code> [virtual]</code></td>
706 <table cellspacing=5 cellpadding=0 border=0>
714 Sends text from a user to a socket.
716 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)
718 Definition at line <a class="el" href="modules_8cpp-source.html#l00083">83</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
720 <div class="fragment"><pre>00084 {
721 00085 WriteFrom(Socket,User,<span class="stringliteral">"%s"</span>,s.c_str());
726 <a name="a2" doxytag="Server::SendOpers"></a><p>
727 <table width="100%" cellpadding="2" cellspacing="0" border="0">
730 <table cellpadding="0" cellspacing="0" border="0">
732 <td class="md" nowrap valign="top"> void Server::SendOpers </td>
733 <td class="md" valign="top">( </td>
734 <td class="md" nowrap valign="top">string </td>
735 <td class="mdname1" valign="top" nowrap> <em>s</em> </td>
736 <td class="md" valign="top">) </td>
737 <td class="md" nowrap><code> [virtual]</code></td>
744 <table cellspacing=5 cellpadding=0 border=0>
752 Sends text to all opers.
754 This method sends a server notice to all opers with the usermode +s.
756 Definition at line <a class="el" href="modules_8cpp-source.html#l00063">63</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
758 <div class="fragment"><pre>00064 {
759 00065 WriteOpers(<span class="stringliteral">"%s"</span>,s.c_str());
764 <a name="a5" doxytag="Server::SendServ"></a><p>
765 <table width="100%" cellpadding="2" cellspacing="0" border="0">
768 <table cellpadding="0" cellspacing="0" border="0">
770 <td class="md" nowrap valign="top"> void Server::SendServ </td>
771 <td class="md" valign="top">( </td>
772 <td class="md" nowrap valign="top">int </td>
773 <td class="mdname" nowrap> <em>Socket</em>, </td>
778 <td class="md" nowrap>string </td>
779 <td class="mdname" nowrap> <em>s</em></td>
783 <td class="md">) </td>
784 <td class="md" colspan="2"><code> [virtual]</code></td>
791 <table cellspacing=5 cellpadding=0 border=0>
799 Sends text from the server to a socket.
801 This method writes a line of text to an established socket, with the servername prepended as used by numerics (see RFC 1459)
803 Definition at line <a class="el" href="modules_8cpp-source.html#l00078">78</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
805 <div class="fragment"><pre>00079 {
806 00080 WriteServ(Socket,<span class="stringliteral">"%s"</span>,s.c_str());
811 <a name="a7" doxytag="Server::SendTo"></a><p>
812 <table width="100%" cellpadding="2" cellspacing="0" border="0">
815 <table cellpadding="0" cellspacing="0" border="0">
817 <td class="md" nowrap valign="top"> void Server::SendTo </td>
818 <td class="md" valign="top">( </td>
819 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
820 <td class="mdname" nowrap> <em>Source</em>, </td>
825 <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> * </td>
826 <td class="mdname" nowrap> <em>Dest</em>, </td>
831 <td class="md" nowrap>string </td>
832 <td class="mdname" nowrap> <em>s</em></td>
836 <td class="md">) </td>
837 <td class="md" colspan="2"><code> [virtual]</code></td>
844 <table cellspacing=5 cellpadding=0 border=0>
852 Sends text from a user to another user.
854 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)
856 Definition at line <a class="el" href="modules_8cpp-source.html#l00088">88</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
858 <div class="fragment"><pre>00089 {
859 00090 WriteTo(Source,Dest,<span class="stringliteral">"%s"</span>,s.c_str());
864 <a name="a11" doxytag="Server::SendWallops"></a><p>
865 <table width="100%" cellpadding="2" cellspacing="0" border="0">
868 <table cellpadding="0" cellspacing="0" border="0">
870 <td class="md" nowrap valign="top"> void Server::SendWallops </td>
871 <td class="md" valign="top">( </td>
872 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
873 <td class="mdname" nowrap> <em>User</em>, </td>
878 <td class="md" nowrap>string </td>
879 <td class="mdname" nowrap> <em>text</em></td>
883 <td class="md">) </td>
884 <td class="md" colspan="2"><code> [virtual]</code></td>
891 <table cellspacing=5 cellpadding=0 border=0>
899 Sends a WALLOPS message.
901 This method writes a WALLOPS message to all users with the +w flag, originating from the specified user.
903 Definition at line <a class="el" href="modules_8cpp-source.html#l00122">122</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
905 <div class="fragment"><pre>00123 {
906 00124 WriteWallOps(User,<span class="stringliteral">"%s"</span>,text.c_str());
911 <hr>The documentation for this class was generated from the following files:<ul>
912 <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>
913 <hr><address style="align: right;"><small>Generated on Mon Jan 27 00:16:43 2003 for InspIRCd by
914 <a href="http://www.doxygen.org/index.html">
915 <img src="doxygen.png" alt="doxygen" align="middle" border=0
916 width=110 height=53></a>1.3-rc2 </small></address>