grpc.framework.face.html 97 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468
  1. <!DOCTYPE html>
  2. <!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
  3. <!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
  4. <head>
  5. <meta charset="utf-8">
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <title>grpc.framework.face package &mdash; grpcio 0.10.0a0 documentation</title>
  8. <link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
  9. <link rel="top" title="grpcio 0.10.0a0 documentation" href="index.html"/>
  10. <link rel="up" title="grpc.framework package" href="grpc.framework.html"/>
  11. <link rel="next" title="grpc.framework.face.testing package" href="grpc.framework.face.testing.html"/>
  12. <link rel="prev" title="grpc.framework.common package" href="grpc.framework.common.html"/>
  13. <script src="_static/js/modernizr.min.js"></script>
  14. </head>
  15. <body class="wy-body-for-nav" role="document">
  16. <div class="wy-grid-for-nav">
  17. <nav data-toggle="wy-nav-shift" class="wy-nav-side">
  18. <div class="wy-side-nav-search">
  19. <a href="index.html" class="icon icon-home"> grpcio
  20. </a>
  21. <div role="search">
  22. <form id="rtd-search-form" class="wy-form" action="search.html" method="get">
  23. <input type="text" name="q" placeholder="Search docs" />
  24. <input type="hidden" name="check_keywords" value="yes" />
  25. <input type="hidden" name="area" value="default" />
  26. </form>
  27. </div>
  28. </div>
  29. <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
  30. <ul class="current">
  31. <li class="toctree-l1 current"><a class="reference internal" href="grpc.html">grpc package</a><ul class="current">
  32. <li class="toctree-l2 current"><a class="reference internal" href="grpc.html#subpackages">Subpackages</a><ul class="current">
  33. <li class="toctree-l3"><a class="reference internal" href="grpc.early_adopter.html">grpc.early_adopter package</a><ul>
  34. <li class="toctree-l4"><a class="reference internal" href="grpc.early_adopter.html#submodules">Submodules</a></li>
  35. <li class="toctree-l4"><a class="reference internal" href="grpc.early_adopter.html#module-grpc.early_adopter.implementations">grpc.early_adopter.implementations module</a></li>
  36. <li class="toctree-l4"><a class="reference internal" href="grpc.early_adopter.html#module-grpc.early_adopter.implementations_test">grpc.early_adopter.implementations_test module</a></li>
  37. <li class="toctree-l4"><a class="reference internal" href="grpc.early_adopter.html#module-grpc.early_adopter">Module contents</a></li>
  38. </ul>
  39. </li>
  40. <li class="toctree-l3 current"><a class="reference internal" href="grpc.framework.html">grpc.framework package</a><ul class="current">
  41. <li class="toctree-l4 current"><a class="reference internal" href="grpc.framework.html#subpackages">Subpackages</a></li>
  42. <li class="toctree-l4"><a class="reference internal" href="grpc.framework.html#module-grpc.framework">Module contents</a></li>
  43. </ul>
  44. </li>
  45. </ul>
  46. </li>
  47. <li class="toctree-l2"><a class="reference internal" href="grpc.html#module-grpc">Module contents</a></li>
  48. </ul>
  49. </li>
  50. </ul>
  51. </div>
  52. &nbsp;
  53. </nav>
  54. <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
  55. <nav class="wy-nav-top" role="navigation" aria-label="top navigation">
  56. <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
  57. <a href="index.html">grpcio</a>
  58. </nav>
  59. <div class="wy-nav-content">
  60. <div class="rst-content">
  61. <div role="navigation" aria-label="breadcrumbs navigation">
  62. <ul class="wy-breadcrumbs">
  63. <li><a href="index.html">Docs</a> &raquo;</li>
  64. <li><a href="grpc.html">grpc package</a> &raquo;</li>
  65. <li><a href="grpc.framework.html">grpc.framework package</a> &raquo;</li>
  66. <li>grpc.framework.face package</li>
  67. <li class="wy-breadcrumbs-aside">
  68. <a href="_sources/grpc.framework.face.txt" rel="nofollow"> View page source</a>
  69. </li>
  70. </ul>
  71. <hr/>
  72. </div>
  73. <div role="main" class="document">
  74. <div class="section" id="grpc-framework-face-package">
  75. <h1>grpc.framework.face package<a class="headerlink" href="#grpc-framework-face-package" title="Permalink to this headline">¶</a></h1>
  76. <div class="section" id="subpackages">
  77. <h2>Subpackages<a class="headerlink" href="#subpackages" title="Permalink to this headline">¶</a></h2>
  78. <div class="toctree-wrapper compound">
  79. <ul>
  80. <li class="toctree-l1"><a class="reference internal" href="grpc.framework.face.testing.html">grpc.framework.face.testing package</a><ul>
  81. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#submodules">Submodules</a></li>
  82. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.base_util">grpc.framework.face.testing.base_util module</a></li>
  83. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.blocking_invocation_inline_service_test_case">grpc.framework.face.testing.blocking_invocation_inline_service_test_case module</a></li>
  84. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.callback">grpc.framework.face.testing.callback module</a></li>
  85. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.control">grpc.framework.face.testing.control module</a></li>
  86. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.coverage">grpc.framework.face.testing.coverage module</a></li>
  87. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.digest">grpc.framework.face.testing.digest module</a></li>
  88. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.event_invocation_synchronous_event_service_test_case">grpc.framework.face.testing.event_invocation_synchronous_event_service_test_case module</a></li>
  89. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.future_invocation_asynchronous_event_service_test_case">grpc.framework.face.testing.future_invocation_asynchronous_event_service_test_case module</a></li>
  90. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.interfaces">grpc.framework.face.testing.interfaces module</a></li>
  91. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.serial">grpc.framework.face.testing.serial module</a></li>
  92. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.service">grpc.framework.face.testing.service module</a></li>
  93. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.stock_service">grpc.framework.face.testing.stock_service module</a></li>
  94. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing.test_case">grpc.framework.face.testing.test_case module</a></li>
  95. <li class="toctree-l2"><a class="reference internal" href="grpc.framework.face.testing.html#module-grpc.framework.face.testing">Module contents</a></li>
  96. </ul>
  97. </li>
  98. </ul>
  99. </div>
  100. </div>
  101. <div class="section" id="submodules">
  102. <h2>Submodules<a class="headerlink" href="#submodules" title="Permalink to this headline">¶</a></h2>
  103. </div>
  104. <div class="section" id="module-grpc.framework.face.blocking_invocation_inline_service_test">
  105. <span id="grpc-framework-face-blocking-invocation-inline-service-test-module"></span><h2>grpc.framework.face.blocking_invocation_inline_service_test module<a class="headerlink" href="#module-grpc.framework.face.blocking_invocation_inline_service_test" title="Permalink to this headline">¶</a></h2>
  106. <p>One of the tests of the Face layer of RPC Framework.</p>
  107. <dl class="class">
  108. <dt id="grpc.framework.face.blocking_invocation_inline_service_test.BlockingInvocationInlineServiceTest">
  109. <em class="property">class </em><code class="descclassname">grpc.framework.face.blocking_invocation_inline_service_test.</code><code class="descname">BlockingInvocationInlineServiceTest</code><span class="sig-paren">(</span><em>methodName='runTest'</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/blocking_invocation_inline_service_test.html#BlockingInvocationInlineServiceTest"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.blocking_invocation_inline_service_test.BlockingInvocationInlineServiceTest" title="Permalink to this definition">¶</a></dt>
  110. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face._test_case.FaceTestCase</span></code>, <a class="reference internal" href="grpc.framework.face.testing.html#grpc.framework.face.testing.blocking_invocation_inline_service_test_case.BlockingInvocationInlineServiceTestCase" title="grpc.framework.face.testing.blocking_invocation_inline_service_test_case.BlockingInvocationInlineServiceTestCase"><code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face.testing.blocking_invocation_inline_service_test_case.BlockingInvocationInlineServiceTestCase</span></code></a>, <code class="xref py py-class docutils literal"><span class="pre">unittest.case.TestCase</span></code></p>
  111. </dd></dl>
  112. </div>
  113. <div class="section" id="module-grpc.framework.face.demonstration">
  114. <span id="grpc-framework-face-demonstration-module"></span><h2>grpc.framework.face.demonstration module<a class="headerlink" href="#module-grpc.framework.face.demonstration" title="Permalink to this headline">¶</a></h2>
  115. <p>Demonstration-suitable implementation of the face layer of RPC Framework.</p>
  116. <dl class="class">
  117. <dt id="grpc.framework.face.demonstration.LinkedPair">
  118. <em class="property">class </em><code class="descclassname">grpc.framework.face.demonstration.</code><code class="descname">LinkedPair</code><a class="reference internal" href="_modules/grpc/framework/face/demonstration.html#LinkedPair"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.demonstration.LinkedPair" title="Permalink to this definition">¶</a></dt>
  119. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  120. <p>A Server and Stub that are linked to one another.</p>
  121. <dl class="attribute">
  122. <dt id="grpc.framework.face.demonstration.LinkedPair.server">
  123. <code class="descname">server</code><a class="headerlink" href="#grpc.framework.face.demonstration.LinkedPair.server" title="Permalink to this definition">¶</a></dt>
  124. <dd><p>A Server.</p>
  125. </dd></dl>
  126. <dl class="attribute">
  127. <dt id="grpc.framework.face.demonstration.LinkedPair.stub">
  128. <code class="descname">stub</code><a class="headerlink" href="#grpc.framework.face.demonstration.LinkedPair.stub" title="Permalink to this definition">¶</a></dt>
  129. <dd><p>A Stub.</p>
  130. </dd></dl>
  131. <dl class="method">
  132. <dt id="grpc.framework.face.demonstration.LinkedPair.shut_down">
  133. <code class="descname">shut_down</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/demonstration.html#LinkedPair.shut_down"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.demonstration.LinkedPair.shut_down" title="Permalink to this definition">¶</a></dt>
  134. <dd><p>Shuts down this object and releases its resources.</p>
  135. </dd></dl>
  136. </dd></dl>
  137. <dl class="function">
  138. <dt id="grpc.framework.face.demonstration.server_and_stub">
  139. <code class="descclassname">grpc.framework.face.demonstration.</code><code class="descname">server_and_stub</code><span class="sig-paren">(</span><em>default_timeout</em>, <em>inline_value_in_value_out_methods=None</em>, <em>inline_value_in_stream_out_methods=None</em>, <em>inline_stream_in_value_out_methods=None</em>, <em>inline_stream_in_stream_out_methods=None</em>, <em>event_value_in_value_out_methods=None</em>, <em>event_value_in_stream_out_methods=None</em>, <em>event_stream_in_value_out_methods=None</em>, <em>event_stream_in_stream_out_methods=None</em>, <em>multi_method=None</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/demonstration.html#server_and_stub"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.demonstration.server_and_stub" title="Permalink to this definition">¶</a></dt>
  140. <dd><p>Creates a Server and Stub linked together for use.</p>
  141. </dd></dl>
  142. </div>
  143. <div class="section" id="module-grpc.framework.face.event_invocation_synchronous_event_service_test">
  144. <span id="grpc-framework-face-event-invocation-synchronous-event-service-test-module"></span><h2>grpc.framework.face.event_invocation_synchronous_event_service_test module<a class="headerlink" href="#module-grpc.framework.face.event_invocation_synchronous_event_service_test" title="Permalink to this headline">¶</a></h2>
  145. <p>One of the tests of the Face layer of RPC Framework.</p>
  146. <dl class="class">
  147. <dt id="grpc.framework.face.event_invocation_synchronous_event_service_test.EventInvocationSynchronousEventServiceTest">
  148. <em class="property">class </em><code class="descclassname">grpc.framework.face.event_invocation_synchronous_event_service_test.</code><code class="descname">EventInvocationSynchronousEventServiceTest</code><span class="sig-paren">(</span><em>methodName='runTest'</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/event_invocation_synchronous_event_service_test.html#EventInvocationSynchronousEventServiceTest"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.event_invocation_synchronous_event_service_test.EventInvocationSynchronousEventServiceTest" title="Permalink to this definition">¶</a></dt>
  149. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face._test_case.FaceTestCase</span></code>, <a class="reference internal" href="grpc.framework.face.testing.html#grpc.framework.face.testing.event_invocation_synchronous_event_service_test_case.EventInvocationSynchronousEventServiceTestCase" title="grpc.framework.face.testing.event_invocation_synchronous_event_service_test_case.EventInvocationSynchronousEventServiceTestCase"><code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face.testing.event_invocation_synchronous_event_service_test_case.EventInvocationSynchronousEventServiceTestCase</span></code></a>, <code class="xref py py-class docutils literal"><span class="pre">unittest.case.TestCase</span></code></p>
  150. </dd></dl>
  151. </div>
  152. <div class="section" id="module-grpc.framework.face.exceptions">
  153. <span id="grpc-framework-face-exceptions-module"></span><h2>grpc.framework.face.exceptions module<a class="headerlink" href="#module-grpc.framework.face.exceptions" title="Permalink to this headline">¶</a></h2>
  154. <p>Exceptions used in the Face layer of RPC Framework.</p>
  155. <dl class="exception">
  156. <dt id="grpc.framework.face.exceptions.CancellationError">
  157. <em class="property">exception </em><code class="descclassname">grpc.framework.face.exceptions.</code><code class="descname">CancellationError</code><a class="reference internal" href="_modules/grpc/framework/face/exceptions.html#CancellationError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.exceptions.CancellationError" title="Permalink to this definition">¶</a></dt>
  158. <dd><p>Bases: <a class="reference internal" href="#grpc.framework.face.exceptions.RpcError" title="grpc.framework.face.exceptions.RpcError"><code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face.exceptions.RpcError</span></code></a></p>
  159. <p>Indicates that an RPC has been cancelled.</p>
  160. </dd></dl>
  161. <dl class="exception">
  162. <dt id="grpc.framework.face.exceptions.ExpirationError">
  163. <em class="property">exception </em><code class="descclassname">grpc.framework.face.exceptions.</code><code class="descname">ExpirationError</code><a class="reference internal" href="_modules/grpc/framework/face/exceptions.html#ExpirationError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.exceptions.ExpirationError" title="Permalink to this definition">¶</a></dt>
  164. <dd><p>Bases: <a class="reference internal" href="#grpc.framework.face.exceptions.RpcError" title="grpc.framework.face.exceptions.RpcError"><code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face.exceptions.RpcError</span></code></a></p>
  165. <p>Indicates that an RPC has expired (&#8220;timed out&#8221;).</p>
  166. </dd></dl>
  167. <dl class="exception">
  168. <dt id="grpc.framework.face.exceptions.NetworkError">
  169. <em class="property">exception </em><code class="descclassname">grpc.framework.face.exceptions.</code><code class="descname">NetworkError</code><a class="reference internal" href="_modules/grpc/framework/face/exceptions.html#NetworkError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.exceptions.NetworkError" title="Permalink to this definition">¶</a></dt>
  170. <dd><p>Bases: <a class="reference internal" href="#grpc.framework.face.exceptions.RpcError" title="grpc.framework.face.exceptions.RpcError"><code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face.exceptions.RpcError</span></code></a></p>
  171. <p>Indicates that some error occurred on the network.</p>
  172. </dd></dl>
  173. <dl class="exception">
  174. <dt id="grpc.framework.face.exceptions.NoSuchMethodError">
  175. <em class="property">exception </em><code class="descclassname">grpc.framework.face.exceptions.</code><code class="descname">NoSuchMethodError</code><span class="sig-paren">(</span><em>name</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/exceptions.html#NoSuchMethodError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.exceptions.NoSuchMethodError" title="Permalink to this definition">¶</a></dt>
  176. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">exceptions.Exception</span></code></p>
  177. <p>Raised by customer code to indicate an unrecognized RPC method name.</p>
  178. <dl class="attribute">
  179. <dt id="grpc.framework.face.exceptions.NoSuchMethodError.name">
  180. <code class="descname">name</code><a class="headerlink" href="#grpc.framework.face.exceptions.NoSuchMethodError.name" title="Permalink to this definition">¶</a></dt>
  181. <dd><p>The unrecognized name.</p>
  182. </dd></dl>
  183. </dd></dl>
  184. <dl class="exception">
  185. <dt id="grpc.framework.face.exceptions.RpcError">
  186. <em class="property">exception </em><code class="descclassname">grpc.framework.face.exceptions.</code><code class="descname">RpcError</code><a class="reference internal" href="_modules/grpc/framework/face/exceptions.html#RpcError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.exceptions.RpcError" title="Permalink to this definition">¶</a></dt>
  187. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">exceptions.Exception</span></code></p>
  188. <p>Common super type for all exceptions raised by the Face layer.</p>
  189. <p>Only RPC Framework should instantiate and raise these exceptions.</p>
  190. </dd></dl>
  191. <dl class="exception">
  192. <dt id="grpc.framework.face.exceptions.ServicedError">
  193. <em class="property">exception </em><code class="descclassname">grpc.framework.face.exceptions.</code><code class="descname">ServicedError</code><a class="reference internal" href="_modules/grpc/framework/face/exceptions.html#ServicedError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.exceptions.ServicedError" title="Permalink to this definition">¶</a></dt>
  194. <dd><p>Bases: <a class="reference internal" href="#grpc.framework.face.exceptions.RpcError" title="grpc.framework.face.exceptions.RpcError"><code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face.exceptions.RpcError</span></code></a></p>
  195. <p>Indicates that the Serviced failed in the course of an RPC.</p>
  196. </dd></dl>
  197. <dl class="exception">
  198. <dt id="grpc.framework.face.exceptions.ServicerError">
  199. <em class="property">exception </em><code class="descclassname">grpc.framework.face.exceptions.</code><code class="descname">ServicerError</code><a class="reference internal" href="_modules/grpc/framework/face/exceptions.html#ServicerError"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.exceptions.ServicerError" title="Permalink to this definition">¶</a></dt>
  200. <dd><p>Bases: <a class="reference internal" href="#grpc.framework.face.exceptions.RpcError" title="grpc.framework.face.exceptions.RpcError"><code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face.exceptions.RpcError</span></code></a></p>
  201. <p>Indicates that the Servicer failed in the course of servicing an RPC.</p>
  202. </dd></dl>
  203. </div>
  204. <div class="section" id="module-grpc.framework.face.future_invocation_asynchronous_event_service_test">
  205. <span id="grpc-framework-face-future-invocation-asynchronous-event-service-test-module"></span><h2>grpc.framework.face.future_invocation_asynchronous_event_service_test module<a class="headerlink" href="#module-grpc.framework.face.future_invocation_asynchronous_event_service_test" title="Permalink to this headline">¶</a></h2>
  206. <p>One of the tests of the Face layer of RPC Framework.</p>
  207. <dl class="class">
  208. <dt id="grpc.framework.face.future_invocation_asynchronous_event_service_test.FutureInvocationAsynchronousEventServiceTest">
  209. <em class="property">class </em><code class="descclassname">grpc.framework.face.future_invocation_asynchronous_event_service_test.</code><code class="descname">FutureInvocationAsynchronousEventServiceTest</code><span class="sig-paren">(</span><em>methodName='runTest'</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/future_invocation_asynchronous_event_service_test.html#FutureInvocationAsynchronousEventServiceTest"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.future_invocation_asynchronous_event_service_test.FutureInvocationAsynchronousEventServiceTest" title="Permalink to this definition">¶</a></dt>
  210. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face._test_case.FaceTestCase</span></code>, <a class="reference internal" href="grpc.framework.face.testing.html#grpc.framework.face.testing.future_invocation_asynchronous_event_service_test_case.FutureInvocationAsynchronousEventServiceTestCase" title="grpc.framework.face.testing.future_invocation_asynchronous_event_service_test_case.FutureInvocationAsynchronousEventServiceTestCase"><code class="xref py py-class docutils literal"><span class="pre">grpc.framework.face.testing.future_invocation_asynchronous_event_service_test_case.FutureInvocationAsynchronousEventServiceTestCase</span></code></a>, <code class="xref py py-class docutils literal"><span class="pre">unittest.case.TestCase</span></code></p>
  211. </dd></dl>
  212. </div>
  213. <div class="section" id="module-grpc.framework.face.implementations">
  214. <span id="grpc-framework-face-implementations-module"></span><h2>grpc.framework.face.implementations module<a class="headerlink" href="#module-grpc.framework.face.implementations" title="Permalink to this headline">¶</a></h2>
  215. <p>Entry points into the Face layer of RPC Framework.</p>
  216. <dl class="function">
  217. <dt id="grpc.framework.face.implementations.dynamic_stub">
  218. <code class="descclassname">grpc.framework.face.implementations.</code><code class="descname">dynamic_stub</code><span class="sig-paren">(</span><em>cardinalities</em>, <em>front</em>, <em>pool</em>, <em>prefix</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/implementations.html#dynamic_stub"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.implementations.dynamic_stub" title="Permalink to this definition">¶</a></dt>
  219. <dd><p>Creates an interfaces.DynamicStub.</p>
  220. <table class="docutils field-list" frame="void" rules="none">
  221. <col class="field-name" />
  222. <col class="field-body" />
  223. <tbody valign="top">
  224. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  225. <li><strong>cardinalities</strong> &#8211; A dict from RPC method name to cardinality.Cardinality
  226. value identifying the cardinality of every RPC method to be supported by
  227. the created interfaces.DynamicStub.</li>
  228. <li><strong>front</strong> &#8211; A base_interfaces.Front.</li>
  229. <li><strong>pool</strong> &#8211; A futures.ThreadPoolExecutor.</li>
  230. <li><strong>prefix</strong> &#8211; A string to prepend when mapping requested attribute name to RPC
  231. method name during attribute access on the created
  232. interfaces.DynamicStub.</li>
  233. </ul>
  234. </td>
  235. </tr>
  236. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">An interfaces.DynamicStub that performs RPCs via the given
  237. base_interfaces.Front.</p>
  238. </td>
  239. </tr>
  240. </tbody>
  241. </table>
  242. </dd></dl>
  243. <dl class="function">
  244. <dt id="grpc.framework.face.implementations.generic_stub">
  245. <code class="descclassname">grpc.framework.face.implementations.</code><code class="descname">generic_stub</code><span class="sig-paren">(</span><em>front</em>, <em>pool</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/implementations.html#generic_stub"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.implementations.generic_stub" title="Permalink to this definition">¶</a></dt>
  246. <dd><p>Creates an interfaces.GenericStub.</p>
  247. <table class="docutils field-list" frame="void" rules="none">
  248. <col class="field-name" />
  249. <col class="field-body" />
  250. <tbody valign="top">
  251. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  252. <li><strong>front</strong> &#8211; A base_interfaces.Front.</li>
  253. <li><strong>pool</strong> &#8211; A futures.ThreadPoolExecutor.</li>
  254. </ul>
  255. </td>
  256. </tr>
  257. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">An interfaces.GenericStub that performs RPCs via the given
  258. base_interfaces.Front.</p>
  259. </td>
  260. </tr>
  261. </tbody>
  262. </table>
  263. </dd></dl>
  264. <dl class="function">
  265. <dt id="grpc.framework.face.implementations.servicer">
  266. <code class="descclassname">grpc.framework.face.implementations.</code><code class="descname">servicer</code><span class="sig-paren">(</span><em>pool</em>, <em>method_implementations</em>, <em>multi_method_implementation</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/implementations.html#servicer"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.implementations.servicer" title="Permalink to this definition">¶</a></dt>
  267. <dd><p>Creates a base_interfaces.Servicer.</p>
  268. <p>It is guaranteed that any passed interfaces.MultiMethodImplementation will
  269. only be called to service an RPC if there is no
  270. interfaces.MethodImplementation for the RPC method in the passed
  271. method_implementations dictionary.</p>
  272. <table class="docutils field-list" frame="void" rules="none">
  273. <col class="field-name" />
  274. <col class="field-body" />
  275. <tbody valign="top">
  276. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  277. <li><strong>pool</strong> &#8211; A thread pool.</li>
  278. <li><strong>method_implementations</strong> &#8211; A dictionary from RPC method name to
  279. interfaces.MethodImplementation object to be used to service the named
  280. RPC method.</li>
  281. <li><strong>multi_method_implementation</strong> &#8211; An interfaces.MultiMethodImplementation to be
  282. used to service any RPCs not serviced by the
  283. interfaces.MethodImplementations given in the method_implementations
  284. dictionary, or None.</li>
  285. </ul>
  286. </td>
  287. </tr>
  288. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A base_interfaces.Servicer that services RPCs via the given implementations.</p>
  289. </td>
  290. </tr>
  291. </tbody>
  292. </table>
  293. </dd></dl>
  294. </div>
  295. <div class="section" id="module-grpc.framework.face.interfaces">
  296. <span id="grpc-framework-face-interfaces-module"></span><h2>grpc.framework.face.interfaces module<a class="headerlink" href="#module-grpc.framework.face.interfaces" title="Permalink to this headline">¶</a></h2>
  297. <p>Interfaces for the face layer of RPC Framework.</p>
  298. <dl class="class">
  299. <dt id="grpc.framework.face.interfaces.Abortion">
  300. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">Abortion</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#Abortion"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.Abortion" title="Permalink to this definition">¶</a></dt>
  301. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">enum.Enum</span></code></p>
  302. <p>Categories of RPC abortion.</p>
  303. </dd></dl>
  304. <dl class="class">
  305. <dt id="grpc.framework.face.interfaces.Call">
  306. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">Call</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#Call"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.Call" title="Permalink to this definition">¶</a></dt>
  307. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  308. <p>Invocation-side representation of an RPC.</p>
  309. <dl class="attribute">
  310. <dt id="grpc.framework.face.interfaces.Call.context">
  311. <code class="descname">context</code><a class="headerlink" href="#grpc.framework.face.interfaces.Call.context" title="Permalink to this definition">¶</a></dt>
  312. <dd><p>An RpcContext affording information about the RPC.</p>
  313. </dd></dl>
  314. <dl class="method">
  315. <dt id="grpc.framework.face.interfaces.Call.cancel">
  316. <code class="descname">cancel</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#Call.cancel"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.Call.cancel" title="Permalink to this definition">¶</a></dt>
  317. <dd><p>Requests cancellation of the RPC.</p>
  318. </dd></dl>
  319. </dd></dl>
  320. <dl class="class">
  321. <dt id="grpc.framework.face.interfaces.CancellableIterator">
  322. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">CancellableIterator</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#CancellableIterator"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.CancellableIterator" title="Permalink to this definition">¶</a></dt>
  323. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  324. <p>Implements the Iterator protocol and affords a cancel method.</p>
  325. <dl class="method">
  326. <dt id="grpc.framework.face.interfaces.CancellableIterator.__iter__">
  327. <code class="descname">__iter__</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#CancellableIterator.__iter__"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.CancellableIterator.__iter__" title="Permalink to this definition">¶</a></dt>
  328. <dd><p>Returns the self object in accordance with the Iterator protocol.</p>
  329. </dd></dl>
  330. <dl class="method">
  331. <dt id="grpc.framework.face.interfaces.CancellableIterator.cancel">
  332. <code class="descname">cancel</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#CancellableIterator.cancel"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.CancellableIterator.cancel" title="Permalink to this definition">¶</a></dt>
  333. <dd><p>Requests cancellation of whatever computation underlies this iterator.</p>
  334. </dd></dl>
  335. <dl class="method">
  336. <dt id="grpc.framework.face.interfaces.CancellableIterator.next">
  337. <code class="descname">next</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#CancellableIterator.next"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.CancellableIterator.next" title="Permalink to this definition">¶</a></dt>
  338. <dd><p>Returns a value or raises StopIteration per the Iterator protocol.</p>
  339. </dd></dl>
  340. </dd></dl>
  341. <dl class="class">
  342. <dt id="grpc.framework.face.interfaces.DynamicStub">
  343. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">DynamicStub</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#DynamicStub"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.DynamicStub" title="Permalink to this definition">¶</a></dt>
  344. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  345. <p>A stub with RPC-method-bound multi-callable attributes.</p>
  346. <p>Instances of this type responsd to attribute access as follows: if the
  347. requested attribute is the name of a unary-unary RPC method, the value of the
  348. attribute will be a UnaryUnaryMultiCallable with which to invoke the RPC
  349. method; if the requested attribute is the name of a unary-stream RPC method,
  350. the value of the attribute will be a UnaryStreamMultiCallable with which to
  351. invoke the RPC method; if the requested attribute is the name of a
  352. stream-unary RPC method, the value of the attribute will be a
  353. StreamUnaryMultiCallable with which to invoke the RPC method; and if the
  354. requested attribute is the name of a stream-stream RPC method, the value of
  355. the attribute will be a StreamStreamMultiCallable with which to invoke the
  356. RPC method.</p>
  357. </dd></dl>
  358. <dl class="class">
  359. <dt id="grpc.framework.face.interfaces.GenericStub">
  360. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">GenericStub</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub" title="Permalink to this definition">¶</a></dt>
  361. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  362. <p>Affords RPC methods to callers.</p>
  363. <dl class="method">
  364. <dt id="grpc.framework.face.interfaces.GenericStub.blocking_stream_in_value_out">
  365. <code class="descname">blocking_stream_in_value_out</code><span class="sig-paren">(</span><em>name</em>, <em>request_iterator</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.blocking_stream_in_value_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.blocking_stream_in_value_out" title="Permalink to this definition">¶</a></dt>
  366. <dd><p>Invokes a stream-request-unary-response RPC method.</p>
  367. <p>This method blocks until either returning the response value of the RPC
  368. (in the event of RPC completion) or raising an exception (in the event of
  369. RPC abortion).</p>
  370. <table class="docutils field-list" frame="void" rules="none">
  371. <col class="field-name" />
  372. <col class="field-body" />
  373. <tbody valign="top">
  374. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  375. <li><strong>name</strong> &#8211; The RPC method name.</li>
  376. <li><strong>request_iterator</strong> &#8211; An iterator that yields the request values of the RPC.</li>
  377. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  378. </ul>
  379. </td>
  380. </tr>
  381. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The response value for the RPC.</p>
  382. </td>
  383. </tr>
  384. <tr class="field-odd field"><th class="field-name">Raises:</th><td class="field-body"><p class="first last"><code class="xref py py-exc docutils literal"><span class="pre">exceptions.RpcError</span></code> &#8211;
  385. Indicating that the RPC was aborted.</p>
  386. </td>
  387. </tr>
  388. </tbody>
  389. </table>
  390. </dd></dl>
  391. <dl class="method">
  392. <dt id="grpc.framework.face.interfaces.GenericStub.blocking_value_in_value_out">
  393. <code class="descname">blocking_value_in_value_out</code><span class="sig-paren">(</span><em>name</em>, <em>request</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.blocking_value_in_value_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.blocking_value_in_value_out" title="Permalink to this definition">¶</a></dt>
  394. <dd><p>Invokes a unary-request-unary-response RPC method.</p>
  395. <p>This method blocks until either returning the response value of the RPC
  396. (in the event of RPC completion) or raising an exception (in the event of
  397. RPC abortion).</p>
  398. <table class="docutils field-list" frame="void" rules="none">
  399. <col class="field-name" />
  400. <col class="field-body" />
  401. <tbody valign="top">
  402. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  403. <li><strong>name</strong> &#8211; The RPC method name.</li>
  404. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  405. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  406. </ul>
  407. </td>
  408. </tr>
  409. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The response value for the RPC.</p>
  410. </td>
  411. </tr>
  412. <tr class="field-odd field"><th class="field-name">Raises:</th><td class="field-body"><p class="first last"><code class="xref py py-exc docutils literal"><span class="pre">exceptions.RpcError</span></code> &#8211;
  413. Indicating that the RPC was aborted.</p>
  414. </td>
  415. </tr>
  416. </tbody>
  417. </table>
  418. </dd></dl>
  419. <dl class="method">
  420. <dt id="grpc.framework.face.interfaces.GenericStub.event_stream_in_stream_out">
  421. <code class="descname">event_stream_in_stream_out</code><span class="sig-paren">(</span><em>name</em>, <em>response_consumer</em>, <em>abortion_callback</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.event_stream_in_stream_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.event_stream_in_stream_out" title="Permalink to this definition">¶</a></dt>
  422. <dd><p>Event-driven invocation of a unary-request-stream-response RPC method.</p>
  423. <table class="docutils field-list" frame="void" rules="none">
  424. <col class="field-name" />
  425. <col class="field-body" />
  426. <tbody valign="top">
  427. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  428. <li><strong>name</strong> &#8211; The RPC method name.</li>
  429. <li><strong>response_consumer</strong> &#8211; A stream.Consumer to be called to accept the response
  430. values of the RPC.</li>
  431. <li><strong>abortion_callback</strong> &#8211; A callback to be called and passed an Abortion value
  432. in the event of RPC abortion.</li>
  433. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  434. </ul>
  435. </td>
  436. </tr>
  437. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A pair of a Call object for the RPC and a stream.Consumer to which the
  438. request values of the RPC should be passed.</p>
  439. </td>
  440. </tr>
  441. </tbody>
  442. </table>
  443. </dd></dl>
  444. <dl class="method">
  445. <dt id="grpc.framework.face.interfaces.GenericStub.event_stream_in_value_out">
  446. <code class="descname">event_stream_in_value_out</code><span class="sig-paren">(</span><em>name</em>, <em>response_callback</em>, <em>abortion_callback</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.event_stream_in_value_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.event_stream_in_value_out" title="Permalink to this definition">¶</a></dt>
  447. <dd><p>Event-driven invocation of a unary-request-unary-response RPC method.</p>
  448. <table class="docutils field-list" frame="void" rules="none">
  449. <col class="field-name" />
  450. <col class="field-body" />
  451. <tbody valign="top">
  452. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  453. <li><strong>name</strong> &#8211; The RPC method name.</li>
  454. <li><strong>response_callback</strong> &#8211; A callback to be called to accept the response value
  455. of the RPC.</li>
  456. <li><strong>abortion_callback</strong> &#8211; A callback to be called and passed an Abortion value
  457. in the event of RPC abortion.</li>
  458. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  459. </ul>
  460. </td>
  461. </tr>
  462. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A pair of a Call object for the RPC and a stream.Consumer to which the
  463. request values of the RPC should be passed.</p>
  464. </td>
  465. </tr>
  466. </tbody>
  467. </table>
  468. </dd></dl>
  469. <dl class="method">
  470. <dt id="grpc.framework.face.interfaces.GenericStub.event_value_in_stream_out">
  471. <code class="descname">event_value_in_stream_out</code><span class="sig-paren">(</span><em>name</em>, <em>request</em>, <em>response_consumer</em>, <em>abortion_callback</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.event_value_in_stream_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.event_value_in_stream_out" title="Permalink to this definition">¶</a></dt>
  472. <dd><p>Event-driven invocation of a unary-request-stream-response RPC method.</p>
  473. <table class="docutils field-list" frame="void" rules="none">
  474. <col class="field-name" />
  475. <col class="field-body" />
  476. <tbody valign="top">
  477. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  478. <li><strong>name</strong> &#8211; The RPC method name.</li>
  479. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  480. <li><strong>response_consumer</strong> &#8211; A stream.Consumer to be called to accept the response
  481. values of the RPC.</li>
  482. <li><strong>abortion_callback</strong> &#8211; A callback to be called and passed an Abortion value
  483. in the event of RPC abortion.</li>
  484. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  485. </ul>
  486. </td>
  487. </tr>
  488. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A Call object for the RPC.</p>
  489. </td>
  490. </tr>
  491. </tbody>
  492. </table>
  493. </dd></dl>
  494. <dl class="method">
  495. <dt id="grpc.framework.face.interfaces.GenericStub.event_value_in_value_out">
  496. <code class="descname">event_value_in_value_out</code><span class="sig-paren">(</span><em>name</em>, <em>request</em>, <em>response_callback</em>, <em>abortion_callback</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.event_value_in_value_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.event_value_in_value_out" title="Permalink to this definition">¶</a></dt>
  497. <dd><p>Event-driven invocation of a unary-request-unary-response RPC method.</p>
  498. <table class="docutils field-list" frame="void" rules="none">
  499. <col class="field-name" />
  500. <col class="field-body" />
  501. <tbody valign="top">
  502. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  503. <li><strong>name</strong> &#8211; The RPC method name.</li>
  504. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  505. <li><strong>response_callback</strong> &#8211; A callback to be called to accept the response value
  506. of the RPC.</li>
  507. <li><strong>abortion_callback</strong> &#8211; A callback to be called and passed an Abortion value
  508. in the event of RPC abortion.</li>
  509. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  510. </ul>
  511. </td>
  512. </tr>
  513. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A Call object for the RPC.</p>
  514. </td>
  515. </tr>
  516. </tbody>
  517. </table>
  518. </dd></dl>
  519. <dl class="method">
  520. <dt id="grpc.framework.face.interfaces.GenericStub.future_stream_in_value_out">
  521. <code class="descname">future_stream_in_value_out</code><span class="sig-paren">(</span><em>name</em>, <em>request_iterator</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.future_stream_in_value_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.future_stream_in_value_out" title="Permalink to this definition">¶</a></dt>
  522. <dd><p>Invokes a stream-request-unary-response RPC method.</p>
  523. <table class="docutils field-list" frame="void" rules="none">
  524. <col class="field-name" />
  525. <col class="field-body" />
  526. <tbody valign="top">
  527. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  528. <li><strong>name</strong> &#8211; The RPC method name.</li>
  529. <li><strong>request_iterator</strong> &#8211; An iterator that yields the request values of the RPC.</li>
  530. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  531. </ul>
  532. </td>
  533. </tr>
  534. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A future.Future representing the RPC. In the event of RPC completion, the
  535. returned Future will return an outcome indicating that the RPC returned
  536. the response value of the RPC. In the event of RPC abortion, the
  537. returned Future will return an outcome indicating that the RPC raised
  538. an exceptions.RpcError.</p>
  539. </td>
  540. </tr>
  541. </tbody>
  542. </table>
  543. </dd></dl>
  544. <dl class="method">
  545. <dt id="grpc.framework.face.interfaces.GenericStub.future_value_in_value_out">
  546. <code class="descname">future_value_in_value_out</code><span class="sig-paren">(</span><em>name</em>, <em>request</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.future_value_in_value_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.future_value_in_value_out" title="Permalink to this definition">¶</a></dt>
  547. <dd><p>Invokes a unary-request-unary-response RPC method.</p>
  548. <table class="docutils field-list" frame="void" rules="none">
  549. <col class="field-name" />
  550. <col class="field-body" />
  551. <tbody valign="top">
  552. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  553. <li><strong>name</strong> &#8211; The RPC method name.</li>
  554. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  555. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  556. </ul>
  557. </td>
  558. </tr>
  559. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A future.Future representing the RPC. In the event of RPC completion, the
  560. returned Future will return an outcome indicating that the RPC returned
  561. the response value of the RPC. In the event of RPC abortion, the
  562. returned Future will return an outcome indicating that the RPC raised
  563. an exceptions.RpcError.</p>
  564. </td>
  565. </tr>
  566. </tbody>
  567. </table>
  568. </dd></dl>
  569. <dl class="method">
  570. <dt id="grpc.framework.face.interfaces.GenericStub.inline_stream_in_stream_out">
  571. <code class="descname">inline_stream_in_stream_out</code><span class="sig-paren">(</span><em>name</em>, <em>request_iterator</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.inline_stream_in_stream_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.inline_stream_in_stream_out" title="Permalink to this definition">¶</a></dt>
  572. <dd><p>Invokes a stream-request-stream-response RPC method.</p>
  573. <table class="docutils field-list" frame="void" rules="none">
  574. <col class="field-name" />
  575. <col class="field-body" />
  576. <tbody valign="top">
  577. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  578. <li><strong>name</strong> &#8211; The RPC method name.</li>
  579. <li><strong>request_iterator</strong> &#8211; An iterator that yields the request values of the RPC.</li>
  580. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  581. </ul>
  582. </td>
  583. </tr>
  584. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A CancellableIterator that yields the response values of the RPC and
  585. affords RPC cancellation. Drawing response values from the returned
  586. CancellableIterator may raise exceptions.RpcError indicating abortion of
  587. the RPC.</p>
  588. </td>
  589. </tr>
  590. </tbody>
  591. </table>
  592. </dd></dl>
  593. <dl class="method">
  594. <dt id="grpc.framework.face.interfaces.GenericStub.inline_value_in_stream_out">
  595. <code class="descname">inline_value_in_stream_out</code><span class="sig-paren">(</span><em>name</em>, <em>request</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.inline_value_in_stream_out"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.inline_value_in_stream_out" title="Permalink to this definition">¶</a></dt>
  596. <dd><p>Invokes a unary-request-stream-response RPC method.</p>
  597. <table class="docutils field-list" frame="void" rules="none">
  598. <col class="field-name" />
  599. <col class="field-body" />
  600. <tbody valign="top">
  601. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  602. <li><strong>name</strong> &#8211; The RPC method name.</li>
  603. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  604. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  605. </ul>
  606. </td>
  607. </tr>
  608. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A CancellableIterator that yields the response values of the RPC and
  609. affords RPC cancellation. Drawing response values from the returned
  610. CancellableIterator may raise exceptions.RpcError indicating abortion of
  611. the RPC.</p>
  612. </td>
  613. </tr>
  614. </tbody>
  615. </table>
  616. </dd></dl>
  617. <dl class="method">
  618. <dt id="grpc.framework.face.interfaces.GenericStub.stream_stream_multi_callable">
  619. <code class="descname">stream_stream_multi_callable</code><span class="sig-paren">(</span><em>name</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.stream_stream_multi_callable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.stream_stream_multi_callable" title="Permalink to this definition">¶</a></dt>
  620. <dd><p>Creates a StreamStreamMultiCallable for a stream-stream RPC method.</p>
  621. <table class="docutils field-list" frame="void" rules="none">
  622. <col class="field-name" />
  623. <col class="field-body" />
  624. <tbody valign="top">
  625. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>name</strong> &#8211; The RPC method name.</td>
  626. </tr>
  627. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">A StreamStreamMultiCallable value for the named stream-stream RPC method.</td>
  628. </tr>
  629. </tbody>
  630. </table>
  631. </dd></dl>
  632. <dl class="method">
  633. <dt id="grpc.framework.face.interfaces.GenericStub.stream_unary_multi_callable">
  634. <code class="descname">stream_unary_multi_callable</code><span class="sig-paren">(</span><em>name</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.stream_unary_multi_callable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.stream_unary_multi_callable" title="Permalink to this definition">¶</a></dt>
  635. <dd><p>Creates a StreamUnaryMultiCallable for a stream-unary RPC method.</p>
  636. <table class="docutils field-list" frame="void" rules="none">
  637. <col class="field-name" />
  638. <col class="field-body" />
  639. <tbody valign="top">
  640. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>name</strong> &#8211; The RPC method name.</td>
  641. </tr>
  642. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">A StreamUnaryMultiCallable value for the named stream-unary RPC method.</td>
  643. </tr>
  644. </tbody>
  645. </table>
  646. </dd></dl>
  647. <dl class="method">
  648. <dt id="grpc.framework.face.interfaces.GenericStub.unary_stream_multi_callable">
  649. <code class="descname">unary_stream_multi_callable</code><span class="sig-paren">(</span><em>name</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.unary_stream_multi_callable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.unary_stream_multi_callable" title="Permalink to this definition">¶</a></dt>
  650. <dd><p>Creates a UnaryStreamMultiCallable for a unary-stream RPC method.</p>
  651. <table class="docutils field-list" frame="void" rules="none">
  652. <col class="field-name" />
  653. <col class="field-body" />
  654. <tbody valign="top">
  655. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>name</strong> &#8211; The RPC method name.</td>
  656. </tr>
  657. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">A UnaryStreamMultiCallable value for the name unary-stream RPC method.</td>
  658. </tr>
  659. </tbody>
  660. </table>
  661. </dd></dl>
  662. <dl class="method">
  663. <dt id="grpc.framework.face.interfaces.GenericStub.unary_unary_multi_callable">
  664. <code class="descname">unary_unary_multi_callable</code><span class="sig-paren">(</span><em>name</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#GenericStub.unary_unary_multi_callable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.GenericStub.unary_unary_multi_callable" title="Permalink to this definition">¶</a></dt>
  665. <dd><p>Creates a UnaryUnaryMultiCallable for a unary-unary RPC method.</p>
  666. <table class="docutils field-list" frame="void" rules="none">
  667. <col class="field-name" />
  668. <col class="field-body" />
  669. <tbody valign="top">
  670. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>name</strong> &#8211; The RPC method name.</td>
  671. </tr>
  672. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">A UnaryUnaryMultiCallable value for the named unary-unary RPC method.</td>
  673. </tr>
  674. </tbody>
  675. </table>
  676. </dd></dl>
  677. </dd></dl>
  678. <dl class="class">
  679. <dt id="grpc.framework.face.interfaces.MethodImplementation">
  680. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">MethodImplementation</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#MethodImplementation"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation" title="Permalink to this definition">¶</a></dt>
  681. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  682. <p>A sum type that describes an RPC method implementation.</p>
  683. <dl class="attribute">
  684. <dt id="grpc.framework.face.interfaces.MethodImplementation.cardinality">
  685. <code class="descname">cardinality</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.cardinality" title="Permalink to this definition">¶</a></dt>
  686. <dd><p>A cardinality.Cardinality value.</p>
  687. </dd></dl>
  688. <dl class="attribute">
  689. <dt id="grpc.framework.face.interfaces.MethodImplementation.style">
  690. <code class="descname">style</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.style" title="Permalink to this definition">¶</a></dt>
  691. <dd><p>A style.Service value.</p>
  692. </dd></dl>
  693. <dl class="attribute">
  694. <dt id="grpc.framework.face.interfaces.MethodImplementation.unary_unary_inline">
  695. <code class="descname">unary_unary_inline</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.unary_unary_inline" title="Permalink to this definition">¶</a></dt>
  696. <dd><p>The implementation of the RPC method as a callable
  697. value that takes a request value and an RpcContext object and returns a
  698. response value. Only non-None if cardinality is
  699. cardinality.Cardinality.UNARY_UNARY and style is style.Service.INLINE.</p>
  700. </dd></dl>
  701. <dl class="attribute">
  702. <dt id="grpc.framework.face.interfaces.MethodImplementation.unary_stream_inline">
  703. <code class="descname">unary_stream_inline</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.unary_stream_inline" title="Permalink to this definition">¶</a></dt>
  704. <dd><p>The implementation of the RPC method as a callable
  705. value that takes a request value and an RpcContext object and returns an
  706. iterator of response values. Only non-None if cardinality is
  707. cardinality.Cardinality.UNARY_STREAM and style is style.Service.INLINE.</p>
  708. </dd></dl>
  709. <dl class="attribute">
  710. <dt id="grpc.framework.face.interfaces.MethodImplementation.stream_unary_inline">
  711. <code class="descname">stream_unary_inline</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.stream_unary_inline" title="Permalink to this definition">¶</a></dt>
  712. <dd><p>The implementation of the RPC method as a callable
  713. value that takes an iterator of request values and an RpcContext object
  714. and returns a response value. Only non-None if cardinality is
  715. cardinality.Cardinality.STREAM_UNARY and style is style.Service.INLINE.</p>
  716. </dd></dl>
  717. <dl class="attribute">
  718. <dt id="grpc.framework.face.interfaces.MethodImplementation.stream_stream_inline">
  719. <code class="descname">stream_stream_inline</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.stream_stream_inline" title="Permalink to this definition">¶</a></dt>
  720. <dd><p>The implementation of the RPC method as a callable
  721. value that takes an iterator of request values and an RpcContext object
  722. and returns an iterator of response values. Only non-None if cardinality
  723. is cardinality.Cardinality.STREAM_STREAM and style is
  724. style.Service.INLINE.</p>
  725. </dd></dl>
  726. <dl class="attribute">
  727. <dt id="grpc.framework.face.interfaces.MethodImplementation.unary_unary_event">
  728. <code class="descname">unary_unary_event</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.unary_unary_event" title="Permalink to this definition">¶</a></dt>
  729. <dd><p>The implementation of the RPC method as a callable value
  730. that takes a request value, a response callback to which to pass the
  731. response value of the RPC, and an RpcContext. Only non-None if
  732. cardinality is cardinality.Cardinality.UNARY_UNARY and style is
  733. style.Service.EVENT.</p>
  734. </dd></dl>
  735. <dl class="attribute">
  736. <dt id="grpc.framework.face.interfaces.MethodImplementation.unary_stream_event">
  737. <code class="descname">unary_stream_event</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.unary_stream_event" title="Permalink to this definition">¶</a></dt>
  738. <dd><p>The implementation of the RPC method as a callable
  739. value that takes a request value, a stream.Consumer to which to pass the
  740. the response values of the RPC, and an RpcContext. Only non-None if
  741. cardinality is cardinality.Cardinality.UNARY_STREAM and style is
  742. style.Service.EVENT.</p>
  743. </dd></dl>
  744. <dl class="attribute">
  745. <dt id="grpc.framework.face.interfaces.MethodImplementation.stream_unary_event">
  746. <code class="descname">stream_unary_event</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.stream_unary_event" title="Permalink to this definition">¶</a></dt>
  747. <dd><p>The implementation of the RPC method as a callable
  748. value that takes a response callback to which to pass the response value
  749. of the RPC and an RpcContext and returns a stream.Consumer to which the
  750. request values of the RPC should be passed. Only non-None if cardinality
  751. is cardinality.Cardinality.STREAM_UNARY and style is style.Service.EVENT.</p>
  752. </dd></dl>
  753. <dl class="attribute">
  754. <dt id="grpc.framework.face.interfaces.MethodImplementation.stream_stream_event">
  755. <code class="descname">stream_stream_event</code><a class="headerlink" href="#grpc.framework.face.interfaces.MethodImplementation.stream_stream_event" title="Permalink to this definition">¶</a></dt>
  756. <dd><p>The implementation of the RPC method as a callable
  757. value that takes a stream.Consumer to which to pass the response values
  758. of the RPC and an RpcContext and returns a stream.Consumer to which the
  759. request values of the RPC should be passed. Only non-None if cardinality
  760. is cardinality.Cardinality.STREAM_STREAM and style is
  761. style.Service.EVENT.</p>
  762. </dd></dl>
  763. </dd></dl>
  764. <dl class="class">
  765. <dt id="grpc.framework.face.interfaces.MultiMethodImplementation">
  766. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">MultiMethodImplementation</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#MultiMethodImplementation"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.MultiMethodImplementation" title="Permalink to this definition">¶</a></dt>
  767. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  768. <p>A general type able to service many RPC methods.</p>
  769. <dl class="method">
  770. <dt id="grpc.framework.face.interfaces.MultiMethodImplementation.service">
  771. <code class="descname">service</code><span class="sig-paren">(</span><em>name</em>, <em>response_consumer</em>, <em>context</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#MultiMethodImplementation.service"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.MultiMethodImplementation.service" title="Permalink to this definition">¶</a></dt>
  772. <dd><p>Services an RPC.</p>
  773. <table class="docutils field-list" frame="void" rules="none">
  774. <col class="field-name" />
  775. <col class="field-body" />
  776. <tbody valign="top">
  777. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  778. <li><strong>name</strong> &#8211; The RPC method name.</li>
  779. <li><strong>response_consumer</strong> &#8211; A stream.Consumer to be called to accept the response
  780. values of the RPC.</li>
  781. <li><strong>context</strong> &#8211; An RpcContext object.</li>
  782. </ul>
  783. </td>
  784. </tr>
  785. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">A stream.Consumer with which to accept the request values of the RPC. The
  786. consumer returned from this method may or may not be invoked to
  787. completion: in the case of RPC abortion, RPC Framework will simply stop
  788. passing values to this object. Implementations must not assume that this
  789. object will be called to completion of the request stream or even called
  790. at all.</p>
  791. </td>
  792. </tr>
  793. <tr class="field-odd field"><th class="field-name">Raises:</th><td class="field-body"><ul class="first last simple">
  794. <li><code class="xref py py-exc docutils literal"><span class="pre">abandonment.Abandoned</span></code> &#8211;
  795. May or may not be raised when the RPC has been
  796. aborted.</li>
  797. <li><code class="xref py py-exc docutils literal"><span class="pre">exceptions.NoSuchMethodError</span></code> &#8211;
  798. If this MultiMethod does not recognize the
  799. given RPC method name and is not able to service the RPC.</li>
  800. </ul>
  801. </td>
  802. </tr>
  803. </tbody>
  804. </table>
  805. </dd></dl>
  806. </dd></dl>
  807. <dl class="class">
  808. <dt id="grpc.framework.face.interfaces.RpcContext">
  809. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">RpcContext</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#RpcContext"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.RpcContext" title="Permalink to this definition">¶</a></dt>
  810. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  811. <p>Provides RPC-related information and action.</p>
  812. <dl class="method">
  813. <dt id="grpc.framework.face.interfaces.RpcContext.add_abortion_callback">
  814. <code class="descname">add_abortion_callback</code><span class="sig-paren">(</span><em>abortion_callback</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#RpcContext.add_abortion_callback"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.RpcContext.add_abortion_callback" title="Permalink to this definition">¶</a></dt>
  815. <dd><p>Registers a callback to be called if the RPC is aborted.</p>
  816. <table class="docutils field-list" frame="void" rules="none">
  817. <col class="field-name" />
  818. <col class="field-body" />
  819. <tbody valign="top">
  820. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>abortion_callback</strong> &#8211; A callable to be called and passed an Abortion value
  821. in the event of RPC abortion.</td>
  822. </tr>
  823. </tbody>
  824. </table>
  825. </dd></dl>
  826. <dl class="method">
  827. <dt id="grpc.framework.face.interfaces.RpcContext.is_active">
  828. <code class="descname">is_active</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#RpcContext.is_active"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.RpcContext.is_active" title="Permalink to this definition">¶</a></dt>
  829. <dd><p>Describes whether the RPC is active or has terminated.</p>
  830. </dd></dl>
  831. <dl class="method">
  832. <dt id="grpc.framework.face.interfaces.RpcContext.time_remaining">
  833. <code class="descname">time_remaining</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#RpcContext.time_remaining"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.RpcContext.time_remaining" title="Permalink to this definition">¶</a></dt>
  834. <dd><p>Describes the length of allowed time remaining for the RPC.</p>
  835. <table class="docutils field-list" frame="void" rules="none">
  836. <col class="field-name" />
  837. <col class="field-body" />
  838. <tbody valign="top">
  839. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">A nonnegative float indicating the length of allowed time in seconds
  840. remaining for the RPC to complete before it is considered to have timed
  841. out.</td>
  842. </tr>
  843. </tbody>
  844. </table>
  845. </dd></dl>
  846. </dd></dl>
  847. <dl class="class">
  848. <dt id="grpc.framework.face.interfaces.StreamStreamMultiCallable">
  849. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">StreamStreamMultiCallable</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#StreamStreamMultiCallable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.StreamStreamMultiCallable" title="Permalink to this definition">¶</a></dt>
  850. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  851. <p>Affords invoking a stream-stream RPC in any call style.</p>
  852. <dl class="method">
  853. <dt id="grpc.framework.face.interfaces.StreamStreamMultiCallable.__call__">
  854. <code class="descname">__call__</code><span class="sig-paren">(</span><em>request_iterator</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#StreamStreamMultiCallable.__call__"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.StreamStreamMultiCallable.__call__" title="Permalink to this definition">¶</a></dt>
  855. <dd><p>Synchronously invokes the underlying RPC.</p>
  856. <table class="docutils field-list" frame="void" rules="none">
  857. <col class="field-name" />
  858. <col class="field-body" />
  859. <tbody valign="top">
  860. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  861. <li><strong>request_iterator</strong> &#8211; An iterator that yields request values for the RPC.</li>
  862. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  863. </ul>
  864. </td>
  865. </tr>
  866. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A CancellableIterator that yields the response values of the RPC and
  867. affords RPC cancellation. Drawing response values from the returned
  868. CancellableIterator may raise exceptions.RpcError indicating abortion
  869. of the RPC.</p>
  870. </td>
  871. </tr>
  872. </tbody>
  873. </table>
  874. </dd></dl>
  875. <dl class="method">
  876. <dt id="grpc.framework.face.interfaces.StreamStreamMultiCallable.event">
  877. <code class="descname">event</code><span class="sig-paren">(</span><em>response_consumer</em>, <em>abortion_callback</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#StreamStreamMultiCallable.event"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.StreamStreamMultiCallable.event" title="Permalink to this definition">¶</a></dt>
  878. <dd><p>Asynchronously invokes the underlying RPC.</p>
  879. <dl class="docutils">
  880. <dt>l Args:</dt>
  881. <dd><blockquote class="first">
  882. <div><dl class="docutils">
  883. <dt>response_consumer: A stream.Consumer to be called to accept the restponse</dt>
  884. <dd>values of the RPC.</dd>
  885. <dt>abortion_callback: A callback to be called and passed an Abortion value</dt>
  886. <dd>in the event of RPC abortion.</dd>
  887. </dl>
  888. <p>timeout: A duration of time in seconds to allow for the RPC.</p>
  889. </div></blockquote>
  890. <dl class="last docutils">
  891. <dt>Returns:</dt>
  892. <dd><dl class="first last docutils">
  893. <dt>A pair of a Call object for the RPC and a stream.Consumer to which the</dt>
  894. <dd>request values of the RPC should be passed.</dd>
  895. </dl>
  896. </dd>
  897. </dl>
  898. </dd>
  899. </dl>
  900. </dd></dl>
  901. </dd></dl>
  902. <dl class="class">
  903. <dt id="grpc.framework.face.interfaces.StreamUnaryMultiCallable">
  904. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">StreamUnaryMultiCallable</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#StreamUnaryMultiCallable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.StreamUnaryMultiCallable" title="Permalink to this definition">¶</a></dt>
  905. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  906. <p>Affords invoking a stream-unary RPC in any call style.</p>
  907. <dl class="method">
  908. <dt id="grpc.framework.face.interfaces.StreamUnaryMultiCallable.__call__">
  909. <code class="descname">__call__</code><span class="sig-paren">(</span><em>request_iterator</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#StreamUnaryMultiCallable.__call__"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.StreamUnaryMultiCallable.__call__" title="Permalink to this definition">¶</a></dt>
  910. <dd><p>Synchronously invokes the underlying RPC.</p>
  911. <table class="docutils field-list" frame="void" rules="none">
  912. <col class="field-name" />
  913. <col class="field-body" />
  914. <tbody valign="top">
  915. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  916. <li><strong>request_iterator</strong> &#8211; An iterator that yields request values for the RPC.</li>
  917. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  918. </ul>
  919. </td>
  920. </tr>
  921. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The response value for the RPC.</p>
  922. </td>
  923. </tr>
  924. <tr class="field-odd field"><th class="field-name">Raises:</th><td class="field-body"><p class="first last"><code class="xref py py-exc docutils literal"><span class="pre">exceptions.RpcError</span></code> &#8211;
  925. Indicating that the RPC was aborted.</p>
  926. </td>
  927. </tr>
  928. </tbody>
  929. </table>
  930. </dd></dl>
  931. <dl class="method">
  932. <dt id="grpc.framework.face.interfaces.StreamUnaryMultiCallable.event">
  933. <code class="descname">event</code><span class="sig-paren">(</span><em>response_callback</em>, <em>abortion_callback</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#StreamUnaryMultiCallable.event"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.StreamUnaryMultiCallable.event" title="Permalink to this definition">¶</a></dt>
  934. <dd><p>Asynchronously invokes the underlying RPC.</p>
  935. <table class="docutils field-list" frame="void" rules="none">
  936. <col class="field-name" />
  937. <col class="field-body" />
  938. <tbody valign="top">
  939. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  940. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  941. <li><strong>response_callback</strong> &#8211; A callback to be called to accept the restponse value
  942. of the RPC.</li>
  943. <li><strong>abortion_callback</strong> &#8211; A callback to be called and passed an Abortion value
  944. in the event of RPC abortion.</li>
  945. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  946. </ul>
  947. </td>
  948. </tr>
  949. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A pair of a Call object for the RPC and a stream.Consumer to which the
  950. request values of the RPC should be passed.</p>
  951. </td>
  952. </tr>
  953. </tbody>
  954. </table>
  955. </dd></dl>
  956. <dl class="method">
  957. <dt id="grpc.framework.face.interfaces.StreamUnaryMultiCallable.future">
  958. <code class="descname">future</code><span class="sig-paren">(</span><em>request_iterator</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#StreamUnaryMultiCallable.future"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.StreamUnaryMultiCallable.future" title="Permalink to this definition">¶</a></dt>
  959. <dd><p>Asynchronously invokes the underlying RPC.</p>
  960. <table class="docutils field-list" frame="void" rules="none">
  961. <col class="field-name" />
  962. <col class="field-body" />
  963. <tbody valign="top">
  964. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  965. <li><strong>request_iterator</strong> &#8211; An iterator that yields request values for the RPC.</li>
  966. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  967. </ul>
  968. </td>
  969. </tr>
  970. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A future.Future representing the RPC. In the event of RPC completion, the
  971. returned Future&#8217;s result value will be the response value of the RPC.
  972. In the event of RPC abortion, the returned Future&#8217;s exception value
  973. will be an exceptions.RpcError.</p>
  974. </td>
  975. </tr>
  976. </tbody>
  977. </table>
  978. </dd></dl>
  979. </dd></dl>
  980. <dl class="class">
  981. <dt id="grpc.framework.face.interfaces.UnaryStreamMultiCallable">
  982. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">UnaryStreamMultiCallable</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#UnaryStreamMultiCallable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.UnaryStreamMultiCallable" title="Permalink to this definition">¶</a></dt>
  983. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  984. <p>Affords invoking a unary-stream RPC in any call style.</p>
  985. <dl class="method">
  986. <dt id="grpc.framework.face.interfaces.UnaryStreamMultiCallable.__call__">
  987. <code class="descname">__call__</code><span class="sig-paren">(</span><em>request</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#UnaryStreamMultiCallable.__call__"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.UnaryStreamMultiCallable.__call__" title="Permalink to this definition">¶</a></dt>
  988. <dd><p>Synchronously invokes the underlying RPC.</p>
  989. <table class="docutils field-list" frame="void" rules="none">
  990. <col class="field-name" />
  991. <col class="field-body" />
  992. <tbody valign="top">
  993. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  994. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  995. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  996. </ul>
  997. </td>
  998. </tr>
  999. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A CancellableIterator that yields the response values of the RPC and
  1000. affords RPC cancellation. Drawing response values from the returned
  1001. CancellableIterator may raise exceptions.RpcError indicating abortion
  1002. of the RPC.</p>
  1003. </td>
  1004. </tr>
  1005. </tbody>
  1006. </table>
  1007. </dd></dl>
  1008. <dl class="method">
  1009. <dt id="grpc.framework.face.interfaces.UnaryStreamMultiCallable.event">
  1010. <code class="descname">event</code><span class="sig-paren">(</span><em>request</em>, <em>response_consumer</em>, <em>abortion_callback</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#UnaryStreamMultiCallable.event"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.UnaryStreamMultiCallable.event" title="Permalink to this definition">¶</a></dt>
  1011. <dd><p>Asynchronously invokes the underlying RPC.</p>
  1012. <table class="docutils field-list" frame="void" rules="none">
  1013. <col class="field-name" />
  1014. <col class="field-body" />
  1015. <tbody valign="top">
  1016. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  1017. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  1018. <li><strong>response_consumer</strong> &#8211; A stream.Consumer to be called to accept the restponse
  1019. values of the RPC.</li>
  1020. <li><strong>abortion_callback</strong> &#8211; A callback to be called and passed an Abortion value
  1021. in the event of RPC abortion.</li>
  1022. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  1023. </ul>
  1024. </td>
  1025. </tr>
  1026. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A Call object for the RPC.</p>
  1027. </td>
  1028. </tr>
  1029. </tbody>
  1030. </table>
  1031. </dd></dl>
  1032. </dd></dl>
  1033. <dl class="class">
  1034. <dt id="grpc.framework.face.interfaces.UnaryUnaryMultiCallable">
  1035. <em class="property">class </em><code class="descclassname">grpc.framework.face.interfaces.</code><code class="descname">UnaryUnaryMultiCallable</code><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#UnaryUnaryMultiCallable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.UnaryUnaryMultiCallable" title="Permalink to this definition">¶</a></dt>
  1036. <dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">object</span></code></p>
  1037. <p>Affords invoking a unary-unary RPC in any call style.</p>
  1038. <dl class="method">
  1039. <dt id="grpc.framework.face.interfaces.UnaryUnaryMultiCallable.__call__">
  1040. <code class="descname">__call__</code><span class="sig-paren">(</span><em>request</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#UnaryUnaryMultiCallable.__call__"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.UnaryUnaryMultiCallable.__call__" title="Permalink to this definition">¶</a></dt>
  1041. <dd><p>Synchronously invokes the underlying RPC.</p>
  1042. <table class="docutils field-list" frame="void" rules="none">
  1043. <col class="field-name" />
  1044. <col class="field-body" />
  1045. <tbody valign="top">
  1046. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  1047. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  1048. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  1049. </ul>
  1050. </td>
  1051. </tr>
  1052. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The response value for the RPC.</p>
  1053. </td>
  1054. </tr>
  1055. <tr class="field-odd field"><th class="field-name">Raises:</th><td class="field-body"><p class="first last"><code class="xref py py-exc docutils literal"><span class="pre">exceptions.RpcError</span></code> &#8211;
  1056. Indicating that the RPC was aborted.</p>
  1057. </td>
  1058. </tr>
  1059. </tbody>
  1060. </table>
  1061. </dd></dl>
  1062. <dl class="method">
  1063. <dt id="grpc.framework.face.interfaces.UnaryUnaryMultiCallable.event">
  1064. <code class="descname">event</code><span class="sig-paren">(</span><em>request</em>, <em>response_callback</em>, <em>abortion_callback</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#UnaryUnaryMultiCallable.event"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.UnaryUnaryMultiCallable.event" title="Permalink to this definition">¶</a></dt>
  1065. <dd><p>Asynchronously invokes the underlying RPC.</p>
  1066. <table class="docutils field-list" frame="void" rules="none">
  1067. <col class="field-name" />
  1068. <col class="field-body" />
  1069. <tbody valign="top">
  1070. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  1071. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  1072. <li><strong>response_callback</strong> &#8211; A callback to be called to accept the restponse value
  1073. of the RPC.</li>
  1074. <li><strong>abortion_callback</strong> &#8211; A callback to be called and passed an Abortion value
  1075. in the event of RPC abortion.</li>
  1076. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  1077. </ul>
  1078. </td>
  1079. </tr>
  1080. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A Call object for the RPC.</p>
  1081. </td>
  1082. </tr>
  1083. </tbody>
  1084. </table>
  1085. </dd></dl>
  1086. <dl class="method">
  1087. <dt id="grpc.framework.face.interfaces.UnaryUnaryMultiCallable.future">
  1088. <code class="descname">future</code><span class="sig-paren">(</span><em>request</em>, <em>timeout</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/interfaces.html#UnaryUnaryMultiCallable.future"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.interfaces.UnaryUnaryMultiCallable.future" title="Permalink to this definition">¶</a></dt>
  1089. <dd><p>Asynchronously invokes the underlying RPC.</p>
  1090. <table class="docutils field-list" frame="void" rules="none">
  1091. <col class="field-name" />
  1092. <col class="field-body" />
  1093. <tbody valign="top">
  1094. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  1095. <li><strong>request</strong> &#8211; The request value for the RPC.</li>
  1096. <li><strong>timeout</strong> &#8211; A duration of time in seconds to allow for the RPC.</li>
  1097. </ul>
  1098. </td>
  1099. </tr>
  1100. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">A future.Future representing the RPC. In the event of RPC completion, the
  1101. returned Future&#8217;s result value will be the response value of the RPC.
  1102. In the event of RPC abortion, the returned Future&#8217;s exception value
  1103. will be an exceptions.RpcError.</p>
  1104. </td>
  1105. </tr>
  1106. </tbody>
  1107. </table>
  1108. </dd></dl>
  1109. </dd></dl>
  1110. </div>
  1111. <div class="section" id="module-grpc.framework.face.utilities">
  1112. <span id="grpc-framework-face-utilities-module"></span><h2>grpc.framework.face.utilities module<a class="headerlink" href="#module-grpc.framework.face.utilities" title="Permalink to this headline">¶</a></h2>
  1113. <p>Utilities for RPC framework&#8217;s face layer.</p>
  1114. <dl class="function">
  1115. <dt id="grpc.framework.face.utilities.stream_stream_event">
  1116. <code class="descclassname">grpc.framework.face.utilities.</code><code class="descname">stream_stream_event</code><span class="sig-paren">(</span><em>behavior</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/utilities.html#stream_stream_event"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.utilities.stream_stream_event" title="Permalink to this definition">¶</a></dt>
  1117. <dd><p>Creates an interfaces.MethodImplementation for the given behavior.</p>
  1118. <table class="docutils field-list" frame="void" rules="none">
  1119. <col class="field-name" />
  1120. <col class="field-body" />
  1121. <tbody valign="top">
  1122. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>behavior</strong> &#8211; The implementation of a stream-stream RPC method as a callable
  1123. value that takes a stream.Consumer to which to pass the response values
  1124. of the RPC and an interfaces.RpcContext and returns a stream.Consumer to
  1125. which the request values of the RPC should be passed.</td>
  1126. </tr>
  1127. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">An interfaces.MethodImplementation derived from the given behavior.</td>
  1128. </tr>
  1129. </tbody>
  1130. </table>
  1131. </dd></dl>
  1132. <dl class="function">
  1133. <dt id="grpc.framework.face.utilities.stream_stream_inline">
  1134. <code class="descclassname">grpc.framework.face.utilities.</code><code class="descname">stream_stream_inline</code><span class="sig-paren">(</span><em>behavior</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/utilities.html#stream_stream_inline"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.utilities.stream_stream_inline" title="Permalink to this definition">¶</a></dt>
  1135. <dd><p>Creates an interfaces.MethodImplementation for the given behavior.</p>
  1136. <table class="docutils field-list" frame="void" rules="none">
  1137. <col class="field-name" />
  1138. <col class="field-body" />
  1139. <tbody valign="top">
  1140. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>behavior</strong> &#8211; The implementation of a stream-stream RPC method as a callable
  1141. value that takes an iterator of request values and an
  1142. interfaces.RpcContext object and returns an iterator of response values.</td>
  1143. </tr>
  1144. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">An interfaces.MethodImplementation derived from the given behavior.</td>
  1145. </tr>
  1146. </tbody>
  1147. </table>
  1148. </dd></dl>
  1149. <dl class="function">
  1150. <dt id="grpc.framework.face.utilities.stream_unary_event">
  1151. <code class="descclassname">grpc.framework.face.utilities.</code><code class="descname">stream_unary_event</code><span class="sig-paren">(</span><em>behavior</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/utilities.html#stream_unary_event"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.utilities.stream_unary_event" title="Permalink to this definition">¶</a></dt>
  1152. <dd><p>Creates an interfaces.MethodImplementation for the given behavior.</p>
  1153. <table class="docutils field-list" frame="void" rules="none">
  1154. <col class="field-name" />
  1155. <col class="field-body" />
  1156. <tbody valign="top">
  1157. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>behavior</strong> &#8211; The implementation of a stream-unary RPC method as a callable
  1158. value that takes a response callback to which to pass the response value
  1159. of the RPC and an interfaces.RpcContext and returns a stream.Consumer to
  1160. which the request values of the RPC should be passed.</td>
  1161. </tr>
  1162. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">An interfaces.MethodImplementation derived from the given behavior.</td>
  1163. </tr>
  1164. </tbody>
  1165. </table>
  1166. </dd></dl>
  1167. <dl class="function">
  1168. <dt id="grpc.framework.face.utilities.stream_unary_inline">
  1169. <code class="descclassname">grpc.framework.face.utilities.</code><code class="descname">stream_unary_inline</code><span class="sig-paren">(</span><em>behavior</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/utilities.html#stream_unary_inline"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.utilities.stream_unary_inline" title="Permalink to this definition">¶</a></dt>
  1170. <dd><p>Creates an interfaces.MethodImplementation for the given behavior.</p>
  1171. <table class="docutils field-list" frame="void" rules="none">
  1172. <col class="field-name" />
  1173. <col class="field-body" />
  1174. <tbody valign="top">
  1175. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>behavior</strong> &#8211; The implementation of a stream-unary RPC method as a callable
  1176. value that takes an iterator of request values and an
  1177. interfaces.RpcContext object and returns a response value.</td>
  1178. </tr>
  1179. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">An interfaces.MethodImplementation derived from the given behavior.</td>
  1180. </tr>
  1181. </tbody>
  1182. </table>
  1183. </dd></dl>
  1184. <dl class="function">
  1185. <dt id="grpc.framework.face.utilities.unary_stream_event">
  1186. <code class="descclassname">grpc.framework.face.utilities.</code><code class="descname">unary_stream_event</code><span class="sig-paren">(</span><em>behavior</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/utilities.html#unary_stream_event"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.utilities.unary_stream_event" title="Permalink to this definition">¶</a></dt>
  1187. <dd><p>Creates an interfaces.MethodImplementation for the given behavior.</p>
  1188. <table class="docutils field-list" frame="void" rules="none">
  1189. <col class="field-name" />
  1190. <col class="field-body" />
  1191. <tbody valign="top">
  1192. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>behavior</strong> &#8211; The implementation of a unary-stream RPC method as a callable
  1193. value that takes a request value, a stream.Consumer to which to pass the
  1194. the response values of the RPC, and an interfaces.RpcContext.</td>
  1195. </tr>
  1196. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">An interfaces.MethodImplementation derived from the given behavior.</td>
  1197. </tr>
  1198. </tbody>
  1199. </table>
  1200. </dd></dl>
  1201. <dl class="function">
  1202. <dt id="grpc.framework.face.utilities.unary_stream_inline">
  1203. <code class="descclassname">grpc.framework.face.utilities.</code><code class="descname">unary_stream_inline</code><span class="sig-paren">(</span><em>behavior</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/utilities.html#unary_stream_inline"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.utilities.unary_stream_inline" title="Permalink to this definition">¶</a></dt>
  1204. <dd><p>Creates an interfaces.MethodImplementation for the given behavior.</p>
  1205. <table class="docutils field-list" frame="void" rules="none">
  1206. <col class="field-name" />
  1207. <col class="field-body" />
  1208. <tbody valign="top">
  1209. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>behavior</strong> &#8211; The implementation of a unary-stream RPC method as a callable
  1210. value that takes a request value and an interfaces.RpcContext object and
  1211. returns an iterator of response values.</td>
  1212. </tr>
  1213. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">An interfaces.MethodImplementation derived from the given behavior.</td>
  1214. </tr>
  1215. </tbody>
  1216. </table>
  1217. </dd></dl>
  1218. <dl class="function">
  1219. <dt id="grpc.framework.face.utilities.unary_unary_event">
  1220. <code class="descclassname">grpc.framework.face.utilities.</code><code class="descname">unary_unary_event</code><span class="sig-paren">(</span><em>behavior</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/utilities.html#unary_unary_event"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.utilities.unary_unary_event" title="Permalink to this definition">¶</a></dt>
  1221. <dd><p>Creates an interfaces.MethodImplementation for the given behavior.</p>
  1222. <table class="docutils field-list" frame="void" rules="none">
  1223. <col class="field-name" />
  1224. <col class="field-body" />
  1225. <tbody valign="top">
  1226. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>behavior</strong> &#8211; The implementation of a unary-unary RPC method as a callable
  1227. value that takes a request value, a response callback to which to pass
  1228. the response value of the RPC, and an interfaces.RpcContext.</td>
  1229. </tr>
  1230. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">An interfaces.MethodImplementation derived from the given behavior.</td>
  1231. </tr>
  1232. </tbody>
  1233. </table>
  1234. </dd></dl>
  1235. <dl class="function">
  1236. <dt id="grpc.framework.face.utilities.unary_unary_inline">
  1237. <code class="descclassname">grpc.framework.face.utilities.</code><code class="descname">unary_unary_inline</code><span class="sig-paren">(</span><em>behavior</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grpc/framework/face/utilities.html#unary_unary_inline"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#grpc.framework.face.utilities.unary_unary_inline" title="Permalink to this definition">¶</a></dt>
  1238. <dd><p>Creates an interfaces.MethodImplementation for the given behavior.</p>
  1239. <table class="docutils field-list" frame="void" rules="none">
  1240. <col class="field-name" />
  1241. <col class="field-body" />
  1242. <tbody valign="top">
  1243. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>behavior</strong> &#8211; The implementation of a unary-unary RPC method as a callable value
  1244. that takes a request value and an interfaces.RpcContext object and
  1245. returns a response value.</td>
  1246. </tr>
  1247. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">An interfaces.MethodImplementation derived from the given behavior.</td>
  1248. </tr>
  1249. </tbody>
  1250. </table>
  1251. </dd></dl>
  1252. </div>
  1253. <div class="section" id="module-grpc.framework.face">
  1254. <span id="module-contents"></span><h2>Module contents<a class="headerlink" href="#module-grpc.framework.face" title="Permalink to this headline">¶</a></h2>
  1255. </div>
  1256. </div>
  1257. </div>
  1258. <footer>
  1259. <div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
  1260. <a href="grpc.framework.face.testing.html" class="btn btn-neutral float-right" title="grpc.framework.face.testing package" accesskey="n">Next <span class="fa fa-arrow-circle-right"></span></a>
  1261. <a href="grpc.framework.common.html" class="btn btn-neutral" title="grpc.framework.common package" accesskey="p"><span class="fa fa-arrow-circle-left"></span> Previous</a>
  1262. </div>
  1263. <hr/>
  1264. <div role="contentinfo">
  1265. <p>
  1266. &copy; Copyright 2015, Author.
  1267. </p>
  1268. </div>
  1269. Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/snide/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
  1270. </footer>
  1271. </div>
  1272. </div>
  1273. </section>
  1274. </div>
  1275. <script type="text/javascript">
  1276. var DOCUMENTATION_OPTIONS = {
  1277. URL_ROOT:'./',
  1278. VERSION:'0.10.0a0',
  1279. COLLAPSE_INDEX:false,
  1280. FILE_SUFFIX:'.html',
  1281. HAS_SOURCE: true
  1282. };
  1283. </script>
  1284. <script type="text/javascript" src="_static/jquery.js"></script>
  1285. <script type="text/javascript" src="_static/underscore.js"></script>
  1286. <script type="text/javascript" src="_static/doctools.js"></script>
  1287. <script type="text/javascript" src="_static/js/theme.js"></script>
  1288. <script type="text/javascript">
  1289. jQuery(function () {
  1290. SphinxRtdTheme.StickyNav.enable();
  1291. });
  1292. </script>
  1293. </body>
  1294. </html>