Sophie

Sophie

distrib > Mandriva > 2010.0 > i586 > media > contrib-release > by-pkgid > 29c369053a983cc5d8c880dc6e0a2237 > files > 1699

libdtn-devel-2.6.0-2mdv2009.1.i586.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>DTN Reference Implementation: dtn_api.h File Reference</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.8 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="main.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
      <li><a href="globals.html"><span>File&nbsp;Members</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
<h1>dtn_api.h File Reference</h1><code>#include &quot;<a class="el" href="dtn__errno_8h-source.html">dtn_errno.h</a>&quot;</code><br>
<code>#include &quot;<a class="el" href="dtn__types_8h-source.html">dtn_types.h</a>&quot;</code><br>

<p>
<a href="dtn__api_8h-source.html">Go to the source code of this file.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef int *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a></td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">The basic handle for communication with the <a class="el" href="namespacedtn.html" title="Namespace for the dtn daemon source code.">dtn</a> router.  <a href="#566289d829b69370d7635c21364bfe18"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#468806988bcbe04038d7d201181d0cc3">dtn_open</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> *<a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Open a new connection to the router.  <a href="#468806988bcbe04038d7d201181d0cc3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#887c16260463d6057bf5b03a1ff0e224">dtn_close</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Close an open <a class="el" href="namespacedtn.html" title="Namespace for the dtn daemon source code.">dtn</a> handle.  <a href="#887c16260463d6057bf5b03a1ff0e224"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#6183d81d5f742d13e1fdee26423d94b4">dtn_errno</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the error associated with the given handle.  <a href="#6183d81d5f742d13e1fdee26423d94b4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#e87d5715259043c2490d71b80dd78f81">dtn_set_errno</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, int err)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the error associated with the given handle.  <a href="#e87d5715259043c2490d71b80dd78f81"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#b1f6eb20a2388dbae1c04b3a56db3131">dtn_build_local_eid</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *local_eid, const char *service_tag)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Build an appropriate local endpoint id by appending the specified service tag to the daemon's preferred administrative endpoint id.  <a href="#b1f6eb20a2388dbae1c04b3a56db3131"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#383d25d1f6b8f9b5015d20f6f74bbecd">dtn_register</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="structdtn__reg__info__t.html">dtn_reg_info_t</a> *reginfo, <a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> *newregid)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Create a <a class="el" href="namespacedtn.html" title="Namespace for the dtn daemon source code.">dtn</a> registration.  <a href="#383d25d1f6b8f9b5015d20f6f74bbecd"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#35bfbe9258dacb87a17580fb3e73416a">dtn_unregister</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> <a class="el" href="dtnsend_8cc.html#8eb0c3e35c1feb7baf9802f03bf42e41">regid</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Remove a <a class="el" href="namespacedtn.html" title="Namespace for the dtn daemon source code.">dtn</a> registration.  <a href="#35bfbe9258dacb87a17580fb3e73416a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#2e3457827ae6e670eada24be3536d477">dtn_find_registration</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *eid, <a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> *newregid)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Check for an existing registration on the given endpoint id, returning DTN_SUCCSS and filling in the registration id if it exists, or returning ENOENT if it doesn't.  <a href="#2e3457827ae6e670eada24be3536d477"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#17453cd0fd905210e3fcf5210fc2a5b1">dtn_change_registration</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> <a class="el" href="dtnsend_8cc.html#8eb0c3e35c1feb7baf9802f03bf42e41">regid</a>, <a class="el" href="structdtn__reg__info__t.html">dtn_reg_info_t</a> *reginfo)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Modify an existing registration.  <a href="#17453cd0fd905210e3fcf5210fc2a5b1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#3454bed440eb5848b6ac4017c51fe886">dtn_bind</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> <a class="el" href="dtnsend_8cc.html#8eb0c3e35c1feb7baf9802f03bf42e41">regid</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Associate a registration with the current ipc channel.  <a href="#3454bed440eb5848b6ac4017c51fe886"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#919dd7d4475d6d7bcedfbdfb1d129f6c">dtn_unbind</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> <a class="el" href="dtnsend_8cc.html#8eb0c3e35c1feb7baf9802f03bf42e41">regid</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Explicitly remove an association from the current ipc handle.  <a href="#919dd7d4475d6d7bcedfbdfb1d129f6c"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#3996e6553cb38f6cf857b512492b14e2">dtn_send</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> <a class="el" href="dtnsend_8cc.html#8eb0c3e35c1feb7baf9802f03bf42e41">regid</a>, <a class="el" href="structdtn__bundle__spec__t.html">dtn_bundle_spec_t</a> *spec, <a class="el" href="structdtn__bundle__payload__t.html">dtn_bundle_payload_t</a> *payload, <a class="el" href="structdtn__bundle__id__t.html">dtn_bundle_id_t</a> *id)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Send a bundle either from memory or from a file.  <a href="#3996e6553cb38f6cf857b512492b14e2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#4b733bdb9b4670e3392bd5e72a1dabdc">dtn_cancel</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="structdtn__bundle__id__t.html">dtn_bundle_id_t</a> *id)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Cancel a bundle transmission.  <a href="#4b733bdb9b4670e3392bd5e72a1dabdc"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#1377dbe76849d8852400a9278e4b8df1">dtn_recv</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="structdtn__bundle__spec__t.html">dtn_bundle_spec_t</a> *spec, <a class="el" href="dtn__types_8h.html#3dcfddc1b850a71a18d8a0868f67e762">dtn_bundle_payload_location_t</a> location, <a class="el" href="structdtn__bundle__payload__t.html">dtn_bundle_payload_t</a> *payload, <a class="el" href="dtn__types_8h.html#8865a20f2e713bb38e35736e32e1653c">dtn_timeval_t</a> timeout)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Blocking receive for a bundle, filling in the spec and payload structures with the bundle data.  <a href="#1377dbe76849d8852400a9278e4b8df1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#74afc602b7d95c9b6ed1f03c351691b3">dtn_session_update</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, unsigned int *status, <a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *session, <a class="el" href="dtn__types_8h.html#8865a20f2e713bb38e35736e32e1653c">dtn_timeval_t</a> timeout)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Blocking query for new subscribers on a session.  <a href="#74afc602b7d95c9b6ed1f03c351691b3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#dea67e5fa38121aaaa8526c02f9ebfbf">dtn_poll_fd</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return a file descriptor for the given handle suitable for calling poll() or select() in conjunction with a call to <a class="el" href="dtn__api_8c.html#24563d1e420ea738e7d456a58e3ec152" title="Begin a polling period for incoming bundles.">dtn_begin_poll()</a>.  <a href="#dea67e5fa38121aaaa8526c02f9ebfbf"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#5678c8136cde3d2f6ee98e0d9f051c87">dtn_begin_poll</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>, <a class="el" href="dtn__types_8h.html#8865a20f2e713bb38e35736e32e1653c">dtn_timeval_t</a> timeout)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Begin a polling period for incoming bundles.  <a href="#5678c8136cde3d2f6ee98e0d9f051c87"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#b1937510417914fe7741e6d4767683e5">dtn_cancel_poll</a> (<a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> <a class="el" href="dtncat_8c.html#01daea96255bb21a8979b3b45f5bbb70">handle</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Cancel a polling interval.  <a href="#b1937510417914fe7741e6d4767683e5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#b2935a9a7f4ade630f7d2ad1fec5c615">dtn_copy_eid</a> (<a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *dst, <a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *<a class="el" href="dtnmoteproxy_8c.html#e1ade0f5a1b32f6c8be72f31a99e2a18">src</a>)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Copy the contents of one eid into another.  <a href="#b2935a9a7f4ade630f7d2ad1fec5c615"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#055c8bb8eaa570aacbe6a164ff123c84">dtn_parse_eid_string</a> (<a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *eid, const char *str)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Parse a string into an endpoint id structure, validating that it is in fact a valid endpoint id (i.e.  <a href="#055c8bb8eaa570aacbe6a164ff123c84"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#21b6d705673aae970524972aca3db99f">dtn_set_payload</a> (<a class="el" href="structdtn__bundle__payload__t.html">dtn_bundle_payload_t</a> *payload, <a class="el" href="dtn__types_8h.html#3dcfddc1b850a71a18d8a0868f67e762">dtn_bundle_payload_location_t</a> location, char *<a class="el" href="num2sdnv_8c.html#455b3605dc605fe8e055b9c1470535cf">val</a>, int len)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets the value of the given payload structure to either a memory buffer or a file location.  <a href="#21b6d705673aae970524972aca3db99f"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#50a363bf1bf2803892afc1438ab62cff">dtn_free_payload</a> (<a class="el" href="structdtn__bundle__payload__t.html">dtn_bundle_payload_t</a> *payload)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Frees dynamic storage allocated by the xdr for a bundle payload in dtn_recv.  <a href="#50a363bf1bf2803892afc1438ab62cff"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="dtn__api_8h.html#15b2dcc9b16beb1b91ead827b4ee2ca5">dtn_status_report_reason_to_str</a> (<a class="el" href="dtn__types_8h.html#87e1a70c1e1b7872a0337ed40dc4f134">dtn_status_report_reason_t</a> err)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return a string version of a status report reason code.  <a href="#15b2dcc9b16beb1b91ead827b4ee2ca5"></a><br></td></tr>
</table>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="566289d829b69370d7635c21364bfe18"></a><!-- doxytag: member="dtn_api.h::dtn_handle_t" ref="566289d829b69370d7635c21364bfe18" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef int* <a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
The basic handle for communication with the <a class="el" href="namespacedtn.html" title="Namespace for the dtn daemon source code.">dtn</a> router. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8h-source.html#l00026">26</a> of file <a class="el" href="dtn__api_8h-source.html">dtn_api.h</a>.</p>

</div>
</div><p>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="5678c8136cde3d2f6ee98e0d9f051c87"></a><!-- doxytag: member="dtn_api.h::dtn_begin_poll" ref="5678c8136cde3d2f6ee98e0d9f051c87" args="(dtn_handle_t handle, dtn_timeval_t timeout)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_begin_poll           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#8865a20f2e713bb38e35736e32e1653c">dtn_timeval_t</a>&nbsp;</td>
          <td class="paramname"> <em>timeout</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Begin a polling period for incoming bundles. 
<p>
Returns a file descriptor suitable for calling poll() or select() on (similar to dtn_poll_fd). Note that <a class="el" href="dtn__api_8c.html#ab949d76f4c34a202aea5bac853b310b" title="Associate a registration with the current ipc channel.">dtn_bind()</a> must have been previously called at least once on the handle.<p>
If the kernel returns an indication that there is data ready on the file descriptor, a call to dtn_recv will then return the bundle without blocking, then dtn_poll must be called again to wait for more bundles.<p>
Also, no other API calls besides dtn_recv can be executed during a polling period, so an app must call dtn_cancel_poll before trying to run other API calls. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00604">604</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__ipc_8h-source.html#l00095">DTN_BEGIN_POLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8c-source.html#l00233">dtnipc_send()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__ipc_8h-source.html#l00067">dtnipc_handle::sock</a>, <a class="el" href="dtn__types_8h.html#62ea0edc92ab755946bef6dcfaf1f611">xdr_dtn_timeval_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l10772">_wrap_dtn_begin_poll()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00455">dtn_begin_poll()</a>, <a class="el" href="dtntest_8cc-source.html#l00816">DTNBeginPollCommand::exec()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l11182">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="3454bed440eb5848b6ac4017c51fe886"></a><!-- doxytag: member="dtn_api.h::dtn_bind" ref="3454bed440eb5848b6ac4017c51fe886" args="(dtn_handle_t handle, dtn_reg_id_t regid)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_bind           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a>&nbsp;</td>
          <td class="paramname"> <em>regid</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Associate a registration with the current ipc channel. 
<p>
This serves to put the registration in "active" mode. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00305">305</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__ipc_8h-source.html#l00091">DTN_BIND</a>, <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8c-source.html#l00361">dtnipc_send_recv()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__types_8h.html#9fa23bbd89d3ddf6df49a4fae6ebf28e">xdr_dtn_reg_id_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07922">_wrap_dtn_bind()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00180">dtn_bind()</a>, <a class="el" href="dtntest_8cc-source.html#l00510">DTNBindCommand::exec()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00224">dtntunnel::DTNTunnel::init_registration()</a>, <a class="el" href="dtncpd_8c-source.html#l00049">main()</a>, <a class="el" href="dtncat_8c-source.html#l00602">make_registration()</a>, <a class="el" href="dtncat_8c-source.html#l00257">to_bundles()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07680">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="b1f6eb20a2388dbae1c04b3a56db3131"></a><!-- doxytag: member="dtn_api.h::dtn_build_local_eid" ref="b1f6eb20a2388dbae1c04b3a56db3131" args="(dtn_handle_t handle, dtn_endpoint_id_t *local_eid, const char *service_tag)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_build_local_eid           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>local_eid</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>service_tag</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Build an appropriate local endpoint id by appending the specified service tag to the daemon's preferred administrative endpoint id. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00088">88</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00029">DTN_EINVAL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8h-source.html#l00086">DTN_LOCAL_EID</a>, <a class="el" href="dtn__types_8h-source.html#l00047">DTN_MAX_ENDPOINT_ID</a>, <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, <a class="el" href="dtn__ipc_8c-source.html#l00294">dtnipc_recv()</a>, <a class="el" href="dtn__ipc_8c-source.html#l00233">dtnipc_send()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="num2sdnv_8c-source.html#l00034">len</a>, <a class="el" href="dtn__types_8h-source.html#l00103">dtn_service_tag_t::tag</a>, <a class="el" href="dtn__ipc_8h-source.html#l00073">dtnipc_handle::xdr_decode</a>, <a class="el" href="dtn__types_8h.html#16c5a6f4fcdc988f54f034bb1961b342">xdr_dtn_endpoint_id_t()</a>, <a class="el" href="dtn__types_8h.html#9797727a4d9f870dfd962cd25d1a84de">xdr_dtn_service_tag_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07551">_wrap_dtn_build_local_eid()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00072">dtn_build_local_eid()</a>, <a class="el" href="TcaController_8cc-source.html#l00157">TcaController::init()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00224">dtntunnel::DTNTunnel::init_registration()</a>, <a class="el" href="dtncpd_8c-source.html#l00049">main()</a>, <a class="el" href="dtncat_8c-source.html#l00547">parse_eid()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07278">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="4b733bdb9b4670e3392bd5e72a1dabdc"></a><!-- doxytag: member="dtn_api.h::dtn_cancel" ref="4b733bdb9b4670e3392bd5e72a1dabdc" args="(dtn_handle_t handle, dtn_bundle_id_t *id)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_cancel           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__bundle__id__t.html">dtn_bundle_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>id</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Cancel a bundle transmission. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00402">402</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__ipc_8h-source.html#l00097">DTN_CANCEL</a>, <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8c-source.html#l00361">dtnipc_send_recv()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__types_8h.html#c51906327f0c0e0571243a5dceffc0af">xdr_dtn_bundle_id_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l08837">_wrap_dtn_cancel()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00282">dtn_cancel()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l08825">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="b1937510417914fe7741e6d4767683e5"></a><!-- doxytag: member="dtn_api.h::dtn_cancel_poll" ref="b1937510417914fe7741e6d4767683e5" args="(dtn_handle_t handle)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_cancel_poll           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Cancel a polling interval. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00634">634</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__ipc_8h-source.html#l00096">DTN_CANCEL_POLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00029">DTN_EINVAL</a>, <a class="el" href="dtn__errno_8h-source.html#l00033">DTN_ETIMEOUT</a>, <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, <a class="el" href="dtn__ipc_8c-source.html#l00294">dtnipc_recv()</a>, <a class="el" href="dtn__ipc_8c-source.html#l00361">dtnipc_send_recv()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l10803">_wrap_dtn_cancel_poll()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00465">dtn_cancel_poll()</a>, <a class="el" href="dtntest_8cc-source.html#l00857">DTNCancelPollCommand::exec()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l11220">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="17453cd0fd905210e3fcf5210fc2a5b1"></a><!-- doxytag: member="dtn_api.h::dtn_change_registration" ref="17453cd0fd905210e3fcf5210fc2a5b1" args="(dtn_handle_t handle, dtn_reg_id_t regid, dtn_reg_info_t *reginfo)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_change_registration           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a>&nbsp;</td>
          <td class="paramname"> <em>regid</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__reg__info__t.html">dtn_reg_info_t</a> *&nbsp;</td>
          <td class="paramname"> <em>reginfo</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Modify an existing registration. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00283">283</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00036">DTN_EINTERNAL</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07824">_wrap_dtn_change_registration()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00160">dtn_change_registration()</a>, <a class="el" href="dtnrecv_8c-source.html#l00355">main()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07578">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="887c16260463d6057bf5b03a1ff0e224"></a><!-- doxytag: member="dtn_api.h::dtn_close" ref="887c16260463d6057bf5b03a1ff0e224" args="(dtn_handle_t handle)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_close           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Close an open <a class="el" href="namespacedtn.html" title="Namespace for the dtn daemon source code.">dtn</a> handle. 
<p>
Returns DTN_SUCCESS on success. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00065">65</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, and <a class="el" href="dtn__ipc_8c-source.html#l00203">dtnipc_close()</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07508">_wrap_dtn_close()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00054">dtn_close()</a>, <a class="el" href="dtntest_8cc-source.html#l00106">DTNCloseCommand::exec()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00378">dtntunnel::DTNTunnel::main()</a>, <a class="el" href="dtncat_8c-source.html#l00105">main()</a>, <a class="el" href="dtnmoteproxy_8c-source.html#l00165">reader_thread()</a>, <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07223">XS()</a>, and <a class="el" href="TcaController_8cc-source.html#l00121">TcaController::~TcaController()</a>.</p>

</div>
</div><p>
<a class="anchor" name="b2935a9a7f4ade630f7d2ad1fec5c615"></a><!-- doxytag: member="dtn_api.h::dtn_copy_eid" ref="b2935a9a7f4ade630f7d2ad1fec5c615" args="(dtn_endpoint_id_t *dst, dtn_endpoint_id_t *src)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void dtn_copy_eid           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>src</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Copy the contents of one eid into another. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00674">674</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__types_8h-source.html#l00047">DTN_MAX_ENDPOINT_ID</a>, and <a class="el" href="dtn__types_8h-source.html#l00066">dtn_endpoint_id_t::uri</a>.</p>

<p>Referenced by <a class="el" href="TCPTunnel_8cc-source.html#l00225">dtntunnel::TCPTunnel::TCPTunnel::Connection::Connection()</a>, <a class="el" href="TcaController_8cc-source.html#l00128">TcaController::dtn_reg()</a>, <a class="el" href="dtntest_8cc-source.html#l00395">DTNSendCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00186">DTNRegisterCommand::exec()</a>, <a class="el" href="dtncat_8c-source.html#l00148">from_bundles()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00224">dtntunnel::DTNTunnel::init_registration()</a>, <a class="el" href="dtncp_8c-source.html#l00053">main()</a>, <a class="el" href="dtnmoteproxy_8c-source.html#l00165">reader_thread()</a>, <a class="el" href="TcaController_8cc-source.html#l00930">TcaController::send_bundle()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00298">dtntunnel::DTNTunnel::send_bundle()</a>, and <a class="el" href="dtncat_8c-source.html#l00257">to_bundles()</a>.</p>

</div>
</div><p>
<a class="anchor" name="6183d81d5f742d13e1fdee26423d94b4"></a><!-- doxytag: member="dtn_api.h::dtn_errno" ref="6183d81d5f742d13e1fdee26423d94b4" args="(dtn_handle_t handle)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_errno           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Get the error associated with the given handle. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00074">74</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07529">_wrap_dtn_errno()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00063">dtn_errno()</a>, <a class="el" href="TcaController_8cc-source.html#l00128">TcaController::dtn_reg()</a>, <a class="el" href="TcaController_8cc-source.html#l00819">TcaController::eat_bundles()</a>, <a class="el" href="dtntest_8cc-source.html#l00857">DTNCancelPollCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00816">DTNBeginPollCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00769">DTNPollChannelCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00724">DTNSessionUpdateCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00601">DTNRecvCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00546">DTNUnbindCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00510">DTNBindCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00395">DTNSendCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00252">DTNUnregisterCommand::exec()</a>, <a class="el" href="dtntest_8cc-source.html#l00186">DTNRegisterCommand::exec()</a>, <a class="el" href="dtncat_8c-source.html#l00148">from_bundles()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00224">dtntunnel::DTNTunnel::init_registration()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00378">dtntunnel::DTNTunnel::main()</a>, <a class="el" href="dtncp_8c-source.html#l00053">main()</a>, <a class="el" href="dtncat_8c-source.html#l00602">make_registration()</a>, <a class="el" href="dtnmoteproxy_8c-source.html#l00165">reader_thread()</a>, <a class="el" href="TcaController_8cc-source.html#l00863">TcaController::send_bundle()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00298">dtntunnel::DTNTunnel::send_bundle()</a>, <a class="el" href="dtncat_8c-source.html#l00257">to_bundles()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07250">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="2e3457827ae6e670eada24be3536d477"></a><!-- doxytag: member="dtn_api.h::dtn_find_registration" ref="2e3457827ae6e670eada24be3536d477" args="(dtn_handle_t handle, dtn_endpoint_id_t *eid, dtn_reg_id_t *newregid)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_find_registration           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>eid</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>newregid</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Check for an existing registration on the given endpoint id, returning DTN_SUCCSS and filling in the registration id if it exists, or returning ENOENT if it doesn't. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00235">235</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8h-source.html#l00089">DTN_FIND_REGISTRATION</a>, <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, <a class="el" href="dtn__ipc_8c-source.html#l00294">dtnipc_recv()</a>, <a class="el" href="dtn__ipc_8c-source.html#l00233">dtnipc_send()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__ipc_8h-source.html#l00073">dtnipc_handle::xdr_decode</a>, <a class="el" href="dtn__types_8h.html#16c5a6f4fcdc988f54f034bb1961b342">xdr_dtn_endpoint_id_t()</a>, <a class="el" href="dtn__types_8h.html#9fa23bbd89d3ddf6df49a4fae6ebf28e">xdr_dtn_reg_id_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07786">_wrap_dtn_find_registration()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00140">dtn_find_registration()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00224">dtntunnel::DTNTunnel::init_registration()</a>, <a class="el" href="dtncpd_8c-source.html#l00049">main()</a>, <a class="el" href="dtncat_8c-source.html#l00602">make_registration()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07535">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="50a363bf1bf2803892afc1438ab62cff"></a><!-- doxytag: member="dtn_api.h::dtn_free_payload" ref="50a363bf1bf2803892afc1438ab62cff" args="(dtn_bundle_payload_t *payload)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void dtn_free_payload           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structdtn__bundle__payload__t.html">dtn_bundle_payload_t</a> *&nbsp;</td>
          <td class="paramname"> <em>payload</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Frees dynamic storage allocated by the xdr for a bundle payload in dtn_recv. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00736">736</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__types_8h.html#52d9e9ef1e11bf39693baced9c591d67">xdr_dtn_bundle_payload_t()</a>.</p>

<p>Referenced by <a class="el" href="dtn__api_8c-source.html#l00430">dtn_recv()</a>, <a class="el" href="dtntest_8cc-source.html#l00601">DTNRecvCommand::exec()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00378">dtntunnel::DTNTunnel::main()</a>, and <a class="el" href="dtncp_8c-source.html#l00053">main()</a>.</p>

</div>
</div><p>
<a class="anchor" name="468806988bcbe04038d7d201181d0cc3"></a><!-- doxytag: member="dtn_api.h::dtn_open" ref="468806988bcbe04038d7d201181d0cc3" args="(dtn_handle_t *handle)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_open           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a> *&nbsp;</td>
          <td class="paramname"> <em>handle</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Open a new connection to the router. 
<p>
On success, initializes the handle parameter as a new handle to the daemon and returns DTN_SUCCESS. On failure, sets handle to NULL and returns a dtn_errno error code. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00039">39</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00036">DTN_EINTERNAL</a>, <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, <a class="el" href="dtn__ipc_8c-source.html#l00072">dtnipc_open()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00073">dtnipc_handle::xdr_decode</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07473">_wrap_dtn_open()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00029">dtn_open()</a>, <a class="el" href="dtntest_8cc-source.html#l00066">DTNOpenCommand::exec()</a>, <a class="el" href="TcaController_8cc-source.html#l00157">TcaController::init()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00224">dtntunnel::DTNTunnel::init_registration()</a>, <a class="el" href="dtncat_8c-source.html#l00105">main()</a>, <a class="el" href="dtnmoteproxy_8c-source.html#l00165">reader_thread()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07177">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="055c8bb8eaa570aacbe6a164ff123c84"></a><!-- doxytag: member="dtn_api.h::dtn_parse_eid_string" ref="055c8bb8eaa570aacbe6a164ff123c84" args="(dtn_endpoint_id_t *eid, const char *str)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_parse_eid_string           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>eid</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>str</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Parse a string into an endpoint id structure, validating that it is in fact a valid endpoint id (i.e. 
<p>
a URI). 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00681">681</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00029">DTN_EINVAL</a>, <a class="el" href="dtn__errno_8h-source.html#l00034">DTN_ESIZE</a>, <a class="el" href="dtn__types_8h-source.html#l00047">DTN_MAX_ENDPOINT_ID</a>, <a class="el" href="num2sdnv_8c-source.html#l00034">len</a>, and <a class="el" href="dtn__types_8h-source.html#l00066">dtn_endpoint_id_t::uri</a>.</p>

<p>Referenced by <a class="el" href="dtnping_8c-source.html#l00055">main()</a>, <a class="el" href="TcaController_8cc-source.html#l00054">make_spec()</a>, <a class="el" href="dtncat_8c-source.html#l00547">parse_eid()</a>, <a class="el" href="TcaController_8cc-source.html#l00930">TcaController::send_bundle()</a>, <a class="el" href="APIEndpointIDOpt_8cc-source.html#l00043">dtn::APIEndpointIDOpt::set()</a>, and <a class="el" href="DTNTunnel_8cc-source.html#l00118">dtntunnel::DTNTunnel::validate_options()</a>.</p>

</div>
</div><p>
<a class="anchor" name="dea67e5fa38121aaaa8526c02f9ebfbf"></a><!-- doxytag: member="dtn_api.h::dtn_poll_fd" ref="dea67e5fa38121aaaa8526c02f9ebfbf" args="(dtn_handle_t handle)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_poll_fd           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Return a file descriptor for the given handle suitable for calling poll() or select() in conjunction with a call to <a class="el" href="dtn__api_8c.html#24563d1e420ea738e7d456a58e3ec152" title="Begin a polling period for incoming bundles.">dtn_begin_poll()</a>. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00596">596</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00067">dtnipc_handle::sock</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l10750">_wrap_dtn_poll_fd()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00445">dtn_poll_fd()</a>, <a class="el" href="dtntest_8cc-source.html#l00769">DTNPollChannelCommand::exec()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l11154">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="1377dbe76849d8852400a9278e4b8df1"></a><!-- doxytag: member="dtn_api.h::dtn_recv" ref="1377dbe76849d8852400a9278e4b8df1" args="(dtn_handle_t handle, dtn_bundle_spec_t *spec, dtn_bundle_payload_location_t location, dtn_bundle_payload_t *payload, dtn_timeval_t timeout)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_recv           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__bundle__spec__t.html">dtn_bundle_spec_t</a> *&nbsp;</td>
          <td class="paramname"> <em>spec</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#3dcfddc1b850a71a18d8a0868f67e762">dtn_bundle_payload_location_t</a>&nbsp;</td>
          <td class="paramname"> <em>location</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__bundle__payload__t.html">dtn_bundle_payload_t</a> *&nbsp;</td>
          <td class="paramname"> <em>payload</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#8865a20f2e713bb38e35736e32e1653c">dtn_timeval_t</a>&nbsp;</td>
          <td class="paramname"> <em>timeout</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Blocking receive for a bundle, filling in the spec and payload structures with the bundle data. 
<p>
The location parameter indicates the manner by which the caller wants to receive payload data (i.e. either in memory or in a file). The timeout parameter specifies an interval in milliseconds to block on the server-side (-1 means infinite wait).<p>
Note that it is advisable to call dtn_free_payload on the returned structure, otherwise the XDR routines will memory leak. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00430">430</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="structdtn__bundle__payload__t.html#04e8c46c5b40f187e1fefed80853cc5c">dtn_bundle_payload_t::buf</a>, <a class="el" href="dtn__types_8h-source.html#l00378">dtn_bundle_payload_t::buf_len</a>, <a class="el" href="dtn__types_8h-source.html#l00379">dtn_bundle_payload_t::buf_val</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__api_8c-source.html#l00736">dtn_free_payload()</a>, <a class="el" href="dtn__types_8h-source.html#l00365">DTN_PAYLOAD_FILE</a>, <a class="el" href="dtn__types_8h-source.html#l00366">DTN_PAYLOAD_MEM</a>, <a class="el" href="dtn__ipc_8h-source.html#l00094">DTN_RECV</a>, <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, <a class="el" href="dtn__ipc_8c-source.html#l00294">dtnipc_recv()</a>, <a class="el" href="dtn__ipc_8c-source.html#l00361">dtnipc_send_recv()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="IPDiscovery_8cc.html#d65a8842cc674e3ddf69355898c0ecbf">errno</a>, <a class="el" href="dtnperf-client_8c-source.html#l00115">fd</a>, <a class="el" href="structdtn__bundle__payload__t.html#f3a33fd2ae2b3b8eae2e675f1a038cec">dtn_bundle_payload_t::filename</a>, <a class="el" href="dtnrecv_8c-source.html#l00062">filename</a>, <a class="el" href="dtn__types_8h-source.html#l00375">dtn_bundle_payload_t::filename_val</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="num2sdnv_8c-source.html#l00034">len</a>, <a class="el" href="dtn__types_8h-source.html#l00372">dtn_bundle_payload_t::location</a>, <a class="el" href="dtnrecv_8c-source.html#l00044">PATH_MAX</a>, <a class="el" href="dtn__ipc_8h-source.html#l00073">dtnipc_handle::xdr_decode</a>, <a class="el" href="dtn__types_8h.html#d98f93d0953484b7b74e2bf33aa0d3a7">xdr_dtn_bundle_payload_location_t()</a>, <a class="el" href="dtn__types_8h.html#52d9e9ef1e11bf39693baced9c591d67">xdr_dtn_bundle_payload_t()</a>, <a class="el" href="dtn__types_8h.html#54a4fbc50daeb79cc615af82793cbdc8">xdr_dtn_bundle_spec_t()</a>, <a class="el" href="dtn__types_8h.html#62ea0edc92ab755946bef6dcfaf1f611">xdr_dtn_timeval_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l10521">_wrap_dtn_recv()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00339">dtn_recv()</a>, <a class="el" href="TcaController_8cc-source.html#l00819">TcaController::eat_bundles()</a>, <a class="el" href="dtntest_8cc-source.html#l00601">DTNRecvCommand::exec()</a>, <a class="el" href="dtncat_8c-source.html#l00148">from_bundles()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00378">dtntunnel::DTNTunnel::main()</a>, <a class="el" href="dtncp_8c-source.html#l00053">main()</a>, <a class="el" href="TcaController_8cc-source.html#l00892">TcaController::recv_bundle()</a>, <a class="el" href="dtncat_8c-source.html#l00257">to_bundles()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l10882">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="383d25d1f6b8f9b5015d20f6f74bbecd"></a><!-- doxytag: member="dtn_api.h::dtn_register" ref="383d25d1f6b8f9b5015d20f6f74bbecd" args="(dtn_handle_t handle, dtn_reg_info_t *reginfo, dtn_reg_id_t *newregid)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_register           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__reg__info__t.html">dtn_reg_info_t</a> *&nbsp;</td>
          <td class="paramname"> <em>reginfo</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>newregid</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Create a <a class="el" href="namespacedtn.html" title="Namespace for the dtn daemon source code.">dtn</a> registration. 
<p>
If the init_passive flag in the reginfo struct is true, the registration is initially in passive state, requiring a call to dtn_bind to activate it. Otherwise, the call to dtn_bind is unnecessary as the registration will be created in the active state and bound to the handle. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00147">147</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8h-source.html#l00087">DTN_REGISTER</a>, <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, <a class="el" href="dtn__ipc_8c-source.html#l00294">dtnipc_recv()</a>, <a class="el" href="dtn__ipc_8c-source.html#l00233">dtnipc_send()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__ipc_8h-source.html#l00073">dtnipc_handle::xdr_decode</a>, <a class="el" href="dtn__types_8h.html#9fa23bbd89d3ddf6df49a4fae6ebf28e">xdr_dtn_reg_id_t()</a>, <a class="el" href="dtn__types_8h.html#b71cd0713a2f102c11345bb032ee09d3">xdr_dtn_reg_info_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07666">_wrap_dtn_register()</a>, <a class="el" href="TcaController_8cc-source.html#l00128">TcaController::dtn_reg()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00106">dtn_register()</a>, <a class="el" href="dtntest_8cc-source.html#l00186">DTNRegisterCommand::exec()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00224">dtntunnel::DTNTunnel::init_registration()</a>, <a class="el" href="dtncp_8c-source.html#l00053">main()</a>, <a class="el" href="dtncat_8c-source.html#l00602">make_registration()</a>, <a class="el" href="dtnmoteproxy_8c-source.html#l00165">reader_thread()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07405">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="3996e6553cb38f6cf857b512492b14e2"></a><!-- doxytag: member="dtn_api.h::dtn_send" ref="3996e6553cb38f6cf857b512492b14e2" args="(dtn_handle_t handle, dtn_reg_id_t regid, dtn_bundle_spec_t *spec, dtn_bundle_payload_t *payload, dtn_bundle_id_t *id)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_send           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a>&nbsp;</td>
          <td class="paramname"> <em>regid</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__bundle__spec__t.html">dtn_bundle_spec_t</a> *&nbsp;</td>
          <td class="paramname"> <em>spec</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__bundle__payload__t.html">dtn_bundle_payload_t</a> *&nbsp;</td>
          <td class="paramname"> <em>payload</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__bundle__id__t.html">dtn_bundle_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>id</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Send a bundle either from memory or from a file. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00359">359</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8h-source.html#l00093">DTN_SEND</a>, <a class="el" href="dtn__ipc_8c-source.html#l00361">dtnipc_send_recv()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__ipc_8h-source.html#l00073">dtnipc_handle::xdr_decode</a>, <a class="el" href="dtn__types_8h.html#c51906327f0c0e0571243a5dceffc0af">xdr_dtn_bundle_id_t()</a>, <a class="el" href="dtn__types_8h.html#52d9e9ef1e11bf39693baced9c591d67">xdr_dtn_bundle_payload_t()</a>, <a class="el" href="dtn__types_8h.html#54a4fbc50daeb79cc615af82793cbdc8">xdr_dtn_bundle_spec_t()</a>, <a class="el" href="dtn__types_8h.html#9fa23bbd89d3ddf6df49a4fae6ebf28e">xdr_dtn_reg_id_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l08195">_wrap_dtn_send__SWIG_0()</a>, <a class="el" href="dtn__api__wrap__python_8cc-source.html#l08358">_wrap_dtn_send__SWIG_1()</a>, <a class="el" href="dtn__api__wrap__python_8cc-source.html#l08505">_wrap_dtn_send__SWIG_2()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00205">dtn_send()</a>, <a class="el" href="dtntest_8cc-source.html#l00395">DTNSendCommand::exec()</a>, <a class="el" href="dtncp_8c-source.html#l00053">main()</a>, <a class="el" href="dtnmoteproxy_8c-source.html#l00165">reader_thread()</a>, <a class="el" href="TcaController_8cc-source.html#l00863">TcaController::send_bundle()</a>, <a class="el" href="DTNTunnel_8cc-source.html#l00298">dtntunnel::DTNTunnel::send_bundle()</a>, <a class="el" href="dtncat_8c-source.html#l00257">to_bundles()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l08008">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="74afc602b7d95c9b6ed1f03c351691b3"></a><!-- doxytag: member="dtn_api.h::dtn_session_update" ref="74afc602b7d95c9b6ed1f03c351691b3" args="(dtn_handle_t handle, unsigned int *status, dtn_endpoint_id_t *session, dtn_timeval_t timeout)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_session_update           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int *&nbsp;</td>
          <td class="paramname"> <em>status</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structdtn__endpoint__id__t.html">dtn_endpoint_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>session</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#8865a20f2e713bb38e35736e32e1653c">dtn_timeval_t</a>&nbsp;</td>
          <td class="paramname"> <em>timeout</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Blocking query for new subscribers on a session. 
<p>
One or more registrations must have been bound to the handle with the SESSION_CUSTODY flag set. Returns an indication that the subscription state in the given session has changed (i.e. a subscriber was added or removed). 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00545">545</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8h-source.html#l00098">DTN_SESSION_UPDATE</a>, <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, <a class="el" href="dtn__ipc_8c-source.html#l00294">dtnipc_recv()</a>, <a class="el" href="dtn__ipc_8c-source.html#l00361">dtnipc_send_recv()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__ipc_8h-source.html#l00073">dtnipc_handle::xdr_decode</a>, <a class="el" href="dtn__types_8h.html#16c5a6f4fcdc988f54f034bb1961b342">xdr_dtn_endpoint_id_t()</a>, <a class="el" href="dtn__types_8h.html#62ea0edc92ab755946bef6dcfaf1f611">xdr_dtn_timeval_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l10719">_wrap_dtn_session_update()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00422">dtn_session_update()</a>, <a class="el" href="dtntest_8cc-source.html#l00724">DTNSessionUpdateCommand::exec()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l11116">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="e87d5715259043c2490d71b80dd78f81"></a><!-- doxytag: member="dtn_api.h::dtn_set_errno" ref="e87d5715259043c2490d71b80dd78f81" args="(dtn_handle_t handle, int err)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void dtn_set_errno           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>err</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Set the error associated with the given handle. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00081">81</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap_8cc-source.html#l00339">dtn_recv()</a>, and <a class="el" href="dtn__api__wrap_8cc-source.html#l00205">dtn_send()</a>.</p>

</div>
</div><p>
<a class="anchor" name="21b6d705673aae970524972aca3db99f"></a><!-- doxytag: member="dtn_api.h::dtn_set_payload" ref="21b6d705673aae970524972aca3db99f" args="(dtn_bundle_payload_t *payload, dtn_bundle_payload_location_t location, char *val, int len)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_set_payload           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structdtn__bundle__payload__t.html">dtn_bundle_payload_t</a> *&nbsp;</td>
          <td class="paramname"> <em>payload</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#3dcfddc1b850a71a18d8a0868f67e762">dtn_bundle_payload_location_t</a>&nbsp;</td>
          <td class="paramname"> <em>location</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&nbsp;</td>
          <td class="paramname"> <em>val</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>len</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Sets the value of the given payload structure to either a memory buffer or a file location. 
<p>
Returns: 0 on success, DTN_ESIZE if the memory location is selected and the payload is too big. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00708">708</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="structdtn__bundle__payload__t.html#04e8c46c5b40f187e1fefed80853cc5c">dtn_bundle_payload_t::buf</a>, <a class="el" href="dtn__types_8h-source.html#l00378">dtn_bundle_payload_t::buf_len</a>, <a class="el" href="dtn__types_8h-source.html#l00379">dtn_bundle_payload_t::buf_val</a>, <a class="el" href="dtn__errno_8h-source.html#l00034">DTN_ESIZE</a>, <a class="el" href="dtn__types_8h-source.html#l00052">DTN_MAX_BUNDLE_MEM</a>, <a class="el" href="dtn__types_8h-source.html#l00365">DTN_PAYLOAD_FILE</a>, <a class="el" href="dtn__types_8h-source.html#l00366">DTN_PAYLOAD_MEM</a>, <a class="el" href="dtn__types_8h-source.html#l00367">DTN_PAYLOAD_TEMP_FILE</a>, <a class="el" href="structdtn__bundle__payload__t.html#f3a33fd2ae2b3b8eae2e675f1a038cec">dtn_bundle_payload_t::filename</a>, <a class="el" href="dtn__types_8h-source.html#l00374">dtn_bundle_payload_t::filename_len</a>, <a class="el" href="dtn__types_8h-source.html#l00375">dtn_bundle_payload_t::filename_val</a>, and <a class="el" href="dtn__types_8h-source.html#l00372">dtn_bundle_payload_t::location</a>.</p>

<p>Referenced by <a class="el" href="dtntest_8cc-source.html#l00395">DTNSendCommand::exec()</a>, <a class="el" href="dtncat_8c-source.html#l00576">fill_payload()</a>, <a class="el" href="dtncp_8c-source.html#l00053">main()</a>, <a class="el" href="dtnmoteproxy_8c-source.html#l00165">reader_thread()</a>, <a class="el" href="TcaController_8cc-source.html#l00863">TcaController::send_bundle()</a>, and <a class="el" href="DTNTunnel_8cc-source.html#l00298">dtntunnel::DTNTunnel::send_bundle()</a>.</p>

</div>
</div><p>
<a class="anchor" name="15b2dcc9b16beb1b91ead827b4ee2ca5"></a><!-- doxytag: member="dtn_api.h::dtn_status_report_reason_to_str" ref="15b2dcc9b16beb1b91ead827b4ee2ca5" args="(dtn_status_report_reason_t err)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const char* dtn_status_report_reason_to_str           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#87e1a70c1e1b7872a0337ed40dc4f134">dtn_status_report_reason_t</a>&nbsp;</td>
          <td class="paramname"> <em>err</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Return a string version of a status report reason code. 
<p>

<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00743">743</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__types_8h-source.html#l00309">REASON_BLOCK_UNINTELLIGIBLE</a>, <a class="el" href="dtn__types_8h-source.html#l00305">REASON_DEPLETED_STORAGE</a>, <a class="el" href="dtn__types_8h-source.html#l00306">REASON_ENDPOINT_ID_UNINTELLIGIBLE</a>, <a class="el" href="dtn__types_8h-source.html#l00303">REASON_FORWARDED_UNIDIR_LINK</a>, <a class="el" href="dtn__types_8h-source.html#l00302">REASON_LIFETIME_EXPIRED</a>, <a class="el" href="dtn__types_8h-source.html#l00301">REASON_NO_ADDTL_INFO</a>, <a class="el" href="dtn__types_8h-source.html#l00307">REASON_NO_ROUTE_TO_DEST</a>, <a class="el" href="dtn__types_8h-source.html#l00308">REASON_NO_TIMELY_CONTACT</a>, and <a class="el" href="dtn__types_8h-source.html#l00304">REASON_TRANSMISSION_CANCELLED</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l09708">_wrap_dtn_status_report_reason_to_str()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00315">dtn_status_report_reason_to_str()</a>, <a class="el" href="dtnping_8c-source.html#l00055">main()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l09902">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="919dd7d4475d6d7bcedfbdfb1d129f6c"></a><!-- doxytag: member="dtn_api.h::dtn_unbind" ref="919dd7d4475d6d7bcedfbdfb1d129f6c" args="(dtn_handle_t handle, dtn_reg_id_t regid)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_unbind           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a>&nbsp;</td>
          <td class="paramname"> <em>regid</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Explicitly remove an association from the current ipc handle. 
<p>
Note that this is also implicitly done when the handle is closed.<p>
This serves to put the registration back in "passive" mode. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00332">332</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__ipc_8h-source.html#l00092">DTN_UNBIND</a>, <a class="el" href="dtn__ipc_8c-source.html#l00361">dtnipc_send_recv()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__types_8h.html#9fa23bbd89d3ddf6df49a4fae6ebf28e">xdr_dtn_reg_id_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07953">_wrap_dtn_unbind()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00189">dtn_unbind()</a>, <a class="el" href="dtntest_8cc-source.html#l00546">DTNUnbindCommand::exec()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07718">XS()</a>.</p>

</div>
</div><p>
<a class="anchor" name="35bfbe9258dacb87a17580fb3e73416a"></a><!-- doxytag: member="dtn_api.h::dtn_unregister" ref="35bfbe9258dacb87a17580fb3e73416a" args="(dtn_handle_t handle, dtn_reg_id_t regid)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int dtn_unregister           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="dtn__api_8h.html#566289d829b69370d7635c21364bfe18">dtn_handle_t</a>&nbsp;</td>
          <td class="paramname"> <em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="dtn__types_8h.html#d9378ff6ab7ee699568e037a8105f9b6">dtn_reg_id_t</a>&nbsp;</td>
          <td class="paramname"> <em>regid</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Remove a <a class="el" href="namespacedtn.html" title="Namespace for the dtn daemon source code.">dtn</a> registration. 
<p>
If the registration is in the passive state (i.e. not bound to any handle), it is immediately removed from the system. If it is in active state and bound to the given handle, the removal is deferred until the handle unbinds the registration or closes. This allows applications to pre-emptively call unregister so they don't leak registrations. 
<p>Definition at line <a class="el" href="dtn__api_8c-source.html#l00195">195</a> of file <a class="el" href="dtn__api_8c-source.html">dtn_api.c</a>.</p>

<p>References <a class="el" href="dtn__errno_8h-source.html#l00037">DTN_EINPOLL</a>, <a class="el" href="dtn__errno_8h-source.html#l00030">DTN_EXDR</a>, <a class="el" href="dtn__errno_8h-source.html#l00027">DTN_SUCCESS</a>, <a class="el" href="dtn__ipc_8h-source.html#l00088">DTN_UNREGISTER</a>, <a class="el" href="dtn__ipc_8c-source.html#l00294">dtnipc_recv()</a>, <a class="el" href="dtn__ipc_8c-source.html#l00233">dtnipc_send()</a>, <a class="el" href="dtn__ipc_8h-source.html#l00068">dtnipc_handle::err</a>, <a class="el" href="dtncat_8c-source.html#l00095">handle</a>, <a class="el" href="dtn__ipc_8h-source.html#l00069">dtnipc_handle::in_poll</a>, <a class="el" href="dtn__types_8h.html#9fa23bbd89d3ddf6df49a4fae6ebf28e">xdr_dtn_reg_id_t()</a>, and <a class="el" href="dtn__ipc_8h-source.html#l00072">dtnipc_handle::xdr_encode</a>.</p>

<p>Referenced by <a class="el" href="dtn__api__wrap__python_8cc-source.html#l07747">_wrap_dtn_unregister()</a>, <a class="el" href="dtn__api__wrap_8cc-source.html#l00130">dtn_unregister()</a>, <a class="el" href="dtntest_8cc-source.html#l00252">DTNUnregisterCommand::exec()</a>, <a class="el" href="dtnrecv_8c-source.html#l00355">main()</a>, and <a class="el" href="dtn__api__wrap__perl_8cc-source.html#l07493">XS()</a>.</p>

</div>
</div><p>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Fri Jan 30 09:26:59 2009 for DTN Reference Implementation by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.8 </small></address>
</body>
</html>