class_qwt_system_clock.html 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://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. <meta http-equiv="X-UA-Compatible" content="IE=9"/>
  6. <meta name="generator" content="Doxygen 1.8.20"/>
  7. <meta name="viewport" content="width=device-width, initial-scale=1"/>
  8. <title>Qwt User&#39;s Guide: QwtSystemClock Class Reference</title>
  9. <link href="tabs.css" rel="stylesheet" type="text/css"/>
  10. <script type="text/javascript" src="jquery.js"></script>
  11. <script type="text/javascript" src="dynsections.js"></script>
  12. <link href="navtree.css" rel="stylesheet" type="text/css"/>
  13. <script type="text/javascript" src="resize.js"></script>
  14. <script type="text/javascript" src="navtreedata.js"></script>
  15. <script type="text/javascript" src="navtree.js"></script>
  16. <link href="search/search.css" rel="stylesheet" type="text/css"/>
  17. <script type="text/javascript" src="search/searchdata.js"></script>
  18. <script type="text/javascript" src="search/search.js"></script>
  19. <link href="doxygen.css" rel="stylesheet" type="text/css" />
  20. </head>
  21. <body>
  22. <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
  23. <div id="titlearea">
  24. <table cellspacing="0" cellpadding="0">
  25. <tbody>
  26. <tr style="height: 56px;">
  27. <td id="projectalign" style="padding-left: 0.5em;">
  28. <div id="projectname">Qwt User&#39;s Guide
  29. &#160;<span id="projectnumber">6.1.6</span>
  30. </div>
  31. </td>
  32. </tr>
  33. </tbody>
  34. </table>
  35. </div>
  36. <!-- end header part -->
  37. <!-- Generated by Doxygen 1.8.20 -->
  38. <script type="text/javascript">
  39. /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  40. var searchBox = new SearchBox("searchBox", "search",false,'Search');
  41. /* @license-end */
  42. </script>
  43. <script type="text/javascript" src="menudata.js"></script>
  44. <script type="text/javascript" src="menu.js"></script>
  45. <script type="text/javascript">
  46. /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  47. $(function() {
  48. initMenu('',true,false,'search.php','Search');
  49. $(document).ready(function() { init_search(); });
  50. });
  51. /* @license-end */</script>
  52. <div id="main-nav"></div>
  53. </div><!-- top -->
  54. <div id="side-nav" class="ui-resizable side-nav-resizable">
  55. <div id="nav-tree">
  56. <div id="nav-tree-contents">
  57. <div id="nav-sync" class="sync"></div>
  58. </div>
  59. </div>
  60. <div id="splitbar" style="-moz-user-select:none;"
  61. class="ui-resizable-handle">
  62. </div>
  63. </div>
  64. <script type="text/javascript">
  65. /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  66. $(document).ready(function(){initNavTree('class_qwt_system_clock.html',''); initResizable(); });
  67. /* @license-end */
  68. </script>
  69. <div id="doc-content">
  70. <!-- window showing the filter options -->
  71. <div id="MSearchSelectWindow"
  72. onmouseover="return searchBox.OnSearchSelectShow()"
  73. onmouseout="return searchBox.OnSearchSelectHide()"
  74. onkeydown="return searchBox.OnSearchSelectKey(event)">
  75. </div>
  76. <!-- iframe showing the search results (closed by default) -->
  77. <div id="MSearchResultsWindow">
  78. <iframe src="javascript:void(0)" frameborder="0"
  79. name="MSearchResults" id="MSearchResults">
  80. </iframe>
  81. </div>
  82. <div class="header">
  83. <div class="summary">
  84. <a href="#pub-methods">Public Member Functions</a> &#124;
  85. <a href="class_qwt_system_clock-members.html">List of all members</a> </div>
  86. <div class="headertitle">
  87. <div class="title">QwtSystemClock Class Reference</div> </div>
  88. </div><!--header-->
  89. <div class="contents">
  90. <p><a class="el" href="class_qwt_system_clock.html" title="QwtSystemClock provides high resolution clock time functions.">QwtSystemClock</a> provides high resolution clock time functions.
  91. <a href="class_qwt_system_clock.html#details">More...</a></p>
  92. <p><code>#include &lt;<a class="el" href="qwt__system__clock_8h_source.html">qwt_system_clock.h</a>&gt;</code></p>
  93. <table class="memberdecls">
  94. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
  95. Public Member Functions</h2></td></tr>
  96. <tr class="memitem:a384e20d6049376575bf28306154854fd"><td class="memItemLeft" align="right" valign="top"><a id="a384e20d6049376575bf28306154854fd"></a>
  97. &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_system_clock.html#a384e20d6049376575bf28306154854fd">QwtSystemClock</a> ()</td></tr>
  98. <tr class="memdesc:a384e20d6049376575bf28306154854fd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs a null clock object. <br /></td></tr>
  99. <tr class="separator:a384e20d6049376575bf28306154854fd"><td class="memSeparator" colspan="2">&#160;</td></tr>
  100. <tr class="memitem:a79a46a34a317543a08a8424a333b9ee3"><td class="memItemLeft" align="right" valign="top"><a id="a79a46a34a317543a08a8424a333b9ee3"></a>
  101. virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_system_clock.html#a79a46a34a317543a08a8424a333b9ee3">~QwtSystemClock</a> ()</td></tr>
  102. <tr class="memdesc:a79a46a34a317543a08a8424a333b9ee3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor. <br /></td></tr>
  103. <tr class="separator:a79a46a34a317543a08a8424a333b9ee3"><td class="memSeparator" colspan="2">&#160;</td></tr>
  104. <tr class="memitem:a7cde59f783269c5f3542ec93f450f5bd"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_system_clock.html#a7cde59f783269c5f3542ec93f450f5bd">isNull</a> () const</td></tr>
  105. <tr class="separator:a7cde59f783269c5f3542ec93f450f5bd"><td class="memSeparator" colspan="2">&#160;</td></tr>
  106. <tr class="memitem:a3408bd55b49582f7847865aacc7beb37"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_system_clock.html#a3408bd55b49582f7847865aacc7beb37">start</a> ()</td></tr>
  107. <tr class="separator:a3408bd55b49582f7847865aacc7beb37"><td class="memSeparator" colspan="2">&#160;</td></tr>
  108. <tr class="memitem:a6be327dd133c1d7ecccfb95050eef7b9"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_system_clock.html#a6be327dd133c1d7ecccfb95050eef7b9">restart</a> ()</td></tr>
  109. <tr class="separator:a6be327dd133c1d7ecccfb95050eef7b9"><td class="memSeparator" colspan="2">&#160;</td></tr>
  110. <tr class="memitem:a6d373715eb0fac098f2f02ce42a660c9"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_system_clock.html#a6d373715eb0fac098f2f02ce42a660c9">elapsed</a> () const</td></tr>
  111. <tr class="separator:a6d373715eb0fac098f2f02ce42a660c9"><td class="memSeparator" colspan="2">&#160;</td></tr>
  112. </table>
  113. <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
  114. <div class="textblock"><p><a class="el" href="class_qwt_system_clock.html" title="QwtSystemClock provides high resolution clock time functions.">QwtSystemClock</a> provides high resolution clock time functions. </p>
  115. <p>Sometimes the resolution offered by QTime ( millisecond ) is not accurate enough for implementing time measurements ( f.e. sampling ). <a class="el" href="class_qwt_system_clock.html" title="QwtSystemClock provides high resolution clock time functions.">QwtSystemClock</a> offers a subset of the QTime functionality using higher resolution timers ( if possible ).</p>
  116. <p>Precision and time intervals are multiples of milliseconds (ms).</p>
  117. <p>( <a class="el" href="class_qwt_system_clock.html" title="QwtSystemClock provides high resolution clock time functions.">QwtSystemClock</a> is obsolete since Qt 4.8 as QElapsedTimer offers the same precision )</p>
  118. <dl class="section note"><dt>Note</dt><dd>The implementation uses high-resolution performance counter on Windows, mach_absolute_time() on the Mac or POSIX timers on other systems. If none is available it falls back on QTimer. </dd></dl>
  119. </div><h2 class="groupheader">Member Function Documentation</h2>
  120. <a id="a6d373715eb0fac098f2f02ce42a660c9"></a>
  121. <h2 class="memtitle"><span class="permalink"><a href="#a6d373715eb0fac098f2f02ce42a660c9">&#9670;&nbsp;</a></span>elapsed()</h2>
  122. <div class="memitem">
  123. <div class="memproto">
  124. <table class="memname">
  125. <tr>
  126. <td class="memname">double QwtSystemClock::elapsed </td>
  127. <td>(</td>
  128. <td class="paramname"></td><td>)</td>
  129. <td> const</td>
  130. </tr>
  131. </table>
  132. </div><div class="memdoc">
  133. <dl class="section return"><dt>Returns</dt><dd>Number of milliseconds that have elapsed since the last time <a class="el" href="class_qwt_system_clock.html#a3408bd55b49582f7847865aacc7beb37">start()</a> or <a class="el" href="class_qwt_system_clock.html#a6be327dd133c1d7ecccfb95050eef7b9">restart()</a> was called or 0.0 for null clocks. </dd></dl>
  134. </div>
  135. </div>
  136. <a id="a7cde59f783269c5f3542ec93f450f5bd"></a>
  137. <h2 class="memtitle"><span class="permalink"><a href="#a7cde59f783269c5f3542ec93f450f5bd">&#9670;&nbsp;</a></span>isNull()</h2>
  138. <div class="memitem">
  139. <div class="memproto">
  140. <table class="memname">
  141. <tr>
  142. <td class="memname">bool QwtSystemClock::isNull </td>
  143. <td>(</td>
  144. <td class="paramname"></td><td>)</td>
  145. <td> const</td>
  146. </tr>
  147. </table>
  148. </div><div class="memdoc">
  149. <dl class="section return"><dt>Returns</dt><dd>true if the clock has never been started. </dd></dl>
  150. </div>
  151. </div>
  152. <a id="a6be327dd133c1d7ecccfb95050eef7b9"></a>
  153. <h2 class="memtitle"><span class="permalink"><a href="#a6be327dd133c1d7ecccfb95050eef7b9">&#9670;&nbsp;</a></span>restart()</h2>
  154. <div class="memitem">
  155. <div class="memproto">
  156. <table class="memname">
  157. <tr>
  158. <td class="memname">double QwtSystemClock::restart </td>
  159. <td>(</td>
  160. <td class="paramname"></td><td>)</td>
  161. <td></td>
  162. </tr>
  163. </table>
  164. </div><div class="memdoc">
  165. <p>Set the start time to the current time </p><dl class="section return"><dt>Returns</dt><dd>Time, that is elapsed since the previous start time. </dd></dl>
  166. </div>
  167. </div>
  168. <a id="a3408bd55b49582f7847865aacc7beb37"></a>
  169. <h2 class="memtitle"><span class="permalink"><a href="#a3408bd55b49582f7847865aacc7beb37">&#9670;&nbsp;</a></span>start()</h2>
  170. <div class="memitem">
  171. <div class="memproto">
  172. <table class="memname">
  173. <tr>
  174. <td class="memname">void QwtSystemClock::start </td>
  175. <td>(</td>
  176. <td class="paramname"></td><td>)</td>
  177. <td></td>
  178. </tr>
  179. </table>
  180. </div><div class="memdoc">
  181. <p>Sets the start time to the current time. </p>
  182. </div>
  183. </div>
  184. </div><!-- contents -->
  185. </div><!-- doc-content -->
  186. <!-- start footer part -->
  187. <div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  188. <ul>
  189. <li class="navelem"><a class="el" href="class_qwt_system_clock.html">QwtSystemClock</a></li>
  190. <li class="footer">Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20 </li>
  191. </ul>
  192. </div>
  193. </body>
  194. </html>