classgrpc_1_1internal_1_1_async_writer_interface.html 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
  5. <meta http-equiv="X-UA-Compatible" content="IE=9"/>
  6. <meta name="generator" content="Doxygen 1.8.13"/>
  7. <meta name="viewport" content="width=device-width, initial-scale=1"/>
  8. <title>GRPC C++: grpc::internal::AsyncWriterInterface&lt; W &gt; Class Template Reference</title>
  9. <link href="tabs.css" rel="stylesheet" type="text/css"/>
  10. <script type="text/javascript" src="jquery.js"></script>
  11. <script type="text/javascript" src="dynsections.js"></script>
  12. <link href="search/search.css" rel="stylesheet" type="text/css"/>
  13. <script type="text/javascript" src="search/searchdata.js"></script>
  14. <script type="text/javascript" src="search/search.js"></script>
  15. <link href="doxygen.css" rel="stylesheet" type="text/css" />
  16. <script type="text/javascript"> (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) })(window,document,'script','//www.google-analytics.com/analytics.js','ga'); ga('create', 'UA-60127042-1', 'auto'); ga('send', 'pageview'); </script></head>
  17. <body>
  18. <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
  19. <div id="titlearea">
  20. <table cellspacing="0" cellpadding="0">
  21. <tbody>
  22. <tr style="height: 56px;">
  23. <td id="projectalign" style="padding-left: 0.5em;">
  24. <div id="projectname">GRPC C++
  25. &#160;<span id="projectnumber">1.13.0-dev</span>
  26. </div>
  27. </td>
  28. </tr>
  29. </tbody>
  30. </table>
  31. </div>
  32. <!-- end header part -->
  33. <!-- Generated by Doxygen 1.8.13 -->
  34. <script type="text/javascript">
  35. var searchBox = new SearchBox("searchBox", "search",false,'Search');
  36. </script>
  37. <script type="text/javascript" src="menudata.js"></script>
  38. <script type="text/javascript" src="menu.js"></script>
  39. <script type="text/javascript">
  40. $(function() {
  41. initMenu('',true,false,'search.php','Search');
  42. $(document).ready(function() { init_search(); });
  43. });
  44. </script>
  45. <div id="main-nav"></div>
  46. <!-- window showing the filter options -->
  47. <div id="MSearchSelectWindow"
  48. onmouseover="return searchBox.OnSearchSelectShow()"
  49. onmouseout="return searchBox.OnSearchSelectHide()"
  50. onkeydown="return searchBox.OnSearchSelectKey(event)">
  51. </div>
  52. <!-- iframe showing the search results (closed by default) -->
  53. <div id="MSearchResultsWindow">
  54. <iframe src="javascript:void(0)" frameborder="0"
  55. name="MSearchResults" id="MSearchResults">
  56. </iframe>
  57. </div>
  58. <div id="nav-path" class="navpath">
  59. <ul>
  60. <li class="navelem"><a class="el" href="namespacegrpc.html">grpc</a></li><li class="navelem"><a class="el" href="namespacegrpc_1_1internal.html">internal</a></li><li class="navelem"><a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html">AsyncWriterInterface</a></li> </ul>
  61. </div>
  62. </div><!-- top -->
  63. <div class="header">
  64. <div class="summary">
  65. <a href="#pub-methods">Public Member Functions</a> </div>
  66. <div class="headertitle">
  67. <div class="title">grpc::internal::AsyncWriterInterface&lt; W &gt; Class Template Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div> </div>
  68. </div><!--header-->
  69. <div class="contents">
  70. <p>An interface that can be fed a sequence of messages of type <em>W</em>.
  71. <a href="classgrpc_1_1internal_1_1_async_writer_interface.html#details">More...</a></p>
  72. <p><code>#include &lt;<a class="el" href="grpcpp_2impl_2codegen_2async__stream_8h_source.html">async_stream.h</a>&gt;</code></p>
  73. <table class="memberdecls">
  74. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
  75. Public Member Functions</h2></td></tr>
  76. <tr class="memitem:a8ad846091252c112c4db0b41965e5a4c"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html#a8ad846091252c112c4db0b41965e5a4c">~AsyncWriterInterface</a> ()</td></tr>
  77. <tr class="separator:a8ad846091252c112c4db0b41965e5a4c"><td class="memSeparator" colspan="2">&#160;</td></tr>
  78. <tr class="memitem:aa61e21fdfef0a4fb34f595bef767e6a8"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html#aa61e21fdfef0a4fb34f595bef767e6a8">Write</a> (const W &amp;msg, void *tag)=0</td></tr>
  79. <tr class="memdesc:aa61e21fdfef0a4fb34f595bef767e6a8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Request the writing of <em>msg</em> with identifying tag <em>tag</em>. <a href="#aa61e21fdfef0a4fb34f595bef767e6a8">More...</a><br /></td></tr>
  80. <tr class="separator:aa61e21fdfef0a4fb34f595bef767e6a8"><td class="memSeparator" colspan="2">&#160;</td></tr>
  81. <tr class="memitem:a5745991911afa0fb12646a5f79738a0d"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html#a5745991911afa0fb12646a5f79738a0d">Write</a> (const W &amp;msg, <a class="el" href="classgrpc_1_1_write_options.html">WriteOptions</a> options, void *tag)=0</td></tr>
  82. <tr class="memdesc:a5745991911afa0fb12646a5f79738a0d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Request the writing of <em>msg</em> using <a class="el" href="classgrpc_1_1_write_options.html" title="Per-message write options. ">WriteOptions</a> <em>options</em> with identifying tag <em>tag</em>. <a href="#a5745991911afa0fb12646a5f79738a0d">More...</a><br /></td></tr>
  83. <tr class="separator:a5745991911afa0fb12646a5f79738a0d"><td class="memSeparator" colspan="2">&#160;</td></tr>
  84. <tr class="memitem:a02565abb7c6b4a7a49c0b29159194b66"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html#a02565abb7c6b4a7a49c0b29159194b66">WriteLast</a> (const W &amp;msg, <a class="el" href="classgrpc_1_1_write_options.html">WriteOptions</a> options, void *tag)</td></tr>
  85. <tr class="memdesc:a02565abb7c6b4a7a49c0b29159194b66"><td class="mdescLeft">&#160;</td><td class="mdescRight">Request the writing of <em>msg</em> and coalesce it with the writing of trailing metadata, using <a class="el" href="classgrpc_1_1_write_options.html" title="Per-message write options. ">WriteOptions</a> <em>options</em> with identifying tag <em>tag</em>. <a href="#a02565abb7c6b4a7a49c0b29159194b66">More...</a><br /></td></tr>
  86. <tr class="separator:a02565abb7c6b4a7a49c0b29159194b66"><td class="memSeparator" colspan="2">&#160;</td></tr>
  87. </table>
  88. <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
  89. <div class="textblock"><h3>template&lt;class W&gt;<br />
  90. class grpc::internal::AsyncWriterInterface&lt; W &gt;</h3>
  91. <p>An interface that can be fed a sequence of messages of type <em>W</em>. </p>
  92. </div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
  93. <a id="a8ad846091252c112c4db0b41965e5a4c"></a>
  94. <h2 class="memtitle"><span class="permalink"><a href="#a8ad846091252c112c4db0b41965e5a4c">&#9670;&nbsp;</a></span>~AsyncWriterInterface()</h2>
  95. <div class="memitem">
  96. <div class="memproto">
  97. <div class="memtemplate">
  98. template&lt;class W &gt; </div>
  99. <table class="mlabels">
  100. <tr>
  101. <td class="mlabels-left">
  102. <table class="memname">
  103. <tr>
  104. <td class="memname">virtual <a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html">grpc::internal::AsyncWriterInterface</a>&lt; W &gt;::~<a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html">AsyncWriterInterface</a> </td>
  105. <td>(</td>
  106. <td class="paramname"></td><td>)</td>
  107. <td></td>
  108. </tr>
  109. </table>
  110. </td>
  111. <td class="mlabels-right">
  112. <span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span> </td>
  113. </tr>
  114. </table>
  115. </div><div class="memdoc">
  116. </div>
  117. </div>
  118. <h2 class="groupheader">Member Function Documentation</h2>
  119. <a id="aa61e21fdfef0a4fb34f595bef767e6a8"></a>
  120. <h2 class="memtitle"><span class="permalink"><a href="#aa61e21fdfef0a4fb34f595bef767e6a8">&#9670;&nbsp;</a></span>Write() <span class="overload">[1/2]</span></h2>
  121. <div class="memitem">
  122. <div class="memproto">
  123. <div class="memtemplate">
  124. template&lt;class W &gt; </div>
  125. <table class="mlabels">
  126. <tr>
  127. <td class="mlabels-left">
  128. <table class="memname">
  129. <tr>
  130. <td class="memname">virtual void <a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html">grpc::internal::AsyncWriterInterface</a>&lt; W &gt;::Write </td>
  131. <td>(</td>
  132. <td class="paramtype">const W &amp;&#160;</td>
  133. <td class="paramname"><em>msg</em>, </td>
  134. </tr>
  135. <tr>
  136. <td class="paramkey"></td>
  137. <td></td>
  138. <td class="paramtype">void *&#160;</td>
  139. <td class="paramname"><em>tag</em>&#160;</td>
  140. </tr>
  141. <tr>
  142. <td></td>
  143. <td>)</td>
  144. <td></td><td></td>
  145. </tr>
  146. </table>
  147. </td>
  148. <td class="mlabels-right">
  149. <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
  150. </tr>
  151. </table>
  152. </div><div class="memdoc">
  153. <p>Request the writing of <em>msg</em> with identifying tag <em>tag</em>. </p>
  154. <p>Only one write may be outstanding at any given time. This means that after calling Write, one must wait to receive <em>tag</em> from the completion queue BEFORE calling Write again. This is thread-safe with respect to <em><a class="el" href="classgrpc_1_1internal_1_1_async_reader_interface.html#adf87c602036d69158950b7299d0aae70" title="Read a message of type R into msg. ">AsyncReaderInterface::Read</a></em> </p>
  155. <dl class="params"><dt>Parameters</dt><dd>
  156. <table class="params">
  157. <tr><td class="paramdir">[in]</td><td class="paramname">msg</td><td>The message to be written. </td></tr>
  158. <tr><td class="paramdir">[in]</td><td class="paramname">tag</td><td>The tag identifying the operation. </td></tr>
  159. </table>
  160. </dd>
  161. </dl>
  162. <p>Implemented in <a class="el" href="classgrpc_1_1_server_async_reader_writer.html#a816fd9065473a24d4ab613ee2ecb19e1">grpc::ServerAsyncReaderWriter&lt; W, R &gt;</a>, <a class="el" href="classgrpc_1_1_server_async_writer.html#a467f70c7460ceb7738fb938b3bf93c85">grpc::ServerAsyncWriter&lt; W &gt;</a>, <a class="el" href="classgrpc_1_1_client_async_reader_writer.html#a07bcc3a0737c3bee3ef50def89af5fc7">grpc::ClientAsyncReaderWriter&lt; W, R &gt;</a>, and <a class="el" href="classgrpc_1_1_client_async_writer.html#a0e981b6dcce663e655edf305573f2f30">grpc::ClientAsyncWriter&lt; W &gt;</a>.</p>
  163. </div>
  164. </div>
  165. <a id="a5745991911afa0fb12646a5f79738a0d"></a>
  166. <h2 class="memtitle"><span class="permalink"><a href="#a5745991911afa0fb12646a5f79738a0d">&#9670;&nbsp;</a></span>Write() <span class="overload">[2/2]</span></h2>
  167. <div class="memitem">
  168. <div class="memproto">
  169. <div class="memtemplate">
  170. template&lt;class W &gt; </div>
  171. <table class="mlabels">
  172. <tr>
  173. <td class="mlabels-left">
  174. <table class="memname">
  175. <tr>
  176. <td class="memname">virtual void <a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html">grpc::internal::AsyncWriterInterface</a>&lt; W &gt;::Write </td>
  177. <td>(</td>
  178. <td class="paramtype">const W &amp;&#160;</td>
  179. <td class="paramname"><em>msg</em>, </td>
  180. </tr>
  181. <tr>
  182. <td class="paramkey"></td>
  183. <td></td>
  184. <td class="paramtype"><a class="el" href="classgrpc_1_1_write_options.html">WriteOptions</a>&#160;</td>
  185. <td class="paramname"><em>options</em>, </td>
  186. </tr>
  187. <tr>
  188. <td class="paramkey"></td>
  189. <td></td>
  190. <td class="paramtype">void *&#160;</td>
  191. <td class="paramname"><em>tag</em>&#160;</td>
  192. </tr>
  193. <tr>
  194. <td></td>
  195. <td>)</td>
  196. <td></td><td></td>
  197. </tr>
  198. </table>
  199. </td>
  200. <td class="mlabels-right">
  201. <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
  202. </tr>
  203. </table>
  204. </div><div class="memdoc">
  205. <p>Request the writing of <em>msg</em> using <a class="el" href="classgrpc_1_1_write_options.html" title="Per-message write options. ">WriteOptions</a> <em>options</em> with identifying tag <em>tag</em>. </p>
  206. <p>Only one write may be outstanding at any given time. This means that after calling Write, one must wait to receive <em>tag</em> from the completion queue BEFORE calling Write again. <a class="el" href="classgrpc_1_1_write_options.html" title="Per-message write options. ">WriteOptions</a> <em>options</em> is used to set the write options of this message. This is thread-safe with respect to <em><a class="el" href="classgrpc_1_1internal_1_1_async_reader_interface.html#adf87c602036d69158950b7299d0aae70" title="Read a message of type R into msg. ">AsyncReaderInterface::Read</a></em> </p>
  207. <dl class="params"><dt>Parameters</dt><dd>
  208. <table class="params">
  209. <tr><td class="paramdir">[in]</td><td class="paramname">msg</td><td>The message to be written. </td></tr>
  210. <tr><td class="paramdir">[in]</td><td class="paramname">options</td><td>The <a class="el" href="classgrpc_1_1_write_options.html" title="Per-message write options. ">WriteOptions</a> to be used to write this message. </td></tr>
  211. <tr><td class="paramdir">[in]</td><td class="paramname">tag</td><td>The tag identifying the operation. </td></tr>
  212. </table>
  213. </dd>
  214. </dl>
  215. <p>Implemented in <a class="el" href="classgrpc_1_1_server_async_reader_writer.html#a325a7fa8669c6212f36da5cf59ffb80c">grpc::ServerAsyncReaderWriter&lt; W, R &gt;</a>, <a class="el" href="classgrpc_1_1_server_async_writer.html#a370212343d5044083c218b5ee0fa0057">grpc::ServerAsyncWriter&lt; W &gt;</a>, <a class="el" href="classgrpc_1_1_client_async_reader_writer.html#abcea1a4d9d8f6f1070940b1997fe0125">grpc::ClientAsyncReaderWriter&lt; W, R &gt;</a>, and <a class="el" href="classgrpc_1_1_client_async_writer.html#a3f3d8e3e47b7181f7312fd6e3eb32674">grpc::ClientAsyncWriter&lt; W &gt;</a>.</p>
  216. </div>
  217. </div>
  218. <a id="a02565abb7c6b4a7a49c0b29159194b66"></a>
  219. <h2 class="memtitle"><span class="permalink"><a href="#a02565abb7c6b4a7a49c0b29159194b66">&#9670;&nbsp;</a></span>WriteLast()</h2>
  220. <div class="memitem">
  221. <div class="memproto">
  222. <div class="memtemplate">
  223. template&lt;class W &gt; </div>
  224. <table class="mlabels">
  225. <tr>
  226. <td class="mlabels-left">
  227. <table class="memname">
  228. <tr>
  229. <td class="memname">void <a class="el" href="classgrpc_1_1internal_1_1_async_writer_interface.html">grpc::internal::AsyncWriterInterface</a>&lt; W &gt;::WriteLast </td>
  230. <td>(</td>
  231. <td class="paramtype">const W &amp;&#160;</td>
  232. <td class="paramname"><em>msg</em>, </td>
  233. </tr>
  234. <tr>
  235. <td class="paramkey"></td>
  236. <td></td>
  237. <td class="paramtype"><a class="el" href="classgrpc_1_1_write_options.html">WriteOptions</a>&#160;</td>
  238. <td class="paramname"><em>options</em>, </td>
  239. </tr>
  240. <tr>
  241. <td class="paramkey"></td>
  242. <td></td>
  243. <td class="paramtype">void *&#160;</td>
  244. <td class="paramname"><em>tag</em>&#160;</td>
  245. </tr>
  246. <tr>
  247. <td></td>
  248. <td>)</td>
  249. <td></td><td></td>
  250. </tr>
  251. </table>
  252. </td>
  253. <td class="mlabels-right">
  254. <span class="mlabels"><span class="mlabel">inline</span></span> </td>
  255. </tr>
  256. </table>
  257. </div><div class="memdoc">
  258. <p>Request the writing of <em>msg</em> and coalesce it with the writing of trailing metadata, using <a class="el" href="classgrpc_1_1_write_options.html" title="Per-message write options. ">WriteOptions</a> <em>options</em> with identifying tag <em>tag</em>. </p>
  259. <p>For client, WriteLast is equivalent of performing Write and WritesDone in a single step. For server, WriteLast buffers the <em>msg</em>. The writing of <em>msg</em> is held until Finish is called, where <em>msg</em> and trailing metadata are coalesced and write is initiated. Note that WriteLast can only buffer <em>msg</em> up to the flow control window size. If <em>msg</em> size is larger than the window size, it will be sent on wire without buffering.</p>
  260. <dl class="params"><dt>Parameters</dt><dd>
  261. <table class="params">
  262. <tr><td class="paramdir">[in]</td><td class="paramname">msg</td><td>The message to be written. </td></tr>
  263. <tr><td class="paramdir">[in]</td><td class="paramname">options</td><td>The <a class="el" href="classgrpc_1_1_write_options.html" title="Per-message write options. ">WriteOptions</a> to be used to write this message. </td></tr>
  264. <tr><td class="paramdir">[in]</td><td class="paramname">tag</td><td>The tag identifying the operation. </td></tr>
  265. </table>
  266. </dd>
  267. </dl>
  268. </div>
  269. </div>
  270. <hr/>The documentation for this class was generated from the following file:<ul>
  271. <li>include/grpcpp/impl/codegen/<a class="el" href="grpcpp_2impl_2codegen_2async__stream_8h_source.html">async_stream.h</a></li>
  272. </ul>
  273. </div><!-- contents -->
  274. <!-- start footer part -->
  275. <hr class="footer"/><address class="footer"><small>
  276. Generated on Tue May 15 2018 17:01:01 for GRPC C++ by &#160;<a href="http://www.doxygen.org/index.html">
  277. <img class="footer" src="doxygen.png" alt="doxygen"/>
  278. </a> 1.8.13
  279. </small></address>
  280. </body>
  281. </html>