aboutsummaryrefslogtreecommitdiff
path: root/docs/doxygen/nel/a02307.html
diff options
context:
space:
mode:
Diffstat (limited to 'docs/doxygen/nel/a02307.html')
-rw-r--r--docs/doxygen/nel/a02307.html4227
1 files changed, 4227 insertions, 0 deletions
diff --git a/docs/doxygen/nel/a02307.html b/docs/doxygen/nel/a02307.html
new file mode 100644
index 00000000..818dda63
--- /dev/null
+++ b/docs/doxygen/nel/a02307.html
@@ -0,0 +1,4227 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
+<title>NeL: NLNET::CCallbackServer class Reference</title>
+<link href="doxygen.css" rel="stylesheet" type="text/css">
+</head><body>
+<!-- Generated by Doxygen 1.3.6 -->
+<div class="qindex"> <form class="search" action="search.php" method="get">
+<a class="qindex" href="main.html">Main&nbsp;Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</a> | <a class="qindex" href="classes.html">Alphabetical&nbsp;List</a> | <a class="qindex" href="annotated.html">Data&nbsp;Structures</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="namespacemembers.html">Namespace&nbsp;Members</a> | <a class="qindex" href="functions.html">Data&nbsp;Fields</a> | <a class="qindex" href="globals.html">Globals</a> | <a class="qindex" href="pages.html">Related&nbsp;Pages</a> | <span class="search"><u>S</u>earch&nbsp;for&nbsp;<input class="search" type="text" name="query" value="" size="20" accesskey="s"/></span></form></div>
+<h1>NLNET::CCallbackServer Class Reference</h1><code>#include &lt;<a class="el" href="a05529.html">callback_server.h</a>&gt;</code>
+<p>
+<p>Inheritance diagram for NLNET::CCallbackServer:
+<p><center><img src="a02307.png" usemap="#NLNET::CCallbackServer_map" border="0" alt=""></center>
+<map name="NLNET::CCallbackServer_map">
+<area href="a02306.html" alt="NLNET::CCallbackNetBase" shape="rect" coords="0,56,163,80">
+<area href="a02302.html" alt="NLNET::CBufServer" shape="rect" coords="173,56,336,80">
+<area href="a02296.html" alt="NLNET::CBufNetBase" shape="rect" coords="173,0,336,24">
+</map>
+<hr><a name="_details"></a><h2>Detailed Description</h2>
+Server class for layer 3 <dl compact><dt><b>Author:</b></dt><dd>Vianney Lecroart <p>
+Nevrax France </dd></dl>
+<dl compact><dt><b>Date:</b></dt><dd>2001 </dd></dl>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05529.html#l00044">44</a> of file <a class="el" href="a05529.html">callback_server.h</a>.<table border=0 cellpadding=0 cellspacing=0>
+<tr><td></td></tr>
+<tr><td colspan=2><br><h2>Public Types</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>enum &nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServerw7">TEventType</a> { <a class="el" href="a02296.html#NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw10">User</a> = 'U',
+<a class="el" href="a02296.html#NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw0">Connection</a> = 'C',
+<a class="el" href="a02296.html#NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw1">Disconnection</a> = 'D'
+ }</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Type of incoming events (max 256). <a href="#NLNET_1_1CCallbackServerw7">More...</a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>enum &nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerw8">TRecordingState</a> { <a class="el" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw3">Off</a>,
+<a class="el" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw4">Record</a>,
+<a class="el" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw5">Replay</a>
+ }</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>enum &nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServerw9">TThreadStategy</a> { <a class="el" href="a02302.html#NLNET_1_1CCallbackServerw9NLNET_1_1CCallbackServerw6">SpreadSockets</a>,
+<a class="el" href="a02302.html#NLNET_1_1CCallbackServerw9NLNET_1_1CCallbackServerw2">FillThreads</a>
+ }</td></tr>
+
+<tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera0">addCallbackArray</a> (const <a class="el" href="a03900.html">TCallbackItem</a> *callbackarray, <a class="el" href="a03449.html#NLMISC_1_1CStringIdArrayw0">NLMISC::CStringIdArray::TStringId</a> arraysize)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera1">authorizeOnly</a> (const char *callbackName, <a class="el" href="a02303.html">TSockId</a> hostid=<a class="el" href="a05379.html#a75">InvalidSockId</a>)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera2">bytesReceived</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the number of bytes popped by <a class="el" href="a02302.html#NLNET_1_1CCallbackServera30">receive()</a> since the beginning. <a href="#NLNET_1_1CCallbackServera2"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera3">bytesSent</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the number of bytes pushed by <a class="el" href="a02302.html#NLNET_1_1CBufServera20">send()</a> since the beginning. <a href="#NLNET_1_1CCallbackServera3"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera4">CCallbackServer</a> (<a class="el" href="a02306.html#NLNET_1_1CCallbackServerw8">TRecordingState</a> rec=Off, const std::string &amp;recfilename="", bool recordall=true)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor. <a href="#NLNET_1_1CCallbackServera4"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera5">connected</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns true if the connection is still connected. on server, we always "connected". <a href="#NLNET_1_1CCallbackServera5"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera6">disconnect</a> (<a class="el" href="a02303.html">TSockId</a> hostid, bool quick=false)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera7">disconnect</a> (<a class="el" href="a02303.html">TSockId</a> hostid)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera8">displayAllMyAssociations</a> ()</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera9">displayReceiveQueueStat</a> (<a class="el" href="a02813.html">NLMISC::CLog</a> *log=<a class="el" href="a05378.html#a12">NLMISC::InfoLog</a>)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera10">displaySendQueueStat</a> (<a class="el" href="a02813.html">NLMISC::CLog</a> *log=<a class="el" href="a05378.html#a12">NLMISC::InfoLog</a>, <a class="el" href="a02303.html">TSockId</a> destid=<a class="el" href="a05379.html#a75">InvalidSockId</a>)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera11">displayThreadStat</a> (<a class="el" href="a02813.html">NLMISC::CLog</a> *log=<a class="el" href="a05378.html#a12">NLMISC::InfoLog</a>)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera12">flush</a> (<a class="el" href="a02303.html">TSockId</a> destid)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Force to send all data pending in the send queue. <a href="#NLNET_1_1CCallbackServera12"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera13">getBytesReceived</a> ()</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera14">getBytesSent</a> ()</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera15">getReceiveQueueSize</a> ()</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera16">getSendQueueSize</a> (<a class="el" href="a02303.html">TSockId</a> destid)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera17">getSendQueueSize</a> ()</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03449.html">NLMISC::CStringIdArray</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera18">getSIDA</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Use this function to get the String ID Array needed when you want to create a message. <a href="#NLNET_1_1CCallbackServera18"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual <a class="el" href="a02303.html">TSockId</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera19">getSockId</a> (<a class="el" href="a02303.html">TSockId</a> hostid=<a class="el" href="a05379.html#a75">InvalidSockId</a>)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the sockid (cf. <a class="el" href="a02305.html">CCallbackClient</a>). <a href="#NLNET_1_1CCallbackServera19"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="a02665.html">CInetAddress</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera20">hostAddress</a> (<a class="el" href="a02303.html">TSockId</a> hostid)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the address of the specified host. <a href="#NLNET_1_1CCallbackServera20"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera21">ignoreAllUnknownId</a> (bool b)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera22">init</a> (<a class="el" href="a04558.html#a9">uint16</a> port)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Listens on the specified port. <a href="#NLNET_1_1CCallbackServera22"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera23">isAServer</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns true if this is a <a class="el" href="a02307.html">CCallbackServer</a>. <a href="#NLNET_1_1CCallbackServera23"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="a02665.html">CInetAddress</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera24">listenAddress</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the internet address of the listening socket. <a href="#NLNET_1_1CCallbackServera24"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServera25">maxExpectedBlockSize</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the max size of the received messages (default: 2^31-1). <a href="#NLNET_1_1CCallbackServera25"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServera26">maxSentBlockSize</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the max size of the sent messages (default: 2^31-1). <a href="#NLNET_1_1CCallbackServera26"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera27">nbConnections</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the number of connections (at the last <a class="el" href="a02302.html#NLNET_1_1CCallbackServera40">update()</a>). <a href="#NLNET_1_1CCallbackServera27"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera28">newBytesReceived</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the number of bytes popped by <a class="el" href="a02302.html#NLNET_1_1CCallbackServera30">receive()</a> since the previous call to this method. <a href="#NLNET_1_1CCallbackServera28"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera29">newBytesSent</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the number of bytes pushed by <a class="el" href="a02302.html#NLNET_1_1CBufServera20">send()</a> since the previous call to this method. <a href="#NLNET_1_1CCallbackServera29"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera30">receive</a> (<a class="el" href="a02271.html">NLMISC::CMemStream</a> &amp;<a class="el" href="a04223.html#a589">buffer</a>, <a class="el" href="a02303.html">TSockId</a> *hostid)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera31">send</a> (const <a class="el" href="a02918.html">CMessage</a> &amp;<a class="el" href="a04223.html#a589">buffer</a>, <a class="el" href="a02303.html">TSockId</a> hostid, bool log=true)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sends a message to the specified host. <a href="#NLNET_1_1CCallbackServera31"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera32">setConnectionCallback</a> (<a class="el" href="a05379.html#a76">TNetCallback</a> cb, void *arg)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets callback for incoming connections (or NULL to disable callback). <a href="#NLNET_1_1CCallbackServera32"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera33">setDefaultCallback</a> (<a class="el" href="a05379.html#a83">TMsgCallback</a> defaultCallback)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets default callback for unknown message types. <a href="#NLNET_1_1CCallbackServera33"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera34">setDisconnectionCallback</a> (<a class="el" href="a05379.html#a76">TNetCallback</a> cb, void *arg)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets callback for disconnections (or NULL to disable callback). <a href="#NLNET_1_1CCallbackServera34"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServera35">setMaxExpectedBlockSize</a> (<a class="el" href="a04558.html#a10">sint32</a> limit)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServera36">setMaxSentBlockSize</a> (<a class="el" href="a04558.html#a10">sint32</a> limit)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServera37">setOtherSideAssociations</a> (const char **associationarray, <a class="el" href="a03449.html#NLMISC_1_1CStringIdArrayw0">NLMISC::CStringIdArray::TStringId</a> arraysize)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera38">setSizeFlushTrigger</a> (<a class="el" href="a02303.html">TSockId</a> destid, <a class="el" href="a04558.html#a10">sint32</a> <a class="el" href="a04223.html#a587">size</a>)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera39">setTimeFlushTrigger</a> (<a class="el" href="a02303.html">TSockId</a> destid, <a class="el" href="a04558.html#a10">sint32</a> ms)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServera40">update</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Update the network (call this method evenly). <a href="#NLNET_1_1CCallbackServera40"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServera41">update</a> (<a class="el" href="a04558.html#a10">sint32</a> timeout=0)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Updates the network (call this method evenly). <a href="#NLNET_1_1CCallbackServera41"></a><br><br></td></tr>
+<tr><td colspan=2><br><h2>Protected Member Functions</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServerb0">addNewThread</a> (<a class="el" href="a05379.html#a81">CThreadPool</a> &amp;threadpool, <a class="el" href="a03365.html">CServerBufSock</a> *bufsock)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServerb1">argOfConnectionCallback</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the argument of the connection callback. <a href="#NLNET_1_1CCallbackServerb1"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServerb2">argOfDisconnectionCallback</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the argument of the disconnection callback. <a href="#NLNET_1_1CCallbackServerb2"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerb3">baseUpdate</a> (<a class="el" href="a04558.html#a10">sint32</a> timeout=0)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Used by client and server class. <a href="#NLNET_1_1CCallbackServerb3"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> () const </td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a05379.html#a76">TNetCallback</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServerb5">connectionCallback</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the connection callback. <a href="#NLNET_1_1CCallbackServerb5"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>volatile bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServerb6">dataAvailableFlag</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return _DataAvailable. <a href="#NLNET_1_1CCallbackServerb6"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a05379.html#a76">TNetCallback</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServerb7">disconnectionCallback</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the disconnection callback. <a href="#NLNET_1_1CCallbackServerb7"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServerb8">dispatchNewSocket</a> (<a class="el" href="a03365.html">CServerBufSock</a> *bufsock)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServerb9">noDelay</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the TCP_NODELAY flag. <a href="#NLNET_1_1CCallbackServerb9"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerb10">processOneMessage</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a message from the network and process it. <a href="#NLNET_1_1CCallbackServerb10"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServerb11">pushBufferToHost</a> (const <a class="el" href="a02271.html">NLMISC::CMemStream</a> &amp;<a class="el" href="a04223.html#a589">buffer</a>, <a class="el" href="a02303.html">TSockId</a> hostid)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Pushes a buffer to the specified host's send queue and update (unless not connected). <a href="#NLNET_1_1CCallbackServerb11"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServerb12">pushMessageIntoReceiveQueue</a> (const <a class="el" href="a04558.html#a7">uint8</a> *<a class="el" href="a04223.html#a589">buffer</a>, <a class="el" href="a04558.html#a11">uint32</a> <a class="el" href="a04223.html#a587">size</a>)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServerb13">pushMessageIntoReceiveQueue</a> (const std::vector&lt; <a class="el" href="a04558.html#a7">uint8</a> &gt; &amp;<a class="el" href="a04223.html#a589">buffer</a>)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Push message into receive queue (mutexed). <a href="#NLNET_1_1CCallbackServerb13"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a05379.html#a78">CSynchronizedFIFO</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServerb14">receiveQueue</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Access to the receive queue. <a href="#NLNET_1_1CCallbackServerb14"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03366.html">CServerReceiveTask</a> *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServerb15">receiveTask</a> (std::vector&lt; <a class="el" href="a03880.html">NLMISC::IThread</a> * &gt;::iterator ipt)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the receive task corresponding to a particular thread. <a href="#NLNET_1_1CCallbackServerb15"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServerb16">setDataAvailableFlag</a> (bool da)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets _DataAvailable. <a href="#NLNET_1_1CCallbackServerb16"></a><br><br></td></tr>
+<tr><td colspan=2><br><h2>Protected Attributes</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp0">_BytesReceived</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a13">uint64</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp1">_BytesSent</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>std::vector&lt; <a class="el" href="a03900.html">TCallbackItem</a> &gt;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a05379.html#a83">TMsgCallback</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp3">_DefaultCallback</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp4">_FirstUpdate</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03449.html">NLMISC::CStringIdArray</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp5">_InputSIDA</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp6">_IsAServer</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a05379.html#a76">TNetCallback</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp7">_NewDisconnectionCallback</a></td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Used by client and server class. <a href="#NLNET_1_1CCallbackServerp7"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03449.html">NLMISC::CStringIdArray</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp8">_OutputSIDA</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02306.html#NLNET_1_1CCallbackServerp9">_ThreadId</a></td></tr>
+
+<tr><td colspan=2><br><h2>Private Member Functions</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServerd0">dataAvailable</a> ()</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServerd1">receive</a> (<a class="el" href="a02918.html">CMessage</a> &amp;<a class="el" href="a04223.html#a589">buffer</a>, <a class="el" href="a02303.html">TSockId</a> *hostid)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">On this layer, you can't call directly receive, It s the <a class="el" href="a02302.html#NLNET_1_1CCallbackServera40">update()</a> function that receive and call your callaback. <a href="#NLNET_1_1CCallbackServerd1"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServerd2">send</a> (const <a class="el" href="a02271.html">NLMISC::CMemStream</a> &amp;<a class="el" href="a04223.html#a589">buffer</a>, <a class="el" href="a02303.html">TSockId</a> hostid)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">This function is public in the base class and put it private here because user cannot use it in layer 2. <a href="#NLNET_1_1CCallbackServerd2"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServerd3">sendAllMyAssociations</a> (<a class="el" href="a02303.html">TSockId</a> to)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Used by client and server class. <a href="#NLNET_1_1CCallbackServerd3"></a><br><br></td></tr>
+<tr><td colspan=2><br><h2>Private Attributes</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a05379.html#a76">TNetCallback</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServerr0">_ConnectionCallback</a></td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Connection callback. <a href="#NLNET_1_1CCallbackServerr0"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServerr1">_ConnectionCbArg</a></td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Argument of the connection callback. <a href="#NLNET_1_1CCallbackServerr1"></a><br><br></td></tr>
+<tr><td colspan=2><br><h2>Friends</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02307.html#NLNET_1_1CCallbackServern0">cbsNewConnection</a> (<a class="el" href="a02303.html">TSockId</a> <a class="el" href="a04113.html#a70">from</a>, void *<a class="el" href="a04223.html#a637">data</a>)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>class&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServern1">CListenTask</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>class&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServern2">CServerBufSock</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>class&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>class&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02296.html#NLNET_1_1CCallbackServern4">NLNET::CBufSock</a></td></tr>
+
+</table>
+<hr><h2>Member Enumeration Documentation</h2>
+<a class="anchor" name="NLNET_1_1CCallbackServerw7" doxytag="NLNET::CCallbackServer::TEventType" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> enum <a class="el" href="a02296.html#NLNET_1_1CCallbackServerw7">NLNET::CBufNetBase::TEventType</a><code> [inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Type of incoming events (max 256).
+<p>
+<dl compact><dt><b>Enumeration values: </b></dt><dd>
+<table border=0 cellspacing=2 cellpadding=0>
+<tr><td valign=top><em><a class="anchor" name="NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw10" doxytag="User" ></a>User</em>&nbsp;</td><td>
+</td></tr>
+<tr><td valign=top><em><a class="anchor" name="NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw0" doxytag="Connection" ></a>Connection</em>&nbsp;</td><td>
+</td></tr>
+<tr><td valign=top><em><a class="anchor" name="NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw1" doxytag="Disconnection" ></a>Disconnection</em>&nbsp;</td><td>
+</td></tr>
+</table>
+</dl>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00079">79</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+<div class="fragment"><pre>00079 { <a class="code" href="a02296.html#NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw10">User</a> = <span class="charliteral">'U'</span>, <a class="code" href="a02296.html#NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw0">Connection</a> = <span class="charliteral">'C'</span>, <a class="code" href="a02296.html#NLNET_1_1CCallbackServerw7NLNET_1_1CCallbackServerw1">Disconnection</a> = <span class="charliteral">'D'</span> };
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerw8" doxytag="NLNET::CCallbackServer::TRecordingState" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> enum <a class="el" href="a02306.html#NLNET_1_1CCallbackServerw8">NLNET::CCallbackNetBase::TRecordingState</a><code> [inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+<dl compact><dt><b>Enumeration values: </b></dt><dd>
+<table border=0 cellspacing=2 cellpadding=0>
+<tr><td valign=top><em><a class="anchor" name="NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw3" doxytag="Off" ></a>Off</em>&nbsp;</td><td>
+</td></tr>
+<tr><td valign=top><em><a class="anchor" name="NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw4" doxytag="Record" ></a>Record</em>&nbsp;</td><td>
+</td></tr>
+<tr><td valign=top><em><a class="anchor" name="NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw5" doxytag="Replay" ></a>Replay</em>&nbsp;</td><td>
+</td></tr>
+</table>
+</dl>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00163">163</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+<div class="fragment"><pre>00163 { <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw3">Off</a>, <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw4">Record</a>, <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw5">Replay</a> };
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerw9" doxytag="NLNET::CCallbackServer::TThreadStategy" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> enum <a class="el" href="a02302.html#NLNET_1_1CCallbackServerw9">NLNET::CBufServer::TThreadStategy</a><code> [inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+<dl compact><dt><b>Enumeration values: </b></dt><dd>
+<table border=0 cellspacing=2 cellpadding=0>
+<tr><td valign=top><em><a class="anchor" name="NLNET_1_1CCallbackServerw9NLNET_1_1CCallbackServerw6" doxytag="SpreadSockets" ></a>SpreadSockets</em>&nbsp;</td><td>
+</td></tr>
+<tr><td valign=top><em><a class="anchor" name="NLNET_1_1CCallbackServerw9NLNET_1_1CCallbackServerw2" doxytag="FillThreads" ></a>FillThreads</em>&nbsp;</td><td>
+</td></tr>
+</table>
+</dl>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00160">160</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+<div class="fragment"><pre>00160 { <a class="code" href="a02302.html#NLNET_1_1CCallbackServerw9NLNET_1_1CCallbackServerw6">SpreadSockets</a>, <a class="code" href="a02302.html#NLNET_1_1CCallbackServerw9NLNET_1_1CCallbackServerw2">FillThreads</a> };
+</pre></div> </td>
+ </tr>
+</table>
+<hr><h2>Constructor &amp; Destructor Documentation</h2>
+<a class="anchor" name="NLNET_1_1CCallbackServera4" doxytag="NLNET::CCallbackServer::CCallbackServer" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> NLNET::CCallbackServer::CCallbackServer </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02306.html#NLNET_1_1CCallbackServerw8">TRecordingState</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>rec</em> = Off, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>const std::string &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>recfilename</em> = "", </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>bool&nbsp;</td>
+ <td class="mdname" nowrap> <em>recordall</em> = true</td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Constructor.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05528.html#l00070">70</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+References <a class="el" href="a05528.html#l00045">NLNET::cbsNewConnection()</a>, <a class="el" href="a05513.html#l00130">DEFAULT_MAX_SOCKETS_PER_THREADS</a>, <a class="el" href="a05513.html#l00129">DEFAULT_MAX_THREADS</a>, <a class="el" href="a05513.html#l00128">DEFAULT_STRATEGY</a>, and <a class="el" href="a05622.html#l00333">nlassertex</a>.
+<p>
+<div class="fragment"><pre>00070 :
+00071 <a class="code" href="a02306.html#NLNET_1_1CCallbackNetBaseb1">CCallbackNetBase</a>( rec, recfilename, recordall ),
+00072 <a class="code" href="a02302.html#NLNET_1_1CBufServera2">CBufServer</a>( DEFAULT_STRATEGY, DEFAULT_MAX_THREADS, DEFAULT_MAX_SOCKETS_PER_THREADS, <span class="keyword">true</span>, rec==Replay ),
+00073 <a class="code" href="a02307.html#NLNET_1_1CCallbackServerr0">_ConnectionCallback</a>(NULL),
+00074 <a class="code" href="a02307.html#NLNET_1_1CCallbackServerr1">_ConnectionCbArg</a>(NULL)
+00075 {
+00076 <span class="preprocessor">#ifndef USE_MESSAGE_RECORDER</span>
+00077 <span class="preprocessor"></span> <a class="code" href="a04199.html#a8">nlassertex</a>( rec==Off, (<span class="stringliteral">"LNETL3S: The message recorder is disabled at compilation time ; switch the recording state Off"</span>) );
+00078 <span class="preprocessor">#endif</span>
+00079 <span class="preprocessor"></span>
+00080 CBufServer::setDisconnectionCallback (_NewDisconnectionCallback, <span class="keyword">this</span>);
+00081 CBufServer::setConnectionCallback (cbsNewConnection, <span class="keyword">this</span>);
+00082
+00083 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp6">_IsAServer</a> = <span class="keyword">true</span>;
+00084 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp3">_DefaultCallback</a> = NULL;
+00085 }
+
+</pre></div> </td>
+ </tr>
+</table>
+<hr><h2>Member Function Documentation</h2>
+<a class="anchor" name="NLNET_1_1CCallbackServera0" doxytag="NLNET::CCallbackServer::addCallbackArray" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::addCallbackArray </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const <a class="el" href="a03900.html">TCallbackItem</a> *&nbsp;</td>
+ <td class="mdname" nowrap> <em>callbackarray</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a03449.html#NLMISC_1_1CStringIdArrayw0">NLMISC::CStringIdArray::TStringId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>arraysize</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Appends callback array with the specified array. You can add callback only *after* adding the server or the client. <dl compact><dt><b>Parameters:</b></dt><dd>
+ <table border="0" cellspacing="2" cellpadding="0">
+ <tr><td valign=top><em>arraysize</em>&nbsp;</td><td>is the number of callback items.</td></tr>
+ </table>
+</dl>
+
+<p>
+Definition at line <a class="el" href="a05526.html#l00184">184</a> of file <a class="el" href="a05526.html">callback_net_base.cpp</a>.
+<p>
+References <a class="el" href="a05527.html#l00196">NLNET::CCallbackNetBase::_CallbackArray</a>, <a class="el" href="a05527.html#l00193">NLNET::CCallbackNetBase::_OutputSIDA</a>, <a class="el" href="a06468.html#l00059">NLMISC::CStringIdArray::addString()</a>, <a class="el" href="a05527.html#l00064">NLNET::TCallbackItem::Callback</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a06468.html#l00142">NLMISC::CStringIdArray::resize()</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a06468.html#l00148">NLMISC::CStringIdArray::size()</a>, <a class="el" href="a06468.html#l00054">NLMISC::CStringIdArray::TStringId</a>, and <a class="el" href="a05981.html#l00105">uint</a>.
+<p>
+Referenced by <a class="el" href="a05524.html#l00059">NLNET::CCallbackClient::CCallbackClient()</a>, <a class="el" href="a05526.html#l00148">NLNET::CCallbackNetBase::CCallbackNetBase()</a>, <a class="el" href="a06138.html#l00577">NLNET::CPacsClient::connect()</a>, <a class="el" href="a06089.html#l00239">NLNET::CNamingClient::connect()</a>, <a class="el" href="a05958.html#l00063">NLNET::CLoginClient::connectToShard()</a>, <a class="el" href="a06645.html#l00479">NLNET::CUnifiedNetwork::init()</a>, <a class="el" href="a05962.html#l00338">NLNET::CLoginServer::init()</a>, and <a class="el" href="a06650.html#l00280">NLNET::_CUniTime::installServer()</a>.
+<p>
+<div class="fragment"><pre>00185 {
+00186 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00187
+00188 <span class="comment">// be sure that the 2 array have the same size</span>
+00189 <a class="code" href="a04199.html#a6">nlassert</a> (<a class="code" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a>.size () == (<a class="code" href="a04558.html#a15">uint</a>)<a class="code" href="a02306.html#NLNET_1_1CCallbackServerp8">_OutputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya12">size</a> ());
+00190
+00191 <span class="keywordflow">if</span> (arraysize == 1 &amp;&amp; callbackarray[0].Callback == NULL &amp;&amp; string(<span class="stringliteral">""</span>) == callbackarray[0].Key)
+00192 {
+00193 <span class="comment">// it's an empty array, ignore it</span>
+00194 <span class="keywordflow">return</span>;
+00195 }
+00196
+00197 <span class="comment">// resize the array</span>
+00198 <a class="code" href="a04558.html#a14">sint</a> oldsize = <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a>.size();
+00199
+00200 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a>.resize (oldsize + arraysize);
+00201 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp8">_OutputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya11">resize</a> (oldsize + arraysize);
+00202
+00203 <span class="comment">//TOO MUCH MESSAGE nldebug ("L3NB_CB: Adding %d callback to the array", arraysize);</span>
+00204
+00205 <span class="keywordflow">for</span> (<a class="code" href="a04558.html#a14">sint</a> i = 0; i &lt; arraysize; i++)
+00206 {
+00207 <a class="code" href="a03449.html#NLMISC_1_1CStringIdArrayw0">CStringIdArray::TStringId</a> ni = oldsize + i;
+00208 <span class="comment">//TOO MUCH MESSAGE nldebug ("L3NB_CB: Adding callback to message '%s', id '%d'", callbackarray[i].Key, ni);</span>
+00209 <span class="comment">// copy callback value</span>
+00210
+00211 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a>[ni] = callbackarray[i];
+00212 <span class="comment">// add the string to the string id array</span>
+00213 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp8">_OutputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya1">addString</a> (callbackarray[i].Key, ni);
+00214
+00215 }
+00216 <span class="comment">// nldebug ("LNETL3NB_CB: Added %d callback Now, there're %d callback associated with message type", arraysize, _CallbackArray.size ());</span>
+00217 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb0" doxytag="NLNET::CCallbackServer::addNewThread" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::addNewThread </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a05379.html#a81">CThreadPool</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>threadpool</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a03365.html">CServerBufSock</a> *&nbsp;</td>
+ <td class="mdname" nowrap> <em>bufsock</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05512.html#l00958">958</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00432">NLNET::CServerReceiveTask::addNewSocket()</a>, <a class="el" href="a05513.html#l00273">NLNET::CBufServer::CServerReceiveTask</a>, <a class="el" href="a05513.html#l00115">NLNET::CThreadPool</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, <a class="el" href="a05515.html#l00040">nlnettrace</a>, and <a class="el" href="a05515.html#l00351">NLNET::CServerBufSock::setOwnerTask()</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00866">NLNET::CBufServer::dispatchNewSocket()</a>.
+<p>
+<div class="fragment"><pre>00959 {
+00960 <a class="code" href="a04092.html#a0">nlnettrace</a>( <span class="stringliteral">"CBufServer::addNewThread"</span> );
+00961 <a class="code" href="a04199.html#a6">nlassert</a>( bufsock != NULL );
+00962
+00963 <span class="comment">// Create new task and dispatch the socket to it</span>
+00964 <a class="code" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a> *task = <span class="keyword">new</span> <a class="code" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a>( <span class="keyword">this</span> );
+00965 bufsock-&gt;setOwnerTask( task );
+00966 task-&gt;addNewSocket( bufsock );
+00967
+00968 <span class="comment">// Add a new thread to the pool, with this task</span>
+00969 IThread *thr = IThread::create( task );
+00970 {
+00971 threadpool.push_back( thr );
+00972 thr-&gt;start();
+00973 <a class="code" href="a04199.html#a0">nldebug</a>( <span class="stringliteral">"LNETL1: Added a new thread; pool size is %d"</span>, threadpool.size() );
+00974 <a class="code" href="a04199.html#a0">nldebug</a>( <span class="stringliteral">"LNETL1: New socket dispatched to thread %d"</span>, threadpool.size()-1 );
+00975 }
+00976 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb1" doxytag="NLNET::CCallbackServer::argOfConnectionCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void* NLNET::CBufServer::argOfConnectionCallback </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the argument of the connection callback.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00314">314</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05513.html#l00352">NLNET::CBufServer::_ConnectionCbArg</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00364">NLNET::CBufServer::dataAvailable()</a>.
+<p>
+<div class="fragment"><pre>00314 { <span class="keywordflow">return</span> <a class="code" href="a02307.html#NLNET_1_1CCallbackServerr1">_ConnectionCbArg</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb2" doxytag="NLNET::CCallbackServer::argOfDisconnectionCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void* NLNET::CBufNetBase::argOfDisconnectionCallback </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the argument of the disconnection callback.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00160">160</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00220">NLNET::CBufNetBase::_DisconnectionCbArg</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00364">NLNET::CBufServer::dataAvailable()</a>, and <a class="el" href="a05506.html#l00140">NLNET::CBufClient::dataAvailable()</a>.
+<p>
+<div class="fragment"><pre>00160 { <span class="keywordflow">return</span> _DisconnectionCbArg; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera1" doxytag="NLNET::CCallbackServer::authorizeOnly" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::authorizeOnly </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const char *&nbsp;</td>
+ <td class="mdname" nowrap> <em>callbackName</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>hostid</em> = <a class="el" href="a05379.html#a75">InvalidSockId</a></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets the callback that you want the other side calls. If it didn't call this callback, it will be disconnected If cb is NULL, we authorize *all* callback. On a client, the hostid must be InvalidSockId (or ommited). On a server, you must provide a hostid.
+<p>
+Definition at line <a class="el" href="a05526.html#l00471">471</a> of file <a class="el" href="a05526.html">callback_net_base.cpp</a>.
+<p>
+References <a class="el" href="a05514.html#l00329">NLNET::CBufSock::asString()</a>, <a class="el" href="a05515.html#l00070">NLNET::CBufSock::AuthorizedCallback</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea15">NLNET::CCallbackNetBase::getSockId()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+Referenced by <a class="el" href="a05962.html#l00181">NLNET::cbShardValidation()</a>, and <a class="el" href="a05962.html#l00230">NLNET::ClientConnection()</a>.
+<p>
+<div class="fragment"><pre>00472 {
+00473 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00474
+00475 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3NB: authorizeOnly (%s, %s)"</span>, callbackName, hostid-&gt;asString().c_str());
+00476
+00477 hostid = <a class="code" href="a02307.html#NLNET_1_1CCallbackServera19">getSockId</a> (hostid);
+00478
+00479 <a class="code" href="a04199.html#a6">nlassert</a> (hostid != InvalidSockId);
+00480
+00481 hostid-&gt;AuthorizedCallback = (callbackName == NULL)?<span class="stringliteral">""</span>:callbackName;
+00482 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb3" doxytag="NLNET::CCallbackServer::baseUpdate" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::baseUpdate </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a10">sint32</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>timeout</em> = 0 </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Used by client and server class.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05526.html#l00328">328</a> of file <a class="el" href="a05526.html">callback_net_base.cpp</a>.
+<p>
+References <a class="el" href="a05527.html#l00202">NLNET::CCallbackNetBase::_FirstUpdate</a>, <a class="el" href="a05527.html#l00188">NLNET::CCallbackNetBase::_InputSIDA</a>, <a class="el" href="a05527.html#l00220">NLNET::CCallbackNetBase::_LastMovedStringArray</a>, <a class="el" href="a05527.html#l00219">NLNET::CCallbackNetBase::_LastUpdateTime</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05527.html#l00132">NLNET::CCallbackNetBase::dataAvailable()</a>, <a class="el" href="a06468.html#l00160">NLMISC::CStringIdArray::getAskedStringArray()</a>, <a class="el" href="a06468.html#l00154">NLMISC::CStringIdArray::getNeedToAskedStringArray()</a>, <a class="el" href="a05788.html#l00056">H_AUTO</a>, <a class="el" href="a06468.html#l00166">NLMISC::CStringIdArray::moveNeedToAskToAskedStringArray()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, <a class="el" href="a05586.html#l00073">NLMISC::nlSleep()</a>, <a class="el" href="a05526.html#l00223">NLNET::CCallbackNetBase::processOneMessage()</a>, <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea19">NLNET::CCallbackNetBase::send()</a>, <a class="el" href="a05979.html#l00420">NLMISC::CMemStream::serial()</a>, <a class="el" href="a05981.html#l00099">sint32</a>, <a class="el" href="a05646.html#l00645">size</a>, <a class="el" href="a06468.html#l00054">NLMISC::CStringIdArray::TStringId</a>, and <a class="el" href="a06553.html#l00047">NLMISC::TTime</a>.
+<p>
+Referenced by <a class="el" href="a05528.html#l00175">update()</a>, and <a class="el" href="a05524.html#l00162">NLNET::CCallbackClient::update()</a>.
+<p>
+<div class="fragment"><pre>00329 {
+00330 <a class="code" href="a04365.html#a4">H_AUTO</a>(L3UpdateCallbackNetBase);
+00331
+00332 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00333
+00334 <span class="comment">// slow down the layer H_AUTO (CCallbackNetBase_baseUpdate);</span>
+00335
+00336 <a class="code" href="a04199.html#a6">nlassert</a>( timeout &gt;= -1 );
+00337 <a class="code" href="a05378.html#a242">TTime</a> t0 = CTime::getLocalTime();
+00338
+00339 <span class="comment">//</span>
+00340 <span class="comment">// The first time, we init time counters</span>
+00341 <span class="comment">//</span>
+00342 <span class="keywordflow">if</span> (<a class="code" href="a02306.html#NLNET_1_1CCallbackServerp4">_FirstUpdate</a>)
+00343 {
+00344 <span class="comment">// nldebug("LNETL3NB: First update()");</span>
+00345 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp4">_FirstUpdate</a> = <span class="keyword">false</span>;
+00346 _LastUpdateTime = t0;
+00347 _LastMovedStringArray = t0;
+00348 }
+00349
+00350 <span class="comment">//</span>
+00351 <span class="comment">// Every 1 seconds if we have new unknown association, we ask them to the other side</span>
+00352 <span class="comment">//</span>
+00353 <span class="keywordflow">if</span> (t0 - _LastUpdateTime &gt; 1000)
+00354 {
+00355 <span class="comment">// nldebug("LNETL3NB: baseUpdate()");</span>
+00356 _LastUpdateTime = t0;
+00357
+00358 <span class="keyword">const</span> set&lt;string&gt; &amp;sa = <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp5">_InputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya7">getNeedToAskedStringArray</a> ();
+00359 <span class="keywordflow">if</span> (!sa.empty ())
+00360 {
+00361 <a class="code" href="a02918.html">CMessage</a> msgout (_InputSIDA, <span class="stringliteral">"AA"</span>);
+00362 <span class="comment">//nlassert (sa.size () &lt; 65536); // no size limit anymore</span>
+00363 <a class="code" href="a03449.html#NLMISC_1_1CStringIdArrayw0">CStringIdArray::TStringId</a> <a class="code" href="a04223.html#a587">size</a> = sa.size ();
+00364 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3NB_ASSOC: I need %d string association, ask them to the other side"</span>, size);
+00365 msgout.<a class="code" href="a02271.html#NLNET_1_1CMessagea41">serial</a> (size);
+00366 <span class="keywordflow">for</span> (set&lt;string&gt;::iterator it = sa.begin(); it != sa.end(); it++)
+00367 {
+00368 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3NB_ASSOC: what is the id of '%s'?"</span>, (*it).c_str ());
+00369 string str(*it);
+00370 msgout.<a class="code" href="a02271.html#NLNET_1_1CMessagea41">serial</a> (str);
+00371 }
+00372 <span class="comment">// send the message to the other side</span>
+00373 <a class="code" href="a02307.html#NLNET_1_1CCallbackServera31">send</a> (msgout, 0);
+00374 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp5">_InputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya10">moveNeedToAskToAskedStringArray</a>();
+00375 _LastMovedStringArray = t0;
+00376 }
+00377 }
+00378
+00379 <span class="comment">//</span>
+00380 <span class="comment">// Every 60 seconds if we have not answered association, we ask again to get them!</span>
+00381 <span class="comment">//</span>
+00382 <span class="keywordflow">if</span> (!<a class="code" href="a02306.html#NLNET_1_1CCallbackServerp5">_InputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya5">getAskedStringArray</a>().empty() &amp;&amp; t0 - _LastMovedStringArray &gt; 60000)
+00383 {
+00384 <span class="comment">// we didn't have an answer for the association, resend them</span>
+00385 <span class="keyword">const</span> set&lt;string&gt; sa = <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp5">_InputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya5">getAskedStringArray</a> ();
+00386 <a class="code" href="a02918.html">CMessage</a> msgout (_InputSIDA, <span class="stringliteral">"AA"</span>);
+00387 <span class="comment">//nlassert (sa.size () &lt; 65536); // no size limit anymore</span>
+00388 <a class="code" href="a03449.html#NLMISC_1_1CStringIdArrayw0">CStringIdArray::TStringId</a> <a class="code" href="a04223.html#a587">size</a> = sa.size ();
+00389 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3NB_ASSOC: client didn't answer my asked association, retry! I need %d string association, ask them to the other side"</span>, size);
+00390 msgout.<a class="code" href="a02271.html#NLNET_1_1CMessagea41">serial</a> (size);
+00391 <span class="keywordflow">for</span> (set&lt;string&gt;::iterator it = sa.begin(); it != sa.end(); it++)
+00392 {
+00393 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3NB_ASSOC: what is the id of '%s'?"</span>, (*it).c_str ());
+00394 string str(*it);
+00395 msgout.<a class="code" href="a02271.html#NLNET_1_1CMessagea41">serial</a> (str);
+00396 }
+00397 <span class="comment">// sends the message to the other side</span>
+00398 <a class="code" href="a02307.html#NLNET_1_1CCallbackServera31">send</a> (msgout, 0);
+00399 _LastMovedStringArray = t0;
+00400 }
+00401
+00402 <span class="comment">/*</span>
+00403 <span class="comment"> * timeout -1 =&gt; read one message in the queue or nothing if no message in queue</span>
+00404 <span class="comment"> * timeout 0 =&gt; read all messages in the queue</span>
+00405 <span class="comment"> * timeout other =&gt; read all messages in the queue until timeout expired (at least all one time)</span>
+00406 <span class="comment"> */</span>
+00407
+00408 <span class="keywordtype">bool</span> exit = <span class="keyword">false</span>;
+00409
+00410 <span class="keywordflow">while</span> (!exit)
+00411 {
+00412 <span class="comment">// process all messages in the queue</span>
+00413 <span class="keywordflow">while</span> (<a class="code" href="a02307.html#NLNET_1_1CCallbackServerd0">dataAvailable</a> ())
+00414 {
+00415 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb10">processOneMessage</a> ();
+00416 <span class="keywordflow">if</span> (timeout == -1)
+00417 {
+00418 exit = <span class="keyword">true</span>;
+00419 <span class="keywordflow">break</span>;
+00420 }
+00421 }
+00422
+00423 <span class="comment">// need to exit?</span>
+00424 <span class="keywordflow">if</span> (timeout == 0 || (<a class="code" href="a04558.html#a10">sint32</a>)(CTime::getLocalTime() - t0) &gt; timeout)
+00425 {
+00426 exit = <span class="keyword">true</span>;
+00427 }
+00428 <span class="keywordflow">else</span>
+00429 {
+00430 <span class="comment">// enable multithreading on windows :-/</span>
+00431 <span class="comment">// slow down the layer H_AUTO (CCallbackNetBase_baseUpdate_nlSleep);</span>
+00432 <a class="code" href="a05378.html#a256">nlSleep</a> (10);
+00433 }
+00434 }
+00435
+00436 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00437 <span class="preprocessor"></span> _MR_UpdateCounter++;
+00438 <span class="preprocessor">#endif</span>
+00439 <span class="preprocessor"></span>
+00440 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera2" doxytag="NLNET::CCallbackServer::bytesReceived" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> NLNET::CBufServer::bytesReceived </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the number of bytes popped by <a class="el" href="a02302.html#NLNET_1_1CCallbackServera30">receive()</a> since the beginning.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00255">255</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05513.html#l00358">NLNET::CBufServer::_BytesPoppedIn</a>, and <a class="el" href="a05981.html#l00102">uint64</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00749">NLNET::CBufServer::newBytesReceived()</a>.
+<p>
+<div class="fragment"><pre>00255 { <span class="keywordflow">return</span> _BytesPoppedIn; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera3" doxytag="NLNET::CCallbackServer::bytesSent" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> NLNET::CBufServer::bytesSent </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the number of bytes pushed by <a class="el" href="a02302.html#NLNET_1_1CBufServera20">send()</a> since the beginning.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00261">261</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05513.html#l00355">NLNET::CBufServer::_BytesPushedOut</a>, and <a class="el" href="a05981.html#l00102">uint64</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00761">NLNET::CBufServer::newBytesSent()</a>.
+<p>
+<div class="fragment"><pre>00261 { <span class="keywordflow">return</span> _BytesPushedOut; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb4" doxytag="NLNET::CCallbackServer::checkThreadId" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::checkThreadId </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05526.html#l00533">533</a> of file <a class="el" href="a05526.html">callback_net_base.cpp</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00184">NLNET::CCallbackNetBase::addCallbackArray()</a>, <a class="el" href="a05526.html#l00471">NLNET::CCallbackNetBase::authorizeOnly()</a>, <a class="el" href="a05526.html#l00328">NLNET::CCallbackNetBase::baseUpdate()</a>, <a class="el" href="a05524.html#l00286">NLNET::CCallbackClient::connect()</a>, <a class="el" href="a05529.html#l00067">connected()</a>, <a class="el" href="a05525.html#l00069">NLNET::CCallbackClient::connected()</a>, <a class="el" href="a05528.html#l00283">dataAvailable()</a>, <a class="el" href="a05524.html#l00192">NLNET::CCallbackClient::dataAvailable()</a>, <a class="el" href="a05528.html#l00246">disconnect()</a>, <a class="el" href="a05524.html#l00354">NLNET::CCallbackClient::disconnect()</a>, <a class="el" href="a05526.html#l00464">NLNET::CCallbackNetBase::displayAllMyAssociations()</a>, <a class="el" href="a05529.html#l00055">flush()</a>, <a class="el" href="a05524.html#l00134">NLNET::CCallbackClient::flush()</a>, <a class="el" href="a05528.html#l00268">getSockId()</a>, <a class="el" href="a05524.html#l00272">NLNET::CCallbackClient::getSockId()</a>, <a class="el" href="a05529.html#l00077">hostAddress()</a>, <a class="el" href="a05527.html#l00126">NLNET::CCallbackNetBase::isAServer()</a>, <a class="el" href="a05526.html#l00223">NLNET::CCallbackNetBase::processOneMessage()</a>, <a class="el" href="a05528.html#l00205">receive()</a>, <a class="el" href="a05524.html#l00220">NLNET::CCallbackClient::receive()</a>, <a class="el" href="a05528.html#l00124">send()</a>, <a class="el" href="a05524.html#l00079">NLNET::CCallbackClient::send()</a>, <a class="el" href="a05528.html#l00091">sendAllMyAssociations()</a>, <a class="el" href="a05529.html#l00061">setConnectionCallback()</a>, <a class="el" href="a05529.html#l00064">setDisconnectionCallback()</a>, <a class="el" href="a05527.html#l00113">NLNET::CCallbackNetBase::setDisconnectionCallback()</a>, <a class="el" href="a05525.html#l00080">NLNET::CCallbackClient::setDisconnectionCallback()</a>, <a class="el" href="a05526.html#l00451">NLNET::CCallbackNetBase::setOtherSideAssociations()</a>, <a class="el" href="a05528.html#l00175">update()</a>, and <a class="el" href="a05524.html#l00162">NLNET::CCallbackClient::update()</a>.
+<p>
+<div class="fragment"><pre>00534 {
+00535 <span class="comment">/* some people use this class in different thread but with a mutex to be sure to have</span>
+00536 <span class="comment"> no concurent access</span>
+00537 <span class="comment"> if (getThreadId () != _ThreadId)</span>
+00538 <span class="comment"> {</span>
+00539 <span class="comment"> nlerror ("You try to access to the same CCallbackClient or CCallbackServer with 2 differents thread (%d and %d)", _ThreadId, getThreadId());</span>
+00540 <span class="comment"> }</span>
+00541 <span class="comment">*/</span>
+00542 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera5" doxytag="NLNET::CCallbackServer::connected" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> bool NLNET::CCallbackServer::connected </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns true if the connection is still connected. on server, we always "connected".
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea2">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00067">67</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>.
+<p>
+<div class="fragment"><pre>00067 { <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> (); <span class="keywordflow">return</span> <span class="keyword">true</span>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb5" doxytag="NLNET::CCallbackServer::connectionCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a05379.html#a76">TNetCallback</a> NLNET::CBufServer::connectionCallback </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the connection callback.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00311">311</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05513.html#l00349">NLNET::CBufServer::_ConnectionCallback</a>, and <a class="el" href="a05511.html#l00047">NLNET::TNetCallback</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00364">NLNET::CBufServer::dataAvailable()</a>.
+<p>
+<div class="fragment"><pre>00311 { <span class="keywordflow">return</span> <a class="code" href="a02307.html#NLNET_1_1CCallbackServerr0">_ConnectionCallback</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerd0" doxytag="NLNET::CCallbackServer::dataAvailable" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> bool NLNET::CCallbackServer::dataAvailable </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [private]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Checks if there is some data to receive. Returns false if the receive queue is empty. This is where the connection/disconnection callbacks can be called.
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServera3">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05528.html#l00283">283</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+References <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>.
+<p>
+<div class="fragment"><pre>00284 {
+00285 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00286
+00287 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00288 <span class="preprocessor"></span> <span class="keywordflow">if</span> ( _MR_RecordingState != <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw5">Replay</a> )
+00289 {
+00290 <span class="preprocessor">#endif</span>
+00291 <span class="preprocessor"></span>
+00292 <span class="comment">// Real dataAvailable()</span>
+00293 <span class="keywordflow">return</span> CBufServer::dataAvailable ();
+00294
+00295 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00296 <span class="preprocessor"></span> }
+00297 <span class="keywordflow">else</span>
+00298 {
+00299 <span class="comment">// Simulated dataAvailable()</span>
+00300 <span class="keywordflow">return</span> CCallbackNetBase::replayDataAvailable();
+00301 }
+00302 <span class="preprocessor">#endif</span>
+00303 <span class="preprocessor"></span>}
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb6" doxytag="NLNET::CCallbackServer::dataAvailableFlag" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> volatile bool NLNET::CBufNetBase::dataAvailableFlag </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Return _DataAvailable.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00206">206</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00214">NLNET::CBufNetBase::_DataAvailable</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00364">NLNET::CBufServer::dataAvailable()</a>, and <a class="el" href="a05506.html#l00140">NLNET::CBufClient::dataAvailable()</a>.
+<p>
+<div class="fragment"><pre>00206 { <span class="keywordflow">return</span> _DataAvailable; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera6" doxytag="NLNET::CCallbackServer::disconnect" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::disconnect </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>hostid</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>bool&nbsp;</td>
+ <td class="mdname" nowrap> <em>quick</em> = false</td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Disconnect a connection Set hostid to InvalidSockId to disconnect all connections. If hostid is not InvalidSockId and the socket is not connected, the method does nothing. If quick is true, any pending data will not be sent before disconnecting.
+<p>
+Definition at line <a class="el" href="a05512.html#l00251">251</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00487">NLNET::CServerReceiveTask::_Connections</a>, <a class="el" href="a05513.html#l00346">NLNET::CBufServer::_ThreadPool</a>, <a class="el" href="a02444.html#NLNET_1_1CUdpSockz2109_0">NLNET::CSock::connected()</a>, <a class="el" href="a06487.html#l00101">NLNET::CTcpSock::disconnect()</a>, <a class="el" href="a05514.html#l00137">NLNET::CBufSock::flush()</a>, <a class="el" href="a05515.html#l00040">nlnettrace</a>, <a class="el" href="a05513.html#l00284">NLNET::CBufServer::receiveTask()</a>, <a class="el" href="a05515.html#l00243">NLNET::CBufSock::Sock</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00252 {
+00253 <a class="code" href="a04092.html#a0">nlnettrace</a>( <span class="stringliteral">"CBufServer::disconnect"</span> );
+00254 <span class="keywordflow">if</span> ( hostid != InvalidSockId )
+00255 {
+00256 <span class="comment">// Disconnect only if physically connected</span>
+00257 <span class="keywordflow">if</span> ( hostid-&gt;Sock-&gt;connected() )
+00258 {
+00259 <span class="keywordflow">if</span> ( ! quick )
+00260 {
+00261 hostid-&gt;flush();
+00262 }
+00263 hostid-&gt;Sock-&gt;disconnect(); <span class="comment">// the connection will be removed by the next call of update()</span>
+00264 }
+00265 }
+00266 <span class="keywordflow">else</span>
+00267 {
+00268 <span class="comment">// Disconnect all</span>
+00269 CThreadPool::iterator ipt;
+00270 {
+00271 CSynchronized&lt;CThreadPool&gt;::CAccessor poolsync( &amp;_ThreadPool );
+00272 <span class="keywordflow">for</span> ( ipt=poolsync.value().begin(); ipt!=poolsync.value().end(); ++ipt )
+00273 {
+00274 <a class="code" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a> *task = <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb15">receiveTask</a>(ipt);
+00275 CConnections::iterator ipb;
+00276 {
+00277 CSynchronized&lt;CConnections&gt;::CAccessor connectionssync( &amp;task-&gt;_Connections );
+00278 <span class="keywordflow">for</span> ( ipb=connectionssync.value().begin(); ipb!=connectionssync.value().end(); ++ipb )
+00279 {
+00280 <span class="keywordflow">if</span> ( (*ipb)-&gt;Sock-&gt;connected() )
+00281 {
+00282 <span class="keywordflow">if</span> ( ! quick )
+00283 {
+00284 (*ipb)-&gt;flush();
+00285 }
+00286 (*ipb)-&gt;Sock-&gt;disconnect();
+00287 }
+00288 }
+00289 }
+00290 }
+00291 }
+00292 }
+00293 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera7" doxytag="NLNET::CCallbackServer::disconnect" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::disconnect </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>hostid</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Disconnect a connection Set hostid to InvalidSockId to disconnect all connections. If hostid is not InvalidSockId and the socket is not connected, the method does nothing. Before disconnecting, any pending data is actually sent.
+<p>
+Reimplemented from <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea4">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05528.html#l00246">246</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+References <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+Referenced by <a class="el" href="a05962.html#l00142">NLNET::cbWSDisconnectClient()</a>, and <a class="el" href="a06645.html#l00599">NLNET::CUnifiedNetwork::release()</a>.
+<p>
+<div class="fragment"><pre>00247 {
+00248 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00249
+00250 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00251 <span class="preprocessor"></span> <span class="keywordflow">if</span> ( _MR_RecordingState != <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw5">Replay</a> )
+00252 {
+00253 <span class="preprocessor">#endif</span>
+00254 <span class="preprocessor"></span> <span class="comment">// Disconnect</span>
+00255 CBufServer::disconnect( hostid );
+00256
+00257 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00258 <span class="preprocessor"></span> }
+00259 <span class="comment">// else, no need to manually replay the disconnection, such as in CCallbackClient,</span>
+00260 <span class="comment">// it will be replayed during the next update()</span>
+00261 <span class="preprocessor">#endif</span>
+00262 <span class="preprocessor"></span>}
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb7" doxytag="NLNET::CCallbackServer::disconnectionCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a05379.html#a76">TNetCallback</a> NLNET::CBufNetBase::disconnectionCallback </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the disconnection callback.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00157">157</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00217">NLNET::CBufNetBase::_DisconnectionCallback</a>, and <a class="el" href="a05511.html#l00047">NLNET::TNetCallback</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00364">NLNET::CBufServer::dataAvailable()</a>, and <a class="el" href="a05506.html#l00140">NLNET::CBufClient::dataAvailable()</a>.
+<p>
+<div class="fragment"><pre>00157 { <span class="keywordflow">return</span> _DisconnectionCallback; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb8" doxytag="NLNET::CCallbackServer::dispatchNewSocket" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::dispatchNewSocket </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a03365.html">CServerBufSock</a> *&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>bufsock</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Binds a new socket and send buffer to an existing or a new thread (that starts) Note: this method is called in the listening thread.
+<p>
+Definition at line <a class="el" href="a05512.html#l00866">866</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00332">NLNET::CBufServer::_MaxSocketsPerThread</a>, <a class="el" href="a05513.html#l00329">NLNET::CBufServer::_MaxThreads</a>, <a class="el" href="a05513.html#l00346">NLNET::CBufServer::_ThreadPool</a>, <a class="el" href="a05513.html#l00326">NLNET::CBufServer::_ThreadStrategy</a>, <a class="el" href="a05513.html#l00432">NLNET::CServerReceiveTask::addNewSocket()</a>, <a class="el" href="a05512.html#l00958">NLNET::CBufServer::addNewThread()</a>, <a class="el" href="a05484.html#l00038">min</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, <a class="el" href="a05515.html#l00040">nlnettrace</a>, <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a05513.html#l00421">NLNET::CServerReceiveTask::numberOfConnections()</a>, <a class="el" href="a05513.html#l00284">NLNET::CBufServer::receiveTask()</a>, <a class="el" href="a05515.html#l00351">NLNET::CServerBufSock::setOwnerTask()</a>, <a class="el" href="a02302.html#NLNET_1_1CCallbackServerw9NLNET_1_1CCallbackServerw6">NLNET::CBufServer::SpreadSockets</a>, and <a class="el" href="a05981.html#l00105">uint</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00779">NLNET::CListenTask::run()</a>.
+<p>
+<div class="fragment"><pre>00867 {
+00868 <a class="code" href="a04092.html#a0">nlnettrace</a>( <span class="stringliteral">"CBufServer::dispatchNewSocket"</span> );
+00869
+00870 CSynchronized&lt;CThreadPool&gt;::CAccessor poolsync( &amp;_ThreadPool );
+00871 <span class="keywordflow">if</span> ( _ThreadStrategy == <a class="code" href="a02302.html#NLNET_1_1CCallbackServerw9NLNET_1_1CCallbackServerw6">SpreadSockets</a> )
+00872 {
+00873 <span class="comment">// Find the thread with the smallest number of connections and check if all</span>
+00874 <span class="comment">// threads do not have the same number of connections</span>
+00875 <a class="code" href="a04558.html#a15">uint</a> <a class="code" href="a04061.html#a0">min</a> = 0xFFFFFFFF;
+00876 <a class="code" href="a04558.html#a15">uint</a> max = 0;
+00877 CThreadPool::iterator ipt, iptmin, iptmax;
+00878 <span class="keywordflow">for</span> ( iptmin=iptmax=ipt=poolsync.value().begin(); ipt!=poolsync.value().end(); ++ipt )
+00879 {
+00880 <a class="code" href="a04558.html#a15">uint</a> noc = <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb15">receiveTask</a>(ipt)-&gt;numberOfConnections();
+00881 <span class="keywordflow">if</span> ( noc &lt; <a class="code" href="a04061.html#a0">min</a> )
+00882 {
+00883 <a class="code" href="a04061.html#a0">min</a> = noc;
+00884 iptmin = ipt;
+00885 }
+00886 <span class="keywordflow">if</span> ( noc &gt; max )
+00887 {
+00888 max = noc;
+00889 iptmax = ipt;
+00890 }
+00891 }
+00892
+00893 <span class="comment">// Check if we make the pool of threads grow (if we have not found vacant room</span>
+00894 <span class="comment">// and if it is allowed to)</span>
+00895 <span class="keywordflow">if</span> ( (poolsync.value().empty()) ||
+00896 ((<a class="code" href="a04061.html#a0">min</a> == max) &amp;&amp; (poolsync.value().size() &lt; _MaxThreads)) )
+00897 {
+00898 <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb0">addNewThread</a>( poolsync.value(), bufsock );
+00899 }
+00900 <span class="keywordflow">else</span>
+00901 {
+00902 <span class="comment">// Dispatch socket to an existing thread of the pool</span>
+00903 <a class="code" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a> *task = <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb15">receiveTask</a>(iptmin);
+00904 bufsock-&gt;setOwnerTask( task );
+00905 task-&gt;addNewSocket( bufsock );
+00906 <span class="preprocessor">#ifdef NL_OS_UNIX</span>
+00907 <span class="preprocessor"></span> task-&gt;wakeUp();
+00908 <span class="preprocessor">#endif </span>
+00909 <span class="preprocessor"></span>
+00910 <span class="keywordflow">if</span> ( <a class="code" href="a04061.html#a0">min</a> &gt;= (<a class="code" href="a04558.html#a15">uint</a>)_MaxSocketsPerThread )
+00911 {
+00912 <a class="code" href="a04199.html#a2">nlwarning</a>( <span class="stringliteral">"LNETL1: Exceeding the maximum number of sockets per thread"</span> );
+00913 }
+00914 <a class="code" href="a04199.html#a0">nldebug</a>( <span class="stringliteral">"LNETL1: New socket dispatched to thread %d"</span>, iptmin-poolsync.value().begin() );
+00915 }
+00916
+00917 }
+00918 <span class="keywordflow">else</span> <span class="comment">// _ThreadStrategy == FillThreads</span>
+00919 {
+00920 CThreadPool::iterator ipt;
+00921 <span class="keywordflow">for</span> ( ipt=poolsync.value().begin(); ipt!=poolsync.value().end(); ++ipt )
+00922 {
+00923 <a class="code" href="a04558.html#a15">uint</a> noc = <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb15">receiveTask</a>(ipt)-&gt;numberOfConnections();
+00924 <span class="keywordflow">if</span> ( noc &lt; _MaxSocketsPerThread )
+00925 {
+00926 <span class="keywordflow">break</span>;
+00927 }
+00928 }
+00929
+00930 <span class="comment">// Check if we have to make the thread pool grow (if we have not found vacant room)</span>
+00931 <span class="keywordflow">if</span> ( ipt == poolsync.value().end() )
+00932 {
+00933 <span class="keywordflow">if</span> ( poolsync.value().size() == _MaxThreads )
+00934 {
+00935 <a class="code" href="a04199.html#a2">nlwarning</a>( <span class="stringliteral">"LNETL1: Exceeding the maximum number of threads"</span> );
+00936 }
+00937 <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb0">addNewThread</a>( poolsync.value(), bufsock );
+00938 }
+00939 <span class="keywordflow">else</span>
+00940 {
+00941 <span class="comment">// Dispatch socket to an existing thread of the pool</span>
+00942 <a class="code" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a> *task = <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb15">receiveTask</a>(ipt);
+00943 bufsock-&gt;setOwnerTask( task );
+00944 task-&gt;addNewSocket( bufsock );
+00945 <span class="preprocessor">#ifdef NL_OS_UNIX</span>
+00946 <span class="preprocessor"></span> task-&gt;wakeUp();
+00947 <span class="preprocessor">#endif </span>
+00948 <span class="preprocessor"></span> <a class="code" href="a04199.html#a0">nldebug</a>( <span class="stringliteral">"LNETL1: New socket dispatched to thread %d"</span>, ipt-poolsync.value().begin() );
+00949 }
+00950 }
+00951 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera8" doxytag="NLNET::CCallbackServer::displayAllMyAssociations" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::displayAllMyAssociations </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05526.html#l00464">464</a> of file <a class="el" href="a05526.html">callback_net_base.cpp</a>.
+<p>
+References <a class="el" href="a05527.html#l00193">NLNET::CCallbackNetBase::_OutputSIDA</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, and <a class="el" href="a06468.html#l00187">NLMISC::CStringIdArray::display()</a>.
+<p>
+Referenced by <a class="el" href="a05958.html#l00063">NLNET::CLoginClient::connectToShard()</a>.
+<p>
+<div class="fragment"><pre>00465 {
+00466 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00467
+00468 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp8">_OutputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya4">display</a> ();
+00469 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera9" doxytag="NLNET::CCallbackServer::displayReceiveQueueStat" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::displayReceiveQueueStat </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02813.html">NLMISC::CLog</a> *&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>log</em> = <a class="el" href="a05378.html#a12">NLMISC::InfoLog</a> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Implements <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea6">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00085">85</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+<div class="fragment"><pre>00085 { CBufServer::displayReceiveQueueStat(log); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera10" doxytag="NLNET::CCallbackServer::displaySendQueueStat" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::displaySendQueueStat </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02813.html">NLMISC::CLog</a> *&nbsp;</td>
+ <td class="mdname" nowrap> <em>log</em> = <a class="el" href="a05378.html#a12">NLMISC::InfoLog</a>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>destid</em> = <a class="el" href="a05379.html#a75">InvalidSockId</a></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inline]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServera6">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00086">86</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00086 { CBufServer::displaySendQueueStat(log, destid); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera11" doxytag="NLNET::CCallbackServer::displayThreadStat" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::displayThreadStat </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02813.html">NLMISC::CLog</a> *&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>log</em> = <a class="el" href="a05378.html#a12">NLMISC::InfoLog</a> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServera7">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00088">88</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+<div class="fragment"><pre>00088 { CBufServer::displayThreadStat(log); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera12" doxytag="NLNET::CCallbackServer::flush" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> bool NLNET::CCallbackServer::flush </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>destid</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Force to send all data pending in the send queue.
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServera8">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00055">55</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00055 { <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> (); <a class="code" href="a04199.html#a6">nlassert</a>( destid != InvalidSockId ); <span class="keywordflow">return</span> CBufServer::flush(destid); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera13" doxytag="NLNET::CCallbackServer::getBytesReceived" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> NLNET::CCallbackNetBase::getBytesReceived </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00088">88</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+References <a class="el" href="a05527.html#l00167">NLNET::CCallbackNetBase::_BytesReceived</a>, and <a class="el" href="a05981.html#l00102">uint64</a>.
+<p>
+Referenced by <a class="el" href="a06645.html#l01263">NLNET::CUnifiedNetwork::getBytesReceived()</a>.
+<p>
+<div class="fragment"><pre>00088 { <span class="keywordflow">return</span> <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp0">_BytesReceived</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera14" doxytag="NLNET::CCallbackServer::getBytesSent" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> NLNET::CCallbackNetBase::getBytesSent </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00087">87</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+References <a class="el" href="a05527.html#l00167">NLNET::CCallbackNetBase::_BytesSent</a>, and <a class="el" href="a05981.html#l00102">uint64</a>.
+<p>
+Referenced by <a class="el" href="a06645.html#l01239">NLNET::CUnifiedNetwork::getBytesSent()</a>.
+<p>
+<div class="fragment"><pre>00087 { <span class="keywordflow">return</span> <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp1">_BytesSent</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera15" doxytag="NLNET::CCallbackServer::getReceiveQueueSize" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> NLNET::CCallbackServer::getReceiveQueueSize </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Implements <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea12">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00082">82</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05981.html#l00102">uint64</a>.
+<p>
+Referenced by <a class="el" href="a06645.html#l01311">NLNET::CUnifiedNetwork::getReceiveQueueSize()</a>.
+<p>
+<div class="fragment"><pre>00082 { <span class="keywordflow">return</span> CBufServer::getReceiveQueueSize(); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera16" doxytag="NLNET::CCallbackServer::getSendQueueSize" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a11">uint32</a> NLNET::CBufServer::getSendQueueSize </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>destid</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05512.html#l00660">660</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00487">NLNET::CServerReceiveTask::_Connections</a>, <a class="el" href="a05513.html#l00346">NLNET::CBufServer::_ThreadPool</a>, <a class="el" href="a05513.html#l00284">NLNET::CBufServer::receiveTask()</a>, <a class="el" href="a05515.html#l00240">NLNET::CBufSock::SendFifo</a>, <a class="el" href="a05508.html#l00410">NLMISC::CBufFIFO::size()</a>, <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+<div class="fragment"><pre>00661 {
+00662 <span class="keywordflow">if</span> ( destid != InvalidSockId )
+00663 {
+00664 <span class="keywordflow">return</span> destid-&gt;SendFifo.size();
+00665 }
+00666 <span class="keywordflow">else</span>
+00667 {
+00668 <span class="comment">// add all client buffers</span>
+00669
+00670 <a class="code" href="a04558.html#a11">uint32</a> total = 0;
+00671
+00672 <span class="comment">// For each thread</span>
+00673 CThreadPool::iterator ipt;
+00674 {
+00675 CSynchronized&lt;CThreadPool&gt;::CAccessor poolsync( &amp;_ThreadPool );
+00676 <span class="keywordflow">for</span> ( ipt=poolsync.value().begin(); ipt!=poolsync.value().end(); ++ipt )
+00677 {
+00678 <span class="comment">// For each thread of the pool</span>
+00679 <a class="code" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a> *task = <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb15">receiveTask</a>(ipt);
+00680 CConnections::iterator ipb;
+00681 {
+00682 CSynchronized&lt;CConnections&gt;::CAccessor connectionssync( &amp;task-&gt;_Connections );
+00683 <span class="keywordflow">for</span> ( ipb=connectionssync.value().begin(); ipb!=connectionssync.value().end(); ++ipb )
+00684 {
+00685 <span class="comment">// For each socket of the thread, update sending</span>
+00686 total = (*ipb)-&gt;SendFifo.size ();
+00687 }
+00688 }
+00689 }
+00690 }
+00691 <span class="keywordflow">return</span> total;
+00692 }
+00693 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera17" doxytag="NLNET::CCallbackServer::getSendQueueSize" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> NLNET::CCallbackServer::getSendQueueSize </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Implements <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea13">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00083">83</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05981.html#l00102">uint64</a>.
+<p>
+Referenced by <a class="el" href="a06645.html#l01287">NLNET::CUnifiedNetwork::getSendQueueSize()</a>.
+<p>
+<div class="fragment"><pre>00083 { <span class="keywordflow">return</span> CBufServer::getSendQueueSize(0); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera18" doxytag="NLNET::CCallbackServer::getSIDA" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a03449.html">NLMISC::CStringIdArray</a>&amp; NLNET::CCallbackNetBase::getSIDA </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Use this function to get the String ID Array needed when you want to create a message.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00129">129</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+References <a class="el" href="a05527.html#l00188">NLNET::CCallbackNetBase::_InputSIDA</a>.
+<p>
+Referenced by <a class="el" href="a05524.html#l00043">NLNET::cbcMessageRecvAllAssociations()</a>, <a class="el" href="a05526.html#l00088">NLNET::cbnbMessageAskAssociations()</a>, <a class="el" href="a05526.html#l00055">NLNET::cbnbMessageRecvAssociations()</a>, <a class="el" href="a06650.html#l00262">NLNET::cbServerAskUniversalTime()</a>, <a class="el" href="a05962.html#l00181">NLNET::cbShardValidation()</a>, <a class="el" href="a05958.html#l00063">NLNET::CLoginClient::connectToShard()</a>, <a class="el" href="a06094.html#l00123">NLNET::CNetDisplayer::doDisplay()</a>, <a class="el" href="a06089.html#l00411">NLNET::CNamingClient::queryServicePort()</a>, <a class="el" href="a06089.html#l00302">NLNET::CNamingClient::registerService()</a>, <a class="el" href="a06089.html#l00340">NLNET::CNamingClient::registerServiceWithSId()</a>, <a class="el" href="a06089.html#l00373">NLNET::CNamingClient::resendRegisteration()</a>, <a class="el" href="a05528.html#l00091">sendAllMyAssociations()</a>, <a class="el" href="a05526.html#l00451">NLNET::CCallbackNetBase::setOtherSideAssociations()</a>, and <a class="el" href="a06089.html#l00385">NLNET::CNamingClient::unregisterService()</a>.
+<p>
+<div class="fragment"><pre>00129 { <span class="keywordflow">return</span> <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp5">_InputSIDA</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera19" doxytag="NLNET::CCallbackServer::getSockId" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a02303.html">TSockId</a> NLNET::CCallbackServer::getSockId </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>hostid</em> = <a class="el" href="a05379.html#a75">InvalidSockId</a> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the sockid (cf. <a class="el" href="a02305.html">CCallbackClient</a>).
+<p>
+
+<p>
+Implements <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea15">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05528.html#l00268">268</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+References <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00269 {
+00270 <a class="code" href="a04199.html#a6">nlassert</a> (hostid != InvalidSockId); <span class="comment">// invalid hostid</span>
+00271 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00272 <a class="code" href="a04199.html#a6">nlassert</a> (connected ());
+00273 <a class="code" href="a04199.html#a6">nlassert</a> (hostid != NULL);
+00274 <span class="keywordflow">return</span> hostid;
+00275 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera20" doxytag="NLNET::CCallbackServer::hostAddress" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> const <a class="el" href="a02665.html">CInetAddress</a>&amp; NLNET::CCallbackServer::hostAddress </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>hostid</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the address of the specified host.
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServera11">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00077">77</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00077 { <a class="code" href="a04199.html#a6">nlassert</a>(hostid!=InvalidSockId); <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a>(); <span class="keywordflow">return</span> CBufServer::hostAddress (hostid); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera21" doxytag="NLNET::CCallbackServer::ignoreAllUnknownId" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::ignoreAllUnknownId </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">bool&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>b</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+If you ignore all unknown id, the net will not ask for other side to know new association. It's used in the naming service for example because the naming client will never answer. In this case, it will always send the message with the full string name (slower)
+<p>
+Definition at line <a class="el" href="a05527.html#l00157">157</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+References <a class="el" href="a05527.html#l00188">NLNET::CCallbackNetBase::_InputSIDA</a>, and <a class="el" href="a06468.html#l00176">NLMISC::CStringIdArray::ignoreAllUnknownId()</a>.
+<p>
+<div class="fragment"><pre>00158 {
+00159 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp5">_InputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya9">ignoreAllUnknownId</a> (b);
+00160 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera22" doxytag="NLNET::CCallbackServer::init" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::init </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a9">uint16</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>port</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Listens on the specified port.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05512.html#l00093">93</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00335">NLNET::CBufServer::_ListenTask</a>, <a class="el" href="a05513.html#l00338">NLNET::CBufServer::_ListenThread</a>, <a class="el" href="a05513.html#l00370">NLNET::CBufServer::_ReplayMode</a>, <a class="el" href="a05512.html#l00111">NLNET::CListenTask::init()</a>, <a class="el" href="a05511.html#l00135">NLNET::CBufNetBase::maxExpectedBlockSize()</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, <a class="el" href="a05515.html#l00040">nlnettrace</a>, <a class="el" href="a03880.html#NLMISC_1_1IThreada4">NLMISC::IThread::start()</a>, and <a class="el" href="a05981.html#l00098">uint16</a>.
+<p>
+Referenced by <a class="el" href="a06098.html#l00207">NLNET::CNetManager::addServer()</a>, and <a class="el" href="a06645.html#l00479">NLNET::CUnifiedNetwork::init()</a>.
+<p>
+<div class="fragment"><pre>00094 {
+00095 <a class="code" href="a04092.html#a0">nlnettrace</a>( <span class="stringliteral">"CBufServer::init"</span> );
+00096 <span class="keywordflow">if</span> ( ! _ReplayMode )
+00097 {
+00098 _ListenTask-&gt;init( port, <a class="code" href="a02296.html#NLNET_1_1CCallbackServera25">maxExpectedBlockSize</a>() );
+00099 _ListenThread-&gt;start();
+00100 }
+00101 <span class="keywordflow">else</span>
+00102 {
+00103 <a class="code" href="a04199.html#a0">nldebug</a>( <span class="stringliteral">"LNETL1: Binding listen socket to any address, port %hu"</span>, port );
+00104 }
+00105 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera23" doxytag="NLNET::CCallbackServer::isAServer" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> bool NLNET::CCallbackNetBase::isAServer </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns true if this is a <a class="el" href="a02307.html">CCallbackServer</a>.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00126">126</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+References <a class="el" href="a05527.html#l00201">NLNET::CCallbackNetBase::_IsAServer</a>, and <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>.
+<p>
+<div class="fragment"><pre>00126 { <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> (); <span class="keywordflow">return</span> <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp6">_IsAServer</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera24" doxytag="NLNET::CCallbackServer::listenAddress" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> const <a class="el" href="a02665.html">CInetAddress</a>&amp; NLNET::CBufServer::listenAddress </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the internet address of the listening socket.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00238">238</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05513.html#l00335">NLNET::CBufServer::_ListenTask</a>, and <a class="el" href="a05513.html#l00104">NLNET::CListenTask::localAddr()</a>.
+<p>
+Referenced by <a class="el" href="a05962.html#l00338">NLNET::CLoginServer::init()</a>, <a class="el" href="a05962.html#l00467">NLNET::NLMISC_DYNVARIABLE()</a>, and <a class="el" href="a05962.html#l00244">NLNET::setListenAddress()</a>.
+<p>
+<div class="fragment"><pre>00238 { <span class="keywordflow">return</span> _ListenTask-&gt;localAddr(); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera25" doxytag="NLNET::CCallbackServer::maxExpectedBlockSize" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a11">uint32</a> NLNET::CBufNetBase::maxExpectedBlockSize </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the max size of the received messages (default: 2^31-1).
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00135">135</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00223">NLNET::CBufNetBase::_MaxExpectedBlockSize</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+Referenced by <a class="el" href="a05506.html#l00085">NLNET::CBufClient::connect()</a>, and <a class="el" href="a05512.html#l00093">NLNET::CBufServer::init()</a>.
+<p>
+<div class="fragment"><pre>00136 {
+00137 <span class="keywordflow">return</span> _MaxExpectedBlockSize;
+00138 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera26" doxytag="NLNET::CCallbackServer::maxSentBlockSize" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a11">uint32</a> NLNET::CBufNetBase::maxSentBlockSize </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the max size of the sent messages (default: 2^31-1).
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00141">141</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00226">NLNET::CBufNetBase::_MaxSentBlockSize</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00299">NLNET::CBufServer::send()</a>, and <a class="el" href="a05506.html#l00121">NLNET::CBufClient::send()</a>.
+<p>
+<div class="fragment"><pre>00142 {
+00143 <span class="keywordflow">return</span> _MaxSentBlockSize;
+00144 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera27" doxytag="NLNET::CCallbackServer::nbConnections" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a11">uint32</a> NLNET::CBufServer::nbConnections </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the number of connections (at the last <a class="el" href="a02302.html#NLNET_1_1CCallbackServera40">update()</a>).
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00267">267</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05513.html#l00367">NLNET::CBufServer::_NbConnections</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+Referenced by <a class="el" href="a05528.html#l00124">send()</a>.
+<p>
+<div class="fragment"><pre>00267 { <span class="keywordflow">return</span> _NbConnections; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera28" doxytag="NLNET::CCallbackServer::newBytesReceived" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> NLNET::CBufServer::newBytesReceived </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the number of bytes popped by <a class="el" href="a02302.html#NLNET_1_1CCallbackServera30">receive()</a> since the previous call to this method.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05512.html#l00749">749</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00361">NLNET::CBufServer::_PrevBytesPoppedIn</a>, <a class="el" href="a05513.html#l00255">NLNET::CBufServer::bytesReceived()</a>, and <a class="el" href="a05981.html#l00102">uint64</a>.
+<p>
+<div class="fragment"><pre>00750 {
+00751 <a class="code" href="a04558.html#a13">uint64</a> b = <a class="code" href="a02302.html#NLNET_1_1CCallbackServera2">bytesReceived</a>();
+00752 <a class="code" href="a04558.html#a13">uint64</a> nbrecvd = b - _PrevBytesPoppedIn;
+00753 <span class="comment">//nlinfo( "b: %"NL_I64"u new: %"NL_I64"u", b, nbrecvd );</span>
+00754 _PrevBytesPoppedIn = b;
+00755 <span class="keywordflow">return</span> nbrecvd;
+00756 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera29" doxytag="NLNET::CCallbackServer::newBytesSent" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> NLNET::CBufServer::newBytesSent </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the number of bytes pushed by <a class="el" href="a02302.html#NLNET_1_1CBufServera20">send()</a> since the previous call to this method.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05512.html#l00761">761</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00364">NLNET::CBufServer::_PrevBytesPushedOut</a>, <a class="el" href="a05513.html#l00261">NLNET::CBufServer::bytesSent()</a>, and <a class="el" href="a05981.html#l00102">uint64</a>.
+<p>
+<div class="fragment"><pre>00762 {
+00763 <a class="code" href="a04558.html#a13">uint64</a> b = <a class="code" href="a02302.html#NLNET_1_1CCallbackServera3">bytesSent</a>();
+00764 <a class="code" href="a04558.html#a13">uint64</a> nbsent = b - _PrevBytesPushedOut;
+00765 <span class="comment">//nlinfo( "b: %"NL_I64"u new: %"NL_I64"u", b, nbsent );</span>
+00766 _PrevBytesPushedOut = b;
+00767 <span class="keywordflow">return</span> nbsent;
+00768 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb9" doxytag="NLNET::CCallbackServer::noDelay" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> bool NLNET::CBufServer::noDelay </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the TCP_NODELAY flag.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00276">276</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00779">NLNET::CListenTask::run()</a>.
+<p>
+<div class="fragment"><pre>00276 { <span class="keywordflow">return</span> _NoDelay; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb10" doxytag="NLNET::CCallbackServer::processOneMessage" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::processOneMessage </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Read a message from the network and process it.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05526.html#l00223">223</a> of file <a class="el" href="a05526.html">callback_net_base.cpp</a>.
+<p>
+References <a class="el" href="a05527.html#l00167">NLNET::CCallbackNetBase::_BytesReceived</a>, <a class="el" href="a05527.html#l00196">NLNET::CCallbackNetBase::_CallbackArray</a>, <a class="el" href="a05527.html#l00199">NLNET::CCallbackNetBase::_DefaultCallback</a>, <a class="el" href="a05527.html#l00193">NLNET::CCallbackNetBase::_OutputSIDA</a>, <a class="el" href="a05514.html#l00329">NLNET::CBufSock::asString()</a>, <a class="el" href="a05515.html#l00070">NLNET::CBufSock::AuthorizedCallback</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05527.html#l00138">NLNET::CCallbackNetBase::disconnect()</a>, <a class="el" href="a06026.html#l00432">NLNET::CMessage::getId()</a>, <a class="el" href="a06026.html#l00411">NLNET::CMessage::getName()</a>, <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea15">NLNET::CCallbackNetBase::getSockId()</a>, <a class="el" href="a06027.html#l00104">NLNET::CMessage::length()</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBaseb4">NLNET::CCallbackNetBase::receive()</a>, <a class="el" href="a05981.html#l00097">sint16</a>, <a class="el" href="a05527.html#l00055">NLNET::TMsgCallback</a>, <a class="el" href="a06026.html#l00441">NLNET::CMessage::toString()</a>, <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>, <a class="el" href="a06468.html#l00054">NLMISC::CStringIdArray::TStringId</a>, and <a class="el" href="a06027.html#l00239">NLNET::CMessage::TypeHasAnId</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00328">NLNET::CCallbackNetBase::baseUpdate()</a>.
+<p>
+<div class="fragment"><pre>00224 {
+00225 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00226
+00227 <span class="comment">// slow down the layer H_AUTO (CCallbackNetBase_processOneMessage);</span>
+00228
+00229 <a class="code" href="a02918.html">CMessage</a> msgin (_OutputSIDA, <span class="stringliteral">""</span>, <span class="keyword">true</span>);
+00230 <a class="code" href="a05379.html#a74">TSockId</a> tsid;
+00231 <a class="code" href="a02307.html#NLNET_1_1CCallbackServerd1">receive</a> (msgin, &amp;tsid);
+00232
+00233 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp0">_BytesReceived</a> += msgin.<a class="code" href="a02918.html#NLNET_1_1CMessagea24">length</a> ();
+00234
+00235 <span class="comment">// now, we have to call the good callback</span>
+00236 <a class="code" href="a03449.html#NLMISC_1_1CStringIdArrayw0">NLMISC::CStringIdArray::TStringId</a> pos = -1;
+00237 <span class="keywordflow">if</span> (msgin.<a class="code" href="a02918.html#NLNET_1_1CMessageo1">TypeHasAnId</a>)
+00238 {
+00239 pos = msgin.<a class="code" href="a02918.html#NLNET_1_1CMessagea15">getId</a> ();
+00240 }
+00241 <span class="keywordflow">else</span>
+00242 {
+00243 std::string name = msgin.<a class="code" href="a02918.html#NLNET_1_1CMessagea16">getName</a> ();
+00244 <a class="code" href="a04558.html#a8">sint16</a> i;
+00245 <span class="keywordflow">for</span> (i = 0; i &lt; (<a class="code" href="a04558.html#a8">sint16</a>) <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a>.size (); i++)
+00246 {
+00247 <span class="keywordflow">if</span> (name == <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a>[i].Key)
+00248 {
+00249 pos = i;
+00250 <span class="keywordflow">break</span>;
+00251 }
+00252 }
+00253 }
+00254
+00255 <a class="code" href="a05379.html#a83">TMsgCallback</a> cb = NULL;
+00256 <span class="keywordflow">if</span> (pos &lt; 0 || pos &gt;= (<a class="code" href="a04558.html#a8">sint16</a>) <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a>.size ())
+00257 {
+00258 <span class="keywordflow">if</span> (<a class="code" href="a02306.html#NLNET_1_1CCallbackServerp3">_DefaultCallback</a> == NULL)
+00259 {
+00260 <a class="code" href="a04199.html#a2">nlwarning</a> (<span class="stringliteral">"LNETL3NB_CB: Callback %s not found in _CallbackArray"</span>, msgin.<a class="code" href="a02918.html#NLNET_1_1CMessagea63">toString</a>().c_str());
+00261 }
+00262 <span class="keywordflow">else</span>
+00263 {
+00264 cb = <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp3">_DefaultCallback</a>;
+00265 }
+00266 }
+00267 <span class="keywordflow">else</span>
+00268 {
+00269 cb = <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp2">_CallbackArray</a>[pos].Callback;
+00270 }
+00271
+00272 <a class="code" href="a05379.html#a74">TSockId</a> realid = <a class="code" href="a02307.html#NLNET_1_1CCallbackServera19">getSockId</a> (tsid);
+00273
+00274 <span class="keywordflow">if</span> (!realid-&gt;AuthorizedCallback.empty() &amp;&amp; msgin.<a class="code" href="a02918.html#NLNET_1_1CMessagea16">getName</a>() != realid-&gt;AuthorizedCallback)
+00275 {
+00276 <a class="code" href="a04199.html#a2">nlwarning</a> (<span class="stringliteral">"LNETL3NB_CB: %s try to call the callback %s but only %s is authorized. Disconnect him!"</span>, tsid-&gt;asString().c_str(), msgin.<a class="code" href="a02918.html#NLNET_1_1CMessagea63">toString</a>().c_str(), tsid-&gt;AuthorizedCallback.c_str());
+00277 <a class="code" href="a02307.html#NLNET_1_1CCallbackServera7">disconnect</a> (tsid);
+00278 }
+00279 <span class="keywordflow">else</span> <span class="keywordflow">if</span> (cb == NULL)
+00280 {
+00281 <a class="code" href="a04199.html#a2">nlwarning</a> (<span class="stringliteral">"LNETL3NB_CB: Callback %s is NULL, can't call it"</span>, msgin.<a class="code" href="a02918.html#NLNET_1_1CMessagea63">toString</a>().c_str());
+00282 }
+00283 <span class="keywordflow">else</span>
+00284 {
+00285 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3NB_CB: Calling callback (%s)%s"</span>, msgin.<a class="code" href="a02918.html#NLNET_1_1CMessagea16">getName</a>().c_str(), (cb==<a class="code" href="a02306.html#NLNET_1_1CCallbackServerp3">_DefaultCallback</a>)?<span class="stringliteral">" DEFAULT_CB"</span>:<span class="stringliteral">""</span>);
+00286 cb(msgin, realid, *<span class="keyword">this</span>);
+00287 }
+00288
+00289 <span class="comment">/*</span>
+00290 <span class="comment"> if (pos &lt; 0 || pos &gt;= (sint16) _CallbackArray.size ())</span>
+00291 <span class="comment"> {</span>
+00292 <span class="comment"> if (_DefaultCallback == NULL)</span>
+00293 <span class="comment"> nlwarning ("LNETL3NB_CB: Callback %s not found in _CallbackArray", msgin.toString().c_str());</span>
+00294 <span class="comment"> else</span>
+00295 <span class="comment"> {</span>
+00296 <span class="comment"> // ...</span>
+00297 <span class="comment"> }</span>
+00298 <span class="comment"> }</span>
+00299 <span class="comment"> else</span>
+00300 <span class="comment"> {</span>
+00301 <span class="comment"> TSockId realid = getSockId (tsid);</span>
+00302 <span class="comment"></span>
+00303 <span class="comment"> if (!realid-&gt;AuthorizedCallback.empty() &amp;&amp; msgin.getName() != realid-&gt;AuthorizedCallback)</span>
+00304 <span class="comment"> {</span>
+00305 <span class="comment"> nlwarning ("LNETL3NB_CB: %s try to call the callback %s but only %s is authorized. Disconnect him!", tsid-&gt;asString().c_str(), msgin.toString().c_str(), tsid-&gt;AuthorizedCallback.c_str());</span>
+00306 <span class="comment"> disconnect (tsid);</span>
+00307 <span class="comment"> }</span>
+00308 <span class="comment"> else if (_CallbackArray[pos].Callback == NULL)</span>
+00309 <span class="comment"> {</span>
+00310 <span class="comment"> nlwarning ("LNETL3NB_CB: Callback %s is NULL, can't call it", msgin.toString().c_str());</span>
+00311 <span class="comment"> }</span>
+00312 <span class="comment"> else</span>
+00313 <span class="comment"> {</span>
+00314 <span class="comment"> nldebug ("LNETL3NB_CB: Calling callback (%s)", _CallbackArray[pos].Key);</span>
+00315 <span class="comment"> _CallbackArray[pos].Callback (msgin, realid, *this);</span>
+00316 <span class="comment"> }</span>
+00317 <span class="comment"> }</span>
+00318 <span class="comment">*/</span>
+00319 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb11" doxytag="NLNET::CCallbackServer::pushBufferToHost" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::pushBufferToHost </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const <a class="el" href="a02271.html">NLMISC::CMemStream</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>buffer</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>hostid</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Pushes a buffer to the specified host's send queue and update (unless not connected).
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00298">298</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05513.html#l00355">NLNET::CBufServer::_BytesPushedOut</a>, <a class="el" href="a05646.html#l00649">buffer</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05515.html#l00178">NLNET::CBufSock::pushBuffer()</a>, <a class="el" href="a05511.html#l00059">NLNET::TBlockSize</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00299">NLNET::CBufServer::send()</a>.
+<p>
+<div class="fragment"><pre>00299 {
+00300 <a class="code" href="a04199.html#a6">nlassert</a>( hostid != InvalidSockId );
+00301 <span class="keywordflow">if</span> ( hostid-&gt;pushBuffer( buffer ) )
+00302 {
+00303 _BytesPushedOut += <a class="code" href="a04223.html#a589">buffer</a>.length() + <span class="keyword">sizeof</span>(<a class="code" href="a05379.html#a80">TBlockSize</a>); <span class="comment">// statistics</span>
+00304 }
+00305 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb12" doxytag="NLNET::CCallbackServer::pushMessageIntoReceiveQueue" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufNetBase::pushMessageIntoReceiveQueue </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const <a class="el" href="a04558.html#a7">uint8</a> *&nbsp;</td>
+ <td class="mdname" nowrap> <em>buffer</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>size</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00183">183</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00211">NLNET::CBufNetBase::_RecvFifo</a>, <a class="el" href="a05646.html#l00649">buffer</a>, <a class="el" href="a05511.html#l00056">NLNET::CFifoAccessor</a>, <a class="el" href="a05511.html#l00203">NLNET::CBufNetBase::setDataAvailableFlag()</a>, <a class="el" href="a05646.html#l00645">size</a>, <a class="el" href="a05981.html#l00100">uint32</a>, and <a class="el" href="a05981.html#l00096">uint8</a>.
+<p>
+<div class="fragment"><pre>00184 {
+00185 <span class="comment">//sint32 mbsize;</span>
+00186 {
+00187 <span class="comment">//nldebug( "BNB: Acquiring the receive queue... ");</span>
+00188 <a class="code" href="a05379.html#a79">CFifoAccessor</a> recvfifo( &amp;_RecvFifo );
+00189 <span class="comment">//nldebug( "BNB: Acquired, pushing the received buffer... ");</span>
+00190 recvfifo.value().push( buffer, size );
+00191 <span class="comment">//nldebug( "BNB: Pushed, releasing the receive queue..." );</span>
+00192 <span class="comment">//mbsize = recvfifo.value().size() / 1048576;</span>
+00193 <a class="code" href="a02296.html#NLNET_1_1CCallbackServerb16">setDataAvailableFlag</a>( <span class="keyword">true</span> );
+00194 }
+00195 <span class="comment">//nldebug( "BNB: Released." );</span>
+00196 <span class="comment">/*if ( mbsize &gt; 1 )</span>
+00197 <span class="comment"> {</span>
+00198 <span class="comment"> nlwarning( "The receive queue size exceeds %d MB", mbsize );</span>
+00199 <span class="comment"> }*/</span>
+00200 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb13" doxytag="NLNET::CCallbackServer::pushMessageIntoReceiveQueue" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufNetBase::pushMessageIntoReceiveQueue </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const std::vector&lt; <a class="el" href="a04558.html#a7">uint8</a> &gt; &amp;&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>buffer</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Push message into receive queue (mutexed).
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00164">164</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00211">NLNET::CBufNetBase::_RecvFifo</a>, <a class="el" href="a05646.html#l00649">buffer</a>, <a class="el" href="a05511.html#l00056">NLNET::CFifoAccessor</a>, and <a class="el" href="a05511.html#l00203">NLNET::CBufNetBase::setDataAvailableFlag()</a>.
+<p>
+Referenced by <a class="el" href="a05515.html#l00135">NLNET::CBufSock::advertiseSystemEvent()</a>, and <a class="el" href="a05506.html#l00437">NLNET::CClientReceiveTask::run()</a>.
+<p>
+<div class="fragment"><pre>00165 {
+00166 <span class="comment">//sint32 mbsize;</span>
+00167 {
+00168 <span class="comment">//nldebug( "BNB: Acquiring the receive queue... ");</span>
+00169 <a class="code" href="a05379.html#a79">CFifoAccessor</a> recvfifo( &amp;_RecvFifo );
+00170 <span class="comment">//nldebug( "BNB: Acquired, pushing the received buffer... ");</span>
+00171 recvfifo.value().push( buffer );
+00172 <span class="comment">//nldebug( "BNB: Pushed, releasing the receive queue..." );</span>
+00173 <span class="comment">//mbsize = recvfifo.value().size() / 1048576;</span>
+00174 <a class="code" href="a02296.html#NLNET_1_1CCallbackServerb16">setDataAvailableFlag</a>( <span class="keyword">true</span> );
+00175 }
+00176 <span class="comment">//nldebug( "BNB: Released." );</span>
+00177 <span class="comment">//if ( mbsize &gt; 1 )</span>
+00178 <span class="comment">//{</span>
+00179 <span class="comment">// nlwarning( "The receive queue size exceeds %d MB", mbsize );</span>
+00180 <span class="comment">//}</span>
+00181 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera30" doxytag="NLNET::CCallbackServer::receive" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::receive </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02271.html">NLMISC::CMemStream</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>buffer</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a02303.html">TSockId</a> *&nbsp;</td>
+ <td class="mdname" nowrap> <em>hostid</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Receives next block of data in the specified (resizes the vector) You must call <a class="el" href="a02302.html#NLNET_1_1CBufServera3">dataAvailable()</a> before every call to <a class="el" href="a02302.html#NLNET_1_1CCallbackServera30">receive()</a>
+<p>
+Definition at line <a class="el" href="a05512.html#l00565">565</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00358">NLNET::CBufServer::_BytesPoppedIn</a>, <a class="el" href="a05646.html#l00649">buffer</a>, <a class="el" href="a05511.html#l00056">NLNET::CFifoAccessor</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a06462.html#l00060">NLMISC_BSWAP32</a>, <a class="el" href="a05515.html#l00040">nlnettrace</a>, <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a05511.html#l00154">NLNET::CBufNetBase::receiveQueue()</a>, <a class="el" href="a05511.html#l00203">NLNET::CBufNetBase::setDataAvailableFlag()</a>, <a class="el" href="a05511.html#l00059">NLNET::TBlockSize</a>, <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+<div class="fragment"><pre>00566 {
+00567 <a class="code" href="a04092.html#a0">nlnettrace</a>( <span class="stringliteral">"CBufServer::receive"</span> );
+00568 <span class="comment">//nlassert( dataAvailable() );</span>
+00569 <a class="code" href="a04199.html#a6">nlassert</a>( phostid != NULL );
+00570 {
+00571 <a class="code" href="a05379.html#a79">CFifoAccessor</a> recvfifo( &amp;<a class="code" href="a02296.html#NLNET_1_1CCallbackServerb14">receiveQueue</a>() );
+00572 <a class="code" href="a04199.html#a6">nlassert</a>( ! recvfifo.value().empty() );
+00573 recvfifo.value().front( buffer );
+00574 recvfifo.value().pop();
+00575 <a class="code" href="a02296.html#NLNET_1_1CCallbackServerb16">setDataAvailableFlag</a>( ! recvfifo.value().empty() );
+00576 }
+00577
+00578 <span class="comment">// Extract hostid (and event type)</span>
+00579 *phostid = *((<a class="code" href="a05379.html#a74">TSockId</a>*)&amp;(<a class="code" href="a04223.html#a589">buffer</a>.buffer()[<a class="code" href="a04223.html#a589">buffer</a>.size()-<span class="keyword">sizeof</span>(<a class="code" href="a05379.html#a74">TSockId</a>)-1]));
+00580 <a class="code" href="a04199.html#a6">nlassert</a>( <a class="code" href="a04223.html#a589">buffer</a>.buffer()[<a class="code" href="a04223.html#a589">buffer</a>.size()-1] == CBufNetBase::User );
+00581
+00582 <span class="comment">// debug features, we number all packet to be sure that they are all sent and received</span>
+00583 <span class="comment">// \todo remove this debug feature when ok</span>
+00584 <span class="preprocessor">#ifdef NL_BIG_ENDIAN</span>
+00585 <span class="preprocessor"></span> <a class="code" href="a04558.html#a11">uint32</a> val = <a class="code" href="a05039.html#a1">NLMISC_BSWAP32</a>(*(<a class="code" href="a04558.html#a11">uint32</a>*)<a class="code" href="a04223.html#a589">buffer</a>.buffer());
+00586 <span class="preprocessor">#else</span>
+00587 <span class="preprocessor"></span> <a class="code" href="a04558.html#a11">uint32</a> val = *(<a class="code" href="a04558.html#a11">uint32</a>*)<a class="code" href="a04223.html#a589">buffer</a>.buffer();
+00588 <span class="preprocessor">#endif</span>
+00589 <span class="preprocessor"></span>
+00590 <span class="comment">// nldebug ("receive message number %u", val);</span>
+00591 <span class="keywordflow">if</span> ((*phostid)-&gt;ReceiveNextValue != val)
+00592 {
+00593 <a class="code" href="a04199.html#a2">nlwarning</a> (<span class="stringliteral">"LNETL1: !!!LOST A MESSAGE!!! I received the message number %u but I'm waiting the message number %u (cnx %s), warn lecroart@nevrax.com with the log now please"</span>, val, (*phostid)-&gt;ReceiveNextValue, (*phostid)-&gt;asString().c_str());
+00594 <span class="comment">// resync the message number</span>
+00595 (*phostid)-&gt;ReceiveNextValue = val;
+00596 }
+00597
+00598 (*phostid)-&gt;ReceiveNextValue++;
+00599
+00600 <a class="code" href="a04223.html#a589">buffer</a>.resize( <a class="code" href="a04223.html#a589">buffer</a>.size()-<span class="keyword">sizeof</span>(<a class="code" href="a05379.html#a74">TSockId</a>)-1 );
+00601
+00602 <span class="comment">// TODO OPTIM remove the nldebug for speed</span>
+00603 <span class="comment">//commented for optimisation nldebug( "LNETL1: Read buffer (%d+%d B) from %s", buffer.size(), sizeof(TSockId)+1, /*stringFromVector(buffer).c_str(), */(*phostid)-&gt;asString().c_str() );</span>
+00604
+00605 <span class="comment">// Statistics</span>
+00606 _BytesPoppedIn += <a class="code" href="a04223.html#a589">buffer</a>.size() + <span class="keyword">sizeof</span>(<a class="code" href="a05379.html#a80">TBlockSize</a>);
+00607 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerd1" doxytag="NLNET::CCallbackServer::receive" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::receive </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02918.html">CMessage</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>buffer</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a02303.html">TSockId</a> *&nbsp;</td>
+ <td class="mdname" nowrap> <em>hostid</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [private, virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+On this layer, you can't call directly receive, It s the <a class="el" href="a02302.html#NLNET_1_1CCallbackServera40">update()</a> function that receive and call your callaback.
+<p>
+
+<p>
+Implements <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBaseb4">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05528.html#l00205">205</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+References <a class="el" href="a05646.html#l00649">buffer</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05379.html#a225a87">NLNET::Receiving</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00206 {
+00207 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00208 <a class="code" href="a04199.html#a6">nlassert</a> (connected ());
+00209
+00210 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00211 <span class="preprocessor"></span> <span class="keywordflow">if</span> ( _MR_RecordingState != <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw5">Replay</a> )
+00212 {
+00213 <span class="preprocessor">#endif</span>
+00214 <span class="preprocessor"></span>
+00215 <span class="comment">// Receive</span>
+00216 CBufServer::receive (buffer, hostid);
+00217
+00218 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00219 <span class="preprocessor"></span> <span class="keywordflow">if</span> ( _MR_RecordingState == <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw4">Record</a> )
+00220 {
+00221 <span class="comment">// Record received message</span>
+00222 _MR_Recorder.recordNext( _MR_UpdateCounter, Receiving, *hostid, const_cast&lt;CMessage&amp;&gt;(buffer) );
+00223 }
+00224 }
+00225 <span class="keywordflow">else</span>
+00226 {
+00227 <span class="comment">// Retrieve received message loaded by dataAvailable()</span>
+00228 <a class="code" href="a04223.html#a589">buffer</a> = _MR_Recorder.ReceivedMessages.front().Message;
+00229 *hostid = _MR_Recorder.ReceivedMessages.front().SockId;
+00230 _MR_Recorder.ReceivedMessages.pop();
+00231 }
+00232 <span class="preprocessor">#endif</span>
+00233 <span class="preprocessor"></span>
+00234 <a class="code" href="a04223.html#a589">buffer</a>.readType ();
+00235 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb14" doxytag="NLNET::CCallbackServer::receiveQueue" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a05379.html#a78">CSynchronizedFIFO</a>&amp; NLNET::CBufNetBase::receiveQueue </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Access to the receive queue.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00154">154</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00211">NLNET::CBufNetBase::_RecvFifo</a>, and <a class="el" href="a05511.html#l00053">NLNET::CSynchronizedFIFO</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00364">NLNET::CBufServer::dataAvailable()</a>, <a class="el" href="a05506.html#l00140">NLNET::CBufClient::dataAvailable()</a>, <a class="el" href="a05506.html#l00318">NLNET::CBufClient::disconnect()</a>, <a class="el" href="a05512.html#l00565">NLNET::CBufServer::receive()</a>, <a class="el" href="a05506.html#l00272">NLNET::CBufClient::receive()</a>, and <a class="el" href="a05512.html#l00987">NLNET::CServerReceiveTask::run()</a>.
+<p>
+<div class="fragment"><pre>00154 { <span class="keywordflow">return</span> _RecvFifo; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb15" doxytag="NLNET::CCallbackServer::receiveTask" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a03366.html">CServerReceiveTask</a>* NLNET::CBufServer::receiveTask </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">std::vector&lt; <a class="el" href="a03880.html">NLMISC::IThread</a> * &gt;::iterator&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>ipt</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Returns the receive task corresponding to a particular thread.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00284">284</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00251">NLNET::CBufServer::disconnect()</a>, <a class="el" href="a05512.html#l00866">NLNET::CBufServer::dispatchNewSocket()</a>, <a class="el" href="a05512.html#l00713">NLNET::CBufServer::displaySendQueueStat()</a>, <a class="el" href="a05512.html#l00695">NLNET::CBufServer::displayThreadStat()</a>, <a class="el" href="a05512.html#l00660">NLNET::CBufServer::getSendQueueSize()</a>, <a class="el" href="a05512.html#l00299">NLNET::CBufServer::send()</a>, <a class="el" href="a05512.html#l00613">NLNET::CBufServer::update()</a>, and <a class="el" href="a05512.html#l00166">NLNET::CBufServer::~CBufServer()</a>.
+<p>
+<div class="fragment"><pre>00285 {
+00286 <span class="keywordflow">return</span> ((<a class="code" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a>*)((*ipt)-&gt;getRunnable()));
+00287 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerd2" doxytag="NLNET::CCallbackServer::send" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::send </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const <a class="el" href="a02271.html">NLMISC::CMemStream</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>buffer</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>hostid</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inline, private]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+This function is public in the base class and put it private here because user cannot use it in layer 2.
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServera20">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00093">93</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05622.html#l00416">nlstop</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00093 { <a class="code" href="a04199.html#a12">nlstop</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera31" doxytag="NLNET::CCallbackServer::send" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::send </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const <a class="el" href="a02918.html">CMessage</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>buffer</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>hostid</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>bool&nbsp;</td>
+ <td class="mdname" nowrap> <em>log</em> = true</td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sends a message to the specified host.
+<p>
+
+<p>
+Implements <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea19">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05528.html#l00124">124</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+References <a class="el" href="a05646.html#l00649">buffer</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05513.html#l00267">NLNET::CBufServer::nbConnections()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05379.html#a225a86">NLNET::Sending</a>, <a class="el" href="a05981.html#l00104">sint</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+Referenced by <a class="el" href="a05528.html#l00091">sendAllMyAssociations()</a>.
+<p>
+<div class="fragment"><pre>00125 {
+00126 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00127 <a class="code" href="a04199.html#a6">nlassert</a> (connected ());
+00128 <a class="code" href="a04199.html#a6">nlassert</a> (<a class="code" href="a04223.html#a589">buffer</a>.length() != 0);
+00129 <a class="code" href="a04199.html#a6">nlassert</a> (<a class="code" href="a04223.html#a589">buffer</a>.typeIsSet());
+00130
+00131 <span class="keywordflow">if</span> (hostid == InvalidSockId)
+00132 {
+00133 <span class="comment">// broadcast</span>
+00134 <a class="code" href="a04558.html#a14">sint</a> nb = <a class="code" href="a02302.html#NLNET_1_1CCallbackServera27">nbConnections</a> ();
+00135 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp1">_BytesSent</a> += <a class="code" href="a04223.html#a589">buffer</a>.length () * nb;
+00136 }
+00137 <span class="keywordflow">else</span>
+00138 {
+00139 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp1">_BytesSent</a> += <a class="code" href="a04223.html#a589">buffer</a>.length ();
+00140 }
+00141
+00142 <span class="comment">// if (log)</span>
+00143 {
+00144 <span class="comment">// nldebug ("LNETL3S: Server: send(%s, %s)", buffer.toString().c_str(), hostid-&gt;asString().c_str());</span>
+00145 }
+00146
+00147 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00148 <span class="preprocessor"></span> <span class="keywordflow">if</span> ( _MR_RecordingState != <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw5">Replay</a> )
+00149 {
+00150 <span class="preprocessor">#endif</span>
+00151 <span class="preprocessor"></span>
+00152 <span class="comment">// Send</span>
+00153 CBufServer::send (buffer, hostid);
+00154
+00155 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00156 <span class="preprocessor"></span> <span class="keywordflow">if</span> ( _MR_RecordingState == <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw4">Record</a> )
+00157 {
+00158 <span class="comment">// Record sent message</span>
+00159 _MR_Recorder.recordNext( _MR_UpdateCounter, Sending, hostid, const_cast&lt;CMessage&amp;&gt;(buffer) );
+00160 }
+00161 }
+00162 <span class="keywordflow">else</span>
+00163 {
+00165 }
+00166 <span class="preprocessor">#endif</span>
+00167 <span class="preprocessor"></span>}
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerd3" doxytag="NLNET::CCallbackServer::sendAllMyAssociations" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::sendAllMyAssociations </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>to</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [private]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Used by client and server class.
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea20">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05528.html#l00091">91</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+References <a class="el" href="a05514.html#l00329">NLNET::CBufSock::asString()</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05527.html#l00129">NLNET::CCallbackNetBase::getSIDA()</a>, <a class="el" href="a06468.html#l00131">NLMISC::CStringIdArray::getString()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, <a class="el" href="a05528.html#l00124">send()</a>, <a class="el" href="a05979.html#l00420">NLMISC::CMemStream::serial()</a>, <a class="el" href="a06468.html#l00148">NLMISC::CStringIdArray::size()</a>, <a class="el" href="a05646.html#l00645">size</a>, <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>, and <a class="el" href="a06468.html#l00054">NLMISC::CStringIdArray::TStringId</a>.
+<p>
+<div class="fragment"><pre>00092 {
+00093 <a class="code" href="a04199.html#a6">nlassert</a> (to != InvalidSockId); <span class="comment">// invalid hostid</span>
+00094 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00095 <a class="code" href="a04199.html#a6">nlassert</a> (connected ());
+00096
+00097 <span class="comment">// he wants all associations</span>
+00098 <a class="code" href="a02918.html">CMessage</a> msgout (<a class="code" href="a02306.html#NLNET_1_1CCallbackServera18">getSIDA</a>(), <span class="stringliteral">"RAA"</span>);
+00099
+00100 <a class="code" href="a03449.html#NLMISC_1_1CStringIdArrayw0">CStringIdArray::TStringId</a> <a class="code" href="a04223.html#a587">size</a>;
+00101 <a class="code" href="a04223.html#a587">size</a> = <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp8">_OutputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya12">size</a> ();
+00102
+00103 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3S: Send all (%d) my string association to %s"</span>, size, to-&gt;asString().c_str());
+00104
+00105 msgout.<a class="code" href="a02271.html#NLNET_1_1CMessagea41">serial</a> (size);
+00106
+00107 <span class="keywordflow">for</span> (<a class="code" href="a03449.html#NLMISC_1_1CStringIdArrayw0">CStringIdArray::TStringId</a> i = 0; i &lt; <a class="code" href="a04223.html#a587">size</a>; i++)
+00108 {
+00109 <span class="comment">// nldebug ("LNETL3S: sending association '%s' -&gt; %d", _OutputSIDA.getString(i).c_str (), i);</span>
+00110 string str(<a class="code" href="a02306.html#NLNET_1_1CCallbackServerp8">_OutputSIDA</a>.<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya8">getString</a>(i));
+00111 msgout.<a class="code" href="a02271.html#NLNET_1_1CMessagea41">serial</a> (str);
+00112 msgout.<a class="code" href="a02271.html#NLNET_1_1CMessagea41">serial</a> (i);
+00113 }
+00114
+00115 <a class="code" href="a02307.html#NLNET_1_1CCallbackServera31">send</a> (msgout, to);
+00116 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera32" doxytag="NLNET::CCallbackServer::setConnectionCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::setConnectionCallback </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a05379.html#a76">TNetCallback</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>cb</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>void *&nbsp;</td>
+ <td class="mdname" nowrap> <em>arg</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inline]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets callback for incoming connections (or NULL to disable callback).
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServera21">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00061">61</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, and <a class="el" href="a05511.html#l00047">NLNET::TNetCallback</a>.
+<p>
+Referenced by <a class="el" href="a06098.html#l00207">NLNET::CNetManager::addServer()</a>, <a class="el" href="a06645.html#l00479">NLNET::CUnifiedNetwork::init()</a>, and <a class="el" href="a05962.html#l00338">NLNET::CLoginServer::init()</a>.
+<p>
+<div class="fragment"><pre>00061 { <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> (); <a class="code" href="a02307.html#NLNET_1_1CCallbackServerr0">_ConnectionCallback</a> = cb; <a class="code" href="a02307.html#NLNET_1_1CCallbackServerr1">_ConnectionCbArg</a> = arg; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerb16" doxytag="NLNET::CCallbackServer::setDataAvailableFlag" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufNetBase::setDataAvailableFlag </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">bool&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>da</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, protected, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets _DataAvailable.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00203">203</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00214">NLNET::CBufNetBase::_DataAvailable</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00364">NLNET::CBufServer::dataAvailable()</a>, <a class="el" href="a05506.html#l00140">NLNET::CBufClient::dataAvailable()</a>, <a class="el" href="a05506.html#l00318">NLNET::CBufClient::disconnect()</a>, <a class="el" href="a05511.html#l00164">NLNET::CBufNetBase::pushMessageIntoReceiveQueue()</a>, <a class="el" href="a05512.html#l00565">NLNET::CBufServer::receive()</a>, <a class="el" href="a05506.html#l00272">NLNET::CBufClient::receive()</a>, and <a class="el" href="a05512.html#l00987">NLNET::CServerReceiveTask::run()</a>.
+<p>
+<div class="fragment"><pre>00203 { _DataAvailable = da; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera33" doxytag="NLNET::CCallbackServer::setDefaultCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::setDefaultCallback </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a05379.html#a83">TMsgCallback</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>defaultCallback</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets default callback for unknown message types.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00110">110</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+References <a class="el" href="a05527.html#l00199">NLNET::CCallbackNetBase::_DefaultCallback</a>, and <a class="el" href="a05527.html#l00055">NLNET::TMsgCallback</a>.
+<p>
+Referenced by <a class="el" href="a06645.html#l00653">NLNET::CUnifiedNetwork::addService()</a>, and <a class="el" href="a06645.html#l00479">NLNET::CUnifiedNetwork::init()</a>.
+<p>
+<div class="fragment"><pre>00110 { <a class="code" href="a02306.html#NLNET_1_1CCallbackServerp3">_DefaultCallback</a> = defaultCallback; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera34" doxytag="NLNET::CCallbackServer::setDisconnectionCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::setDisconnectionCallback </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a05379.html#a76">TNetCallback</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>cb</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>void *&nbsp;</td>
+ <td class="mdname" nowrap> <em>arg</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inline]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets callback for disconnections (or NULL to disable callback).
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea22">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00064">64</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+References <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, and <a class="el" href="a05511.html#l00047">NLNET::TNetCallback</a>.
+<p>
+Referenced by <a class="el" href="a06645.html#l00479">NLNET::CUnifiedNetwork::init()</a>.
+<p>
+<div class="fragment"><pre>00064 { <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> (); CCallbackNetBase::setDisconnectionCallback (cb, arg); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera35" doxytag="NLNET::CCallbackServer::setMaxExpectedBlockSize" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufNetBase::setMaxExpectedBlockSize </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a10">sint32</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>limit</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets the max size of the received messages. If receiving a message bigger than the limit, the connection will be dropped.<p>
+Default value: 1 MegaByte If you put a negative number as limit, the max size is reset to the default value. Warning: you can call this method only at initialization time, before connecting (for a client) or calling init() (for a server) !
+<p>
+Definition at line <a class="el" href="a05511.html#l00109">109</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00223">NLNET::CBufNetBase::_MaxExpectedBlockSize</a>, <a class="el" href="a05981.html#l00099">sint32</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+<div class="fragment"><pre>00110 {
+00111 <span class="keywordflow">if</span> ( limit &lt; 0 )
+00112 _MaxExpectedBlockSize = 1048576;
+00113 <span class="keywordflow">else</span>
+00114 _MaxExpectedBlockSize = (<a class="code" href="a04558.html#a11">uint32</a>)limit;
+00115 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera36" doxytag="NLNET::CCallbackServer::setMaxSentBlockSize" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufNetBase::setMaxSentBlockSize </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a10">sint32</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>limit</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets the max size of the sent messages. Note: Limiting of sending not implemented, currently<p>
+Default value: 1 MegaByte If you put a negative number as limit, the max size is reset to the default value. Warning: you can call this method only at initialization time, before connecting (for a client) or calling init() (for a server) !
+<p>
+Definition at line <a class="el" href="a05511.html#l00126">126</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>.
+<p>
+References <a class="el" href="a05511.html#l00226">NLNET::CBufNetBase::_MaxSentBlockSize</a>, <a class="el" href="a05981.html#l00099">sint32</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+<div class="fragment"><pre>00127 {
+00128 <span class="keywordflow">if</span> ( limit &lt; 0 )
+00129 _MaxSentBlockSize = 1048576;
+00130 <span class="keywordflow">else</span>
+00131 _MaxSentBlockSize = (<a class="code" href="a04558.html#a11">uint32</a>)limit;
+00132 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera37" doxytag="NLNET::CCallbackServer::setOtherSideAssociations" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackNetBase::setOtherSideAssociations </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const char **&nbsp;</td>
+ <td class="mdname" nowrap> <em>associationarray</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a03449.html#NLMISC_1_1CStringIdArrayw0">NLMISC::CStringIdArray::TStringId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>arraysize</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Gives some association of the other side. The goal is, in specific case, we don't want to ask associations to the other side (client is not secure for example). In this case, we can set other side associations by hand using this functions.
+<p>
+Definition at line <a class="el" href="a05526.html#l00451">451</a> of file <a class="el" href="a05526.html">callback_net_base.cpp</a>.
+<p>
+References <a class="el" href="a06468.html#l00059">NLMISC::CStringIdArray::addString()</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05527.html#l00129">NLNET::CCallbackNetBase::getSIDA()</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, <a class="el" href="a05981.html#l00104">sint</a>, and <a class="el" href="a06468.html#l00054">NLMISC::CStringIdArray::TStringId</a>.
+<p>
+<div class="fragment"><pre>00452 {
+00453 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00454
+00455 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3NB_ASSOC: setOtherSideAssociations() sets %d association strings"</span>, arraysize);
+00456
+00457 <span class="keywordflow">for</span> (<a class="code" href="a04558.html#a14">sint</a> i = 0; i &lt; arraysize; i++)
+00458 {
+00459 <a class="code" href="a04199.html#a0">nldebug</a> (<span class="stringliteral">"LNETL3NB_ASSOC: association '%s' -&gt; %d"</span>, associationarray[i], i);
+00460 <a class="code" href="a02306.html#NLNET_1_1CCallbackServera18">getSIDA</a>().<a class="code" href="a03449.html#NLMISC_1_1CStringIdArraya1">addString</a> (associationarray[i], i);
+00461 }
+00462 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera38" doxytag="NLNET::CCallbackServer::setSizeFlushTrigger" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::setSizeFlushTrigger </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>destid</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a10">sint32</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>size</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets the size flush trigger. When the size of the send queue reaches or exceeds this value, all data in the send queue is automatically sent (-1 to disable this trigger )
+<p>
+Definition at line <a class="el" href="a05513.html#l00226">226</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05515.html#l00104">NLNET::CBufSock::setSizeFlushTrigger()</a>, <a class="el" href="a05981.html#l00099">sint32</a>, <a class="el" href="a05646.html#l00645">size</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00226 { <a class="code" href="a04199.html#a6">nlassert</a>( destid != InvalidSockId ); destid-&gt;setSizeFlushTrigger( size ); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera39" doxytag="NLNET::CCallbackServer::setTimeFlushTrigger" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::setTimeFlushTrigger </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>destid</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a10">sint32</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>ms</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [inline, inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Sets the time flush trigger (in millisecond). When this time is elapsed, all data in the send queue is automatically sent (-1 to disable this trigger)
+<p>
+Definition at line <a class="el" href="a05513.html#l00221">221</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+References <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05514.html#l00236">NLNET::CBufSock::setTimeFlushTrigger()</a>, <a class="el" href="a05981.html#l00099">sint32</a>, and <a class="el" href="a05511.html#l00042">NLNET::TSockId</a>.
+<p>
+<div class="fragment"><pre>00221 { <a class="code" href="a04199.html#a6">nlassert</a>( destid != InvalidSockId ); destid-&gt;setTimeFlushTrigger( ms ); }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera40" doxytag="NLNET::CCallbackServer::update" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CBufServer::update </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inherited]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Update the network (call this method evenly).
+<p>
+
+<p>
+Definition at line <a class="el" href="a05512.html#l00613">613</a> of file <a class="el" href="a05512.html">buf_server.cpp</a>.
+<p>
+References <a class="el" href="a05513.html#l00487">NLNET::CServerReceiveTask::_Connections</a>, <a class="el" href="a05513.html#l00367">NLNET::CBufServer::_NbConnections</a>, <a class="el" href="a05513.html#l00346">NLNET::CBufServer::_ThreadPool</a>, <a class="el" href="a05622.html#l00101">nldebug</a>, and <a class="el" href="a05513.html#l00284">NLNET::CBufServer::receiveTask()</a>.
+<p>
+<div class="fragment"><pre>00614 {
+00615 <span class="comment">//nlnettrace( "CBufServer::update-BEGIN" );</span>
+00616
+00617 _NbConnections = 0;
+00618
+00619 <span class="comment">// For each thread</span>
+00620 CThreadPool::iterator ipt;
+00621 {
+00622 <span class="comment">//nldebug( "UPD: Acquiring the Thread Pool" );</span>
+00623 CSynchronized&lt;CThreadPool&gt;::CAccessor poolsync( &amp;_ThreadPool );
+00624 <span class="comment">//nldebug( "UPD: Acquired." );</span>
+00625 <span class="keywordflow">for</span> ( ipt=poolsync.value().begin(); ipt!=poolsync.value().end(); ++ipt )
+00626 {
+00627 <span class="comment">// For each thread of the pool</span>
+00628 <a class="code" href="a02302.html#NLNET_1_1CCallbackServern3">CServerReceiveTask</a> *task = <a class="code" href="a02302.html#NLNET_1_1CCallbackServerb15">receiveTask</a>(ipt);
+00629 CConnections::iterator ipb;
+00630 {
+00631 CSynchronized&lt;CConnections&gt;::CAccessor connectionssync( &amp;task-&gt;_Connections );
+00632 <span class="keywordflow">for</span> ( ipb=connectionssync.value().begin(); ipb!=connectionssync.value().end(); ++ipb )
+00633 {
+00634 <span class="comment">// For each socket of the thread, update sending</span>
+00635 <span class="keywordflow">if</span> ( ! ((*ipb)-&gt;Sock-&gt;connected() &amp;&amp; (*ipb)-&gt;update()) )
+00636 {
+00637 <span class="comment">// Update did not work or the socket is not connected anymore</span>
+00638 <a class="code" href="a04199.html#a0">nldebug</a>( <span class="stringliteral">"LNETL1: Socket %s is disconnected"</span>, (*ipb)-&gt;asString().c_str() );
+00639 <span class="comment">// Disconnection event if disconnected (known either from flush (in update) or when receiving data)</span>
+00640 (*ipb)-&gt;advertiseDisconnection( <span class="keyword">this</span>, *ipb );
+00641
+00642 <span class="comment">/*if ( (*ipb)-&gt;advertiseDisconnection( this, *ipb ) )</span>
+00643 <span class="comment"> {</span>
+00644 <span class="comment"> // Now the connection removal is in dataAvailable()</span>
+00645 <span class="comment"> // POLL6</span>
+00646 <span class="comment"> }*/</span>
+00647 }
+00648 <span class="keywordflow">else</span>
+00649 {
+00650 _NbConnections++;
+00651 }
+00652 }
+00653 }
+00654 }
+00655 }
+00656
+00657 <span class="comment">//nlnettrace( "CBufServer::update-END" );</span>
+00658 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServera41" doxytag="NLNET::CCallbackServer::update" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLNET::CCallbackServer::update </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a10">sint32</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>timeout</em> = 0 </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Updates the network (call this method evenly).
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02306.html#NLNET_1_1CCallbackNetBasea24">NLNET::CCallbackNetBase</a>.
+<p>
+Definition at line <a class="el" href="a05528.html#l00175">175</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+References <a class="el" href="a05526.html#l00328">NLNET::CCallbackNetBase::baseUpdate()</a>, <a class="el" href="a05526.html#l00533">NLNET::CCallbackNetBase::checkThreadId()</a>, <a class="el" href="a05788.html#l00056">H_AUTO</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, and <a class="el" href="a05981.html#l00099">sint32</a>.
+<p>
+Referenced by <a class="el" href="a06645.html#l00857">NLNET::CUnifiedNetwork::update()</a>.
+<p>
+<div class="fragment"><pre>00176 {
+00177 <a class="code" href="a04365.html#a4">H_AUTO</a>(L3UpdateServer);
+00178
+00179 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb4">checkThreadId</a> ();
+00180 <a class="code" href="a04199.html#a6">nlassert</a> (connected ());
+00181
+00182 <span class="comment">// nldebug ("LNETL3S: Client: update()");</span>
+00183 <a class="code" href="a02306.html#NLNET_1_1CCallbackServerb3">baseUpdate</a> ( timeout ); <span class="comment">// first receive</span>
+00184
+00185 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00186 <span class="preprocessor"></span> <span class="keywordflow">if</span> ( _MR_RecordingState != <a class="code" href="a02306.html#NLNET_1_1CCallbackServerw8NLNET_1_1CCallbackServerw5">Replay</a> )
+00187 {
+00188 <span class="preprocessor">#endif</span>
+00189 <span class="preprocessor"></span>
+00190 <span class="comment">// L1-2 Update (nothing to do in replay mode)</span>
+00191 CBufServer::update (); <span class="comment">// then send</span>
+00192
+00193 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00194 <span class="preprocessor"></span> }
+00195 <span class="preprocessor">#endif</span>
+00196 <span class="preprocessor"></span>
+00197 }
+</pre></div> </td>
+ </tr>
+</table>
+<hr><h2>Friends And Related Function Documentation</h2>
+<a class="anchor" name="NLNET_1_1CCallbackServern0" doxytag="NLNET::CCallbackServer::cbsNewConnection" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void cbsNewConnection </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a02303.html">TSockId</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>from</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>void *&nbsp;</td>
+ <td class="mdname" nowrap> <em>data</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [friend]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05528.html#l00045">45</a> of file <a class="el" href="a05528.html">callback_server.cpp</a>.
+<p>
+<div class="fragment"><pre>00046 {
+00047 <a class="code" href="a04199.html#a6">nlassert</a> (data != NULL);
+00048 <a class="code" href="a02307.html#NLNET_1_1CCallbackServera4">CCallbackServer</a> *server = (<a class="code" href="a02307.html#NLNET_1_1CCallbackServera4">CCallbackServer</a> *)<a class="code" href="a04223.html#a637">data</a>;
+00049
+00050 <a class="code" href="a04199.html#a0">nldebug</a>(<span class="stringliteral">"LNETL3S: newConnection()"</span>);
+00051
+00052 <span class="preprocessor">#ifdef USE_MESSAGE_RECORDER</span>
+00053 <span class="preprocessor"></span> <span class="comment">// Record connection</span>
+00054 server-&gt;noticeConnection( from );
+00055 <span class="preprocessor">#endif</span>
+00056 <span class="preprocessor"></span>
+00057 <span class="comment">// send all my association to the new client</span>
+00058 <span class="comment">// association are disactivated so we don t need to send them</span>
+00059 <span class="comment">// server-&gt;sendAllMyAssociations (from);</span>
+00060
+00061 <span class="comment">// call the client callback if necessary</span>
+00062 <span class="keywordflow">if</span> (server-&gt;_ConnectionCallback != NULL)
+00063 server-&gt;_ConnectionCallback (from, server-&gt;_ConnectionCbArg);
+00064 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServern1" doxytag="NLNET::CCallbackServer::CListenTask" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> friend class <a class="el" href="a02770.html">CListenTask</a><code> [friend, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00272">272</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00058">NLNET::CBufServer::CBufServer()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServern2" doxytag="NLNET::CCallbackServer::CServerBufSock" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> friend class <a class="el" href="a03365.html">CServerBufSock</a><code> [friend, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00271">271</a> of file <a class="el" href="a05513.html">buf_server.h</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServern3" doxytag="NLNET::CCallbackServer::CServerReceiveTask" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> friend class <a class="el" href="a03366.html">CServerReceiveTask</a><code> [friend, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05513.html#l00273">273</a> of file <a class="el" href="a05513.html">buf_server.h</a>.
+<p>
+Referenced by <a class="el" href="a05512.html#l00958">NLNET::CBufServer::addNewThread()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServern4" doxytag="NLNET::CCallbackServer::NLNET::CBufSock" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> friend class <a class="el" href="a02303.html">NLNET::CBufSock</a><code> [friend, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05511.html#l00148">148</a> of file <a class="el" href="a05511.html">buf_net_base.h</a>. </td>
+ </tr>
+</table>
+<hr><h2>Field Documentation</h2>
+<a class="anchor" name="NLNET_1_1CCallbackServerp0" doxytag="NLNET::CCallbackServer::_BytesReceived" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp0">NLNET::CCallbackNetBase::_BytesReceived</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00167">167</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00148">NLNET::CCallbackNetBase::CCallbackNetBase()</a>, <a class="el" href="a05527.html#l00088">NLNET::CCallbackNetBase::getBytesReceived()</a>, and <a class="el" href="a05526.html#l00223">NLNET::CCallbackNetBase::processOneMessage()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp1" doxytag="NLNET::CCallbackServer::_BytesSent" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a13">uint64</a> <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp1">NLNET::CCallbackNetBase::_BytesSent</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00167">167</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00148">NLNET::CCallbackNetBase::CCallbackNetBase()</a>, and <a class="el" href="a05527.html#l00087">NLNET::CCallbackNetBase::getBytesSent()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp2" doxytag="NLNET::CCallbackServer::_CallbackArray" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> std::vector&lt;<a class="el" href="a03900.html">TCallbackItem</a>&gt; <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp2">NLNET::CCallbackNetBase::_CallbackArray</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00196">196</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00184">NLNET::CCallbackNetBase::addCallbackArray()</a>, and <a class="el" href="a05526.html#l00223">NLNET::CCallbackNetBase::processOneMessage()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerr0" doxytag="NLNET::CCallbackServer::_ConnectionCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a05379.html#a76">TNetCallback</a> <a class="el" href="a02307.html#NLNET_1_1CCallbackServerr0">NLNET::CCallbackServer::_ConnectionCallback</a><code> [private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Connection callback.
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServerr2">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00100">100</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+Referenced by <a class="el" href="a05528.html#l00045">NLNET::cbsNewConnection()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerr1" doxytag="NLNET::CCallbackServer::_ConnectionCbArg" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void* <a class="el" href="a02307.html#NLNET_1_1CCallbackServerr1">NLNET::CCallbackServer::_ConnectionCbArg</a><code> [private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Argument of the connection callback.
+<p>
+
+<p>
+Reimplemented from <a class="el" href="a02302.html#NLNET_1_1CBufServerr3">NLNET::CBufServer</a>.
+<p>
+Definition at line <a class="el" href="a05529.html#l00101">101</a> of file <a class="el" href="a05529.html">callback_server.h</a>.
+<p>
+Referenced by <a class="el" href="a05528.html#l00045">NLNET::cbsNewConnection()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp3" doxytag="NLNET::CCallbackServer::_DefaultCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a05379.html#a83">TMsgCallback</a> <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp3">NLNET::CCallbackNetBase::_DefaultCallback</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00199">199</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00223">NLNET::CCallbackNetBase::processOneMessage()</a>, and <a class="el" href="a05527.html#l00110">NLNET::CCallbackNetBase::setDefaultCallback()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp4" doxytag="NLNET::CCallbackServer::_FirstUpdate" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> bool <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp4">NLNET::CCallbackNetBase::_FirstUpdate</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00202">202</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00328">NLNET::CCallbackNetBase::baseUpdate()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp5" doxytag="NLNET::CCallbackServer::_InputSIDA" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a03449.html">NLMISC::CStringIdArray</a> <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp5">NLNET::CCallbackNetBase::_InputSIDA</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00188">188</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00328">NLNET::CCallbackNetBase::baseUpdate()</a>, <a class="el" href="a05527.html#l00129">NLNET::CCallbackNetBase::getSIDA()</a>, and <a class="el" href="a05527.html#l00157">NLNET::CCallbackNetBase::ignoreAllUnknownId()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp6" doxytag="NLNET::CCallbackServer::_IsAServer" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> bool <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp6">NLNET::CCallbackNetBase::_IsAServer</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00201">201</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05527.html#l00126">NLNET::CCallbackNetBase::isAServer()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp7" doxytag="NLNET::CCallbackServer::_NewDisconnectionCallback" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a05379.html#a76">TNetCallback</a> <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp7">NLNET::CCallbackNetBase::_NewDisconnectionCallback</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Used by client and server class.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00170">170</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00148">NLNET::CCallbackNetBase::CCallbackNetBase()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp8" doxytag="NLNET::CCallbackServer::_OutputSIDA" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a03449.html">NLMISC::CStringIdArray</a> <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp8">NLNET::CCallbackNetBase::_OutputSIDA</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00193">193</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00184">NLNET::CCallbackNetBase::addCallbackArray()</a>, <a class="el" href="a05526.html#l00088">NLNET::cbnbMessageAskAssociations()</a>, <a class="el" href="a05526.html#l00464">NLNET::CCallbackNetBase::displayAllMyAssociations()</a>, and <a class="el" href="a05526.html#l00223">NLNET::CCallbackNetBase::processOneMessage()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLNET_1_1CCallbackServerp9" doxytag="NLNET::CCallbackServer::_ThreadId" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a15">uint</a> <a class="el" href="a02306.html#NLNET_1_1CCallbackServerp9">NLNET::CCallbackNetBase::_ThreadId</a><code> [protected, inherited]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+<dl compact><dt><b><a class="el" href="todo.html#_todo000049">Todo:</a></b></dt><dd>ace: debug feature that we should remove one day nefore releasing the game</dd></dl>
+
+<p>
+Definition at line <a class="el" href="a05527.html#l00232">232</a> of file <a class="el" href="a05527.html">callback_net_base.h</a>.
+<p>
+Referenced by <a class="el" href="a05526.html#l00148">NLNET::CCallbackNetBase::CCallbackNetBase()</a>. </td>
+ </tr>
+</table>
+<hr>The documentation for this class was generated from the following files:<ul>
+<li><a class="el" href="a05529.html">callback_server.h</a><li><a class="el" href="a05528.html">callback_server.cpp</a></ul>
+<hr size="1"><address style="align: right;"><small>Generated on Tue Mar 16 13:56:32 2004 for NeL by
+<a href="http://www.doxygen.org/index.html">
+<img src="doxygen.png" alt="doxygen" align="middle" border=0 >
+</a>1.3.6 </small></address>
+</body>
+</html>