1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 2 <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> 3 <title>NTPTime class Reference</title> 4 <link href="doxygen.css" rel="stylesheet" type="text/css"> 5 </head><body> 6 <!-- Generated by Doxygen 1.2.18 --> 7 <center> 8 <a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="modules.html">Modules</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="annotated.html">Data Structures</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Data Fields</a> <a class="qindex" href="globals.html">Globals</a> </center> 9 <hr><h1>NTPTime Class Reference<br> 10 <small> 11 [<a class="el" href="group__osclbase.html">OSCL Base</a>]</small> 12 </h1>The NTPTime class represents a time value as the number of seconds since 0h (UTC) Jan. 1, 1900. 13 <a href="#_details">More...</a> 14 <p> 15 <code>#include <<a class="el" href="oscl__time_8h-source.html">oscl_time.h</a>></code> 16 <p> 17 <table border=0 cellpadding=0 cellspacing=0> 18 <tr><td></td></tr> 19 <tr><td colspan=2><br><h2>Public Methods</h2></td></tr> 20 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF </td><td valign=bottom><a class="el" href="classNTPTime.html#a0">NTPTime</a> ()</td></tr> 21 <tr><td> </td><td><font size=-1><em>The default constructor creates an NTPTime instance representing the current system time.</em> <a href="#a0"></a><em></em></font><br><br></td></tr> 22 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF </td><td valign=bottom><a class="el" href="classNTPTime.html#a1">NTPTime</a> (const NTPTime &src)</td></tr> 23 <tr><td> </td><td><font size=-1><em>Copy constructor to create a new NTPTime from an existing one.</em> <a href="#a1"></a><em></em></font><br><br></td></tr> 24 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF </td><td valign=bottom><a class="el" href="classNTPTime.html#a2">NTPTime</a> (const uint32 seconds)</td></tr> 25 <tr><td> </td><td><font size=-1><em>Construct an NTPTime from a uint32.</em> <a href="#a2"></a><em></em></font><br><br></td></tr> 26 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF </td><td valign=bottom><a class="el" href="classNTPTime.html#a3">NTPTime</a> (const int32 seconds)</td></tr> 27 <tr><td> </td><td><font size=-1><em>Construct an NTPTime from a int.</em> <a href="#a3"></a><em></em></font><br><br></td></tr> 28 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF </td><td valign=bottom><a class="el" href="classNTPTime.html#a4">NTPTime</a> (const <a class="el" href="classTimeValue.html">TimeValue</a> &t)</td></tr> 29 <tr><td> </td><td><font size=-1><em>Construct a NTPTime instance from a <a class="el" href="classTimeValue.html">TimeValue</a> instance.</em> <a href="#a4"></a><em></em></font><br><br></td></tr> 30 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF </td><td valign=bottom><a class="el" href="classNTPTime.html#a5">NTPTime</a> (const <a class="el" href="group__osclbase.html#a31">uint64</a> value)</td></tr> 31 <tr><td> </td><td><font size=-1><em>Construct a NTPTime instance from a uint64 value.</em> <a href="#a5"></a><em></em></font><br><br></td></tr> 32 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF NTPTime & </td><td valign=bottom><a class="el" href="classNTPTime.html#a6">operator=</a> (uint32 newval)</td></tr> 33 <tr><td> </td><td><font size=-1><em>The assignment operator for a 32 bit integer.</em> <a href="#a6"></a><em></em></font><br><br></td></tr> 34 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF NTPTime & </td><td valign=bottom><a class="el" href="classNTPTime.html#a7">operator=</a> (<a class="el" href="group__osclbase.html#a31">uint64</a> newval)</td></tr> 35 <tr><td> </td><td><font size=-1><em>The assignment operator for a 64 bit integer.</em> <a href="#a7"></a><em></em></font><br><br></td></tr> 36 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF NTPTime & </td><td valign=bottom><a class="el" href="classNTPTime.html#a8">operator+=</a> (<a class="el" href="group__osclbase.html#a31">uint64</a> val)</td></tr> 37 <tr><td> </td><td><font size=-1><em>The += operator is used to add a 64 bit 32.32 value to an existing NTPTime value.</em> <a href="#a8"></a><em></em></font><br><br></td></tr> 38 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF NTPTime </td><td valign=bottom><a class="el" href="classNTPTime.html#a9">operator-</a> (const NTPTime &ntpt) const</td></tr> 39 <tr><td> </td><td><font size=-1><em>The - operator allows subtraction of one NTPTime value from another. This is useful to measure an interval.</em> <a href="#a9"></a><em></em></font><br><br></td></tr> 40 <tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="classNTPTime.html#a10">set_from_system_time</a> (const uint32 systemtime)</td></tr> 41 <tr><td> </td><td><font size=-1><em>This method converts a 32-bit system time to NTP time.</em> <a href="#a10"></a><em></em></font><br><br></td></tr> 42 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF uint32 </td><td valign=bottom><a class="el" href="classNTPTime.html#a11">get_middle32</a> () const</td></tr> 43 <tr><td> </td><td><font size=-1><em>Grab the middle 32 bits of the 64 bit 32.32 representation.</em> <a href="#a11"></a><em></em></font><br><br></td></tr> 44 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF uint32 </td><td valign=bottom><a class="el" href="classNTPTime.html#a12">get_upper32</a> () const</td></tr> 45 <tr><td> </td><td><font size=-1><em>This method returns the upper 32 bits of the 32.32 representation.</em> <a href="#a12"></a><em></em></font><br><br></td></tr> 46 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF uint32 </td><td valign=bottom><a class="el" href="classNTPTime.html#a13">get_lower32</a> () const</td></tr> 47 <tr><td> </td><td><font size=-1><em>This method returns the lower 32 bits of the 32.32 representation.</em> <a href="#a13"></a><em></em></font><br><br></td></tr> 48 <tr><td nowrap align=right valign=top>int32 </td><td valign=bottom><a class="el" href="classNTPTime.html#a14">to_system_time</a> () const</td></tr> 49 <tr><td> </td><td><font size=-1><em>This method converts the ntp time value to system time.</em> <a href="#a14"></a><em></em></font><br><br></td></tr> 50 <tr><td nowrap align=right valign=top>OSCL_COND_IMPORT_REF <a class="el" href="group__osclbase.html#a31">uint64</a> </td><td valign=bottom><a class="el" href="classNTPTime.html#a15">get_value</a> () const</td></tr> 51 <tr><td> </td><td><font size=-1><em>This method returns the 32.32 ntp representation.</em> <a href="#a15"></a><em></em></font><br><br></td></tr> 52 <tr><td nowrap align=right valign=top>OSCL_IMPORT_REF int </td><td valign=bottom><a class="el" href="classNTPTime.html#a16">set_to_current_time</a> ()</td></tr> 53 <tr><td> </td><td><font size=-1><em>This method sets the 32.32 representation to the current system time value.</em> <a href="#a16"></a><em></em></font><br><br></td></tr> 54 </table> 55 <hr><a name="_details"></a><h2>Detailed Description</h2> 56 The NTPTime class represents a time value as the number of seconds since 0h (UTC) Jan. 1, 1900. 57 <p> 58 The NTPTime class: Conversion to/from Unix (epoch at 0h Jan. 1, 1970) amount to addition/subtraction of 2208988800. A single 64 bit value is used to represent the time. This value represents the number of seconds since 0h (UTC) Jan. 1, 1900. There is an implied binary point betweeen the upper 32 bits and lower 32 bits (this is referred to as a 32.32 fractional representation). For example a binary value of 00000000 00000000 00000000 00000011 10000000 00000000 00000000 00000000 represents 3.5 seconds since Jan 1, 1900. 59 <p> 60 <hr><h2>Constructor & Destructor Documentation</h2> 61 <a name="a0" doxytag="NTPTime::NTPTime"></a><p> 62 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 63 <tr> 64 <td class="md"> 65 <table cellpadding="0" cellspacing="0" border="0"> 66 <tr> 67 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime::NTPTime </td> 68 <td class="md" valign="top">( </td> 69 <td class="mdname1" valign="top" nowrap> </td> 70 <td class="md" valign="top">) </td> 71 <td class="md" nowrap></td> 72 </tr> 73 74 </table> 75 </td> 76 </tr> 77 </table> 78 <table cellspacing=5 cellpadding=0 border=0> 79 <tr> 80 <td> 81 82 </td> 83 <td> 84 85 <p> 86 The default constructor creates an NTPTime instance representing the current system time. 87 <p> 88 </td> 89 </tr> 90 </table> 91 <a name="a1" doxytag="NTPTime::NTPTime"></a><p> 92 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 93 <tr> 94 <td class="md"> 95 <table cellpadding="0" cellspacing="0" border="0"> 96 <tr> 97 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime::NTPTime </td> 98 <td class="md" valign="top">( </td> 99 <td class="md" nowrap valign="top">const NTPTime & </td> 100 <td class="mdname1" valign="top" nowrap> <em>src</em> </td> 101 <td class="md" valign="top">) </td> 102 <td class="md" nowrap></td> 103 </tr> 104 105 </table> 106 </td> 107 </tr> 108 </table> 109 <table cellspacing=5 cellpadding=0 border=0> 110 <tr> 111 <td> 112 113 </td> 114 <td> 115 116 <p> 117 Copy constructor to create a new NTPTime from an existing one. 118 <p> 119 </td> 120 </tr> 121 </table> 122 <a name="a2" doxytag="NTPTime::NTPTime"></a><p> 123 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 124 <tr> 125 <td class="md"> 126 <table cellpadding="0" cellspacing="0" border="0"> 127 <tr> 128 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime::NTPTime </td> 129 <td class="md" valign="top">( </td> 130 <td class="md" nowrap valign="top">const uint32 </td> 131 <td class="mdname1" valign="top" nowrap> <em>seconds</em> </td> 132 <td class="md" valign="top">) </td> 133 <td class="md" nowrap></td> 134 </tr> 135 136 </table> 137 </td> 138 </tr> 139 </table> 140 <table cellspacing=5 cellpadding=0 border=0> 141 <tr> 142 <td> 143 144 </td> 145 <td> 146 147 <p> 148 Construct an NTPTime from a uint32. 149 <p> 150 <dl compact><dt><b>Parameters: </b></dt><dd> 151 <table border=0 cellspacing=2 cellpadding=0> 152 <tr><td valign=top><em>seconds</em> </td><td> 153 The uint32 input represents the number of seconds since Jan. 1, 1900. </td></tr> 154 </table> 155 </dl> </td> 156 </tr> 157 </table> 158 <a name="a3" doxytag="NTPTime::NTPTime"></a><p> 159 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 160 <tr> 161 <td class="md"> 162 <table cellpadding="0" cellspacing="0" border="0"> 163 <tr> 164 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime::NTPTime </td> 165 <td class="md" valign="top">( </td> 166 <td class="md" nowrap valign="top">const int32 </td> 167 <td class="mdname1" valign="top" nowrap> <em>seconds</em> </td> 168 <td class="md" valign="top">) </td> 169 <td class="md" nowrap></td> 170 </tr> 171 172 </table> 173 </td> 174 </tr> 175 </table> 176 <table cellspacing=5 cellpadding=0 border=0> 177 <tr> 178 <td> 179 180 </td> 181 <td> 182 183 <p> 184 Construct an NTPTime from a int. 185 <p> 186 <dl compact><dt><b>Parameters: </b></dt><dd> 187 <table border=0 cellspacing=2 cellpadding=0> 188 <tr><td valign=top><em>seconds</em> </td><td> 189 The int input represents the number of seconds since Jan. 1, 1900. </td></tr> 190 </table> 191 </dl> </td> 192 </tr> 193 </table> 194 <a name="a4" doxytag="NTPTime::NTPTime"></a><p> 195 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 196 <tr> 197 <td class="md"> 198 <table cellpadding="0" cellspacing="0" border="0"> 199 <tr> 200 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime::NTPTime </td> 201 <td class="md" valign="top">( </td> 202 <td class="md" nowrap valign="top">const <a class="el" href="classTimeValue.html">TimeValue</a> & </td> 203 <td class="mdname1" valign="top" nowrap> <em>t</em> </td> 204 <td class="md" valign="top">) </td> 205 <td class="md" nowrap></td> 206 </tr> 207 208 </table> 209 </td> 210 </tr> 211 </table> 212 <table cellspacing=5 cellpadding=0 border=0> 213 <tr> 214 <td> 215 216 </td> 217 <td> 218 219 <p> 220 Construct a NTPTime instance from a <a class="el" href="classTimeValue.html">TimeValue</a> instance. 221 <p> 222 This constructor creates an NTPTime value representing the same absolute time as the <a class="el" href="classTimeValue.html">TimeValue</a> parameter. <dl compact><dt><b>Parameters: </b></dt><dd> 223 <table border=0 cellspacing=2 cellpadding=0> 224 <tr><td valign=top><em>t</em> </td><td> 225 A reference to a <a class="el" href="classTimeValue.html">TimeValue</a> object. </td></tr> 226 </table> 227 </dl> </td> 228 </tr> 229 </table> 230 <a name="a5" doxytag="NTPTime::NTPTime"></a><p> 231 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 232 <tr> 233 <td class="md"> 234 <table cellpadding="0" cellspacing="0" border="0"> 235 <tr> 236 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime::NTPTime </td> 237 <td class="md" valign="top">( </td> 238 <td class="md" nowrap valign="top">const <a class="el" href="group__osclbase.html#a31">uint64</a> </td> 239 <td class="mdname1" valign="top" nowrap> <em>value</em> </td> 240 <td class="md" valign="top">) </td> 241 <td class="md" nowrap></td> 242 </tr> 243 244 </table> 245 </td> 246 </tr> 247 </table> 248 <table cellspacing=5 cellpadding=0 border=0> 249 <tr> 250 <td> 251 252 </td> 253 <td> 254 255 <p> 256 Construct a NTPTime instance from a uint64 value. 257 <p> 258 <dl compact><dt><b>Parameters: </b></dt><dd> 259 <table border=0 cellspacing=2 cellpadding=0> 260 <tr><td valign=top><em>value</em> </td><td> 261 A 64 bit integer argument which is used as the ntp 32.32 fractional representation. </td></tr> 262 </table> 263 </dl> </td> 264 </tr> 265 </table> 266 <hr><h2>Member Function Documentation</h2> 267 <a name="a13" doxytag="NTPTime::get_lower32"></a><p> 268 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 269 <tr> 270 <td class="md"> 271 <table cellpadding="0" cellspacing="0" border="0"> 272 <tr> 273 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF uint32 NTPTime::get_lower32 </td> 274 <td class="md" valign="top">( </td> 275 <td class="mdname1" valign="top" nowrap> </td> 276 <td class="md" valign="top">) </td> 277 <td class="md" nowrap></td> 278 </tr> 279 280 </table> 281 </td> 282 </tr> 283 </table> 284 <table cellspacing=5 cellpadding=0 border=0> 285 <tr> 286 <td> 287 288 </td> 289 <td> 290 291 <p> 292 This method returns the lower 32 bits of the 32.32 representation. 293 <p> 294 </td> 295 </tr> 296 </table> 297 <a name="a11" doxytag="NTPTime::get_middle32"></a><p> 298 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 299 <tr> 300 <td class="md"> 301 <table cellpadding="0" cellspacing="0" border="0"> 302 <tr> 303 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF uint32 NTPTime::get_middle32 </td> 304 <td class="md" valign="top">( </td> 305 <td class="mdname1" valign="top" nowrap> </td> 306 <td class="md" valign="top">) </td> 307 <td class="md" nowrap></td> 308 </tr> 309 310 </table> 311 </td> 312 </tr> 313 </table> 314 <table cellspacing=5 cellpadding=0 border=0> 315 <tr> 316 <td> 317 318 </td> 319 <td> 320 321 <p> 322 Grab the middle 32 bits of the 64 bit 32.32 representation. 323 <p> 324 </td> 325 </tr> 326 </table> 327 <a name="a12" doxytag="NTPTime::get_upper32"></a><p> 328 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 329 <tr> 330 <td class="md"> 331 <table cellpadding="0" cellspacing="0" border="0"> 332 <tr> 333 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF uint32 NTPTime::get_upper32 </td> 334 <td class="md" valign="top">( </td> 335 <td class="mdname1" valign="top" nowrap> </td> 336 <td class="md" valign="top">) </td> 337 <td class="md" nowrap></td> 338 </tr> 339 340 </table> 341 </td> 342 </tr> 343 </table> 344 <table cellspacing=5 cellpadding=0 border=0> 345 <tr> 346 <td> 347 348 </td> 349 <td> 350 351 <p> 352 This method returns the upper 32 bits of the 32.32 representation. 353 <p> 354 </td> 355 </tr> 356 </table> 357 <a name="a15" doxytag="NTPTime::get_value"></a><p> 358 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 359 <tr> 360 <td class="md"> 361 <table cellpadding="0" cellspacing="0" border="0"> 362 <tr> 363 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF <a class="el" href="group__osclbase.html#a31">uint64</a> NTPTime::get_value </td> 364 <td class="md" valign="top">( </td> 365 <td class="mdname1" valign="top" nowrap> </td> 366 <td class="md" valign="top">) </td> 367 <td class="md" nowrap></td> 368 </tr> 369 370 </table> 371 </td> 372 </tr> 373 </table> 374 <table cellspacing=5 cellpadding=0 border=0> 375 <tr> 376 <td> 377 378 </td> 379 <td> 380 381 <p> 382 This method returns the 32.32 ntp representation. 383 <p> 384 </td> 385 </tr> 386 </table> 387 <a name="a8" doxytag="NTPTime::operator+="></a><p> 388 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 389 <tr> 390 <td class="md"> 391 <table cellpadding="0" cellspacing="0" border="0"> 392 <tr> 393 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime& NTPTime::operator+= </td> 394 <td class="md" valign="top">( </td> 395 <td class="md" nowrap valign="top"><a class="el" href="group__osclbase.html#a31">uint64</a> </td> 396 <td class="mdname1" valign="top" nowrap> <em>val</em> </td> 397 <td class="md" valign="top">) </td> 398 <td class="md" nowrap></td> 399 </tr> 400 401 </table> 402 </td> 403 </tr> 404 </table> 405 <table cellspacing=5 cellpadding=0 border=0> 406 <tr> 407 <td> 408 409 </td> 410 <td> 411 412 <p> 413 The += operator is used to add a 64 bit 32.32 value to an existing NTPTime value. 414 <p> 415 <dl compact><dt><b>Parameters: </b></dt><dd> 416 <table border=0 cellspacing=2 cellpadding=0> 417 <tr><td valign=top><em>val</em> </td><td> 418 The 64 bit 32.32 value to add to this object's value. </td></tr> 419 </table> 420 </dl> </td> 421 </tr> 422 </table> 423 <a name="a9" doxytag="NTPTime::operator-"></a><p> 424 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 425 <tr> 426 <td class="md"> 427 <table cellpadding="0" cellspacing="0" border="0"> 428 <tr> 429 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime NTPTime::operator- </td> 430 <td class="md" valign="top">( </td> 431 <td class="md" nowrap valign="top">const NTPTime & </td> 432 <td class="mdname1" valign="top" nowrap> <em>ntpt</em> </td> 433 <td class="md" valign="top">) </td> 434 <td class="md" nowrap> const</td> 435 </tr> 436 437 </table> 438 </td> 439 </tr> 440 </table> 441 <table cellspacing=5 cellpadding=0 border=0> 442 <tr> 443 <td> 444 445 </td> 446 <td> 447 448 <p> 449 The - operator allows subtraction of one NTPTime value from another. This is useful to measure an interval. 450 <p> 451 <dl compact><dt><b>Parameters: </b></dt><dd> 452 <table border=0 cellspacing=2 cellpadding=0> 453 <tr><td valign=top><em>ntpt</em> </td><td> 454 A reference to the NTPTime object to be subracted from this one. </td></tr> 455 </table> 456 </dl> </td> 457 </tr> 458 </table> 459 <a name="a7" doxytag="NTPTime::operator="></a><p> 460 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 461 <tr> 462 <td class="md"> 463 <table cellpadding="0" cellspacing="0" border="0"> 464 <tr> 465 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime& NTPTime::operator= </td> 466 <td class="md" valign="top">( </td> 467 <td class="md" nowrap valign="top"><a class="el" href="group__osclbase.html#a31">uint64</a> </td> 468 <td class="mdname1" valign="top" nowrap> <em>newval</em> </td> 469 <td class="md" valign="top">) </td> 470 <td class="md" nowrap></td> 471 </tr> 472 473 </table> 474 </td> 475 </tr> 476 </table> 477 <table cellspacing=5 cellpadding=0 border=0> 478 <tr> 479 <td> 480 481 </td> 482 <td> 483 484 <p> 485 The assignment operator for a 64 bit integer. 486 <p> 487 <dl compact><dt><b>Parameters: </b></dt><dd> 488 <table border=0 cellspacing=2 cellpadding=0> 489 <tr><td valign=top><em>newval</em> </td><td> 490 A 64 bit value which represents the 32.32 fractional representation of the ntp time. </td></tr> 491 </table> 492 </dl> </td> 493 </tr> 494 </table> 495 <a name="a6" doxytag="NTPTime::operator="></a><p> 496 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 497 <tr> 498 <td class="md"> 499 <table cellpadding="0" cellspacing="0" border="0"> 500 <tr> 501 <td class="md" nowrap valign="top"> OSCL_COND_IMPORT_REF NTPTime& NTPTime::operator= </td> 502 <td class="md" valign="top">( </td> 503 <td class="md" nowrap valign="top">uint32 </td> 504 <td class="mdname1" valign="top" nowrap> <em>newval</em> </td> 505 <td class="md" valign="top">) </td> 506 <td class="md" nowrap></td> 507 </tr> 508 509 </table> 510 </td> 511 </tr> 512 </table> 513 <table cellspacing=5 cellpadding=0 border=0> 514 <tr> 515 <td> 516 517 </td> 518 <td> 519 520 <p> 521 The assignment operator for a 32 bit integer. 522 <p> 523 <dl compact><dt><b>Parameters: </b></dt><dd> 524 <table border=0 cellspacing=2 cellpadding=0> 525 <tr><td valign=top><em>newval</em> </td><td> 526 A 32 bit integer representing the upper 32 bits of the 32.32 NTP time (e.g. the number of whole seconds since Jan 1, 1900 UTC). </td></tr> 527 </table> 528 </dl> </td> 529 </tr> 530 </table> 531 <a name="a10" doxytag="NTPTime::set_from_system_time"></a><p> 532 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 533 <tr> 534 <td class="md"> 535 <table cellpadding="0" cellspacing="0" border="0"> 536 <tr> 537 <td class="md" nowrap valign="top"> void NTPTime::set_from_system_time </td> 538 <td class="md" valign="top">( </td> 539 <td class="md" nowrap valign="top">const uint32 </td> 540 <td class="mdname1" valign="top" nowrap> <em>systemtime</em> </td> 541 <td class="md" valign="top">) </td> 542 <td class="md" nowrap></td> 543 </tr> 544 545 </table> 546 </td> 547 </tr> 548 </table> 549 <table cellspacing=5 cellpadding=0 border=0> 550 <tr> 551 <td> 552 553 </td> 554 <td> 555 556 <p> 557 This method converts a 32-bit system time to NTP time. 558 <p> 559 This method sets the value of the NTPTime instance to the absolute time represented by the 32 bit input argument. <dl compact><dt><b>Parameters: </b></dt><dd> 560 <table border=0 cellspacing=2 cellpadding=0> 561 <tr><td valign=top><em>systemtime</em> </td><td> 562 This 32-bit value is interpreted as the number of seconds since the unix epoch Jan. 1 1970. </td></tr> 563 </table> 564 </dl> </td> 565 </tr> 566 </table> 567 <a name="a16" doxytag="NTPTime::set_to_current_time"></a><p> 568 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 569 <tr> 570 <td class="md"> 571 <table cellpadding="0" cellspacing="0" border="0"> 572 <tr> 573 <td class="md" nowrap valign="top"> OSCL_IMPORT_REF int NTPTime::set_to_current_time </td> 574 <td class="md" valign="top">( </td> 575 <td class="mdname1" valign="top" nowrap> </td> 576 <td class="md" valign="top">) </td> 577 <td class="md" nowrap></td> 578 </tr> 579 580 </table> 581 </td> 582 </tr> 583 </table> 584 <table cellspacing=5 cellpadding=0 border=0> 585 <tr> 586 <td> 587 588 </td> 589 <td> 590 591 <p> 592 This method sets the 32.32 representation to the current system time value. 593 <p> 594 </td> 595 </tr> 596 </table> 597 <a name="a14" doxytag="NTPTime::to_system_time"></a><p> 598 <table width="100%" cellpadding="2" cellspacing="0" border="0"> 599 <tr> 600 <td class="md"> 601 <table cellpadding="0" cellspacing="0" border="0"> 602 <tr> 603 <td class="md" nowrap valign="top"> int32 NTPTime::to_system_time </td> 604 <td class="md" valign="top">( </td> 605 <td class="mdname1" valign="top" nowrap> </td> 606 <td class="md" valign="top">) </td> 607 <td class="md" nowrap></td> 608 </tr> 609 610 </table> 611 </td> 612 </tr> 613 </table> 614 <table cellspacing=5 cellpadding=0 border=0> 615 <tr> 616 <td> 617 618 </td> 619 <td> 620 621 <p> 622 This method converts the ntp time value to system time. 623 <p> 624 This method returns a 32 bit value representing the same absolute time as the NTP time value, but expressed as whole seconds since the unix epoch. The fractional part of the ntp value is discarded. </td> 625 </tr> 626 </table> 627 <hr>The documentation for this class was generated from the following file:<ul> 628 <li><a class="el" href="oscl__time_8h-source.html">oscl_time.h</a></ul> 629 <hr size="1"><img src="pvlogo_small.jpg"><address style="align: right;"><small>OSCL API</small> 630 <address style="align: left;"><small>Posting Version: OPENCORE_20090310 </small> 631 </small></address> 632 </body> 633 </html> 634