Sophie

Sophie

distrib > Fedora > 18 > i386 > by-pkgid > 99df56fad12ab23758bed1b8176d3e3d > files > 41

globus-gass-transfer-doc-7.2-9.fc18.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta name="robots" content="noindex">
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<!-- THIS FILE IS AUTOMATICALLY GENERATED FROM THE GLOBUS SOURCE CODE
     DO NOT MODIFY.
-->
<title>Globus Reference Manual</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head>
<body>
<!-- Generated by Doxygen 1.8.3.1 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('group__globus__gass__transfer__data.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#typedef-members">Typedefs</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">Sending and Receiving Data</div>  </div>
</div><!--header-->
<div class="contents">
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
Typedefs</h2></td></tr>
<tr class="memitem:ga53b976e41617d6caba4ed64e05271a62"><td class="memItemLeft" align="right" valign="top">typedef void(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__globus__gass__transfer__data.html#ga53b976e41617d6caba4ed64e05271a62">globus_gass_transfer_bytes_callback_t</a> )(void *arg, <a class="el" href="structglobus__gass__transfer__request__t.html">globus_gass_transfer_request_t</a> request, globus_byte_t *bytes, globus_size_t length, globus_bool_t last_data)</td></tr>
<tr class="separator:ga53b976e41617d6caba4ed64e05271a62"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gaf9fafa443774f59abd5a6584bdeee646"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__globus__gass__transfer__data.html#gaf9fafa443774f59abd5a6584bdeee646">globus_gass_transfer_send_bytes</a> (<a class="el" href="structglobus__gass__transfer__request__t.html">globus_gass_transfer_request_t</a> request, globus_byte_t *bytes, globus_size_t send_length, globus_bool_t last_data, <a class="el" href="group__globus__gass__transfer__data.html#ga53b976e41617d6caba4ed64e05271a62">globus_gass_transfer_bytes_callback_t</a> callback, void *user_arg)</td></tr>
<tr class="separator:gaf9fafa443774f59abd5a6584bdeee646"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gacd7c5a82e0018c76dfce993035a5bf6a"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__globus__gass__transfer__data.html#gacd7c5a82e0018c76dfce993035a5bf6a">globus_gass_transfer_receive_bytes</a> (<a class="el" href="structglobus__gass__transfer__request__t.html">globus_gass_transfer_request_t</a> request, globus_byte_t *bytes, globus_size_t max_length, globus_size_t wait_for_length, <a class="el" href="group__globus__gass__transfer__data.html#ga53b976e41617d6caba4ed64e05271a62">globus_gass_transfer_bytes_callback_t</a> callback, void *user_arg)</td></tr>
<tr class="separator:gacd7c5a82e0018c76dfce993035a5bf6a"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<h2 class="groupheader">Typedef Documentation</h2>
<a class="anchor" id="ga53b976e41617d6caba4ed64e05271a62"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void(*  globus_gass_transfer_bytes_callback_t)(void *arg, <a class="el" href="structglobus__gass__transfer__request__t.html">globus_gass_transfer_request_t</a> request, globus_byte_t *bytes, globus_size_t length, globus_bool_t last_data)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Byte send or receive callback function. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">arg</td><td>The user_arg passed to the function which registered this callback. The user may use this value for any purpose. </td></tr>
    <tr><td class="paramname">request</td><td>The request handle associated with this byte array. </td></tr>
    <tr><td class="paramname">bytes</td><td>The byte array which was sent or received. </td></tr>
    <tr><td class="paramname">length</td><td>The length of data which was sent or received. </td></tr>
    <tr><td class="paramname">last_data</td><td>Boolean flag whether this is the final byte array for this request.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__globus__gass__transfer__data.html#gaf9fafa443774f59abd5a6584bdeee646" title="Send a byte array associated with a request handle.">globus_gass_transfer_send_bytes()</a>, <a class="el" href="group__globus__gass__transfer__data.html#gacd7c5a82e0018c76dfce993035a5bf6a" title="Receive a byte array associated with a request handle.">globus_gass_transfer_receive_bytes()</a> </dd></dl>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="gaf9fafa443774f59abd5a6584bdeee646"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int globus_gass_transfer_send_bytes </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structglobus__gass__transfer__request__t.html">globus_gass_transfer_request_t</a>&#160;</td>
          <td class="paramname"><em>request</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">globus_byte_t *&#160;</td>
          <td class="paramname"><em>bytes</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">globus_size_t&#160;</td>
          <td class="paramname"><em>send_length</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">globus_bool_t&#160;</td>
          <td class="paramname"><em>last_data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__globus__gass__transfer__data.html#ga53b976e41617d6caba4ed64e05271a62">globus_gass_transfer_bytes_callback_t</a>&#160;</td>
          <td class="paramname"><em>callback</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>user_arg</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Send a byte array associated with a request handle. </p>
<p>This function sends a block of data to a server or client as part of the processing for a request. Multiple data blocks may be registered with the GASS transfer library at once.</p>
<p>When processing a server request, this function may only be used in conjunction with "get" requests. The user must call <a class="el" href="group__globus__gass__transfer__server.html#ga068c0c63ed4e2635d273c2f61c823c0b" title="Authorize a request.">globus_gass_transfer_authorize()</a> before calling this function.</p>
<p>When processing a client request, this function may only be used in conjunction with "put" or "append" requests. This function may not be called before either the callback function has been invoked, or the blocking globus_gass_tranfser_put() or <a class="el" href="group__globus__gass__transfer__client.html#ga5055caf41715f0d4a01a3f785fc61440" title="Blocking file append.">globus_gass_transfer_append()</a> function has returned.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">request</td><td>The request handle with which this block of bytes is associated. </td></tr>
    <tr><td class="paramname">bytes</td><td>A user-supplied buffer containing the data associated with the request. </td></tr>
    <tr><td class="paramname">send_length</td><td>The length of the <em>bytes</em> array. </td></tr>
    <tr><td class="paramname">last_data</td><td>A flag to indicate whether this is the final block of data for the request. If this is true, then the <em>callback</em> function will be delayed until the server acknowledges that the file has been completely received. </td></tr>
    <tr><td class="paramname">callback</td><td>Function to call once the <em>bytes</em> array has been sent. </td></tr>
    <tr><td class="paramname">user_arg</td><td>Argument to be passed to the <em>callback</em> function.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">GLOBUS_SUCCESS</td><td>The <em>bytes</em> array was successfully registered with the GASS transfer library. The <em>callback</em> function will be invoked once it has been sent. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_NULL_POINTER</td><td>The <em>bytes</em> or <em>callback</em> parameter was NULL. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_INVALID_USER</td><td>The <em>request</em> was invalid, or it is not one on which bytes can be sent. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_NOT_INITIALIZED</td><td>The callback to a non-blocking file request has not been invoked yet, a blocking file request has not returned, or the request has not yet been authorized. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_REQUEST_FAILED</td><td>The <em>request</em> has failed by either the client, server, or protocol module implementation. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_DONE</td><td>The <em>request</em> has already been completed. </td></tr>
  </table>
  </dd>
</dl>

<p>References <a class="el" href="group__globus__gass__transfer__request.html#gga5602a52b98af47f77e032fcdd913957fa97544dc3720e5c09efd1517b12a396ce">GLOBUS_GASS_TRANSFER_REQUEST_TYPE_APPEND</a>, <a class="el" href="group__globus__gass__transfer__request.html#gga5602a52b98af47f77e032fcdd913957fa83bbfcfb85a560accca8f9745dd9e278">GLOBUS_GASS_TRANSFER_REQUEST_TYPE_GET</a>, and <a class="el" href="group__globus__gass__transfer__request.html#gga5602a52b98af47f77e032fcdd913957fac5675a8c4b950712e27dcec83192e628">GLOBUS_GASS_TRANSFER_REQUEST_TYPE_PUT</a>.</p>

</div>
</div>
<a class="anchor" id="gacd7c5a82e0018c76dfce993035a5bf6a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int globus_gass_transfer_receive_bytes </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structglobus__gass__transfer__request__t.html">globus_gass_transfer_request_t</a>&#160;</td>
          <td class="paramname"><em>request</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">globus_byte_t *&#160;</td>
          <td class="paramname"><em>bytes</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">globus_size_t&#160;</td>
          <td class="paramname"><em>max_length</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">globus_size_t&#160;</td>
          <td class="paramname"><em>wait_for_length</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__globus__gass__transfer__data.html#ga53b976e41617d6caba4ed64e05271a62">globus_gass_transfer_bytes_callback_t</a>&#160;</td>
          <td class="paramname"><em>callback</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>user_arg</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Receive a byte array associated with a request handle. </p>
<p>This function receives a block of data from a server or client as part of the processing for a request. Multiple data blocks may be registered with the GASS transfer library at once.</p>
<p>When processing a server request, this function may only be used in conjunction with "put" or "append" requests. The user must call <a class="el" href="group__globus__gass__transfer__server.html#ga068c0c63ed4e2635d273c2f61c823c0b" title="Authorize a request.">globus_gass_transfer_authorize()</a> before calling this function.</p>
<p>When processing a client request, this function may only be used in conjunction with "get" requests. This function may not be called before either the callback function has been invoked, or the blocking globus_gass_tranfser_put() or <a class="el" href="group__globus__gass__transfer__client.html#ga5055caf41715f0d4a01a3f785fc61440" title="Blocking file append.">globus_gass_transfer_append()</a> function has returned.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">request</td><td>The request handle with which this block of bytes is associated. </td></tr>
    <tr><td class="paramname">bytes</td><td>A user-supplied buffer containing the data associated with the request. </td></tr>
    <tr><td class="paramname">max_length</td><td>The length of the <em>bytes</em> array. </td></tr>
    <tr><td class="paramname">wait_for_length</td><td>The minimum amount of data to wait for before invoking the <em>callback</em> function. A partial byte array of at least this amount will be returned in the callback, unless end-of-file is reached before this amount. </td></tr>
    <tr><td class="paramname">callback</td><td>Function to call once the <em>bytes</em> array has been received. </td></tr>
    <tr><td class="paramname">user_arg</td><td>Argument to be passed to the <em>callback</em> function.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">GLOBUS_SUCCESS</td><td>The <em>bytes</em> array was successfully registered with the GASS transfer library. The <em>callback</em> function will be invoked once it has been received. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_NULL_POINTER</td><td>The <em>bytes</em> or <em>callback</em> parameter was NULL. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_INVALID_USER</td><td>The <em>request</em> was invalid, or it is not one on which bytes can be sent. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_NOT_INITIALIZED</td><td>The callback to a non-blocking file request has not been invoked yet, a blocking file request has not returned, or the request has not yet been authorized. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_REQUEST_FAILED</td><td>The <em>request</em> has failed by either the client, server, or protocol module implementation. </td></tr>
    <tr><td class="paramname">GLOBUS_GASS_TRANSFER_ERROR_DONE</td><td>The <em>request</em> has already been completed. </td></tr>
  </table>
  </dd>
</dl>

<p>References <a class="el" href="group__globus__gass__transfer__request.html#gga5602a52b98af47f77e032fcdd913957fa97544dc3720e5c09efd1517b12a396ce">GLOBUS_GASS_TRANSFER_REQUEST_TYPE_APPEND</a>, <a class="el" href="group__globus__gass__transfer__request.html#gga5602a52b98af47f77e032fcdd913957fa83bbfcfb85a560accca8f9745dd9e278">GLOBUS_GASS_TRANSFER_REQUEST_TYPE_GET</a>, and <a class="el" href="group__globus__gass__transfer__request.html#gga5602a52b98af47f77e032fcdd913957fac5675a8c4b950712e27dcec83192e628">GLOBUS_GASS_TRANSFER_REQUEST_TYPE_PUT</a>.</p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<hr>
<p align="center">
<a href="http://www.globus.org/toolkit/about.html" target="_top">about globus</a> |
<a href="http://www.globus.org/toolkit/" target="_top">globus toolkit</a> |
<a href="https://dev.globus.org/wiki/Welcome/" target="_top">dev.globus</a>
<br>
<br>
Comments? <a href="mailto:webmaster@globus.org">webmaster@globus.org</a>
</body>
</html>