Lines Matching full:method

35 inline bool ClientOnlyStreaming(const grpc_generator::Method* method) {  in ClientOnlyStreaming()  argument
36 return method->ClientStreaming() && !method->ServerStreaming(); in ClientOnlyStreaming()
39 inline bool ServerOnlyStreaming(const grpc_generator::Method* method) { in ServerOnlyStreaming() argument
40 return !method->ClientStreaming() && method->ServerStreaming(); in ServerOnlyStreaming()
167 grpc_generator::Printer* printer, const grpc_generator::Method* method, in PrintHeaderClientMethodInterfaces() argument
169 (*vars)["Method"] = method->name(); in PrintHeaderClientMethodInterfaces()
170 (*vars)["Request"] = method->input_type_name(); in PrintHeaderClientMethodInterfaces()
171 (*vars)["Response"] = method->output_type_name(); in PrintHeaderClientMethodInterfaces()
175 grpc::string method_params; // extra arguments to method in PrintHeaderClientMethodInterfaces()
176 grpc::string raw_args; // extra arguments to raw version of method in PrintHeaderClientMethodInterfaces()
181 if (method->NoStreaming()) { in PrintHeaderClientMethodInterfaces()
184 "virtual ::grpc::Status $Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethodInterfaces()
192 "$AsyncPrefix$$Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethodInterfaces()
200 "$AsyncPrefix$$Method$Raw(context, request, cq));\n"); in PrintHeaderClientMethodInterfaces()
204 } else if (ClientOnlyStreaming(method)) { in PrintHeaderClientMethodInterfaces()
208 " $Method$(" in PrintHeaderClientMethodInterfaces()
214 "($Method$Raw(context, response));\n"); in PrintHeaderClientMethodInterfaces()
224 " $AsyncPrefix$$Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethodInterfaces()
232 "$AsyncPrefix$$Method$Raw(context, response, " in PrintHeaderClientMethodInterfaces()
237 } else if (ServerOnlyStreaming(method)) { in PrintHeaderClientMethodInterfaces()
241 " $Method$(::grpc::ClientContext* context, const $Request$& request)" in PrintHeaderClientMethodInterfaces()
247 "($Method$Raw(context, request));\n"); in PrintHeaderClientMethodInterfaces()
257 "$AsyncPrefix$$Method$(" in PrintHeaderClientMethodInterfaces()
265 "$AsyncPrefix$$Method$Raw(context, request, cq$AsyncRawArgs$));\n"); in PrintHeaderClientMethodInterfaces()
269 } else if (method->BidiStreaming()) { in PrintHeaderClientMethodInterfaces()
273 "$Method$(::grpc::ClientContext* context) {\n"); in PrintHeaderClientMethodInterfaces()
279 "$Method$Raw(context));\n"); in PrintHeaderClientMethodInterfaces()
290 "$AsyncPrefix$$Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethodInterfaces()
297 "$AsyncPrefix$$Method$Raw(context, cq$AsyncRawArgs$));\n"); in PrintHeaderClientMethodInterfaces()
303 if (method->NoStreaming()) { in PrintHeaderClientMethodInterfaces()
309 "$AsyncPrefix$$Method$Raw(::grpc::ClientContext* context, " in PrintHeaderClientMethodInterfaces()
313 } else if (ClientOnlyStreaming(method)) { in PrintHeaderClientMethodInterfaces()
317 " $Method$Raw(" in PrintHeaderClientMethodInterfaces()
325 " $AsyncPrefix$$Method$Raw(::grpc::ClientContext* context, " in PrintHeaderClientMethodInterfaces()
329 } else if (ServerOnlyStreaming(method)) { in PrintHeaderClientMethodInterfaces()
333 "$Method$Raw(" in PrintHeaderClientMethodInterfaces()
341 "$AsyncPrefix$$Method$Raw(" in PrintHeaderClientMethodInterfaces()
345 } else if (method->BidiStreaming()) { in PrintHeaderClientMethodInterfaces()
349 "$Method$Raw(::grpc::ClientContext* context) = 0;\n"); in PrintHeaderClientMethodInterfaces()
357 "$AsyncPrefix$$Method$Raw(::grpc::ClientContext* context, " in PrintHeaderClientMethodInterfaces()
365 const grpc_generator::Method* method, in PrintHeaderClientMethod() argument
368 (*vars)["Method"] = method->name(); in PrintHeaderClientMethod()
369 (*vars)["Request"] = method->input_type_name(); in PrintHeaderClientMethod()
370 (*vars)["Response"] = method->output_type_name(); in PrintHeaderClientMethod()
373 grpc::string method_params; // extra arguments to method in PrintHeaderClientMethod()
374 grpc::string raw_args; // extra arguments to raw version of method in PrintHeaderClientMethod()
379 if (method->NoStreaming()) { in PrintHeaderClientMethod()
382 "::grpc::Status $Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethod()
389 "$AsyncPrefix$$Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethod()
396 "$AsyncPrefix$$Method$Raw(context, request, cq));\n"); in PrintHeaderClientMethod()
400 } else if (ClientOnlyStreaming(method)) { in PrintHeaderClientMethod()
404 " $Method$(" in PrintHeaderClientMethod()
409 "($Method$Raw(context, response));\n"); in PrintHeaderClientMethod()
418 " $AsyncPrefix$$Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethod()
425 "$AsyncPrefix$$Method$Raw(context, response, " in PrintHeaderClientMethod()
430 } else if (ServerOnlyStreaming(method)) { in PrintHeaderClientMethod()
434 " $Method$(::grpc::ClientContext* context, const $Request$& request)" in PrintHeaderClientMethod()
440 "($Method$Raw(context, request));\n"); in PrintHeaderClientMethod()
450 "$AsyncPrefix$$Method$(" in PrintHeaderClientMethod()
457 "$AsyncPrefix$$Method$Raw(context, request, cq$AsyncRawArgs$));\n"); in PrintHeaderClientMethod()
461 } else if (method->BidiStreaming()) { in PrintHeaderClientMethod()
465 " $Method$(::grpc::ClientContext* context) {\n"); in PrintHeaderClientMethod()
470 "$Method$Raw(context));\n"); in PrintHeaderClientMethod()
480 "$AsyncPrefix$$Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethod()
487 "$AsyncPrefix$$Method$Raw(context, cq$AsyncRawArgs$));\n"); in PrintHeaderClientMethod()
493 if (method->NoStreaming()) { in PrintHeaderClientMethod()
499 "$AsyncPrefix$$Method$Raw(::grpc::ClientContext* context, " in PrintHeaderClientMethod()
503 } else if (ClientOnlyStreaming(method)) { in PrintHeaderClientMethod()
505 "::grpc::ClientWriter< $Request$>* $Method$Raw(" in PrintHeaderClientMethod()
514 "::grpc::ClientAsyncWriter< $Request$>* $AsyncPrefix$$Method$Raw(" in PrintHeaderClientMethod()
518 } else if (ServerOnlyStreaming(method)) { in PrintHeaderClientMethod()
520 "::grpc::ClientReader< $Response$>* $Method$Raw(" in PrintHeaderClientMethod()
529 "::grpc::ClientAsyncReader< $Response$>* $AsyncPrefix$$Method$Raw(" in PrintHeaderClientMethod()
533 } else if (method->BidiStreaming()) { in PrintHeaderClientMethod()
536 "$Method$Raw(::grpc::ClientContext* context) override;\n"); in PrintHeaderClientMethod()
544 "$AsyncPrefix$$Method$Raw(::grpc::ClientContext* context, " in PrintHeaderClientMethod()
567 grpc_generator::Printer* printer, const grpc_generator::Method* method, in PrintHeaderClientMethodCallbackInterfaces() argument
572 (*vars)["Method"] = method->name(); in PrintHeaderClientMethodCallbackInterfaces()
573 (*vars)["Request"] = method->input_type_name(); in PrintHeaderClientMethodCallbackInterfaces()
574 (*vars)["Response"] = method->output_type_name(); in PrintHeaderClientMethodCallbackInterfaces()
576 if (method->NoStreaming()) { in PrintHeaderClientMethodCallbackInterfaces()
578 "virtual void $Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethodCallbackInterfaces()
581 } else if (ClientOnlyStreaming(method)) { in PrintHeaderClientMethodCallbackInterfaces()
583 } else if (ServerOnlyStreaming(method)) { in PrintHeaderClientMethodCallbackInterfaces()
585 } else if (method->BidiStreaming()) { in PrintHeaderClientMethodCallbackInterfaces()
617 const grpc_generator::Method* method, in PrintHeaderClientMethodCallback() argument
623 (*vars)["Method"] = method->name(); in PrintHeaderClientMethodCallback()
624 (*vars)["Request"] = method->input_type_name(); in PrintHeaderClientMethodCallback()
625 (*vars)["Response"] = method->output_type_name(); in PrintHeaderClientMethodCallback()
627 if (method->NoStreaming()) { in PrintHeaderClientMethodCallback()
629 "void $Method$(::grpc::ClientContext* context, " in PrintHeaderClientMethodCallback()
632 } else if (ClientOnlyStreaming(method)) { in PrintHeaderClientMethodCallback()
634 } else if (ServerOnlyStreaming(method)) { in PrintHeaderClientMethodCallback()
636 } else if (method->BidiStreaming()) { in PrintHeaderClientMethodCallback()
662 const grpc_generator::Method* method, in PrintHeaderClientMethodData() argument
664 (*vars)["Method"] = method->name(); in PrintHeaderClientMethodData()
666 "const ::grpc::internal::RpcMethod rpcmethod_$Method$_;\n"); in PrintHeaderClientMethodData()
670 const grpc_generator::Method* method, in PrintHeaderServerMethodSync() argument
672 (*vars)["Method"] = method->name(); in PrintHeaderServerMethodSync()
673 (*vars)["Request"] = method->input_type_name(); in PrintHeaderServerMethodSync()
674 (*vars)["Response"] = method->output_type_name(); in PrintHeaderServerMethodSync()
675 printer->Print(method->GetLeadingComments("//").c_str()); in PrintHeaderServerMethodSync()
676 if (method->NoStreaming()) { in PrintHeaderServerMethodSync()
678 "virtual ::grpc::Status $Method$(" in PrintHeaderServerMethodSync()
681 } else if (ClientOnlyStreaming(method)) { in PrintHeaderServerMethodSync()
683 "virtual ::grpc::Status $Method$(" in PrintHeaderServerMethodSync()
687 } else if (ServerOnlyStreaming(method)) { in PrintHeaderServerMethodSync()
689 "virtual ::grpc::Status $Method$(" in PrintHeaderServerMethodSync()
692 } else if (method->BidiStreaming()) { in PrintHeaderServerMethodSync()
695 "virtual ::grpc::Status $Method$(" in PrintHeaderServerMethodSync()
700 printer->Print(method->GetTrailingComments("//").c_str()); in PrintHeaderServerMethodSync()
707 grpc_generator::Printer* printer, const grpc_generator::Method* method, in PrintHeaderServerAsyncMethodsHelper() argument
709 if (method->NoStreaming()) { in PrintHeaderServerAsyncMethodsHelper()
712 "// disable synchronous version of this method\n" in PrintHeaderServerAsyncMethodsHelper()
713 "::grpc::Status $Method$(" in PrintHeaderServerAsyncMethodsHelper()
721 "void Request$Method$(" in PrintHeaderServerAsyncMethodsHelper()
730 } else if (ClientOnlyStreaming(method)) { in PrintHeaderServerAsyncMethodsHelper()
733 "// disable synchronous version of this method\n" in PrintHeaderServerAsyncMethodsHelper()
734 "::grpc::Status $Method$(" in PrintHeaderServerAsyncMethodsHelper()
743 "void Request$Method$(" in PrintHeaderServerAsyncMethodsHelper()
752 } else if (ServerOnlyStreaming(method)) { in PrintHeaderServerAsyncMethodsHelper()
755 "// disable synchronous version of this method\n" in PrintHeaderServerAsyncMethodsHelper()
756 "::grpc::Status $Method$(" in PrintHeaderServerAsyncMethodsHelper()
765 "void Request$Method$(" in PrintHeaderServerAsyncMethodsHelper()
775 } else if (method->BidiStreaming()) { in PrintHeaderServerAsyncMethodsHelper()
778 "// disable synchronous version of this method\n" in PrintHeaderServerAsyncMethodsHelper()
779 "::grpc::Status $Method$(" in PrintHeaderServerAsyncMethodsHelper()
788 "void Request$Method$(" in PrintHeaderServerAsyncMethodsHelper()
802 const grpc_generator::Method* method, in PrintHeaderServerMethodAsync() argument
804 (*vars)["Method"] = method->name(); in PrintHeaderServerMethodAsync()
806 (*vars)["Request"] = method->input_type_name(); in PrintHeaderServerMethodAsync()
807 (*vars)["Response"] = method->output_type_name(); in PrintHeaderServerMethodAsync()
809 (*vars)["RealRequest"] = method->input_type_name(); in PrintHeaderServerMethodAsync()
810 (*vars)["RealResponse"] = method->output_type_name(); in PrintHeaderServerMethodAsync()
813 "class WithAsyncMethod_$Method$ : public BaseClass {\n"); in PrintHeaderServerMethodAsync()
820 "WithAsyncMethod_$Method$() {\n" in PrintHeaderServerMethodAsync()
824 "~WithAsyncMethod_$Method$() override {\n" in PrintHeaderServerMethodAsync()
827 PrintHeaderServerAsyncMethodsHelper(printer, method, vars); in PrintHeaderServerMethodAsync()
833 grpc_generator::Printer* printer, const grpc_generator::Method* method, in PrintHeaderServerMethodStreamedUnary() argument
835 (*vars)["Method"] = method->name(); in PrintHeaderServerMethodStreamedUnary()
836 (*vars)["Request"] = method->input_type_name(); in PrintHeaderServerMethodStreamedUnary()
837 (*vars)["Response"] = method->output_type_name(); in PrintHeaderServerMethodStreamedUnary()
838 if (method->NoStreaming()) { in PrintHeaderServerMethodStreamedUnary()
841 "class WithStreamedUnaryMethod_$Method$ : " in PrintHeaderServerMethodStreamedUnary()
850 "WithStreamedUnaryMethod_$Method$() {\n" in PrintHeaderServerMethodStreamedUnary()
854 "(&WithStreamedUnaryMethod_$Method$<BaseClass>::" in PrintHeaderServerMethodStreamedUnary()
855 "Streamed$Method$, this, std::placeholders::_1, " in PrintHeaderServerMethodStreamedUnary()
859 "~WithStreamedUnaryMethod_$Method$() override {\n" in PrintHeaderServerMethodStreamedUnary()
864 "// disable regular version of this method\n" in PrintHeaderServerMethodStreamedUnary()
865 "::grpc::Status $Method$(" in PrintHeaderServerMethodStreamedUnary()
872 "// replace default version of method with streamed unary\n" in PrintHeaderServerMethodStreamedUnary()
873 "virtual ::grpc::Status Streamed$Method$(" in PrintHeaderServerMethodStreamedUnary()
884 grpc_generator::Printer* printer, const grpc_generator::Method* method, in PrintHeaderServerMethodSplitStreaming() argument
886 (*vars)["Method"] = method->name(); in PrintHeaderServerMethodSplitStreaming()
887 (*vars)["Request"] = method->input_type_name(); in PrintHeaderServerMethodSplitStreaming()
888 (*vars)["Response"] = method->output_type_name(); in PrintHeaderServerMethodSplitStreaming()
889 if (ServerOnlyStreaming(method)) { in PrintHeaderServerMethodSplitStreaming()
892 "class WithSplitStreamingMethod_$Method$ : " in PrintHeaderServerMethodSplitStreaming()
902 "WithSplitStreamingMethod_$Method$() {\n" in PrintHeaderServerMethodSplitStreaming()
906 "(&WithSplitStreamingMethod_$Method$<BaseClass>::" in PrintHeaderServerMethodSplitStreaming()
907 "Streamed$Method$, this, std::placeholders::_1, " in PrintHeaderServerMethodSplitStreaming()
911 "~WithSplitStreamingMethod_$Method$() override {\n" in PrintHeaderServerMethodSplitStreaming()
916 "// disable regular version of this method\n" in PrintHeaderServerMethodSplitStreaming()
917 "::grpc::Status $Method$(" in PrintHeaderServerMethodSplitStreaming()
925 "// replace default version of method with split streamed\n" in PrintHeaderServerMethodSplitStreaming()
926 "virtual ::grpc::Status Streamed$Method$(" in PrintHeaderServerMethodSplitStreaming()
937 grpc_generator::Printer* printer, const grpc_generator::Method* method, in PrintHeaderServerMethodGeneric() argument
939 (*vars)["Method"] = method->name(); in PrintHeaderServerMethodGeneric()
940 (*vars)["Request"] = method->input_type_name(); in PrintHeaderServerMethodGeneric()
941 (*vars)["Response"] = method->output_type_name(); in PrintHeaderServerMethodGeneric()
944 "class WithGenericMethod_$Method$ : public BaseClass {\n"); in PrintHeaderServerMethodGeneric()
951 "WithGenericMethod_$Method$() {\n" in PrintHeaderServerMethodGeneric()
955 "~WithGenericMethod_$Method$() override {\n" in PrintHeaderServerMethodGeneric()
958 if (method->NoStreaming()) { in PrintHeaderServerMethodGeneric()
961 "// disable synchronous version of this method\n" in PrintHeaderServerMethodGeneric()
962 "::grpc::Status $Method$(" in PrintHeaderServerMethodGeneric()
968 } else if (ClientOnlyStreaming(method)) { in PrintHeaderServerMethodGeneric()
971 "// disable synchronous version of this method\n" in PrintHeaderServerMethodGeneric()
972 "::grpc::Status $Method$(" in PrintHeaderServerMethodGeneric()
979 } else if (ServerOnlyStreaming(method)) { in PrintHeaderServerMethodGeneric()
982 "// disable synchronous version of this method\n" in PrintHeaderServerMethodGeneric()
983 "::grpc::Status $Method$(" in PrintHeaderServerMethodGeneric()
990 } else if (method->BidiStreaming()) { in PrintHeaderServerMethodGeneric()
993 "// disable synchronous version of this method\n" in PrintHeaderServerMethodGeneric()
994 "::grpc::Status $Method$(" in PrintHeaderServerMethodGeneric()
1007 const grpc_generator::Method* method, in PrintHeaderServerMethodRaw() argument
1009 (*vars)["Method"] = method->name(); in PrintHeaderServerMethodRaw()
1011 (*vars)["Request"] = method->input_type_name(); in PrintHeaderServerMethodRaw()
1012 (*vars)["Response"] = method->output_type_name(); in PrintHeaderServerMethodRaw()
1017 printer->Print(*vars, "class WithRawMethod_$Method$ : public BaseClass {\n"); in PrintHeaderServerMethodRaw()
1024 "WithRawMethod_$Method$() {\n" in PrintHeaderServerMethodRaw()
1028 "~WithRawMethod_$Method$() override {\n" in PrintHeaderServerMethodRaw()
1031 PrintHeaderServerAsyncMethodsHelper(printer, method, vars); in PrintHeaderServerMethodRaw()
1060 printer->Print(service->method(i)->GetLeadingComments("//").c_str()); in PrintHeaderService()
1061 PrintHeaderClientMethodInterfaces(printer, service->method(i).get(), vars, in PrintHeaderService()
1063 printer->Print(service->method(i)->GetTrailingComments("//").c_str()); in PrintHeaderService()
1067 printer->Print(service->method(i)->GetLeadingComments("//").c_str()); in PrintHeaderService()
1068 PrintHeaderClientMethodCallbackInterfaces(printer, service->method(i).get(), in PrintHeaderService()
1070 printer->Print(service->method(i)->GetTrailingComments("//").c_str()); in PrintHeaderService()
1077 PrintHeaderClientMethodInterfaces(printer, service->method(i).get(), vars, in PrintHeaderService()
1090 PrintHeaderClientMethod(printer, service->method(i).get(), vars, true); in PrintHeaderService()
1094 PrintHeaderClientMethodCallback(printer, service->method(i).get(), vars, in PrintHeaderService()
1104 PrintHeaderClientMethod(printer, service->method(i).get(), vars, false); in PrintHeaderService()
1107 PrintHeaderClientMethodData(printer, service->method(i).get(), vars); in PrintHeaderService()
1126 PrintHeaderServerMethodSync(printer, service->method(i).get(), vars); in PrintHeaderService()
1134 PrintHeaderServerMethodAsync(printer, service->method(i).get(), vars); in PrintHeaderService()
1140 (*vars)["method_name"] = service->method(i).get()->name(); in PrintHeaderService()
1152 PrintHeaderServerMethodGeneric(printer, service->method(i).get(), vars); in PrintHeaderService()
1158 PrintHeaderServerMethodRaw(printer, service->method(i).get(), vars); in PrintHeaderService()
1164 PrintHeaderServerMethodStreamedUnary(printer, service->method(i).get(), in PrintHeaderService()
1170 (*vars)["method_name"] = service->method(i).get()->name(); in PrintHeaderService()
1171 if (service->method(i)->NoStreaming()) { in PrintHeaderService()
1177 if (service->method(i)->NoStreaming()) { in PrintHeaderService()
1186 PrintHeaderServerMethodSplitStreaming(printer, service->method(i).get(), in PrintHeaderService()
1192 (*vars)["method_name"] = service->method(i).get()->name(); in PrintHeaderService()
1193 auto method = service->method(i); in PrintHeaderService() local
1194 if (ServerOnlyStreaming(method.get())) { in PrintHeaderService()
1200 auto method = service->method(i); in PrintHeaderService() local
1201 if (ServerOnlyStreaming(method.get())) { in PrintHeaderService()
1210 (*vars)["method_name"] = service->method(i).get()->name(); in PrintHeaderService()
1211 auto method = service->method(i); in PrintHeaderService() local
1212 if (ServerOnlyStreaming(method.get())) { in PrintHeaderService()
1215 if (service->method(i)->NoStreaming()) { in PrintHeaderService()
1221 auto method = service->method(i); in PrintHeaderService() local
1222 if (service->method(i)->NoStreaming() || in PrintHeaderService()
1223 ServerOnlyStreaming(method.get())) { in PrintHeaderService()
1242 // method names. in GetHeaderServices()
1357 const grpc_generator::Method* method, in PrintSourceClientMethod() argument
1359 (*vars)["Method"] = method->name(); in PrintSourceClientMethod()
1360 (*vars)["Request"] = method->input_type_name(); in PrintSourceClientMethod()
1361 (*vars)["Response"] = method->output_type_name(); in PrintSourceClientMethod()
1365 grpc::string method_params; // extra arguments to method in PrintSourceClientMethod()
1369 if (method->NoStreaming()) { in PrintSourceClientMethod()
1371 "::grpc::Status $ns$$Service$::Stub::$Method$(" in PrintSourceClientMethod()
1376 "(channel_.get(), rpcmethod_$Method$_, " in PrintSourceClientMethod()
1380 "void $ns$$Service$::Stub::experimental_async::$Method$(" in PrintSourceClientMethod()
1386 "(stub_->channel_.get(), stub_->rpcmethod_$Method$_, " in PrintSourceClientMethod()
1394 "$ns$$Service$::Stub::$AsyncPrefix$$Method$Raw(::grpc::" in PrintSourceClientMethod()
1403 "rpcmethod_$Method$_, " in PrintSourceClientMethod()
1407 } else if (ClientOnlyStreaming(method)) { in PrintSourceClientMethod()
1410 "$ns$$Service$::Stub::$Method$Raw(" in PrintSourceClientMethod()
1416 "rpcmethod_$Method$_, " in PrintSourceClientMethod()
1429 "$ns$$Service$::Stub::$AsyncPrefix$$Method$Raw(" in PrintSourceClientMethod()
1436 "rpcmethod_$Method$_, " in PrintSourceClientMethod()
1440 } else if (ServerOnlyStreaming(method)) { in PrintSourceClientMethod()
1444 "$ns$$Service$::Stub::$Method$Raw(" in PrintSourceClientMethod()
1450 "rpcmethod_$Method$_, " in PrintSourceClientMethod()
1464 "$ns$$Service$::Stub::$AsyncPrefix$$Method$Raw(" in PrintSourceClientMethod()
1471 "rpcmethod_$Method$_, " in PrintSourceClientMethod()
1475 } else if (method->BidiStreaming()) { in PrintSourceClientMethod()
1479 "$ns$$Service$::Stub::$Method$Raw(::grpc::ClientContext* context) {\n"); in PrintSourceClientMethod()
1484 "rpcmethod_$Method$_, " in PrintSourceClientMethod()
1497 "$ns$$Service$::Stub::$AsyncPrefix$$Method$Raw(::grpc::" in PrintSourceClientMethod()
1505 "rpcmethod_$Method$_, " in PrintSourceClientMethod()
1513 const grpc_generator::Method* method, in PrintSourceServerMethod() argument
1515 (*vars)["Method"] = method->name(); in PrintSourceServerMethod()
1516 (*vars)["Request"] = method->input_type_name(); in PrintSourceServerMethod()
1517 (*vars)["Response"] = method->output_type_name(); in PrintSourceServerMethod()
1518 if (method->NoStreaming()) { in PrintSourceServerMethod()
1520 "::grpc::Status $ns$$Service$::Service::$Method$(" in PrintSourceServerMethod()
1530 } else if (ClientOnlyStreaming(method)) { in PrintSourceServerMethod()
1532 "::grpc::Status $ns$$Service$::Service::$Method$(" in PrintSourceServerMethod()
1543 } else if (ServerOnlyStreaming(method)) { in PrintSourceServerMethod()
1545 "::grpc::Status $ns$$Service$::Service::$Method$(" in PrintSourceServerMethod()
1556 } else if (method->BidiStreaming()) { in PrintSourceServerMethod()
1558 "::grpc::Status $ns$$Service$::Service::$Method$(" in PrintSourceServerMethod()
1580 (*vars)["Method"] = service->method(i).get()->name(); in PrintSourceService()
1581 printer->Print(*vars, " \"/$Package$$Service$/$Method$\",\n"); in PrintSourceService()
1601 auto method = service->method(i); in PrintSourceService() local
1602 (*vars)["Method"] = method->name(); in PrintSourceService()
1604 if (method->NoStreaming()) { in PrintSourceService()
1609 } else if (ClientOnlyStreaming(method.get())) { in PrintSourceService()
1611 } else if (ServerOnlyStreaming(method.get())) { in PrintSourceService()
1617 ", rpcmethod_$Method$_(" in PrintSourceService()
1628 PrintSourceClientMethod(printer, service->method(i).get(), vars); in PrintSourceService()
1634 auto method = service->method(i); in PrintSourceService() local
1636 (*vars)["Method"] = method->name(); in PrintSourceService()
1637 (*vars)["Request"] = method->input_type_name(); in PrintSourceService()
1638 (*vars)["Response"] = method->output_type_name(); in PrintSourceService()
1639 if (method->NoStreaming()) { in PrintSourceService()
1648 " std::mem_fn(&$ns$$Service$::Service::$Method$), this)));\n"); in PrintSourceService()
1649 } else if (ClientOnlyStreaming(method.get())) { in PrintSourceService()
1657 " std::mem_fn(&$ns$$Service$::Service::$Method$), this)));\n"); in PrintSourceService()
1658 } else if (ServerOnlyStreaming(method.get())) { in PrintSourceService()
1666 " std::mem_fn(&$ns$$Service$::Service::$Method$), this)));\n"); in PrintSourceService()
1667 } else if (method->BidiStreaming()) { in PrintSourceService()
1675 " std::mem_fn(&$ns$$Service$::Service::$Method$), this)));\n"); in PrintSourceService()
1685 PrintSourceServerMethod(printer, service->method(i).get(), vars); in PrintSourceService()
1697 // method names. in GetSourceServices()
1807 const grpc_generator::Method* method, in PrintMockClientMethods() argument
1809 (*vars)["Method"] = method->name(); in PrintMockClientMethods()
1810 (*vars)["Request"] = method->input_type_name(); in PrintMockClientMethods()
1811 (*vars)["Response"] = method->output_type_name(); in PrintMockClientMethods()
1815 grpc::string method_params; // extra arguments to method in PrintMockClientMethods()
1819 if (method->NoStreaming()) { in PrintMockClientMethods()
1822 "MOCK_METHOD3($Method$, ::grpc::Status(::grpc::ClientContext* context, " in PrintMockClientMethods()
1828 "MOCK_METHOD3($AsyncPrefix$$Method$Raw, " in PrintMockClientMethods()
1833 } else if (ClientOnlyStreaming(method)) { in PrintMockClientMethods()
1836 "MOCK_METHOD2($Method$Raw, " in PrintMockClientMethods()
1845 "MOCK_METHOD$MockArgs$($AsyncPrefix$$Method$Raw, " in PrintMockClientMethods()
1850 } else if (ServerOnlyStreaming(method)) { in PrintMockClientMethods()
1853 "MOCK_METHOD2($Method$Raw, " in PrintMockClientMethods()
1863 "MOCK_METHOD$MockArgs$($AsyncPrefix$$Method$Raw, " in PrintMockClientMethods()
1868 } else if (method->BidiStreaming()) { in PrintMockClientMethods()
1871 "MOCK_METHOD1($Method$Raw, " in PrintMockClientMethods()
1881 "MOCK_METHOD$MockArgs$($AsyncPrefix$$Method$Raw, " in PrintMockClientMethods()
1899 PrintMockClientMethods(printer, service->method(i).get(), vars); in PrintMockService()
1913 // method names. in GetMockServices()