123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128 |
- // Generated by the gRPC C++ plugin.
- // If you make any local change, they will be lost.
- // source: message.proto
- #include "message.pb.h"
- #include "message.grpc.pb.h"
- #include <functional>
- #include <grpcpp/support/async_stream.h>
- #include <grpcpp/support/async_unary_call.h>
- #include <grpcpp/impl/channel_interface.h>
- #include <grpcpp/impl/client_unary_call.h>
- #include <grpcpp/support/client_callback.h>
- #include <grpcpp/support/message_allocator.h>
- #include <grpcpp/support/method_handler.h>
- #include <grpcpp/impl/rpc_service_method.h>
- #include <grpcpp/support/server_callback.h>
- #include <grpcpp/impl/server_callback_handlers.h>
- #include <grpcpp/server_context.h>
- #include <grpcpp/impl/service_type.h>
- #include <grpcpp/support/sync_stream.h>
- namespace NavMessage {
- static const char* NavExcutor_method_names[] = {
- "/NavMessage.NavExcutor/Start",
- "/NavMessage.NavExcutor/Cancel",
- };
- std::unique_ptr< NavExcutor::Stub> NavExcutor::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) {
- (void)options;
- std::unique_ptr< NavExcutor::Stub> stub(new NavExcutor::Stub(channel, options));
- return stub;
- }
- NavExcutor::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options)
- : channel_(channel), rpcmethod_Start_(NavExcutor_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
- , rpcmethod_Cancel_(NavExcutor_method_names[1], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
- {}
- ::grpc::Status NavExcutor::Stub::Start(::grpc::ClientContext* context, const ::NavMessage::NavCmd& request, ::NavMessage::NavResponse* response) {
- return ::grpc::internal::BlockingUnaryCall< ::NavMessage::NavCmd, ::NavMessage::NavResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_Start_, context, request, response);
- }
- void NavExcutor::Stub::async::Start(::grpc::ClientContext* context, const ::NavMessage::NavCmd* request, ::NavMessage::NavResponse* response, std::function<void(::grpc::Status)> f) {
- ::grpc::internal::CallbackUnaryCall< ::NavMessage::NavCmd, ::NavMessage::NavResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Start_, context, request, response, std::move(f));
- }
- void NavExcutor::Stub::async::Start(::grpc::ClientContext* context, const ::NavMessage::NavCmd* request, ::NavMessage::NavResponse* response, ::grpc::ClientUnaryReactor* reactor) {
- ::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Start_, context, request, response, reactor);
- }
- ::grpc::ClientAsyncResponseReader< ::NavMessage::NavResponse>* NavExcutor::Stub::PrepareAsyncStartRaw(::grpc::ClientContext* context, const ::NavMessage::NavCmd& request, ::grpc::CompletionQueue* cq) {
- return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::NavMessage::NavResponse, ::NavMessage::NavCmd, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_Start_, context, request);
- }
- ::grpc::ClientAsyncResponseReader< ::NavMessage::NavResponse>* NavExcutor::Stub::AsyncStartRaw(::grpc::ClientContext* context, const ::NavMessage::NavCmd& request, ::grpc::CompletionQueue* cq) {
- auto* result =
- this->PrepareAsyncStartRaw(context, request, cq);
- result->StartCall();
- return result;
- }
- ::grpc::Status NavExcutor::Stub::Cancel(::grpc::ClientContext* context, const ::NavMessage::NavCmd& request, ::NavMessage::NavResponse* response) {
- return ::grpc::internal::BlockingUnaryCall< ::NavMessage::NavCmd, ::NavMessage::NavResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_Cancel_, context, request, response);
- }
- void NavExcutor::Stub::async::Cancel(::grpc::ClientContext* context, const ::NavMessage::NavCmd* request, ::NavMessage::NavResponse* response, std::function<void(::grpc::Status)> f) {
- ::grpc::internal::CallbackUnaryCall< ::NavMessage::NavCmd, ::NavMessage::NavResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Cancel_, context, request, response, std::move(f));
- }
- void NavExcutor::Stub::async::Cancel(::grpc::ClientContext* context, const ::NavMessage::NavCmd* request, ::NavMessage::NavResponse* response, ::grpc::ClientUnaryReactor* reactor) {
- ::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_Cancel_, context, request, response, reactor);
- }
- ::grpc::ClientAsyncResponseReader< ::NavMessage::NavResponse>* NavExcutor::Stub::PrepareAsyncCancelRaw(::grpc::ClientContext* context, const ::NavMessage::NavCmd& request, ::grpc::CompletionQueue* cq) {
- return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::NavMessage::NavResponse, ::NavMessage::NavCmd, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_Cancel_, context, request);
- }
- ::grpc::ClientAsyncResponseReader< ::NavMessage::NavResponse>* NavExcutor::Stub::AsyncCancelRaw(::grpc::ClientContext* context, const ::NavMessage::NavCmd& request, ::grpc::CompletionQueue* cq) {
- auto* result =
- this->PrepareAsyncCancelRaw(context, request, cq);
- result->StartCall();
- return result;
- }
- NavExcutor::Service::Service() {
- AddMethod(new ::grpc::internal::RpcServiceMethod(
- NavExcutor_method_names[0],
- ::grpc::internal::RpcMethod::NORMAL_RPC,
- new ::grpc::internal::RpcMethodHandler< NavExcutor::Service, ::NavMessage::NavCmd, ::NavMessage::NavResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
- [](NavExcutor::Service* service,
- ::grpc::ServerContext* ctx,
- const ::NavMessage::NavCmd* req,
- ::NavMessage::NavResponse* resp) {
- return service->Start(ctx, req, resp);
- }, this)));
- AddMethod(new ::grpc::internal::RpcServiceMethod(
- NavExcutor_method_names[1],
- ::grpc::internal::RpcMethod::NORMAL_RPC,
- new ::grpc::internal::RpcMethodHandler< NavExcutor::Service, ::NavMessage::NavCmd, ::NavMessage::NavResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
- [](NavExcutor::Service* service,
- ::grpc::ServerContext* ctx,
- const ::NavMessage::NavCmd* req,
- ::NavMessage::NavResponse* resp) {
- return service->Cancel(ctx, req, resp);
- }, this)));
- }
- NavExcutor::Service::~Service() {
- }
- ::grpc::Status NavExcutor::Service::Start(::grpc::ServerContext* context, const ::NavMessage::NavCmd* request, ::NavMessage::NavResponse* response) {
- (void) context;
- (void) request;
- (void) response;
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- ::grpc::Status NavExcutor::Service::Cancel(::grpc::ServerContext* context, const ::NavMessage::NavCmd* request, ::NavMessage::NavResponse* response) {
- (void) context;
- (void) request;
- (void) response;
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- } // namespace NavMessage
|