class_q_bt_serial_port_client.html 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
  5. <title>QBluetoothZero: QBtSerialPortClient Class Reference</title>
  6. <link href="tabs.css" rel="stylesheet" type="text/css"/>
  7. <link href="doxygen.css" rel="stylesheet" type="text/css" />
  8. <link href="navtree.css" rel="stylesheet" type="text/css"/>
  9. <script type="text/javascript" src="jquery.js"></script>
  10. <script type="text/javascript" src="resize.js"></script>
  11. <script type="text/javascript" src="navtree.js"></script>
  12. <script type="text/javascript">
  13. $(document).ready(initResizable);
  14. </script>
  15. <link href="search/search.css" rel="stylesheet" type="text/css"/>
  16. <script type="text/javascript" src="search/search.js"></script>
  17. <script type="text/javascript">
  18. $(document).ready(function() { searchBox.OnSelectItem(0); });
  19. </script>
  20. </head>
  21. <body>
  22. <div id="top"><!-- do not remove this div! -->
  23. <div id="titlearea">
  24. <table cellspacing="0" cellpadding="0">
  25. <tbody>
  26. <tr style="height: 56px;">
  27. <td id="projectlogo"><img alt="Logo" src="projecticonBlue.png"/></td>
  28. <td style="padding-left: 0.5em;">
  29. <div id="projectname">QBluetoothZero
  30. &#160;<span id="projectnumber">2.0</span>
  31. </div>
  32. </td>
  33. </tr>
  34. </tbody>
  35. </table>
  36. </div>
  37. <!-- Generated by Doxygen 1.7.5.1 -->
  38. <script type="text/javascript">
  39. var searchBox = new SearchBox("searchBox", "search",false,'Search');
  40. </script>
  41. <div id="navrow1" class="tabs">
  42. <ul class="tablist">
  43. <li><a href="index.html"><span>Main&#160;Page</span></a></li>
  44. <li><a href="namespaces.html"><span>Namespaces</span></a></li>
  45. <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
  46. <li><a href="files.html"><span>Files</span></a></li>
  47. <li>
  48. <div id="MSearchBox" class="MSearchBoxInactive">
  49. <span class="left">
  50. <img id="MSearchSelect" src="search/mag_sel.png"
  51. onmouseover="return searchBox.OnSearchSelectShow()"
  52. onmouseout="return searchBox.OnSearchSelectHide()"
  53. alt=""/>
  54. <input type="text" id="MSearchField" value="Search" accesskey="S"
  55. onfocus="searchBox.OnSearchFieldFocus(true)"
  56. onblur="searchBox.OnSearchFieldFocus(false)"
  57. onkeyup="searchBox.OnSearchFieldChange(event)"/>
  58. </span><span class="right">
  59. <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
  60. </span>
  61. </div>
  62. </li>
  63. </ul>
  64. </div>
  65. <div id="navrow2" class="tabs2">
  66. <ul class="tablist">
  67. <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
  68. <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
  69. <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
  70. </ul>
  71. </div>
  72. </div>
  73. <div id="side-nav" class="ui-resizable side-nav-resizable">
  74. <div id="nav-tree">
  75. <div id="nav-tree-contents">
  76. </div>
  77. </div>
  78. <div id="splitbar" style="-moz-user-select:none;"
  79. class="ui-resizable-handle">
  80. </div>
  81. </div>
  82. <script type="text/javascript">
  83. initNavTree('class_q_bt_serial_port_client.html','');
  84. </script>
  85. <div id="doc-content">
  86. <div class="header">
  87. <div class="summary">
  88. <a href="#pub-types">Public Types</a> &#124;
  89. <a href="#pub-slots">Public Slots</a> &#124;
  90. <a href="#signals">Signals</a> &#124;
  91. <a href="#pub-methods">Public Member Functions</a> &#124;
  92. <a href="#friends">Friends</a> </div>
  93. <div class="headertitle">
  94. <div class="title">QBtSerialPortClient Class Reference</div> </div>
  95. </div>
  96. <div class="contents">
  97. <!-- doxytag: class="QBtSerialPortClient" -->
  98. <p><code>#include &lt;<a class="el" href="_q_bt_serial_port_client_8h_source.html">QBtSerialPortClient.h</a>&gt;</code></p>
  99. <p><a href="class_q_bt_serial_port_client-members.html">List of all members.</a></p>
  100. <table class="memberdecls">
  101. <tr><td colspan="2"><h2><a name="pub-types"></a>
  102. Public Types</h2></td></tr>
  103. <tr><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1">ErrorCode</a> { <br/>
  104. &#160;&#160;<a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1a50f6c62aadf84ffa637bcbdb4e60451d">ErrorAlreadyInUse</a>,
  105. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1abedca71173b66b80dfa656e3d4f29686">ErrorNotSupported</a>,
  106. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1ac476adfdec2aaf236f8c6bd53b9041af">ErrorUnavailable</a>,
  107. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1a35b989866d6431e803797f038cadf67d">ErrorOpeningConnection</a>,
  108. <br/>
  109. &#160;&#160;<a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1a5fc0095f0a801188cb2738135321461c">ErrorAlreadyConnected</a>,
  110. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1a9863faf6864bc72ab3a90bf0be29eabc">ErrorUndefinedError</a>,
  111. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1a868920af2e7103f08a0f20034be40b3c">ErrorUnableToInitializePort</a>,
  112. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1aaeb8211097d52821db75c68095252f21">ErrorNoDeviceSelected</a>,
  113. <br/>
  114. &#160;&#160;<a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1a2545099205e7a2400a52f5a12bb7062c">ErrorNoServiceSelected</a>,
  115. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1ae7731f1d9e1774aee15da250dee1b56e">ErrorConnectionError</a>,
  116. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1a10f63e642e079621cedba2ffa89e4496">ErrorConnectionTimeout</a>,
  117. <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1a100ba8974cbedcdf7a7c7358f2e3e9df">ErrorOnDisconnecting</a>
  118. <br/>
  119. }</td></tr>
  120. <tr><td colspan="2"><h2><a name="pub-slots"></a>
  121. Public Slots</h2></td></tr>
  122. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#ad15d5078a06b111ba81452f0a4edf1ad">connect</a> (const <a class="el" href="class_q_bt_device.html">QBtDevice</a> &amp;remoteDevice, const <a class="el" href="class_q_bt_service.html">QBtService</a> &amp;remoteService)</td></tr>
  123. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#ab63f95253280c7c7bd49f7834a956a16">disconnect</a> ()</td></tr>
  124. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#afd7f72738c717e1eb0a42b5f64a5d69c">sendData</a> (const QString &amp;data)</td></tr>
  125. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#a00ff212b079a842d0a85682a7c0f28ae">sendData</a> (const QByteArray &amp;data)</td></tr>
  126. <tr><td colspan="2"><h2><a name="signals"></a>
  127. Signals</h2></td></tr>
  128. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#aeb80bf3630c995a5e66cd381dddc9706">disconnectedFromServer</a> ()</td></tr>
  129. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#a89ebcf554805fa246b88b99af165c674">connectionResetByPeer</a> ()</td></tr>
  130. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#a6e440482910ac0a327cc846fb11bb495">connectedToServer</a> ()</td></tr>
  131. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#aa9c2031de53af2f01b65c5705e2626ff">dataSent</a> ()</td></tr>
  132. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#aa5d793a84a4dde54de51a29b83dac546">dataReceived</a> (const QString &amp;data)</td></tr>
  133. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#ad4cf7715eb9dbdbe7857b0986a287ab4">dataReceived</a> (const QByteArray &amp;data)</td></tr>
  134. <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#a715738ecda09bf0e98fb3fb70e154a3c">error</a> (<a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1">QBtSerialPortClient::ErrorCode</a> error)</td></tr>
  135. <tr><td colspan="2"><h2><a name="pub-methods"></a>
  136. Public Member Functions</h2></td></tr>
  137. <tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#af0437082f56e3c034ad659baf021a74e">QBtSerialPortClient</a> (QObject *parent)</td></tr>
  138. <tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#ad5b47c21255d3ad5eb813943590825e7">~QBtSerialPortClient</a> ()</td></tr>
  139. <tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#abb350c02d41c7ca23cdd4c091a8d45e0">isConnected</a> ()</td></tr>
  140. <tr><td colspan="2"><h2><a name="friends"></a>
  141. Friends</h2></td></tr>
  142. <tr><td class="memItemLeft" align="right" valign="top">class&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_q_bt_serial_port_client.html#a3dd60c71c114b95749a59df36f50faf6">QBtSerialPortClientPrivate</a></td></tr>
  143. </table>
  144. <hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
  145. <div class="textblock"><p>Class that provides the mechanism to connect to a bluetooth serial port server and communicate.</p>
  146. <p>Calling <a class="el" href="class_q_bt_serial_port_client.html#ad15d5078a06b111ba81452f0a4edf1ad">connect(const QBtDevice&amp;, const QBtService&amp;)</a> user specifies on which device to connect(on which serial port server) and on which bluetooth service. The <a class="el" href="class_q_bt_device.html">QBtDevice</a> instance of the server can be aquired using <a class="el" href="class_q_bt_device_discoverer.html">QBtDeviceDiscoverer</a> or user can create his own instance and set at least the <a class="el" href="class_q_bt_address.html">QBtAddress</a> field. Also the <a class="el" href="class_q_bt_service.html">QBtService</a> can be aquired using <a class="el" href="class_q_bt_service_discoverer.html">QBtServiceDiscoverer</a> targeting the beforementioned device.</p>
  147. <p>On successfull connection, <a class="el" href="class_q_bt_serial_port_client.html#a6e440482910ac0a327cc846fb11bb495">connectedToServer()</a> singal is emitted and user is able to <a class="el" href="class_q_bt_serial_port_client.html#afd7f72738c717e1eb0a42b5f64a5d69c">sendData(const QString&amp;)</a> to the server. If successfull then dataSend() signal is emitted.</p>
  148. <p>If data is recieved from the server, dataReceived(const QString) signal is emitted containing the bytes recieved. At this point user must be carefull to read the data recieved using the same encoding as the sender (in this case serial port server). QString contains all the necessary functions for character encoding that is why is QString is used instead of QByteArray.</p>
  149. <p>When connection is no longer needed, <a class="el" href="class_q_bt_serial_port_client.html#ab63f95253280c7c7bd49f7834a956a16">disconnect()</a> can be called. <a class="el" href="class_q_bt_serial_port_client.html#aeb80bf3630c995a5e66cd381dddc9706">disconnectedFromServer()</a> is then emitted.</p>
  150. <p>In case of error <a class="el" href="class_q_bt_serial_port_client.html#a715738ecda09bf0e98fb3fb70e154a3c">error(QBtSerialPortClient::ErrorCode)</a> signal is emitted. </p>
  151. </div><hr/><h2>Member Enumeration Documentation</h2>
  152. <a class="anchor" id="a006a87609466450a945cddf66988a1b1"></a><!-- doxytag: member="QBtSerialPortClient::ErrorCode" ref="a006a87609466450a945cddf66988a1b1" args="" -->
  153. <div class="memitem">
  154. <div class="memproto">
  155. <table class="memname">
  156. <tr>
  157. <td class="memname">enum <a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1">QBtSerialPortClient::ErrorCode</a></td>
  158. </tr>
  159. </table>
  160. </div>
  161. <div class="memdoc">
  162. <dl><dt><b>Enumerator: </b></dt><dd><table border="0" cellspacing="2" cellpadding="0">
  163. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1a50f6c62aadf84ffa637bcbdb4e60451d"></a><!-- doxytag: member="ErrorAlreadyInUse" ref="a006a87609466450a945cddf66988a1b1a50f6c62aadf84ffa637bcbdb4e60451d" args="" -->ErrorAlreadyInUse</em>&nbsp;</td><td>
  164. </td></tr>
  165. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1abedca71173b66b80dfa656e3d4f29686"></a><!-- doxytag: member="ErrorNotSupported" ref="a006a87609466450a945cddf66988a1b1abedca71173b66b80dfa656e3d4f29686" args="" -->ErrorNotSupported</em>&nbsp;</td><td>
  166. </td></tr>
  167. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1ac476adfdec2aaf236f8c6bd53b9041af"></a><!-- doxytag: member="ErrorUnavailable" ref="a006a87609466450a945cddf66988a1b1ac476adfdec2aaf236f8c6bd53b9041af" args="" -->ErrorUnavailable</em>&nbsp;</td><td>
  168. </td></tr>
  169. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1a35b989866d6431e803797f038cadf67d"></a><!-- doxytag: member="ErrorOpeningConnection" ref="a006a87609466450a945cddf66988a1b1a35b989866d6431e803797f038cadf67d" args="" -->ErrorOpeningConnection</em>&nbsp;</td><td>
  170. </td></tr>
  171. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1a5fc0095f0a801188cb2738135321461c"></a><!-- doxytag: member="ErrorAlreadyConnected" ref="a006a87609466450a945cddf66988a1b1a5fc0095f0a801188cb2738135321461c" args="" -->ErrorAlreadyConnected</em>&nbsp;</td><td>
  172. </td></tr>
  173. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1a9863faf6864bc72ab3a90bf0be29eabc"></a><!-- doxytag: member="ErrorUndefinedError" ref="a006a87609466450a945cddf66988a1b1a9863faf6864bc72ab3a90bf0be29eabc" args="" -->ErrorUndefinedError</em>&nbsp;</td><td>
  174. </td></tr>
  175. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1a868920af2e7103f08a0f20034be40b3c"></a><!-- doxytag: member="ErrorUnableToInitializePort" ref="a006a87609466450a945cddf66988a1b1a868920af2e7103f08a0f20034be40b3c" args="" -->ErrorUnableToInitializePort</em>&nbsp;</td><td>
  176. </td></tr>
  177. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1aaeb8211097d52821db75c68095252f21"></a><!-- doxytag: member="ErrorNoDeviceSelected" ref="a006a87609466450a945cddf66988a1b1aaeb8211097d52821db75c68095252f21" args="" -->ErrorNoDeviceSelected</em>&nbsp;</td><td>
  178. </td></tr>
  179. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1a2545099205e7a2400a52f5a12bb7062c"></a><!-- doxytag: member="ErrorNoServiceSelected" ref="a006a87609466450a945cddf66988a1b1a2545099205e7a2400a52f5a12bb7062c" args="" -->ErrorNoServiceSelected</em>&nbsp;</td><td>
  180. </td></tr>
  181. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1ae7731f1d9e1774aee15da250dee1b56e"></a><!-- doxytag: member="ErrorConnectionError" ref="a006a87609466450a945cddf66988a1b1ae7731f1d9e1774aee15da250dee1b56e" args="" -->ErrorConnectionError</em>&nbsp;</td><td>
  182. </td></tr>
  183. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1a10f63e642e079621cedba2ffa89e4496"></a><!-- doxytag: member="ErrorConnectionTimeout" ref="a006a87609466450a945cddf66988a1b1a10f63e642e079621cedba2ffa89e4496" args="" -->ErrorConnectionTimeout</em>&nbsp;</td><td>
  184. </td></tr>
  185. <tr><td valign="top"><em><a class="anchor" id="a006a87609466450a945cddf66988a1b1a100ba8974cbedcdf7a7c7358f2e3e9df"></a><!-- doxytag: member="ErrorOnDisconnecting" ref="a006a87609466450a945cddf66988a1b1a100ba8974cbedcdf7a7c7358f2e3e9df" args="" -->ErrorOnDisconnecting</em>&nbsp;</td><td>
  186. </td></tr>
  187. </table>
  188. </dd>
  189. </dl>
  190. </div>
  191. </div>
  192. <hr/><h2>Constructor &amp; Destructor Documentation</h2>
  193. <a class="anchor" id="af0437082f56e3c034ad659baf021a74e"></a><!-- doxytag: member="QBtSerialPortClient::QBtSerialPortClient" ref="af0437082f56e3c034ad659baf021a74e" args="(QObject *parent)" -->
  194. <div class="memitem">
  195. <div class="memproto">
  196. <table class="memname">
  197. <tr>
  198. <td class="memname">QBtSerialPortClient::QBtSerialPortClient </td>
  199. <td>(</td>
  200. <td class="paramtype">QObject *&#160;</td>
  201. <td class="paramname"><em>parent</em></td><td>)</td>
  202. <td></td>
  203. </tr>
  204. </table>
  205. </div>
  206. <div class="memdoc">
  207. <p>A Serial port client. According to the bluetooth specification, up to 7 instances of this class can be connected simultaneously to other servers. </p>
  208. </div>
  209. </div>
  210. <a class="anchor" id="ad5b47c21255d3ad5eb813943590825e7"></a><!-- doxytag: member="QBtSerialPortClient::~QBtSerialPortClient" ref="ad5b47c21255d3ad5eb813943590825e7" args="()" -->
  211. <div class="memitem">
  212. <div class="memproto">
  213. <table class="memname">
  214. <tr>
  215. <td class="memname">QBtSerialPortClient::~QBtSerialPortClient </td>
  216. <td>(</td>
  217. <td class="paramname"></td><td>)</td>
  218. <td></td>
  219. </tr>
  220. </table>
  221. </div>
  222. <div class="memdoc">
  223. <p>Destructor.</p>
  224. <p>If <a class="el" href="class_q_bt_serial_port_client.html#abb350c02d41c7ca23cdd4c091a8d45e0">isConnected()</a> then <a class="el" href="class_q_bt_serial_port_client.html#ab63f95253280c7c7bd49f7834a956a16">disconnect()</a> is called. </p>
  225. </div>
  226. </div>
  227. <hr/><h2>Member Function Documentation</h2>
  228. <a class="anchor" id="ad15d5078a06b111ba81452f0a4edf1ad"></a><!-- doxytag: member="QBtSerialPortClient::connect" ref="ad15d5078a06b111ba81452f0a4edf1ad" args="(const QBtDevice &amp;remoteDevice, const QBtService &amp;remoteService)" -->
  229. <div class="memitem">
  230. <div class="memproto">
  231. <table class="memname">
  232. <tr>
  233. <td class="memname">void QBtSerialPortClient::connect </td>
  234. <td>(</td>
  235. <td class="paramtype">const <a class="el" href="class_q_bt_device.html">QBtDevice</a> &amp;&#160;</td>
  236. <td class="paramname"><em>remoteDevice</em>, </td>
  237. </tr>
  238. <tr>
  239. <td class="paramkey"></td>
  240. <td></td>
  241. <td class="paramtype">const <a class="el" href="class_q_bt_service.html">QBtService</a> &amp;&#160;</td>
  242. <td class="paramname"><em>remoteService</em>&#160;</td>
  243. </tr>
  244. <tr>
  245. <td></td>
  246. <td>)</td>
  247. <td></td><td><code> [slot]</code></td>
  248. </tr>
  249. </table>
  250. </div>
  251. <div class="memdoc">
  252. <p><a class="el" href="class_q_bt_serial_port_client.html#ad15d5078a06b111ba81452f0a4edf1ad">connect()</a> RemoteDevice must contain at least the device address. and remoteService at least a class ID (in case of SerialPort port field is also needed). The remoteService info can be acquired by <a class="el" href="class_q_bt_service_discoverer.html">QBtServiceDiscoverer</a>. </p>
  253. </div>
  254. </div>
  255. <a class="anchor" id="a6e440482910ac0a327cc846fb11bb495"></a><!-- doxytag: member="QBtSerialPortClient::connectedToServer" ref="a6e440482910ac0a327cc846fb11bb495" args="()" -->
  256. <div class="memitem">
  257. <div class="memproto">
  258. <table class="memname">
  259. <tr>
  260. <td class="memname">void QBtSerialPortClient::connectedToServer </td>
  261. <td>(</td>
  262. <td class="paramname"></td><td>)</td>
  263. <td><code> [signal]</code></td>
  264. </tr>
  265. </table>
  266. </div>
  267. <div class="memdoc">
  268. <p>Emitted when successfully connected to the remote server. </p>
  269. </div>
  270. </div>
  271. <a class="anchor" id="a89ebcf554805fa246b88b99af165c674"></a><!-- doxytag: member="QBtSerialPortClient::connectionResetByPeer" ref="a89ebcf554805fa246b88b99af165c674" args="()" -->
  272. <div class="memitem">
  273. <div class="memproto">
  274. <table class="memname">
  275. <tr>
  276. <td class="memname">void QBtSerialPortClient::connectionResetByPeer </td>
  277. <td>(</td>
  278. <td class="paramname"></td><td>)</td>
  279. <td><code> [signal]</code></td>
  280. </tr>
  281. </table>
  282. </div>
  283. <div class="memdoc">
  284. <p>Emitted when the server initiated a disconnection. </p>
  285. </div>
  286. </div>
  287. <a class="anchor" id="aa5d793a84a4dde54de51a29b83dac546"></a><!-- doxytag: member="QBtSerialPortClient::dataReceived" ref="aa5d793a84a4dde54de51a29b83dac546" args="(const QString &amp;data)" -->
  288. <div class="memitem">
  289. <div class="memproto">
  290. <table class="memname">
  291. <tr>
  292. <td class="memname">void QBtSerialPortClient::dataReceived </td>
  293. <td>(</td>
  294. <td class="paramtype">const QString &amp;&#160;</td>
  295. <td class="paramname"><em>data</em></td><td>)</td>
  296. <td><code> [signal]</code></td>
  297. </tr>
  298. </table>
  299. </div>
  300. <div class="memdoc">
  301. <p>Emitted as feedback when data are received successfully. </p>
  302. </div>
  303. </div>
  304. <a class="anchor" id="ad4cf7715eb9dbdbe7857b0986a287ab4"></a><!-- doxytag: member="QBtSerialPortClient::dataReceived" ref="ad4cf7715eb9dbdbe7857b0986a287ab4" args="(const QByteArray &amp;data)" -->
  305. <div class="memitem">
  306. <div class="memproto">
  307. <table class="memname">
  308. <tr>
  309. <td class="memname">void QBtSerialPortClient::dataReceived </td>
  310. <td>(</td>
  311. <td class="paramtype">const QByteArray &amp;&#160;</td>
  312. <td class="paramname"><em>data</em></td><td>)</td>
  313. <td><code> [signal]</code></td>
  314. </tr>
  315. </table>
  316. </div>
  317. <div class="memdoc">
  318. <p>Emitted the instance the <a class="el" href="class_q_bt_serial_port_client.html#aa5d793a84a4dde54de51a29b83dac546">dataReceived(const QString&amp;)</a> signal is emitted. User decides which format wants to read. </p>
  319. </div>
  320. </div>
  321. <a class="anchor" id="aa9c2031de53af2f01b65c5705e2626ff"></a><!-- doxytag: member="QBtSerialPortClient::dataSent" ref="aa9c2031de53af2f01b65c5705e2626ff" args="()" -->
  322. <div class="memitem">
  323. <div class="memproto">
  324. <table class="memname">
  325. <tr>
  326. <td class="memname">void QBtSerialPortClient::dataSent </td>
  327. <td>(</td>
  328. <td class="paramname"></td><td>)</td>
  329. <td><code> [signal]</code></td>
  330. </tr>
  331. </table>
  332. </div>
  333. <div class="memdoc">
  334. <p>Emitted when after sendData(QString) is called, if the data is send successfully. </p>
  335. </div>
  336. </div>
  337. <a class="anchor" id="ab63f95253280c7c7bd49f7834a956a16"></a><!-- doxytag: member="QBtSerialPortClient::disconnect" ref="ab63f95253280c7c7bd49f7834a956a16" args="()" -->
  338. <div class="memitem">
  339. <div class="memproto">
  340. <table class="memname">
  341. <tr>
  342. <td class="memname">void QBtSerialPortClient::disconnect </td>
  343. <td>(</td>
  344. <td class="paramname"></td><td>)</td>
  345. <td><code> [slot]</code></td>
  346. </tr>
  347. </table>
  348. </div>
  349. <div class="memdoc">
  350. <p><a class="el" href="class_q_bt_serial_port_client.html#ab63f95253280c7c7bd49f7834a956a16">disconnect()</a> Disconnects from the remote server if previously succusfully connected. </p>
  351. </div>
  352. </div>
  353. <a class="anchor" id="aeb80bf3630c995a5e66cd381dddc9706"></a><!-- doxytag: member="QBtSerialPortClient::disconnectedFromServer" ref="aeb80bf3630c995a5e66cd381dddc9706" args="()" -->
  354. <div class="memitem">
  355. <div class="memproto">
  356. <table class="memname">
  357. <tr>
  358. <td class="memname">void QBtSerialPortClient::disconnectedFromServer </td>
  359. <td>(</td>
  360. <td class="paramname"></td><td>)</td>
  361. <td><code> [signal]</code></td>
  362. </tr>
  363. </table>
  364. </div>
  365. <div class="memdoc">
  366. <p>Emitted when successfully disconnected from the remote server (initiated from client). </p>
  367. </div>
  368. </div>
  369. <a class="anchor" id="a715738ecda09bf0e98fb3fb70e154a3c"></a><!-- doxytag: member="QBtSerialPortClient::error" ref="a715738ecda09bf0e98fb3fb70e154a3c" args="(QBtSerialPortClient::ErrorCode error)" -->
  370. <div class="memitem">
  371. <div class="memproto">
  372. <table class="memname">
  373. <tr>
  374. <td class="memname">void QBtSerialPortClient::error </td>
  375. <td>(</td>
  376. <td class="paramtype"><a class="el" href="class_q_bt_serial_port_client.html#a006a87609466450a945cddf66988a1b1">QBtSerialPortClient::ErrorCode</a>&#160;</td>
  377. <td class="paramname"><em>error</em></td><td>)</td>
  378. <td><code> [signal]</code></td>
  379. </tr>
  380. </table>
  381. </div>
  382. <div class="memdoc">
  383. <p>Emitted in case of error. </p>
  384. </div>
  385. </div>
  386. <a class="anchor" id="abb350c02d41c7ca23cdd4c091a8d45e0"></a><!-- doxytag: member="QBtSerialPortClient::isConnected" ref="abb350c02d41c7ca23cdd4c091a8d45e0" args="()" -->
  387. <div class="memitem">
  388. <div class="memproto">
  389. <table class="memname">
  390. <tr>
  391. <td class="memname">bool QBtSerialPortClient::isConnected </td>
  392. <td>(</td>
  393. <td class="paramname"></td><td>)</td>
  394. <td></td>
  395. </tr>
  396. </table>
  397. </div>
  398. <div class="memdoc">
  399. <p><a class="el" href="class_q_bt_serial_port_client.html#abb350c02d41c7ca23cdd4c091a8d45e0">isConnected()</a></p>
  400. <p>Returns whether or not the client is connected to a remote server. </p>
  401. </div>
  402. </div>
  403. <a class="anchor" id="afd7f72738c717e1eb0a42b5f64a5d69c"></a><!-- doxytag: member="QBtSerialPortClient::sendData" ref="afd7f72738c717e1eb0a42b5f64a5d69c" args="(const QString &amp;data)" -->
  404. <div class="memitem">
  405. <div class="memproto">
  406. <table class="memname">
  407. <tr>
  408. <td class="memname">void QBtSerialPortClient::sendData </td>
  409. <td>(</td>
  410. <td class="paramtype">const QString &amp;&#160;</td>
  411. <td class="paramname"><em>data</em></td><td>)</td>
  412. <td><code> [slot]</code></td>
  413. </tr>
  414. </table>
  415. </div>
  416. <div class="memdoc">
  417. <p><a class="el" href="class_q_bt_serial_port_client.html#afd7f72738c717e1eb0a42b5f64a5d69c">sendData()</a> Send a string to the server. If text is transmitted, it is up to the user to decide which text encoding to use. Upon succesfull transmittion, <a class="el" href="class_q_bt_serial_port_client.html#aa9c2031de53af2f01b65c5705e2626ff">dataSent()</a> signal is emitted. </p>
  418. </div>
  419. </div>
  420. <a class="anchor" id="a00ff212b079a842d0a85682a7c0f28ae"></a><!-- doxytag: member="QBtSerialPortClient::sendData" ref="a00ff212b079a842d0a85682a7c0f28ae" args="(const QByteArray &amp;data)" -->
  421. <div class="memitem">
  422. <div class="memproto">
  423. <table class="memname">
  424. <tr>
  425. <td class="memname">void QBtSerialPortClient::sendData </td>
  426. <td>(</td>
  427. <td class="paramtype">const QByteArray &amp;&#160;</td>
  428. <td class="paramname"><em>data</em></td><td>)</td>
  429. <td><code> [slot]</code></td>
  430. </tr>
  431. </table>
  432. </div>
  433. <div class="memdoc">
  434. <p>Send a array of bytes to the server, as is. Upon succesfull transmittion, <a class="el" href="class_q_bt_serial_port_client.html#aa9c2031de53af2f01b65c5705e2626ff">dataSent()</a> signal is emitted. </p>
  435. </div>
  436. </div>
  437. <hr/><h2>Friends And Related Function Documentation</h2>
  438. <a class="anchor" id="a3dd60c71c114b95749a59df36f50faf6"></a><!-- doxytag: member="QBtSerialPortClient::QBtSerialPortClientPrivate" ref="a3dd60c71c114b95749a59df36f50faf6" args="" -->
  439. <div class="memitem">
  440. <div class="memproto">
  441. <table class="memname">
  442. <tr>
  443. <td class="memname">friend class QBtSerialPortClientPrivate<code> [friend]</code></td>
  444. </tr>
  445. </table>
  446. </div>
  447. <div class="memdoc">
  448. </div>
  449. </div>
  450. <hr/>The documentation for this class was generated from the following file:<ul>
  451. <li><a class="el" href="_q_bt_serial_port_client_8h_source.html">QBtSerialPortClient.h</a></li>
  452. </ul>
  453. </div>
  454. </div>
  455. <div id="nav-path" class="navpath">
  456. <ul>
  457. <li class="navelem"><a class="el" href="class_q_bt_serial_port_client.html">QBtSerialPortClient</a> </li>
  458. <!-- window showing the filter options -->
  459. <div id="MSearchSelectWindow"
  460. onmouseover="return searchBox.OnSearchSelectShow()"
  461. onmouseout="return searchBox.OnSearchSelectHide()"
  462. onkeydown="return searchBox.OnSearchSelectKey(event)">
  463. <a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Properties</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(10)"><span class="SelectionMark">&#160;</span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(11)"><span class="SelectionMark">&#160;</span>Defines</a></div>
  464. <!-- iframe showing the search results (closed by default) -->
  465. <div id="MSearchResultsWindow">
  466. <iframe src="javascript:void(0)" frameborder="0"
  467. name="MSearchResults" id="MSearchResults">
  468. </iframe>
  469. </div>
  470. <li class="footer">Generated on Wed Jan 4 2012 21:05:39 for QBluetoothZero by
  471. <a href="http://www.doxygen.org/index.html">
  472. <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.5.1 </li>
  473. </ul>
  474. </div>
  475. </body>
  476. </html>