Слияние кода завершено, страница обновится автоматически
// Generated by the gRPC C++ plugin.
// If you make any local change, they will be lost.
// source: WechatProto.proto
// Original file comments:
// Go support for Protocol Buffers - Google's data interchange format
//
// Copyright 2015 The Go Authors. All rights reserved.
// https://github.com/golang/protobuf
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
// copyright notice, this list of conditions and the following disclaimer
// in the documentation and/or other materials provided with the
// distribution.
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//
#ifndef GRPC_WechatProto_2eproto__INCLUDED
#define GRPC_WechatProto_2eproto__INCLUDED
#include "WechatProto.pb.h"
#include <functional>
#include <grpcpp/impl/codegen/async_generic_service.h>
#include <grpcpp/impl/codegen/async_stream.h>
#include <grpcpp/impl/codegen/async_unary_call.h>
#include <grpcpp/impl/codegen/client_callback.h>
#include <grpcpp/impl/codegen/method_handler_impl.h>
#include <grpcpp/impl/codegen/proto_utils.h>
#include <grpcpp/impl/codegen/rpc_method.h>
#include <grpcpp/impl/codegen/server_callback.h>
#include <grpcpp/impl/codegen/service_type.h>
#include <grpcpp/impl/codegen/status.h>
#include <grpcpp/impl/codegen/stub_options.h>
#include <grpcpp/impl/codegen/sync_stream.h>
namespace grpc {
class CompletionQueue;
class Channel;
class ServerCompletionQueue;
class ServerContext;
} // namespace grpc
namespace WechatProto {
class Wechat final {
public:
static constexpr char const* service_full_name() {
return "WechatProto.Wechat";
}
class StubInterface {
public:
virtual ~StubInterface() {}
virtual ::grpc::Status HelloWechat(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::WechatProto::WechatMsg* response) = 0;
std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::WechatProto::WechatMsg>> AsyncHelloWechat(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::grpc::CompletionQueue* cq) {
return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::WechatProto::WechatMsg>>(AsyncHelloWechatRaw(context, request, cq));
}
std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::WechatProto::WechatMsg>> PrepareAsyncHelloWechat(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::grpc::CompletionQueue* cq) {
return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::WechatProto::WechatMsg>>(PrepareAsyncHelloWechatRaw(context, request, cq));
}
class experimental_async_interface {
public:
virtual ~experimental_async_interface() {}
virtual void HelloWechat(::grpc::ClientContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response, std::function<void(::grpc::Status)>) = 0;
};
virtual class experimental_async_interface* experimental_async() { return nullptr; }
private:
virtual ::grpc::ClientAsyncResponseReaderInterface< ::WechatProto::WechatMsg>* AsyncHelloWechatRaw(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::grpc::CompletionQueue* cq) = 0;
virtual ::grpc::ClientAsyncResponseReaderInterface< ::WechatProto::WechatMsg>* PrepareAsyncHelloWechatRaw(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::grpc::CompletionQueue* cq) = 0;
};
class Stub final : public StubInterface {
public:
Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel);
::grpc::Status HelloWechat(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::WechatProto::WechatMsg* response) override;
std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::WechatProto::WechatMsg>> AsyncHelloWechat(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::grpc::CompletionQueue* cq) {
return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::WechatProto::WechatMsg>>(AsyncHelloWechatRaw(context, request, cq));
}
std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::WechatProto::WechatMsg>> PrepareAsyncHelloWechat(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::grpc::CompletionQueue* cq) {
return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::WechatProto::WechatMsg>>(PrepareAsyncHelloWechatRaw(context, request, cq));
}
class experimental_async final :
public StubInterface::experimental_async_interface {
public:
void HelloWechat(::grpc::ClientContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response, std::function<void(::grpc::Status)>) override;
private:
friend class Stub;
explicit experimental_async(Stub* stub): stub_(stub) { }
Stub* stub() { return stub_; }
Stub* stub_;
};
class experimental_async_interface* experimental_async() override { return &async_stub_; }
private:
std::shared_ptr< ::grpc::ChannelInterface> channel_;
class experimental_async async_stub_{this};
::grpc::ClientAsyncResponseReader< ::WechatProto::WechatMsg>* AsyncHelloWechatRaw(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::grpc::CompletionQueue* cq) override;
::grpc::ClientAsyncResponseReader< ::WechatProto::WechatMsg>* PrepareAsyncHelloWechatRaw(::grpc::ClientContext* context, const ::WechatProto::WechatMsg& request, ::grpc::CompletionQueue* cq) override;
const ::grpc::internal::RpcMethod rpcmethod_HelloWechat_;
};
static std::unique_ptr<Stub> NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options = ::grpc::StubOptions());
class Service : public ::grpc::Service {
public:
Service();
virtual ~Service();
virtual ::grpc::Status HelloWechat(::grpc::ServerContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response);
};
template <class BaseClass>
class WithAsyncMethod_HelloWechat : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service *service) {}
public:
WithAsyncMethod_HelloWechat() {
::grpc::Service::MarkMethodAsync(0);
}
~WithAsyncMethod_HelloWechat() override {
BaseClassMustBeDerivedFromService(this);
}
// disable synchronous version of this method
::grpc::Status HelloWechat(::grpc::ServerContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response) override {
abort();
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestHelloWechat(::grpc::ServerContext* context, ::WechatProto::WechatMsg* request, ::grpc::ServerAsyncResponseWriter< ::WechatProto::WechatMsg>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
}
};
typedef WithAsyncMethod_HelloWechat<Service > AsyncService;
template <class BaseClass>
class ExperimentalWithCallbackMethod_HelloWechat : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service *service) {}
public:
ExperimentalWithCallbackMethod_HelloWechat() {
::grpc::Service::experimental().MarkMethodCallback(0,
new ::grpc::internal::CallbackUnaryHandler< ::WechatProto::WechatMsg, ::WechatProto::WechatMsg>(
[this](::grpc::ServerContext* context,
const ::WechatProto::WechatMsg* request,
::WechatProto::WechatMsg* response,
::grpc::experimental::ServerCallbackRpcController* controller) {
return this->HelloWechat(context, request, response, controller);
}));
}
~ExperimentalWithCallbackMethod_HelloWechat() override {
BaseClassMustBeDerivedFromService(this);
}
// disable synchronous version of this method
::grpc::Status HelloWechat(::grpc::ServerContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response) override {
abort();
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
virtual void HelloWechat(::grpc::ServerContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); }
};
typedef ExperimentalWithCallbackMethod_HelloWechat<Service > ExperimentalCallbackService;
template <class BaseClass>
class WithGenericMethod_HelloWechat : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service *service) {}
public:
WithGenericMethod_HelloWechat() {
::grpc::Service::MarkMethodGeneric(0);
}
~WithGenericMethod_HelloWechat() override {
BaseClassMustBeDerivedFromService(this);
}
// disable synchronous version of this method
::grpc::Status HelloWechat(::grpc::ServerContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response) override {
abort();
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
};
template <class BaseClass>
class WithRawMethod_HelloWechat : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service *service) {}
public:
WithRawMethod_HelloWechat() {
::grpc::Service::MarkMethodRaw(0);
}
~WithRawMethod_HelloWechat() override {
BaseClassMustBeDerivedFromService(this);
}
// disable synchronous version of this method
::grpc::Status HelloWechat(::grpc::ServerContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response) override {
abort();
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestHelloWechat(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
class ExperimentalWithRawCallbackMethod_HelloWechat : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service *service) {}
public:
ExperimentalWithRawCallbackMethod_HelloWechat() {
::grpc::Service::experimental().MarkMethodRawCallback(0,
new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
[this](::grpc::ServerContext* context,
const ::grpc::ByteBuffer* request,
::grpc::ByteBuffer* response,
::grpc::experimental::ServerCallbackRpcController* controller) {
this->HelloWechat(context, request, response, controller);
}));
}
~ExperimentalWithRawCallbackMethod_HelloWechat() override {
BaseClassMustBeDerivedFromService(this);
}
// disable synchronous version of this method
::grpc::Status HelloWechat(::grpc::ServerContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response) override {
abort();
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
virtual void HelloWechat(::grpc::ServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); }
};
template <class BaseClass>
class WithStreamedUnaryMethod_HelloWechat : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service *service) {}
public:
WithStreamedUnaryMethod_HelloWechat() {
::grpc::Service::MarkMethodStreamed(0,
new ::grpc::internal::StreamedUnaryHandler< ::WechatProto::WechatMsg, ::WechatProto::WechatMsg>(std::bind(&WithStreamedUnaryMethod_HelloWechat<BaseClass>::StreamedHelloWechat, this, std::placeholders::_1, std::placeholders::_2)));
}
~WithStreamedUnaryMethod_HelloWechat() override {
BaseClassMustBeDerivedFromService(this);
}
// disable regular version of this method
::grpc::Status HelloWechat(::grpc::ServerContext* context, const ::WechatProto::WechatMsg* request, ::WechatProto::WechatMsg* response) override {
abort();
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
// replace default version of method with streamed unary
virtual ::grpc::Status StreamedHelloWechat(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::WechatProto::WechatMsg,::WechatProto::WechatMsg>* server_unary_streamer) = 0;
};
typedef WithStreamedUnaryMethod_HelloWechat<Service > StreamedUnaryService;
typedef Service SplitStreamedService;
typedef WithStreamedUnaryMethod_HelloWechat<Service > StreamedService;
};
} // namespace WechatProto
#endif // GRPC_WechatProto_2eproto__INCLUDED
Вы можете оставить комментарий после Вход в систему
Неприемлемый контент может быть отображен здесь и не будет показан на странице. Вы можете проверить и изменить его с помощью соответствующей функции редактирования.
Если вы подтверждаете, что содержание не содержит непристойной лексики/перенаправления на рекламу/насилия/вульгарной порнографии/нарушений/пиратства/ложного/незначительного или незаконного контента, связанного с национальными законами и предписаниями, вы можете нажать «Отправить» для подачи апелляции, и мы обработаем ее как можно скорее.
Опубликовать ( 0 )