GRPC C++  1.66.0
Public Member Functions | Friends
grpc::internal::TemplatedGenericStubCallbackInternal< RequestType, ResponseType > Class Template Reference

Generic stubs provide a type-unaware interface to call gRPC methods by name. More...

#include <generic_stub_internal.h>

Public Member Functions

 TemplatedGenericStubCallbackInternal (std::shared_ptr< grpc::ChannelInterface > channel)
 
void UnaryCall (ClientContext *context, const std::string &method, StubOptions options, const RequestType *request, ResponseType *response, std::function< void(grpc::Status)> on_completion)
 Setup and start a unary call to a named method method using context and specifying the request and response buffers. More...
 
void PrepareUnaryCall (ClientContext *context, const std::string &method, StubOptions options, const RequestType *request, ResponseType *response, ClientUnaryReactor *reactor)
 Setup a unary call to a named method method using context and specifying the request and response buffers. More...
 
void PrepareBidiStreamingCall (ClientContext *context, const std::string &method, StubOptions options, ClientBidiReactor< RequestType, ResponseType > *reactor)
 Setup a call to a named method method using context and tied to reactor . More...
 

Friends

template<class Req , class Resp >
class grpc::TemplatedGenericStub
 
template<class Req , class Resp >
class grpc::TemplatedGenericStubCallback
 

Detailed Description

template<class RequestType, class ResponseType>
class grpc::internal::TemplatedGenericStubCallbackInternal< RequestType, ResponseType >

Generic stubs provide a type-unaware interface to call gRPC methods by name.

In practice, the Request and Response types should be basic types like grpc::ByteBuffer or proto::MessageLite (the base protobuf).

Constructor & Destructor Documentation

◆ TemplatedGenericStubCallbackInternal()

template<class RequestType , class ResponseType >
grpc::internal::TemplatedGenericStubCallbackInternal< RequestType, ResponseType >::TemplatedGenericStubCallbackInternal ( std::shared_ptr< grpc::ChannelInterface channel)
inlineexplicit

Member Function Documentation

◆ PrepareBidiStreamingCall()

template<class RequestType , class ResponseType >
void grpc::internal::TemplatedGenericStubCallbackInternal< RequestType, ResponseType >::PrepareBidiStreamingCall ( ClientContext context,
const std::string &  method,
StubOptions  options,
ClientBidiReactor< RequestType, ResponseType > *  reactor 
)
inline

Setup a call to a named method method using context and tied to reactor .

Like any other bidi streaming RPC, it will not be activated until StartCall is invoked on its reactor.

◆ PrepareUnaryCall()

template<class RequestType , class ResponseType >
void grpc::internal::TemplatedGenericStubCallbackInternal< RequestType, ResponseType >::PrepareUnaryCall ( ClientContext context,
const std::string &  method,
StubOptions  options,
const RequestType *  request,
ResponseType *  response,
ClientUnaryReactor reactor 
)
inline

Setup a unary call to a named method method using context and specifying the request and response buffers.

Like any other reactor-based RPC, it will not be activated until StartCall is invoked on its reactor.

◆ UnaryCall()

template<class RequestType , class ResponseType >
void grpc::internal::TemplatedGenericStubCallbackInternal< RequestType, ResponseType >::UnaryCall ( ClientContext context,
const std::string &  method,
StubOptions  options,
const RequestType *  request,
ResponseType *  response,
std::function< void(grpc::Status)>  on_completion 
)
inline

Setup and start a unary call to a named method method using context and specifying the request and response buffers.

Friends And Related Function Documentation

◆ grpc::TemplatedGenericStub

template<class RequestType , class ResponseType >
template<class Req , class Resp >
friend class grpc::TemplatedGenericStub
friend

◆ grpc::TemplatedGenericStubCallback

template<class RequestType , class ResponseType >
template<class Req , class Resp >
friend class grpc::TemplatedGenericStubCallback
friend

The documentation for this class was generated from the following file: