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">Log</a> (int level, string s)</td></tr>
29 <tr><td> </td><td><font size=-1><em>Writes a log 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#l00113">113</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#l00042">42</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
100 <div class="fragment"><pre>00043 {
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#l00046">46</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
136 <div class="fragment"><pre>00047 {
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#l00129">129</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
183 <div class="fragment"><pre>00130 {
184 00131 string mode = cmode(User,Chan);
185 00132 <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#l00092">92</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
231 <div class="fragment"><pre>00093 {
232 00094 <span class="keywordflow">return</span> (common_channels(u1,u2) != 0);
237 <a name="a14" doxytag="Server::FindChannel"></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"> <a class="el" href="classchanrec.html">chanrec</a> * Server::FindChannel </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>channel</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 Attempts to look up a channel and return a pointer to it.
265 This function will return NULL if the channel does not exist.
267 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>.
269 <div class="fragment"><pre>00125 {
270 00126 <span class="keywordflow">return</span> FindChan(channel.c_str());
275 <a name="a13" doxytag="Server::FindNick"></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="classuserrec.html">userrec</a> * Server::FindNick </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>nick</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 nick and return a pointer to it.
303 This function will return NULL if the nick does not exist.
305 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>.
307 <div class="fragment"><pre>00120 {
308 00121 <span class="keywordflow">return</span> Find(nick);
313 <a name="a18" doxytag="Server::GetAdmin"></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="classAdmin.html">Admin</a> Server::GetAdmin </td>
320 <td class="md" valign="top">( </td>
321 <td class="mdname1" valign="top" nowrap> </td>
322 <td class="md" valign="top">) </td>
323 <td class="md" nowrap><code> [virtual]</code></td>
330 <table cellspacing=5 cellpadding=0 border=0>
338 Returns the information of the server as returned by the /ADMIN command.
340 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.
342 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>.
344 <div class="fragment"><pre>00146 {
345 00147 <span class="keywordflow">return</span> <a class="code" href="classAdmin.html">Admin</a>(getadminname(),getadminemail(),getadminnick());
350 <a name="a17" doxytag="Server::GetNetworkName"></a><p>
351 <table width="100%" cellpadding="2" cellspacing="0" border="0">
354 <table cellpadding="0" cellspacing="0" border="0">
356 <td class="md" nowrap valign="top"> string Server::GetNetworkName </td>
357 <td class="md" valign="top">( </td>
358 <td class="mdname1" valign="top" nowrap> </td>
359 <td class="md" valign="top">) </td>
360 <td class="md" nowrap><code> [virtual]</code></td>
367 <table cellspacing=5 cellpadding=0 border=0>
375 Returns the network name, global to all linked servers.
379 Definition at line <a class="el" href="modules_8cpp-source.html#l00140">140</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
381 <div class="fragment"><pre>00141 {
382 00142 <span class="keywordflow">return</span> getnetworkname();
387 <a name="a16" doxytag="Server::GetServerName"></a><p>
388 <table width="100%" cellpadding="2" cellspacing="0" border="0">
391 <table cellpadding="0" cellspacing="0" border="0">
393 <td class="md" nowrap valign="top"> string Server::GetServerName </td>
394 <td class="md" valign="top">( </td>
395 <td class="mdname1" valign="top" nowrap> </td>
396 <td class="md" valign="top">) </td>
397 <td class="md" nowrap><code> [virtual]</code></td>
404 <table cellspacing=5 cellpadding=0 border=0>
412 Returns the server name of the server where the module is loaded.
416 Definition at line <a class="el" href="modules_8cpp-source.html#l00135">135</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
418 <div class="fragment"><pre>00136 {
419 00137 <span class="keywordflow">return</span> getservername();
424 <a name="a12" doxytag="Server::IsNick"></a><p>
425 <table width="100%" cellpadding="2" cellspacing="0" border="0">
428 <table cellpadding="0" cellspacing="0" border="0">
430 <td class="md" nowrap valign="top"> bool Server::IsNick </td>
431 <td class="md" valign="top">( </td>
432 <td class="md" nowrap valign="top">string </td>
433 <td class="mdname1" valign="top" nowrap> <em>nick</em> </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 true if a nick is valid.
452 Nicks for unregistered connections will return false.
454 Definition at line <a class="el" href="modules_8cpp-source.html#l00114">114</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
456 <div class="fragment"><pre>00115 {
457 00116 <span class="keywordflow">return</span> (isnick(nick.c_str()) != 0);
462 <a name="a3" doxytag="Server::Log"></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"> void Server::Log </td>
469 <td class="md" valign="top">( </td>
470 <td class="md" nowrap valign="top">int </td>
471 <td class="mdname" nowrap> <em>level</em>, </td>
476 <td class="md" nowrap>string </td>
477 <td class="mdname" nowrap> <em>s</em></td>
481 <td class="md">) </td>
482 <td class="md" colspan="2"><code> [virtual]</code></td>
489 <table cellspacing=5 cellpadding=0 border=0>
499 This method writes a line of text to the log. If the level given is lower than the level given in the configuration, this command has no effect.
501 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>.
503 <div class="fragment"><pre>00056 {
504 00057 log(level,<span class="stringliteral">"%s"</span>,s.c_str());
509 <a name="a4" doxytag="Server::Send"></a><p>
510 <table width="100%" cellpadding="2" cellspacing="0" border="0">
513 <table cellpadding="0" cellspacing="0" border="0">
515 <td class="md" nowrap valign="top"> void Server::Send </td>
516 <td class="md" valign="top">( </td>
517 <td class="md" nowrap valign="top">int </td>
518 <td class="mdname" nowrap> <em>Socket</em>, </td>
523 <td class="md" nowrap>string </td>
524 <td class="mdname" nowrap> <em>s</em></td>
528 <td class="md">) </td>
529 <td class="md" colspan="2"><code> [virtual]</code></td>
536 <table cellspacing=5 cellpadding=0 border=0>
544 Sends a line of text down a TCP/IP socket.
546 This method writes a line of text to an established socket, cutting it to 510 characters plus a carriage return and linefeed if required.
548 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>.
550 <div class="fragment"><pre>00061 {
551 00062 Write(Socket,<span class="stringliteral">"%s"</span>,s.c_str());
556 <a name="a8" doxytag="Server::SendChannel"></a><p>
557 <table width="100%" cellpadding="2" cellspacing="0" border="0">
560 <table cellpadding="0" cellspacing="0" border="0">
562 <td class="md" nowrap valign="top"> void Server::SendChannel </td>
563 <td class="md" valign="top">( </td>
564 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
565 <td class="mdname" nowrap> <em>User</em>, </td>
570 <td class="md" nowrap><a class="el" href="classchanrec.html">chanrec</a> * </td>
571 <td class="mdname" nowrap> <em>Channel</em>, </td>
576 <td class="md" nowrap>string </td>
577 <td class="mdname" nowrap> <em>s</em>, </td>
582 <td class="md" nowrap>bool </td>
583 <td class="mdname" nowrap> <em>IncludeSender</em></td>
587 <td class="md">) </td>
588 <td class="md" colspan="2"><code> [virtual]</code></td>
595 <table cellspacing=5 cellpadding=0 border=0>
603 Sends text from a user to a channel (mulicast).
605 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).
607 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>.
609 <div class="fragment"><pre>00081 {
610 00082 <span class="keywordflow">if</span> (IncludeSender)
612 00084 WriteChannel(Channel,User,<span class="stringliteral">"%s"</span>,s.c_str());
614 00086 <span class="keywordflow">else</span>
616 00088 ChanExceptSender(Channel,User,<span class="stringliteral">"%s"</span>,s.c_str());
622 <a name="a10" doxytag="Server::SendCommon"></a><p>
623 <table width="100%" cellpadding="2" cellspacing="0" border="0">
626 <table cellpadding="0" cellspacing="0" border="0">
628 <td class="md" nowrap valign="top"> void Server::SendCommon </td>
629 <td class="md" valign="top">( </td>
630 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
631 <td class="mdname" nowrap> <em>User</em>, </td>
636 <td class="md" nowrap>string </td>
637 <td class="mdname" nowrap> <em>text</em>, </td>
642 <td class="md" nowrap>bool </td>
643 <td class="mdname" nowrap> <em>IncludeSender</em></td>
647 <td class="md">) </td>
648 <td class="md" colspan="2"><code> [virtual]</code></td>
655 <table cellspacing=5 cellpadding=0 border=0>
663 Sends text from a user to one or more channels (mulicast).
665 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.
667 Definition at line <a class="el" href="modules_8cpp-source.html#l00097">97</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
669 <div class="fragment"><pre>00098 {
670 00099 <span class="keywordflow">if</span> (IncludeSender)
672 00101 WriteCommon(User,<span class="stringliteral">"%s"</span>,text.c_str());
674 00103 <span class="keywordflow">else</span>
676 00105 WriteCommonExcept(User,<span class="stringliteral">"%s"</span>,text.c_str());
682 <a name="a6" doxytag="Server::SendFrom"></a><p>
683 <table width="100%" cellpadding="2" cellspacing="0" border="0">
686 <table cellpadding="0" cellspacing="0" border="0">
688 <td class="md" nowrap valign="top"> void Server::SendFrom </td>
689 <td class="md" valign="top">( </td>
690 <td class="md" nowrap valign="top">int </td>
691 <td class="mdname" nowrap> <em>Socket</em>, </td>
696 <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> * </td>
697 <td class="mdname" nowrap> <em>User</em>, </td>
702 <td class="md" nowrap>string </td>
703 <td class="mdname" nowrap> <em>s</em></td>
707 <td class="md">) </td>
708 <td class="md" colspan="2"><code> [virtual]</code></td>
715 <table cellspacing=5 cellpadding=0 border=0>
723 Sends text from a user to a socket.
725 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)
727 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>.
729 <div class="fragment"><pre>00071 {
730 00072 WriteFrom(Socket,User,<span class="stringliteral">"%s"</span>,s.c_str());
735 <a name="a2" doxytag="Server::SendOpers"></a><p>
736 <table width="100%" cellpadding="2" cellspacing="0" border="0">
739 <table cellpadding="0" cellspacing="0" border="0">
741 <td class="md" nowrap valign="top"> void Server::SendOpers </td>
742 <td class="md" valign="top">( </td>
743 <td class="md" nowrap valign="top">string </td>
744 <td class="mdname1" valign="top" nowrap> <em>s</em> </td>
745 <td class="md" valign="top">) </td>
746 <td class="md" nowrap><code> [virtual]</code></td>
753 <table cellspacing=5 cellpadding=0 border=0>
761 Sends text to all opers.
763 This method sends a server notice to all opers with the usermode +s.
765 Definition at line <a class="el" href="modules_8cpp-source.html#l00050">50</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
767 <div class="fragment"><pre>00051 {
768 00052 WriteOpers(<span class="stringliteral">"%s"</span>,s.c_str());
773 <a name="a5" doxytag="Server::SendServ"></a><p>
774 <table width="100%" cellpadding="2" cellspacing="0" border="0">
777 <table cellpadding="0" cellspacing="0" border="0">
779 <td class="md" nowrap valign="top"> void Server::SendServ </td>
780 <td class="md" valign="top">( </td>
781 <td class="md" nowrap valign="top">int </td>
782 <td class="mdname" nowrap> <em>Socket</em>, </td>
787 <td class="md" nowrap>string </td>
788 <td class="mdname" nowrap> <em>s</em></td>
792 <td class="md">) </td>
793 <td class="md" colspan="2"><code> [virtual]</code></td>
800 <table cellspacing=5 cellpadding=0 border=0>
808 Sends text from the server to a socket.
810 This method writes a line of text to an established socket, with the servername prepended as used by numerics (see RFC 1459)
812 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>.
814 <div class="fragment"><pre>00066 {
815 00067 WriteServ(Socket,<span class="stringliteral">"%s"</span>,s.c_str());
820 <a name="a7" doxytag="Server::SendTo"></a><p>
821 <table width="100%" cellpadding="2" cellspacing="0" border="0">
824 <table cellpadding="0" cellspacing="0" border="0">
826 <td class="md" nowrap valign="top"> void Server::SendTo </td>
827 <td class="md" valign="top">( </td>
828 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
829 <td class="mdname" nowrap> <em>Source</em>, </td>
834 <td class="md" nowrap><a class="el" href="classuserrec.html">userrec</a> * </td>
835 <td class="mdname" nowrap> <em>Dest</em>, </td>
840 <td class="md" nowrap>string </td>
841 <td class="mdname" nowrap> <em>s</em></td>
845 <td class="md">) </td>
846 <td class="md" colspan="2"><code> [virtual]</code></td>
853 <table cellspacing=5 cellpadding=0 border=0>
861 Sends text from a user to another user.
863 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)
865 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>.
867 <div class="fragment"><pre>00076 {
868 00077 WriteTo(Source,Dest,<span class="stringliteral">"%s"</span>,s.c_str());
873 <a name="a11" doxytag="Server::SendWallops"></a><p>
874 <table width="100%" cellpadding="2" cellspacing="0" border="0">
877 <table cellpadding="0" cellspacing="0" border="0">
879 <td class="md" nowrap valign="top"> void Server::SendWallops </td>
880 <td class="md" valign="top">( </td>
881 <td class="md" nowrap valign="top"><a class="el" href="classuserrec.html">userrec</a> * </td>
882 <td class="mdname" nowrap> <em>User</em>, </td>
887 <td class="md" nowrap>string </td>
888 <td class="mdname" nowrap> <em>text</em></td>
892 <td class="md">) </td>
893 <td class="md" colspan="2"><code> [virtual]</code></td>
900 <table cellspacing=5 cellpadding=0 border=0>
908 Sends a WALLOPS message.
910 This method writes a WALLOPS message to all users with the +w flag, originating from the specified user.
912 Definition at line <a class="el" href="modules_8cpp-source.html#l00109">109</a> of file <a class="el" href="modules_8cpp-source.html">modules.cpp</a>.
914 <div class="fragment"><pre>00110 {
915 00111 WriteWallOps(User,<span class="stringliteral">"%s"</span>,text.c_str());
920 <hr>The documentation for this class was generated from the following files:<ul>
921 <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>
922 <hr><address style="align: right;"><small>Generated on Sun Feb 9 12:48:19 2003 for InspIRCd by
923 <a href="http://www.doxygen.org/index.html">
924 <img src="doxygen.png" alt="doxygen" align="middle" border=0
925 width=110 height=53></a>1.3-rc2 </small></address>