init
This commit is contained in:
5
docs/client_html/ar01s10.html
Normal file
5
docs/client_html/ar01s10.html
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>Disconnecting from a server</title><link rel="stylesheet" href="ts3doc.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.74.0"><link rel="home" href="index.html" title="TeamSpeak 3 Client SDK Developer Manual"><link rel="up" href="index.html" title="TeamSpeak 3 Client SDK Developer Manual"><link rel="prev" href="ar01s09.html" title="Connecting to a server"><link rel="next" href="ar01s11.html" title="Error handling"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><img id="logo" src="images/logo.png"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Disconnecting from a server</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ar01s09.html"><img src="images/prev.png" alt="Prev"></a><EFBFBD></td><th width="60%" align="center"><EFBFBD></th><td width="20%" align="right"><EFBFBD><a accesskey="n" href="ar01s11.html"><img src="images/next.png" alt="Next"></a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="disconnect"></a>Disconnecting from a server</h2></div></div></div><p>To disconnect from a TeamSpeak 3 server call
|
||||
</p><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">unsigned int <b class="fsfunc">ts3client_stopConnection</b>(</code></td><td><var class="pdparam">serverConnectionHandlerID</var>, </td><td><EFBFBD></td></tr><tr><td><EFBFBD></td><td><var class="pdparam">quitMessage</var><code>)</code>;</td><td><EFBFBD></td></tr></table><div class="paramdef-list"><code>uint64 <var class="pdparam">serverConnectionHandlerID</var></code>;<br><code>const char* <var class="pdparam">quitMessage</var></code>;</div><div class="funcprototype-spacer"><EFBFBD></div></div><p>
|
||||
<a class="indexterm" name="idm44835434918256"></a></p><div class="itemizedlist"><ul type="disc"><li><p><em class="parameter"><code>serverConnectionHandlerID</code></em></p><p>The unique ID for this server connection handler.</p></li><li><p><em class="parameter"><code>quitMessage</code></em></p><p>A message like for example "leaving". The string needs to be encoded in UTF-8 format.</p></li></ul></div><p>Returns <em class="structfield"><code>ERROR_ok</code></em> on success, otherwise an error code as defined in <code class="filename">public_errors.h</code>.</p><p>Like with connecting, on successful disconnecting the client will receive an event:</p><div class="literallayout"><p><br>
|
||||
</p></div><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">void <b class="fsfunc">onConnectStatusChangeEvent</b>(</code></td><td><var class="pdparam">serverConnectionHandlerID</var>, </td><td><EFBFBD></td></tr><tr><td><EFBFBD></td><td><var class="pdparam">newStatus</var>, </td><td><EFBFBD></td></tr><tr><td><EFBFBD></td><td><var class="pdparam">errorNumber</var><code>)</code>;</td><td><EFBFBD></td></tr></table><div class="paramdef-list"><code>uint64 <var class="pdparam">serverConnectionHandlerID</var></code>;<br><code>int <var class="pdparam">newStatus</var></code>;<br><code>int <var class="pdparam">errorNumber</var></code>;</div><div class="funcprototype-spacer"><EFBFBD></div></div><a class="indexterm" name="idm44835434908064"></a><div class="itemizedlist"><ul type="disc"><li><p><em class="parameter"><code>newStatus</code></em></p><p>Set to <em class="structfield"><code>STATUS_DISCONNECTED</code></em> as defined by the enum <a class="link" href="ar01s09.html#connectstatus"><span class="structname">ConnectStatus</span></a><a class="indexterm" name="idm44835434904672"></a>.</p></li><li><p><em class="parameter"><code>errorNumber</code></em></p><p><em class="parameter"><code>errorNumber</code></em> is expected to be <em class="structfield"><code>ERROR_ok</code></em> as response to calling <code class="function">ts3client_stopConnection</code>.</p><p>Values other than <em class="structfield"><code>ERROR_ok</code></em> occur when the connection has been lost for reasons not initiated by the user, e.g. network error, forcefully disconnected etc.</p></li></ul></div><div class="literallayout"><p><br>
|
||||
</p></div><p>Should the server be shutdown, the follow event will be called:</p><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">void <b class="fsfunc">onServerStopEvent</b>(</code></td><td><var class="pdparam">serverConnectionHandlerID</var>, </td><td><EFBFBD></td></tr><tr><td><EFBFBD></td><td><var class="pdparam">shutdownMessage</var><code>)</code>;</td><td><EFBFBD></td></tr></table><div class="paramdef-list"><code>uint64 <var class="pdparam">serverConnectionHandlerID</var></code>;<br><code>const char* <var class="pdparam">shutdownMessage</var></code>;</div><div class="funcprototype-spacer"><EFBFBD></div></div><a class="indexterm" name="idm44835434896144"></a><div class="itemizedlist"><ul type="disc"><li><p><em class="parameter"><code>serverConnectionHandlerID</code></em></p><p>Server connection handler ID of the stopped server.</p></li><li><p><em class="parameter"><code>shutdownMessage</code></em></p><p>Message announcing the reason for the shutdown sent by the server. Has to be encoded in UTF-8 format.</p></li></ul></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ar01s09.html"><img src="images/prev.png" alt="Prev"></a><EFBFBD></td><td width="20%" align="center"><EFBFBD></td><td width="40%" align="right"><EFBFBD><a accesskey="n" href="ar01s11.html"><img src="images/next.png" alt="Next"></a></td></tr><tr><td width="40%" align="left" valign="top">Connecting to a server<65></td><td width="20%" align="center"><a accesskey="h" href="index.html"><img src="images/home.png" alt="Home"></a></td><td width="40%" align="right" valign="top"><EFBFBD>Error handling</td></tr></table></div></body></html>
|
||||
Reference in New Issue
Block a user