Sophie

Sophie

distrib > Fedora > 13 > x86_64 > by-pkgid > ca44e7e21c4b6cd5e0c5fdfbf12b4de7 > files > 85

libnjb-devel-2.2.6-6.fc12.x86_64.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>libnjb: The time manipulation API</title>
<link href="tabs.css" rel="stylesheet" type="text/css">
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.9 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li><a href="dirs.html"><span>Directories</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
<h1>The time manipulation API</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="structnjb__time__struct.html">njb_time_t</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__timeapi.html#gb81e4b0ec40afa88e68334d89ae3ba44">NJB_Get_Time</a> (<a class="el" href="structnjb__struct.html">njb_t</a> *njb)</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__timeapi.html#g257a1f0973dc7e3ed779eb55978de2a7">NJB_Set_Time</a> (<a class="el" href="structnjb__struct.html">njb_t</a> *njb, <a class="el" href="structnjb__time__struct.html">njb_time_t</a> *time)</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__timeapi.html#gd520b434c17f481c42bf12f487e632ae">NJB_Destroy_Time</a> (<a class="el" href="structnjb__time__struct.html">njb_time_t</a> *time)</td></tr>

</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="gd520b434c17f481c42bf12f487e632ae"></a><!-- doxytag: member="libnjb.h::NJB_Destroy_Time" ref="gd520b434c17f481c42bf12f487e632ae" args="(njb_time_t *time)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void NJB_Destroy_Time           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structnjb__time__struct.html">njb_time_t</a> *&nbsp;</td>
          <td class="paramname"> <em>time</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
This destroys a time stamp and frees up any memory used by it.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>time</em>&nbsp;</td><td>the time stamp to destroy. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Examples: </b></dt><dd>
<a class="el" href="dumptime_8c-example.html#a16">dumptime.c</a>, and <a class="el" href="settime_8c-example.html#a17">settime.c</a>.</dl>
</div>
</div><p>
<a class="anchor" name="gb81e4b0ec40afa88e68334d89ae3ba44"></a><!-- doxytag: member="libnjb.h::NJB_Get_Time" ref="gb81e4b0ec40afa88e68334d89ae3ba44" args="(njb_t *njb)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structnjb__time__struct.html">njb_time_t</a>* NJB_Get_Time           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structnjb__struct.html">njb_t</a> *&nbsp;</td>
          <td class="paramname"> <em>njb</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
This returns the current time stamp for the device.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>njb</em>&nbsp;</td><td>a pointer to the <code>njb_t</code> object to get the time from. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>a valid time stamp or NULL on failure. </dd></dl>
<dl compact><dt><b>Examples: </b></dt><dd>
<a class="el" href="dumptime_8c-example.html#a8">dumptime.c</a>, and <a class="el" href="settime_8c-example.html#a15">settime.c</a>.</dl>
<p>References <a class="el" href="libnjb_8h_source.html#l00189">njb_struct::device_type</a>, and <a class="el" href="libnjb_8h_source.html#l00072">NJB_DEVICE_NJB1</a>.</p>

</div>
</div><p>
<a class="anchor" name="g257a1f0973dc7e3ed779eb55978de2a7"></a><!-- doxytag: member="libnjb.h::NJB_Set_Time" ref="g257a1f0973dc7e3ed779eb55978de2a7" args="(njb_t *njb, njb_time_t *time)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int NJB_Set_Time           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structnjb__struct.html">njb_t</a> *&nbsp;</td>
          <td class="paramname"> <em>njb</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structnjb__time__struct.html">njb_time_t</a> *&nbsp;</td>
          <td class="paramname"> <em>time</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
This sets the current time stamp for the device. (Sets the on-board clock.)<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>njb</em>&nbsp;</td><td>a pointer to the <code>njb_t</code> object to set the timestamp on. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>time</em>&nbsp;</td><td>the new timestamp to use (time to set). </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success, -1 on failure. </dd></dl>
<dl compact><dt><b>Examples: </b></dt><dd>
<a class="el" href="settime_8c-example.html#a16">settime.c</a>.</dl>
<p>References <a class="el" href="libnjb_8h_source.html#l00189">njb_struct::device_type</a>, <a class="el" href="libnjb_8h_source.html#l00072">NJB_DEVICE_NJB1</a>, and <a class="el" href="protocol_8c_source.html#l00341">njb_verify_last_command()</a>.</p>

</div>
</div><p>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Sun Jul 26 17:17:29 2009 for libnjb by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.9 </small></address>
</body>
</html>