19 #ifndef GRPCPP_GENERIC_GENERIC_STUB_IMPL_H
20 #define GRPCPP_GENERIC_GENERIC_STUB_IMPL_H
33 typedef ::grpc_impl::ClientAsyncReaderWriter<ByteBuffer, ByteBuffer>
35 typedef ::grpc_impl::ClientAsyncResponseReader<ByteBuffer>
45 explicit GenericStub(std::shared_ptr<grpc::ChannelInterface> channel)
46 : channel_(channel) {}
52 std::unique_ptr<grpc::GenericClientAsyncReaderWriter>
PrepareCall(
70 std::unique_ptr<grpc::GenericClientAsyncReaderWriter>
Call(
113 std::shared_ptr<grpc::ChannelInterface> channel_;
A sequence of bytes.
Definition: byte_buffer.h:67
Did it work? If it didn't, why?
Definition: status.h:31
ClientBidiReactor is the interface for a bidirectional streaming RPC.
Definition: client_callback_impl.h:192
A ClientContext allows the person implementing a service client to:
Definition: client_context_impl.h:184
ClientUnaryReactor is a reactor-style interface for a unary RPC.
Definition: client_callback_impl.h:386
A thin wrapper around grpc_completion_queue (see src/core/lib/surface/completion_queue....
Definition: completion_queue_impl.h:100
NOTE: class experimental_type is not part of the public API of this class TODO(vjpai): Move these con...
Definition: generic_stub_impl.h:77
experimental_type(GenericStub *stub)
Definition: generic_stub_impl.h:79
void UnaryCall(grpc_impl::ClientContext *context, const grpc::string &method, const grpc::ByteBuffer *request, grpc::ByteBuffer *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 re...
Definition: generic_stub.cc:70
void UnaryCall(grpc_impl::ClientContext *context, const grpc::string &method, const grpc::ByteBuffer *request, grpc::ByteBuffer *response, grpc_impl::ClientUnaryReactor *reactor)
Setup and start a unary call to a named method method using context and specifying the request and re...
void PrepareBidiStreamingCall(grpc_impl::ClientContext *context, const grpc::string &method, grpc_impl::ClientBidiReactor< grpc::ByteBuffer, grpc::ByteBuffer > *reactor)
Setup a call to a named method method using context and tied to reactor .
Definition: generic_stub.cc:81
Generic stubs provide a type-unsafe interface to call gRPC methods by name.
Definition: generic_stub_impl.h:43
std::unique_ptr< grpc::GenericClientAsyncResponseReader > PrepareUnaryCall(grpc_impl::ClientContext *context, const grpc::string &method, const grpc::ByteBuffer &request, CompletionQueue *cq)
Setup a unary call to a named method method using context, and don't start it.
Definition: generic_stub.cc:58
GenericStub(std::shared_ptr< grpc::ChannelInterface > channel)
Definition: generic_stub_impl.h:45
std::unique_ptr< grpc::GenericClientAsyncReaderWriter > PrepareCall(grpc::ClientContext *context, const grpc::string &method, CompletionQueue *cq)
Setup a call to a named method method using context, but don't start it.
Definition: generic_stub.cc:50
std::unique_ptr< grpc::GenericClientAsyncReaderWriter > Call(grpc_impl::ClientContext *context, const grpc::string &method, CompletionQueue *cq, void *tag)
DEPRECATED for multi-threaded use Begin a call to a named method method using context.
Definition: generic_stub.cc:43
experimental_type experimental()
NOTE: The function experimental() is not stable public API.
Definition: generic_stub_impl.h:110
An Alarm posts the user-provided tag to its associated completion queue or invokes the user-provided ...
Definition: alarm_impl.h:33
This header provides an object that reads bytes directly from a grpc::ByteBuffer, via the ZeroCopyInp...
Definition: alarm.h:24
::grpc_impl::ClientAsyncResponseReader< ByteBuffer > GenericClientAsyncResponseReader
Definition: generic_stub_impl.h:36
::grpc_impl::ClientAsyncReaderWriter< ByteBuffer, ByteBuffer > GenericClientAsyncReaderWriter
Definition: generic_stub_impl.h:34
::grpc_impl::CompletionQueue CompletionQueue
Definition: completion_queue.h:26
std::string string
Definition: config.h:35