diff --git a/native/cpp/CommonCpp/grpc/_generated/backup.grpc.pb.cc b/native/cpp/CommonCpp/grpc/_generated/backup.grpc.pb.cc index 915f9fed7..a195d6e6a 100644 --- a/native/cpp/CommonCpp/grpc/_generated/backup.grpc.pb.cc +++ b/native/cpp/CommonCpp/grpc/_generated/backup.grpc.pb.cc @@ -1,181 +1,182 @@ // @generated by the gRPC C++ plugin. // If you make any local change, they will be lost. // source: backup.proto #include "backup.pb.h" #include "backup.grpc.pb.h" #include #include #include #include #include #include #include #include #include #include #include #include #include #include namespace backup { static const char* BackupService_method_names[] = { "/backup.BackupService/CreateNewBackup", "/backup.BackupService/SendLog", "/backup.BackupService/RecoverBackupKey", "/backup.BackupService/PullBackup", }; std::unique_ptr< BackupService::Stub> BackupService::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) { (void)options; std::unique_ptr< BackupService::Stub> stub(new BackupService::Stub(channel, options)); return stub; } BackupService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) : channel_(channel), rpcmethod_CreateNewBackup_(BackupService_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::BIDI_STREAMING, channel) , rpcmethod_SendLog_(BackupService_method_names[1], options.suffix_for_stats(),::grpc::internal::RpcMethod::CLIENT_STREAMING, channel) , rpcmethod_RecoverBackupKey_(BackupService_method_names[2], options.suffix_for_stats(),::grpc::internal::RpcMethod::BIDI_STREAMING, channel) - , rpcmethod_PullBackup_(BackupService_method_names[3], options.suffix_for_stats(),::grpc::internal::RpcMethod::BIDI_STREAMING, channel) + , rpcmethod_PullBackup_(BackupService_method_names[3], options.suffix_for_stats(),::grpc::internal::RpcMethod::SERVER_STREAMING, channel) {} ::grpc::ClientReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* BackupService::Stub::CreateNewBackupRaw(::grpc::ClientContext* context) { return ::grpc::internal::ClientReaderWriterFactory< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>::Create(channel_.get(), rpcmethod_CreateNewBackup_, context); } void BackupService::Stub::async::CreateNewBackup(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::CreateNewBackupRequest,::backup::CreateNewBackupResponse>* reactor) { ::grpc::internal::ClientCallbackReaderWriterFactory< ::backup::CreateNewBackupRequest,::backup::CreateNewBackupResponse>::Create(stub_->channel_.get(), stub_->rpcmethod_CreateNewBackup_, context, reactor); } ::grpc::ClientAsyncReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* BackupService::Stub::AsyncCreateNewBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { return ::grpc::internal::ClientAsyncReaderWriterFactory< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>::Create(channel_.get(), cq, rpcmethod_CreateNewBackup_, context, true, tag); } ::grpc::ClientAsyncReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* BackupService::Stub::PrepareAsyncCreateNewBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { return ::grpc::internal::ClientAsyncReaderWriterFactory< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>::Create(channel_.get(), cq, rpcmethod_CreateNewBackup_, context, false, nullptr); } ::grpc::ClientWriter< ::backup::SendLogRequest>* BackupService::Stub::SendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response) { return ::grpc::internal::ClientWriterFactory< ::backup::SendLogRequest>::Create(channel_.get(), rpcmethod_SendLog_, context, response); } void BackupService::Stub::async::SendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::ClientWriteReactor< ::backup::SendLogRequest>* reactor) { ::grpc::internal::ClientCallbackWriterFactory< ::backup::SendLogRequest>::Create(stub_->channel_.get(), stub_->rpcmethod_SendLog_, context, response, reactor); } ::grpc::ClientAsyncWriter< ::backup::SendLogRequest>* BackupService::Stub::AsyncSendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq, void* tag) { return ::grpc::internal::ClientAsyncWriterFactory< ::backup::SendLogRequest>::Create(channel_.get(), cq, rpcmethod_SendLog_, context, response, true, tag); } ::grpc::ClientAsyncWriter< ::backup::SendLogRequest>* BackupService::Stub::PrepareAsyncSendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq) { return ::grpc::internal::ClientAsyncWriterFactory< ::backup::SendLogRequest>::Create(channel_.get(), cq, rpcmethod_SendLog_, context, response, false, nullptr); } ::grpc::ClientReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* BackupService::Stub::RecoverBackupKeyRaw(::grpc::ClientContext* context) { return ::grpc::internal::ClientReaderWriterFactory< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>::Create(channel_.get(), rpcmethod_RecoverBackupKey_, context); } void BackupService::Stub::async::RecoverBackupKey(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::RecoverBackupKeyRequest,::backup::RecoverBackupKeyResponse>* reactor) { ::grpc::internal::ClientCallbackReaderWriterFactory< ::backup::RecoverBackupKeyRequest,::backup::RecoverBackupKeyResponse>::Create(stub_->channel_.get(), stub_->rpcmethod_RecoverBackupKey_, context, reactor); } ::grpc::ClientAsyncReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* BackupService::Stub::AsyncRecoverBackupKeyRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { return ::grpc::internal::ClientAsyncReaderWriterFactory< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>::Create(channel_.get(), cq, rpcmethod_RecoverBackupKey_, context, true, tag); } ::grpc::ClientAsyncReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* BackupService::Stub::PrepareAsyncRecoverBackupKeyRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { return ::grpc::internal::ClientAsyncReaderWriterFactory< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>::Create(channel_.get(), cq, rpcmethod_RecoverBackupKey_, context, false, nullptr); } -::grpc::ClientReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* BackupService::Stub::PullBackupRaw(::grpc::ClientContext* context) { - return ::grpc::internal::ClientReaderWriterFactory< ::backup::PullBackupRequest, ::backup::PullBackupResponse>::Create(channel_.get(), rpcmethod_PullBackup_, context); +::grpc::ClientReader< ::backup::PullBackupResponse>* BackupService::Stub::PullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request) { + return ::grpc::internal::ClientReaderFactory< ::backup::PullBackupResponse>::Create(channel_.get(), rpcmethod_PullBackup_, context, request); } -void BackupService::Stub::async::PullBackup(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::PullBackupRequest,::backup::PullBackupResponse>* reactor) { - ::grpc::internal::ClientCallbackReaderWriterFactory< ::backup::PullBackupRequest,::backup::PullBackupResponse>::Create(stub_->channel_.get(), stub_->rpcmethod_PullBackup_, context, reactor); +void BackupService::Stub::async::PullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest* request, ::grpc::ClientReadReactor< ::backup::PullBackupResponse>* reactor) { + ::grpc::internal::ClientCallbackReaderFactory< ::backup::PullBackupResponse>::Create(stub_->channel_.get(), stub_->rpcmethod_PullBackup_, context, request, reactor); } -::grpc::ClientAsyncReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* BackupService::Stub::AsyncPullBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { - return ::grpc::internal::ClientAsyncReaderWriterFactory< ::backup::PullBackupRequest, ::backup::PullBackupResponse>::Create(channel_.get(), cq, rpcmethod_PullBackup_, context, true, tag); +::grpc::ClientAsyncReader< ::backup::PullBackupResponse>* BackupService::Stub::AsyncPullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq, void* tag) { + return ::grpc::internal::ClientAsyncReaderFactory< ::backup::PullBackupResponse>::Create(channel_.get(), cq, rpcmethod_PullBackup_, context, request, true, tag); } -::grpc::ClientAsyncReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* BackupService::Stub::PrepareAsyncPullBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { - return ::grpc::internal::ClientAsyncReaderWriterFactory< ::backup::PullBackupRequest, ::backup::PullBackupResponse>::Create(channel_.get(), cq, rpcmethod_PullBackup_, context, false, nullptr); +::grpc::ClientAsyncReader< ::backup::PullBackupResponse>* BackupService::Stub::PrepareAsyncPullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq) { + return ::grpc::internal::ClientAsyncReaderFactory< ::backup::PullBackupResponse>::Create(channel_.get(), cq, rpcmethod_PullBackup_, context, request, false, nullptr); } BackupService::Service::Service() { AddMethod(new ::grpc::internal::RpcServiceMethod( BackupService_method_names[0], ::grpc::internal::RpcMethod::BIDI_STREAMING, new ::grpc::internal::BidiStreamingHandler< BackupService::Service, ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>( [](BackupService::Service* service, ::grpc::ServerContext* ctx, ::grpc::ServerReaderWriter<::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* stream) { return service->CreateNewBackup(ctx, stream); }, this))); AddMethod(new ::grpc::internal::RpcServiceMethod( BackupService_method_names[1], ::grpc::internal::RpcMethod::CLIENT_STREAMING, new ::grpc::internal::ClientStreamingHandler< BackupService::Service, ::backup::SendLogRequest, ::google::protobuf::Empty>( [](BackupService::Service* service, ::grpc::ServerContext* ctx, ::grpc::ServerReader<::backup::SendLogRequest>* reader, ::google::protobuf::Empty* resp) { return service->SendLog(ctx, reader, resp); }, this))); AddMethod(new ::grpc::internal::RpcServiceMethod( BackupService_method_names[2], ::grpc::internal::RpcMethod::BIDI_STREAMING, new ::grpc::internal::BidiStreamingHandler< BackupService::Service, ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>( [](BackupService::Service* service, ::grpc::ServerContext* ctx, ::grpc::ServerReaderWriter<::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* stream) { return service->RecoverBackupKey(ctx, stream); }, this))); AddMethod(new ::grpc::internal::RpcServiceMethod( BackupService_method_names[3], - ::grpc::internal::RpcMethod::BIDI_STREAMING, - new ::grpc::internal::BidiStreamingHandler< BackupService::Service, ::backup::PullBackupRequest, ::backup::PullBackupResponse>( + ::grpc::internal::RpcMethod::SERVER_STREAMING, + new ::grpc::internal::ServerStreamingHandler< BackupService::Service, ::backup::PullBackupRequest, ::backup::PullBackupResponse>( [](BackupService::Service* service, ::grpc::ServerContext* ctx, - ::grpc::ServerReaderWriter<::backup::PullBackupResponse, - ::backup::PullBackupRequest>* stream) { - return service->PullBackup(ctx, stream); + const ::backup::PullBackupRequest* req, + ::grpc::ServerWriter<::backup::PullBackupResponse>* writer) { + return service->PullBackup(ctx, req, writer); }, this))); } BackupService::Service::~Service() { } ::grpc::Status BackupService::Service::CreateNewBackup(::grpc::ServerContext* context, ::grpc::ServerReaderWriter< ::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* stream) { (void) context; (void) stream; return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } ::grpc::Status BackupService::Service::SendLog(::grpc::ServerContext* context, ::grpc::ServerReader< ::backup::SendLogRequest>* reader, ::google::protobuf::Empty* response) { (void) context; (void) reader; (void) response; return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } ::grpc::Status BackupService::Service::RecoverBackupKey(::grpc::ServerContext* context, ::grpc::ServerReaderWriter< ::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* stream) { (void) context; (void) stream; return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } -::grpc::Status BackupService::Service::PullBackup(::grpc::ServerContext* context, ::grpc::ServerReaderWriter< ::backup::PullBackupResponse, ::backup::PullBackupRequest>* stream) { +::grpc::Status BackupService::Service::PullBackup(::grpc::ServerContext* context, const ::backup::PullBackupRequest* request, ::grpc::ServerWriter< ::backup::PullBackupResponse>* writer) { (void) context; - (void) stream; + (void) request; + (void) writer; return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } } // namespace backup diff --git a/native/cpp/CommonCpp/grpc/_generated/backup.grpc.pb.h b/native/cpp/CommonCpp/grpc/_generated/backup.grpc.pb.h index cfdca3115..e52a801da 100644 --- a/native/cpp/CommonCpp/grpc/_generated/backup.grpc.pb.h +++ b/native/cpp/CommonCpp/grpc/_generated/backup.grpc.pb.h @@ -1,618 +1,643 @@ // @generated by the gRPC C++ plugin. // If you make any local change, they will be lost. // source: backup.proto #ifndef GRPC_backup_2eproto__INCLUDED #define GRPC_backup_2eproto__INCLUDED #include "backup.pb.h" #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include namespace backup { // * // API - description // CreateNewBackup - This method is called when we want to create a new backup. // We send a new backup key encrypted with the user's password and also the // new compaction. New logs that will be sent from now on will be assigned to // this backup. // SendLog - User sends a new log to the backup service. The log is being // assigned to the latest(or desired) backup's compaction item. // RecoverBackupKey - Pulls data necessary for regenerating the backup key // on the client-side for the latest(or desired) backup // PullBackup - Fetches compaction + all logs assigned to it for the // specified backup(default is the last backup) // class BackupService final { public: static constexpr char const* service_full_name() { return "backup.BackupService"; } class StubInterface { public: virtual ~StubInterface() {} std::unique_ptr< ::grpc::ClientReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>> CreateNewBackup(::grpc::ClientContext* context) { return std::unique_ptr< ::grpc::ClientReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>>(CreateNewBackupRaw(context)); } std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>> AsyncCreateNewBackup(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { return std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>>(AsyncCreateNewBackupRaw(context, cq, tag)); } std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>> PrepareAsyncCreateNewBackup(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { return std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>>(PrepareAsyncCreateNewBackupRaw(context, cq)); } std::unique_ptr< ::grpc::ClientWriterInterface< ::backup::SendLogRequest>> SendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response) { return std::unique_ptr< ::grpc::ClientWriterInterface< ::backup::SendLogRequest>>(SendLogRaw(context, response)); } std::unique_ptr< ::grpc::ClientAsyncWriterInterface< ::backup::SendLogRequest>> AsyncSendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq, void* tag) { return std::unique_ptr< ::grpc::ClientAsyncWriterInterface< ::backup::SendLogRequest>>(AsyncSendLogRaw(context, response, cq, tag)); } std::unique_ptr< ::grpc::ClientAsyncWriterInterface< ::backup::SendLogRequest>> PrepareAsyncSendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq) { return std::unique_ptr< ::grpc::ClientAsyncWriterInterface< ::backup::SendLogRequest>>(PrepareAsyncSendLogRaw(context, response, cq)); } std::unique_ptr< ::grpc::ClientReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>> RecoverBackupKey(::grpc::ClientContext* context) { return std::unique_ptr< ::grpc::ClientReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>>(RecoverBackupKeyRaw(context)); } std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>> AsyncRecoverBackupKey(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { return std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>>(AsyncRecoverBackupKeyRaw(context, cq, tag)); } std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>> PrepareAsyncRecoverBackupKey(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { return std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>>(PrepareAsyncRecoverBackupKeyRaw(context, cq)); } - std::unique_ptr< ::grpc::ClientReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>> PullBackup(::grpc::ClientContext* context) { - return std::unique_ptr< ::grpc::ClientReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>>(PullBackupRaw(context)); + std::unique_ptr< ::grpc::ClientReaderInterface< ::backup::PullBackupResponse>> PullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request) { + return std::unique_ptr< ::grpc::ClientReaderInterface< ::backup::PullBackupResponse>>(PullBackupRaw(context, request)); } - std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>> AsyncPullBackup(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { - return std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>>(AsyncPullBackupRaw(context, cq, tag)); + std::unique_ptr< ::grpc::ClientAsyncReaderInterface< ::backup::PullBackupResponse>> AsyncPullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq, void* tag) { + return std::unique_ptr< ::grpc::ClientAsyncReaderInterface< ::backup::PullBackupResponse>>(AsyncPullBackupRaw(context, request, cq, tag)); } - std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>> PrepareAsyncPullBackup(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { - return std::unique_ptr< ::grpc::ClientAsyncReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>>(PrepareAsyncPullBackupRaw(context, cq)); + std::unique_ptr< ::grpc::ClientAsyncReaderInterface< ::backup::PullBackupResponse>> PrepareAsyncPullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncReaderInterface< ::backup::PullBackupResponse>>(PrepareAsyncPullBackupRaw(context, request, cq)); } class async_interface { public: virtual ~async_interface() {} virtual void CreateNewBackup(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::CreateNewBackupRequest,::backup::CreateNewBackupResponse>* reactor) = 0; virtual void SendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::ClientWriteReactor< ::backup::SendLogRequest>* reactor) = 0; virtual void RecoverBackupKey(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::RecoverBackupKeyRequest,::backup::RecoverBackupKeyResponse>* reactor) = 0; - virtual void PullBackup(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::PullBackupRequest,::backup::PullBackupResponse>* reactor) = 0; + virtual void PullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest* request, ::grpc::ClientReadReactor< ::backup::PullBackupResponse>* reactor) = 0; }; typedef class async_interface experimental_async_interface; virtual class async_interface* async() { return nullptr; } class async_interface* experimental_async() { return async(); } private: virtual ::grpc::ClientReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* CreateNewBackupRaw(::grpc::ClientContext* context) = 0; virtual ::grpc::ClientAsyncReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* AsyncCreateNewBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) = 0; virtual ::grpc::ClientAsyncReaderWriterInterface< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* PrepareAsyncCreateNewBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) = 0; virtual ::grpc::ClientWriterInterface< ::backup::SendLogRequest>* SendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response) = 0; virtual ::grpc::ClientAsyncWriterInterface< ::backup::SendLogRequest>* AsyncSendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq, void* tag) = 0; virtual ::grpc::ClientAsyncWriterInterface< ::backup::SendLogRequest>* PrepareAsyncSendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq) = 0; virtual ::grpc::ClientReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* RecoverBackupKeyRaw(::grpc::ClientContext* context) = 0; virtual ::grpc::ClientAsyncReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* AsyncRecoverBackupKeyRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) = 0; virtual ::grpc::ClientAsyncReaderWriterInterface< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* PrepareAsyncRecoverBackupKeyRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) = 0; - virtual ::grpc::ClientReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* PullBackupRaw(::grpc::ClientContext* context) = 0; - virtual ::grpc::ClientAsyncReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* AsyncPullBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) = 0; - virtual ::grpc::ClientAsyncReaderWriterInterface< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* PrepareAsyncPullBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) = 0; + virtual ::grpc::ClientReaderInterface< ::backup::PullBackupResponse>* PullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request) = 0; + virtual ::grpc::ClientAsyncReaderInterface< ::backup::PullBackupResponse>* AsyncPullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq, void* tag) = 0; + virtual ::grpc::ClientAsyncReaderInterface< ::backup::PullBackupResponse>* PrepareAsyncPullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq) = 0; }; class Stub final : public StubInterface { public: Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options = ::grpc::StubOptions()); std::unique_ptr< ::grpc::ClientReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>> CreateNewBackup(::grpc::ClientContext* context) { return std::unique_ptr< ::grpc::ClientReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>>(CreateNewBackupRaw(context)); } std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>> AsyncCreateNewBackup(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { return std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>>(AsyncCreateNewBackupRaw(context, cq, tag)); } std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>> PrepareAsyncCreateNewBackup(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { return std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>>(PrepareAsyncCreateNewBackupRaw(context, cq)); } std::unique_ptr< ::grpc::ClientWriter< ::backup::SendLogRequest>> SendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response) { return std::unique_ptr< ::grpc::ClientWriter< ::backup::SendLogRequest>>(SendLogRaw(context, response)); } std::unique_ptr< ::grpc::ClientAsyncWriter< ::backup::SendLogRequest>> AsyncSendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq, void* tag) { return std::unique_ptr< ::grpc::ClientAsyncWriter< ::backup::SendLogRequest>>(AsyncSendLogRaw(context, response, cq, tag)); } std::unique_ptr< ::grpc::ClientAsyncWriter< ::backup::SendLogRequest>> PrepareAsyncSendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq) { return std::unique_ptr< ::grpc::ClientAsyncWriter< ::backup::SendLogRequest>>(PrepareAsyncSendLogRaw(context, response, cq)); } std::unique_ptr< ::grpc::ClientReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>> RecoverBackupKey(::grpc::ClientContext* context) { return std::unique_ptr< ::grpc::ClientReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>>(RecoverBackupKeyRaw(context)); } std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>> AsyncRecoverBackupKey(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { return std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>>(AsyncRecoverBackupKeyRaw(context, cq, tag)); } std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>> PrepareAsyncRecoverBackupKey(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { return std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>>(PrepareAsyncRecoverBackupKeyRaw(context, cq)); } - std::unique_ptr< ::grpc::ClientReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>> PullBackup(::grpc::ClientContext* context) { - return std::unique_ptr< ::grpc::ClientReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>>(PullBackupRaw(context)); + std::unique_ptr< ::grpc::ClientReader< ::backup::PullBackupResponse>> PullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request) { + return std::unique_ptr< ::grpc::ClientReader< ::backup::PullBackupResponse>>(PullBackupRaw(context, request)); } - std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>> AsyncPullBackup(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) { - return std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>>(AsyncPullBackupRaw(context, cq, tag)); + std::unique_ptr< ::grpc::ClientAsyncReader< ::backup::PullBackupResponse>> AsyncPullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq, void* tag) { + return std::unique_ptr< ::grpc::ClientAsyncReader< ::backup::PullBackupResponse>>(AsyncPullBackupRaw(context, request, cq, tag)); } - std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>> PrepareAsyncPullBackup(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) { - return std::unique_ptr< ::grpc::ClientAsyncReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>>(PrepareAsyncPullBackupRaw(context, cq)); + std::unique_ptr< ::grpc::ClientAsyncReader< ::backup::PullBackupResponse>> PrepareAsyncPullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncReader< ::backup::PullBackupResponse>>(PrepareAsyncPullBackupRaw(context, request, cq)); } class async final : public StubInterface::async_interface { public: void CreateNewBackup(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::CreateNewBackupRequest,::backup::CreateNewBackupResponse>* reactor) override; void SendLog(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::ClientWriteReactor< ::backup::SendLogRequest>* reactor) override; void RecoverBackupKey(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::RecoverBackupKeyRequest,::backup::RecoverBackupKeyResponse>* reactor) override; - void PullBackup(::grpc::ClientContext* context, ::grpc::ClientBidiReactor< ::backup::PullBackupRequest,::backup::PullBackupResponse>* reactor) override; + void PullBackup(::grpc::ClientContext* context, const ::backup::PullBackupRequest* request, ::grpc::ClientReadReactor< ::backup::PullBackupResponse>* reactor) override; private: friend class Stub; explicit async(Stub* stub): stub_(stub) { } Stub* stub() { return stub_; } Stub* stub_; }; class async* async() override { return &async_stub_; } private: std::shared_ptr< ::grpc::ChannelInterface> channel_; class async async_stub_{this}; ::grpc::ClientReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* CreateNewBackupRaw(::grpc::ClientContext* context) override; ::grpc::ClientAsyncReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* AsyncCreateNewBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) override; ::grpc::ClientAsyncReaderWriter< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* PrepareAsyncCreateNewBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) override; ::grpc::ClientWriter< ::backup::SendLogRequest>* SendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response) override; ::grpc::ClientAsyncWriter< ::backup::SendLogRequest>* AsyncSendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq, void* tag) override; ::grpc::ClientAsyncWriter< ::backup::SendLogRequest>* PrepareAsyncSendLogRaw(::grpc::ClientContext* context, ::google::protobuf::Empty* response, ::grpc::CompletionQueue* cq) override; ::grpc::ClientReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* RecoverBackupKeyRaw(::grpc::ClientContext* context) override; ::grpc::ClientAsyncReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* AsyncRecoverBackupKeyRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) override; ::grpc::ClientAsyncReaderWriter< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* PrepareAsyncRecoverBackupKeyRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) override; - ::grpc::ClientReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* PullBackupRaw(::grpc::ClientContext* context) override; - ::grpc::ClientAsyncReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* AsyncPullBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) override; - ::grpc::ClientAsyncReaderWriter< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* PrepareAsyncPullBackupRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) override; + ::grpc::ClientReader< ::backup::PullBackupResponse>* PullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request) override; + ::grpc::ClientAsyncReader< ::backup::PullBackupResponse>* AsyncPullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq, void* tag) override; + ::grpc::ClientAsyncReader< ::backup::PullBackupResponse>* PrepareAsyncPullBackupRaw(::grpc::ClientContext* context, const ::backup::PullBackupRequest& request, ::grpc::CompletionQueue* cq) override; const ::grpc::internal::RpcMethod rpcmethod_CreateNewBackup_; const ::grpc::internal::RpcMethod rpcmethod_SendLog_; const ::grpc::internal::RpcMethod rpcmethod_RecoverBackupKey_; const ::grpc::internal::RpcMethod rpcmethod_PullBackup_; }; static std::unique_ptr 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 CreateNewBackup(::grpc::ServerContext* context, ::grpc::ServerReaderWriter< ::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* stream); virtual ::grpc::Status SendLog(::grpc::ServerContext* context, ::grpc::ServerReader< ::backup::SendLogRequest>* reader, ::google::protobuf::Empty* response); virtual ::grpc::Status RecoverBackupKey(::grpc::ServerContext* context, ::grpc::ServerReaderWriter< ::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* stream); - virtual ::grpc::Status PullBackup(::grpc::ServerContext* context, ::grpc::ServerReaderWriter< ::backup::PullBackupResponse, ::backup::PullBackupRequest>* stream); + virtual ::grpc::Status PullBackup(::grpc::ServerContext* context, const ::backup::PullBackupRequest* request, ::grpc::ServerWriter< ::backup::PullBackupResponse>* writer); }; template class WithAsyncMethod_CreateNewBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithAsyncMethod_CreateNewBackup() { ::grpc::Service::MarkMethodAsync(0); } ~WithAsyncMethod_CreateNewBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status CreateNewBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } void RequestCreateNewBackup(::grpc::ServerContext* context, ::grpc::ServerAsyncReaderWriter< ::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* stream, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { ::grpc::Service::RequestAsyncBidiStreaming(0, context, stream, new_call_cq, notification_cq, tag); } }; template class WithAsyncMethod_SendLog : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithAsyncMethod_SendLog() { ::grpc::Service::MarkMethodAsync(1); } ~WithAsyncMethod_SendLog() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status SendLog(::grpc::ServerContext* /*context*/, ::grpc::ServerReader< ::backup::SendLogRequest>* /*reader*/, ::google::protobuf::Empty* /*response*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } void RequestSendLog(::grpc::ServerContext* context, ::grpc::ServerAsyncReader< ::google::protobuf::Empty, ::backup::SendLogRequest>* reader, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { ::grpc::Service::RequestAsyncClientStreaming(1, context, reader, new_call_cq, notification_cq, tag); } }; template class WithAsyncMethod_RecoverBackupKey : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithAsyncMethod_RecoverBackupKey() { ::grpc::Service::MarkMethodAsync(2); } ~WithAsyncMethod_RecoverBackupKey() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status RecoverBackupKey(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } void RequestRecoverBackupKey(::grpc::ServerContext* context, ::grpc::ServerAsyncReaderWriter< ::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* stream, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { ::grpc::Service::RequestAsyncBidiStreaming(2, context, stream, new_call_cq, notification_cq, tag); } }; template class WithAsyncMethod_PullBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithAsyncMethod_PullBackup() { ::grpc::Service::MarkMethodAsync(3); } ~WithAsyncMethod_PullBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method - ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::PullBackupResponse, ::backup::PullBackupRequest>* /*stream*/) override { + ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, const ::backup::PullBackupRequest* /*request*/, ::grpc::ServerWriter< ::backup::PullBackupResponse>* /*writer*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } - void RequestPullBackup(::grpc::ServerContext* context, ::grpc::ServerAsyncReaderWriter< ::backup::PullBackupResponse, ::backup::PullBackupRequest>* stream, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { - ::grpc::Service::RequestAsyncBidiStreaming(3, context, stream, new_call_cq, notification_cq, tag); + void RequestPullBackup(::grpc::ServerContext* context, ::backup::PullBackupRequest* request, ::grpc::ServerAsyncWriter< ::backup::PullBackupResponse>* writer, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { + ::grpc::Service::RequestAsyncServerStreaming(3, context, request, writer, new_call_cq, notification_cq, tag); } }; typedef WithAsyncMethod_CreateNewBackup > > > AsyncService; template class WithCallbackMethod_CreateNewBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithCallbackMethod_CreateNewBackup() { ::grpc::Service::MarkMethodCallback(0, new ::grpc::internal::CallbackBidiHandler< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>( [this]( ::grpc::CallbackServerContext* context) { return this->CreateNewBackup(context); })); } ~WithCallbackMethod_CreateNewBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status CreateNewBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } virtual ::grpc::ServerBidiReactor< ::backup::CreateNewBackupRequest, ::backup::CreateNewBackupResponse>* CreateNewBackup( ::grpc::CallbackServerContext* /*context*/) { return nullptr; } }; template class WithCallbackMethod_SendLog : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithCallbackMethod_SendLog() { ::grpc::Service::MarkMethodCallback(1, new ::grpc::internal::CallbackClientStreamingHandler< ::backup::SendLogRequest, ::google::protobuf::Empty>( [this]( ::grpc::CallbackServerContext* context, ::google::protobuf::Empty* response) { return this->SendLog(context, response); })); } ~WithCallbackMethod_SendLog() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status SendLog(::grpc::ServerContext* /*context*/, ::grpc::ServerReader< ::backup::SendLogRequest>* /*reader*/, ::google::protobuf::Empty* /*response*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } virtual ::grpc::ServerReadReactor< ::backup::SendLogRequest>* SendLog( ::grpc::CallbackServerContext* /*context*/, ::google::protobuf::Empty* /*response*/) { return nullptr; } }; template class WithCallbackMethod_RecoverBackupKey : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithCallbackMethod_RecoverBackupKey() { ::grpc::Service::MarkMethodCallback(2, new ::grpc::internal::CallbackBidiHandler< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>( [this]( ::grpc::CallbackServerContext* context) { return this->RecoverBackupKey(context); })); } ~WithCallbackMethod_RecoverBackupKey() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status RecoverBackupKey(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } virtual ::grpc::ServerBidiReactor< ::backup::RecoverBackupKeyRequest, ::backup::RecoverBackupKeyResponse>* RecoverBackupKey( ::grpc::CallbackServerContext* /*context*/) { return nullptr; } }; template class WithCallbackMethod_PullBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithCallbackMethod_PullBackup() { ::grpc::Service::MarkMethodCallback(3, - new ::grpc::internal::CallbackBidiHandler< ::backup::PullBackupRequest, ::backup::PullBackupResponse>( + new ::grpc::internal::CallbackServerStreamingHandler< ::backup::PullBackupRequest, ::backup::PullBackupResponse>( [this]( - ::grpc::CallbackServerContext* context) { return this->PullBackup(context); })); + ::grpc::CallbackServerContext* context, const ::backup::PullBackupRequest* request) { return this->PullBackup(context, request); })); } ~WithCallbackMethod_PullBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method - ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::PullBackupResponse, ::backup::PullBackupRequest>* /*stream*/) override { + ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, const ::backup::PullBackupRequest* /*request*/, ::grpc::ServerWriter< ::backup::PullBackupResponse>* /*writer*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } - virtual ::grpc::ServerBidiReactor< ::backup::PullBackupRequest, ::backup::PullBackupResponse>* PullBackup( - ::grpc::CallbackServerContext* /*context*/) - { return nullptr; } + virtual ::grpc::ServerWriteReactor< ::backup::PullBackupResponse>* PullBackup( + ::grpc::CallbackServerContext* /*context*/, const ::backup::PullBackupRequest* /*request*/) { return nullptr; } }; typedef WithCallbackMethod_CreateNewBackup > > > CallbackService; typedef CallbackService ExperimentalCallbackService; template class WithGenericMethod_CreateNewBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithGenericMethod_CreateNewBackup() { ::grpc::Service::MarkMethodGeneric(0); } ~WithGenericMethod_CreateNewBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status CreateNewBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } }; template class WithGenericMethod_SendLog : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithGenericMethod_SendLog() { ::grpc::Service::MarkMethodGeneric(1); } ~WithGenericMethod_SendLog() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status SendLog(::grpc::ServerContext* /*context*/, ::grpc::ServerReader< ::backup::SendLogRequest>* /*reader*/, ::google::protobuf::Empty* /*response*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } }; template class WithGenericMethod_RecoverBackupKey : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithGenericMethod_RecoverBackupKey() { ::grpc::Service::MarkMethodGeneric(2); } ~WithGenericMethod_RecoverBackupKey() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status RecoverBackupKey(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } }; template class WithGenericMethod_PullBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithGenericMethod_PullBackup() { ::grpc::Service::MarkMethodGeneric(3); } ~WithGenericMethod_PullBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method - ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::PullBackupResponse, ::backup::PullBackupRequest>* /*stream*/) override { + ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, const ::backup::PullBackupRequest* /*request*/, ::grpc::ServerWriter< ::backup::PullBackupResponse>* /*writer*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } }; template class WithRawMethod_CreateNewBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithRawMethod_CreateNewBackup() { ::grpc::Service::MarkMethodRaw(0); } ~WithRawMethod_CreateNewBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status CreateNewBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } void RequestCreateNewBackup(::grpc::ServerContext* context, ::grpc::ServerAsyncReaderWriter< ::grpc::ByteBuffer, ::grpc::ByteBuffer>* stream, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { ::grpc::Service::RequestAsyncBidiStreaming(0, context, stream, new_call_cq, notification_cq, tag); } }; template class WithRawMethod_SendLog : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithRawMethod_SendLog() { ::grpc::Service::MarkMethodRaw(1); } ~WithRawMethod_SendLog() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status SendLog(::grpc::ServerContext* /*context*/, ::grpc::ServerReader< ::backup::SendLogRequest>* /*reader*/, ::google::protobuf::Empty* /*response*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } void RequestSendLog(::grpc::ServerContext* context, ::grpc::ServerAsyncReader< ::grpc::ByteBuffer, ::grpc::ByteBuffer>* reader, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { ::grpc::Service::RequestAsyncClientStreaming(1, context, reader, new_call_cq, notification_cq, tag); } }; template class WithRawMethod_RecoverBackupKey : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithRawMethod_RecoverBackupKey() { ::grpc::Service::MarkMethodRaw(2); } ~WithRawMethod_RecoverBackupKey() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status RecoverBackupKey(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } void RequestRecoverBackupKey(::grpc::ServerContext* context, ::grpc::ServerAsyncReaderWriter< ::grpc::ByteBuffer, ::grpc::ByteBuffer>* stream, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { ::grpc::Service::RequestAsyncBidiStreaming(2, context, stream, new_call_cq, notification_cq, tag); } }; template class WithRawMethod_PullBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithRawMethod_PullBackup() { ::grpc::Service::MarkMethodRaw(3); } ~WithRawMethod_PullBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method - ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::PullBackupResponse, ::backup::PullBackupRequest>* /*stream*/) override { + ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, const ::backup::PullBackupRequest* /*request*/, ::grpc::ServerWriter< ::backup::PullBackupResponse>* /*writer*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } - void RequestPullBackup(::grpc::ServerContext* context, ::grpc::ServerAsyncReaderWriter< ::grpc::ByteBuffer, ::grpc::ByteBuffer>* stream, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { - ::grpc::Service::RequestAsyncBidiStreaming(3, context, stream, new_call_cq, notification_cq, tag); + void RequestPullBackup(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncWriter< ::grpc::ByteBuffer>* writer, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { + ::grpc::Service::RequestAsyncServerStreaming(3, context, request, writer, new_call_cq, notification_cq, tag); } }; template class WithRawCallbackMethod_CreateNewBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithRawCallbackMethod_CreateNewBackup() { ::grpc::Service::MarkMethodRawCallback(0, new ::grpc::internal::CallbackBidiHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>( [this]( ::grpc::CallbackServerContext* context) { return this->CreateNewBackup(context); })); } ~WithRawCallbackMethod_CreateNewBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status CreateNewBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::CreateNewBackupResponse, ::backup::CreateNewBackupRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } virtual ::grpc::ServerBidiReactor< ::grpc::ByteBuffer, ::grpc::ByteBuffer>* CreateNewBackup( ::grpc::CallbackServerContext* /*context*/) { return nullptr; } }; template class WithRawCallbackMethod_SendLog : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithRawCallbackMethod_SendLog() { ::grpc::Service::MarkMethodRawCallback(1, new ::grpc::internal::CallbackClientStreamingHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>( [this]( ::grpc::CallbackServerContext* context, ::grpc::ByteBuffer* response) { return this->SendLog(context, response); })); } ~WithRawCallbackMethod_SendLog() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status SendLog(::grpc::ServerContext* /*context*/, ::grpc::ServerReader< ::backup::SendLogRequest>* /*reader*/, ::google::protobuf::Empty* /*response*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } virtual ::grpc::ServerReadReactor< ::grpc::ByteBuffer>* SendLog( ::grpc::CallbackServerContext* /*context*/, ::grpc::ByteBuffer* /*response*/) { return nullptr; } }; template class WithRawCallbackMethod_RecoverBackupKey : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithRawCallbackMethod_RecoverBackupKey() { ::grpc::Service::MarkMethodRawCallback(2, new ::grpc::internal::CallbackBidiHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>( [this]( ::grpc::CallbackServerContext* context) { return this->RecoverBackupKey(context); })); } ~WithRawCallbackMethod_RecoverBackupKey() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method ::grpc::Status RecoverBackupKey(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::RecoverBackupKeyResponse, ::backup::RecoverBackupKeyRequest>* /*stream*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } virtual ::grpc::ServerBidiReactor< ::grpc::ByteBuffer, ::grpc::ByteBuffer>* RecoverBackupKey( ::grpc::CallbackServerContext* /*context*/) { return nullptr; } }; template class WithRawCallbackMethod_PullBackup : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} public: WithRawCallbackMethod_PullBackup() { ::grpc::Service::MarkMethodRawCallback(3, - new ::grpc::internal::CallbackBidiHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>( + new ::grpc::internal::CallbackServerStreamingHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>( [this]( - ::grpc::CallbackServerContext* context) { return this->PullBackup(context); })); + ::grpc::CallbackServerContext* context, const::grpc::ByteBuffer* request) { return this->PullBackup(context, request); })); } ~WithRawCallbackMethod_PullBackup() override { BaseClassMustBeDerivedFromService(this); } // disable synchronous version of this method - ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, ::grpc::ServerReaderWriter< ::backup::PullBackupResponse, ::backup::PullBackupRequest>* /*stream*/) override { + ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, const ::backup::PullBackupRequest* /*request*/, ::grpc::ServerWriter< ::backup::PullBackupResponse>* /*writer*/) override { abort(); return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } - virtual ::grpc::ServerBidiReactor< ::grpc::ByteBuffer, ::grpc::ByteBuffer>* PullBackup( - ::grpc::CallbackServerContext* /*context*/) - { return nullptr; } + virtual ::grpc::ServerWriteReactor< ::grpc::ByteBuffer>* PullBackup( + ::grpc::CallbackServerContext* /*context*/, const ::grpc::ByteBuffer* /*request*/) { return nullptr; } }; typedef Service StreamedUnaryService; - typedef Service SplitStreamedService; - typedef Service StreamedService; + template + class WithSplitStreamingMethod_PullBackup : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} + public: + WithSplitStreamingMethod_PullBackup() { + ::grpc::Service::MarkMethodStreamed(3, + new ::grpc::internal::SplitServerStreamingHandler< + ::backup::PullBackupRequest, ::backup::PullBackupResponse>( + [this](::grpc::ServerContext* context, + ::grpc::ServerSplitStreamer< + ::backup::PullBackupRequest, ::backup::PullBackupResponse>* streamer) { + return this->StreamedPullBackup(context, + streamer); + })); + } + ~WithSplitStreamingMethod_PullBackup() override { + BaseClassMustBeDerivedFromService(this); + } + // disable regular version of this method + ::grpc::Status PullBackup(::grpc::ServerContext* /*context*/, const ::backup::PullBackupRequest* /*request*/, ::grpc::ServerWriter< ::backup::PullBackupResponse>* /*writer*/) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + // replace default version of method with split streamed + virtual ::grpc::Status StreamedPullBackup(::grpc::ServerContext* context, ::grpc::ServerSplitStreamer< ::backup::PullBackupRequest,::backup::PullBackupResponse>* server_split_streamer) = 0; + }; + typedef WithSplitStreamingMethod_PullBackup SplitStreamedService; + typedef WithSplitStreamingMethod_PullBackup StreamedService; }; } // namespace backup #endif // GRPC_backup_2eproto__INCLUDED diff --git a/native/cpp/CommonCpp/grpc/_generated/backup.pb.cc b/native/cpp/CommonCpp/grpc/_generated/backup.pb.cc index 69cf93a2c..a54684fd4 100644 --- a/native/cpp/CommonCpp/grpc/_generated/backup.pb.cc +++ b/native/cpp/CommonCpp/grpc/_generated/backup.pb.cc @@ -1,2023 +1,2028 @@ // @generated by the protocol buffer compiler. DO NOT EDIT! // source: backup.proto #include "backup.pb.h" #include #include #include #include #include #include #include #include // @@protoc_insertion_point(includes) #include PROTOBUF_PRAGMA_INIT_SEG namespace backup { constexpr CreateNewBackupRequest::CreateNewBackupRequest( ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized) : _oneof_case_{}{} struct CreateNewBackupRequestDefaultTypeInternal { constexpr CreateNewBackupRequestDefaultTypeInternal() : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {} ~CreateNewBackupRequestDefaultTypeInternal() {} union { CreateNewBackupRequest _instance; }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT CreateNewBackupRequestDefaultTypeInternal _CreateNewBackupRequest_default_instance_; constexpr CreateNewBackupResponse::CreateNewBackupResponse( ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized) : backupid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){} struct CreateNewBackupResponseDefaultTypeInternal { constexpr CreateNewBackupResponseDefaultTypeInternal() : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {} ~CreateNewBackupResponseDefaultTypeInternal() {} union { CreateNewBackupResponse _instance; }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT CreateNewBackupResponseDefaultTypeInternal _CreateNewBackupResponse_default_instance_; constexpr SendLogRequest::SendLogRequest( ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized) : _oneof_case_{}{} struct SendLogRequestDefaultTypeInternal { constexpr SendLogRequestDefaultTypeInternal() : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {} ~SendLogRequestDefaultTypeInternal() {} union { SendLogRequest _instance; }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT SendLogRequestDefaultTypeInternal _SendLogRequest_default_instance_; constexpr RecoverBackupKeyRequest::RecoverBackupKeyRequest( ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized) : userid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){} struct RecoverBackupKeyRequestDefaultTypeInternal { constexpr RecoverBackupKeyRequestDefaultTypeInternal() : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {} ~RecoverBackupKeyRequestDefaultTypeInternal() {} union { RecoverBackupKeyRequest _instance; }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT RecoverBackupKeyRequestDefaultTypeInternal _RecoverBackupKeyRequest_default_instance_; constexpr RecoverBackupKeyResponse::RecoverBackupKeyResponse( ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized) - : _oneof_case_{}{} + : backupid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){} struct RecoverBackupKeyResponseDefaultTypeInternal { constexpr RecoverBackupKeyResponseDefaultTypeInternal() : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {} ~RecoverBackupKeyResponseDefaultTypeInternal() {} union { RecoverBackupKeyResponse _instance; }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT RecoverBackupKeyResponseDefaultTypeInternal _RecoverBackupKeyResponse_default_instance_; constexpr PullBackupRequest::PullBackupRequest( ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized) - : userid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){} + : userid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string) + , backupid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){} struct PullBackupRequestDefaultTypeInternal { constexpr PullBackupRequestDefaultTypeInternal() : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {} ~PullBackupRequestDefaultTypeInternal() {} union { PullBackupRequest _instance; }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PullBackupRequestDefaultTypeInternal _PullBackupRequest_default_instance_; constexpr PullBackupResponse::PullBackupResponse( ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized) : _oneof_case_{}{} struct PullBackupResponseDefaultTypeInternal { constexpr PullBackupResponseDefaultTypeInternal() : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {} ~PullBackupResponseDefaultTypeInternal() {} union { PullBackupResponse _instance; }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PullBackupResponseDefaultTypeInternal _PullBackupResponse_default_instance_; } // namespace backup static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_backup_2eproto[7]; static constexpr ::PROTOBUF_NAMESPACE_ID::EnumDescriptor const** file_level_enum_descriptors_backup_2eproto = nullptr; static constexpr ::PROTOBUF_NAMESPACE_ID::ServiceDescriptor const** file_level_service_descriptors_backup_2eproto = nullptr; const ::PROTOBUF_NAMESPACE_ID::uint32 TableStruct_backup_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::backup::CreateNewBackupRequest, _internal_metadata_), ~0u, // no _extensions_ PROTOBUF_FIELD_OFFSET(::backup::CreateNewBackupRequest, _oneof_case_[0]), ~0u, // no _weak_field_map_ ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, PROTOBUF_FIELD_OFFSET(::backup::CreateNewBackupRequest, data_), ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::backup::CreateNewBackupResponse, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ PROTOBUF_FIELD_OFFSET(::backup::CreateNewBackupResponse, backupid_), ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::backup::SendLogRequest, _internal_metadata_), ~0u, // no _extensions_ PROTOBUF_FIELD_OFFSET(::backup::SendLogRequest, _oneof_case_[0]), ~0u, // no _weak_field_map_ ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, PROTOBUF_FIELD_OFFSET(::backup::SendLogRequest, data_), ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::backup::RecoverBackupKeyRequest, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ PROTOBUF_FIELD_OFFSET(::backup::RecoverBackupKeyRequest, userid_), ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::backup::RecoverBackupKeyResponse, _internal_metadata_), ~0u, // no _extensions_ - PROTOBUF_FIELD_OFFSET(::backup::RecoverBackupKeyResponse, _oneof_case_[0]), + ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ - ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, - PROTOBUF_FIELD_OFFSET(::backup::RecoverBackupKeyResponse, data_), + PROTOBUF_FIELD_OFFSET(::backup::RecoverBackupKeyResponse, backupid_), ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::backup::PullBackupRequest, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ PROTOBUF_FIELD_OFFSET(::backup::PullBackupRequest, userid_), + PROTOBUF_FIELD_OFFSET(::backup::PullBackupRequest, backupid_), ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::backup::PullBackupResponse, _internal_metadata_), ~0u, // no _extensions_ PROTOBUF_FIELD_OFFSET(::backup::PullBackupResponse, _oneof_case_[0]), ~0u, // no _weak_field_map_ ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, ::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag, PROTOBUF_FIELD_OFFSET(::backup::PullBackupResponse, data_), }; static const ::PROTOBUF_NAMESPACE_ID::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { { 0, -1, sizeof(::backup::CreateNewBackupRequest)}, { 10, -1, sizeof(::backup::CreateNewBackupResponse)}, { 16, -1, sizeof(::backup::SendLogRequest)}, { 26, -1, sizeof(::backup::RecoverBackupKeyRequest)}, { 32, -1, sizeof(::backup::RecoverBackupKeyResponse)}, - { 39, -1, sizeof(::backup::PullBackupRequest)}, + { 38, -1, sizeof(::backup::PullBackupRequest)}, { 45, -1, sizeof(::backup::PullBackupResponse)}, }; static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = { reinterpret_cast(&::backup::_CreateNewBackupRequest_default_instance_), reinterpret_cast(&::backup::_CreateNewBackupResponse_default_instance_), reinterpret_cast(&::backup::_SendLogRequest_default_instance_), reinterpret_cast(&::backup::_RecoverBackupKeyRequest_default_instance_), reinterpret_cast(&::backup::_RecoverBackupKeyResponse_default_instance_), reinterpret_cast(&::backup::_PullBackupRequest_default_instance_), reinterpret_cast(&::backup::_PullBackupResponse_default_instance_), }; const char descriptor_table_protodef_backup_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = "\n\014backup.proto\022\006backup\032\033google/protobuf/" "empty.proto\"\203\001\n\026CreateNewBackupRequest\022\020" "\n\006userID\030\001 \001(\tH\000\022\024\n\nkeyEntropy\030\002 \001(\014H\000\022\033" "\n\021newCompactionHash\030\003 \001(\014H\000\022\034\n\022newCompac" "tionChunk\030\004 \001(\014H\000B\006\n\004data\"+\n\027CreateNewBa" "ckupResponse\022\020\n\010backupID\030\001 \001(\t\"d\n\016SendLo" "gRequest\022\020\n\006userID\030\001 \001(\tH\000\022\022\n\010backupID\030\002" " \001(\tH\000\022\021\n\007logHash\030\003 \001(\014H\000\022\021\n\007logData\030\004 \001" "(\014H\000B\006\n\004data\")\n\027RecoverBackupKeyRequest\022" - "\016\n\006userID\030\001 \001(\t\"6\n\030RecoverBackupKeyRespo" - "nse\022\022\n\010backupID\030\004 \001(\tH\000B\006\n\004data\"#\n\021PullB" - "ackupRequest\022\016\n\006userID\030\001 \001(\t\"K\n\022PullBack" - "upResponse\022\031\n\017compactionChunk\030\001 \001(\014H\000\022\022\n" - "\010logChunk\030\002 \001(\014H\000B\006\n\004data2\320\002\n\rBackupServ" - "ice\022X\n\017CreateNewBackup\022\036.backup.CreateNe" - "wBackupRequest\032\037.backup.CreateNewBackupR" - "esponse\"\000(\0010\001\022=\n\007SendLog\022\026.backup.SendLo" - "gRequest\032\026.google.protobuf.Empty\"\000(\001\022[\n\020" - "RecoverBackupKey\022\037.backup.RecoverBackupK" - "eyRequest\032 .backup.RecoverBackupKeyRespo" - "nse\"\000(\0010\001\022I\n\nPullBackup\022\031.backup.PullBac" - "kupRequest\032\032.backup.PullBackupResponse\"\000" - "(\0010\001b\006proto3" + "\016\n\006userID\030\001 \001(\t\",\n\030RecoverBackupKeyRespo" + "nse\022\020\n\010backupID\030\004 \001(\t\"5\n\021PullBackupReque" + "st\022\016\n\006userID\030\001 \001(\t\022\020\n\010backupID\030\002 \001(\t\"K\n\022" + "PullBackupResponse\022\031\n\017compactionChunk\030\001 " + "\001(\014H\000\022\022\n\010logChunk\030\002 \001(\014H\000B\006\n\004data2\316\002\n\rBa" + "ckupService\022X\n\017CreateNewBackup\022\036.backup." + "CreateNewBackupRequest\032\037.backup.CreateNe" + "wBackupResponse\"\000(\0010\001\022=\n\007SendLog\022\026.backu" + "p.SendLogRequest\032\026.google.protobuf.Empty" + "\"\000(\001\022[\n\020RecoverBackupKey\022\037.backup.Recove" + "rBackupKeyRequest\032 .backup.RecoverBackup" + "KeyResponse\"\000(\0010\001\022G\n\nPullBackup\022\031.backup" + ".PullBackupRequest\032\032.backup.PullBackupRe" + "sponse\"\0000\001b\006proto3" ; static const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable*const descriptor_table_backup_2eproto_deps[1] = { &::descriptor_table_google_2fprotobuf_2fempty_2eproto, }; static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_backup_2eproto_once; const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_backup_2eproto = { - false, false, 892, descriptor_table_protodef_backup_2eproto, "backup.proto", + false, false, 898, descriptor_table_protodef_backup_2eproto, "backup.proto", &descriptor_table_backup_2eproto_once, descriptor_table_backup_2eproto_deps, 1, 7, schemas, file_default_instances, TableStruct_backup_2eproto::offsets, file_level_metadata_backup_2eproto, file_level_enum_descriptors_backup_2eproto, file_level_service_descriptors_backup_2eproto, }; PROTOBUF_ATTRIBUTE_WEAK ::PROTOBUF_NAMESPACE_ID::Metadata descriptor_table_backup_2eproto_metadata_getter(int index) { ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_backup_2eproto); return descriptor_table_backup_2eproto.file_level_metadata[index]; } // Force running AddDescriptors() at dynamic initialization time. PROTOBUF_ATTRIBUTE_INIT_PRIORITY static ::PROTOBUF_NAMESPACE_ID::internal::AddDescriptorsRunner dynamic_init_dummy_backup_2eproto(&descriptor_table_backup_2eproto); namespace backup { // =================================================================== class CreateNewBackupRequest::_Internal { public: }; CreateNewBackupRequest::CreateNewBackupRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena) : ::PROTOBUF_NAMESPACE_ID::Message(arena) { SharedCtor(); RegisterArenaDtor(arena); // @@protoc_insertion_point(arena_constructor:backup.CreateNewBackupRequest) } CreateNewBackupRequest::CreateNewBackupRequest(const CreateNewBackupRequest& from) : ::PROTOBUF_NAMESPACE_ID::Message() { _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); clear_has_data(); switch (from.data_case()) { case kUserID: { _internal_set_userid(from._internal_userid()); break; } case kKeyEntropy: { _internal_set_keyentropy(from._internal_keyentropy()); break; } case kNewCompactionHash: { _internal_set_newcompactionhash(from._internal_newcompactionhash()); break; } case kNewCompactionChunk: { _internal_set_newcompactionchunk(from._internal_newcompactionchunk()); break; } case DATA_NOT_SET: { break; } } // @@protoc_insertion_point(copy_constructor:backup.CreateNewBackupRequest) } void CreateNewBackupRequest::SharedCtor() { clear_has_data(); } CreateNewBackupRequest::~CreateNewBackupRequest() { // @@protoc_insertion_point(destructor:backup.CreateNewBackupRequest) SharedDtor(); _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } void CreateNewBackupRequest::SharedDtor() { GOOGLE_DCHECK(GetArena() == nullptr); if (has_data()) { clear_data(); } } void CreateNewBackupRequest::ArenaDtor(void* object) { CreateNewBackupRequest* _this = reinterpret_cast< CreateNewBackupRequest* >(object); (void)_this; } void CreateNewBackupRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) { } void CreateNewBackupRequest::SetCachedSize(int size) const { _cached_size_.Set(size); } void CreateNewBackupRequest::clear_data() { // @@protoc_insertion_point(one_of_clear_start:backup.CreateNewBackupRequest) switch (data_case()) { case kUserID: { data_.userid_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case kKeyEntropy: { data_.keyentropy_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case kNewCompactionHash: { data_.newcompactionhash_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case kNewCompactionChunk: { data_.newcompactionchunk_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case DATA_NOT_SET: { break; } } _oneof_case_[0] = DATA_NOT_SET; } void CreateNewBackupRequest::Clear() { // @@protoc_insertion_point(message_clear_start:backup.CreateNewBackupRequest) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; clear_data(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } const char* CreateNewBackupRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure while (!ctx->Done(&ptr)) { ::PROTOBUF_NAMESPACE_ID::uint32 tag; ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); CHK_(ptr); switch (tag >> 3) { // string userID = 1; case 1: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { auto str = _internal_mutable_userid(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "backup.CreateNewBackupRequest.userID")); CHK_(ptr); } else goto handle_unusual; continue; // bytes keyEntropy = 2; case 2: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) { auto str = _internal_mutable_keyentropy(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(ptr); } else goto handle_unusual; continue; // bytes newCompactionHash = 3; case 3: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 26)) { auto str = _internal_mutable_newcompactionhash(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(ptr); } else goto handle_unusual; continue; // bytes newCompactionChunk = 4; case 4: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 34)) { auto str = _internal_mutable_newcompactionchunk(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(ptr); } else goto handle_unusual; continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { ctx->SetLastTag(tag); goto success; } ptr = UnknownFieldParse(tag, _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), ptr, ctx); CHK_(ptr != nullptr); continue; } } // switch } // while success: return ptr; failure: ptr = nullptr; goto success; #undef CHK_ } ::PROTOBUF_NAMESPACE_ID::uint8* CreateNewBackupRequest::_InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { // @@protoc_insertion_point(serialize_to_array_start:backup.CreateNewBackupRequest) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; // string userID = 1; if (_internal_has_userid()) { ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( this->_internal_userid().data(), static_cast(this->_internal_userid().length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "backup.CreateNewBackupRequest.userID"); target = stream->WriteStringMaybeAliased( 1, this->_internal_userid(), target); } // bytes keyEntropy = 2; if (_internal_has_keyentropy()) { target = stream->WriteBytesMaybeAliased( 2, this->_internal_keyentropy(), target); } // bytes newCompactionHash = 3; if (_internal_has_newcompactionhash()) { target = stream->WriteBytesMaybeAliased( 3, this->_internal_newcompactionhash(), target); } // bytes newCompactionChunk = 4; if (_internal_has_newcompactionchunk()) { target = stream->WriteBytesMaybeAliased( 4, this->_internal_newcompactionchunk(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); } // @@protoc_insertion_point(serialize_to_array_end:backup.CreateNewBackupRequest) return target; } size_t CreateNewBackupRequest::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:backup.CreateNewBackupRequest) size_t total_size = 0; ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; switch (data_case()) { // string userID = 1; case kUserID: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( this->_internal_userid()); break; } // bytes keyEntropy = 2; case kKeyEntropy: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::BytesSize( this->_internal_keyentropy()); break; } // bytes newCompactionHash = 3; case kNewCompactionHash: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::BytesSize( this->_internal_newcompactionhash()); break; } // bytes newCompactionChunk = 4; case kNewCompactionChunk: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::BytesSize( this->_internal_newcompactionchunk()); break; } case DATA_NOT_SET: { break; } } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); } int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); SetCachedSize(cached_size); return total_size; } void CreateNewBackupRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:backup.CreateNewBackupRequest) GOOGLE_DCHECK_NE(&from, this); const CreateNewBackupRequest* source = ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated( &from); if (source == nullptr) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:backup.CreateNewBackupRequest) ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:backup.CreateNewBackupRequest) MergeFrom(*source); } } void CreateNewBackupRequest::MergeFrom(const CreateNewBackupRequest& from) { // @@protoc_insertion_point(class_specific_merge_from_start:backup.CreateNewBackupRequest) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; switch (from.data_case()) { case kUserID: { _internal_set_userid(from._internal_userid()); break; } case kKeyEntropy: { _internal_set_keyentropy(from._internal_keyentropy()); break; } case kNewCompactionHash: { _internal_set_newcompactionhash(from._internal_newcompactionhash()); break; } case kNewCompactionChunk: { _internal_set_newcompactionchunk(from._internal_newcompactionchunk()); break; } case DATA_NOT_SET: { break; } } } void CreateNewBackupRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:backup.CreateNewBackupRequest) if (&from == this) return; Clear(); MergeFrom(from); } void CreateNewBackupRequest::CopyFrom(const CreateNewBackupRequest& from) { // @@protoc_insertion_point(class_specific_copy_from_start:backup.CreateNewBackupRequest) if (&from == this) return; Clear(); MergeFrom(from); } bool CreateNewBackupRequest::IsInitialized() const { return true; } void CreateNewBackupRequest::InternalSwap(CreateNewBackupRequest* other) { using std::swap; _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_); swap(data_, other->data_); swap(_oneof_case_[0], other->_oneof_case_[0]); } ::PROTOBUF_NAMESPACE_ID::Metadata CreateNewBackupRequest::GetMetadata() const { return GetMetadataStatic(); } // =================================================================== class CreateNewBackupResponse::_Internal { public: }; CreateNewBackupResponse::CreateNewBackupResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena) : ::PROTOBUF_NAMESPACE_ID::Message(arena) { SharedCtor(); RegisterArenaDtor(arena); // @@protoc_insertion_point(arena_constructor:backup.CreateNewBackupResponse) } CreateNewBackupResponse::CreateNewBackupResponse(const CreateNewBackupResponse& from) : ::PROTOBUF_NAMESPACE_ID::Message() { _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); if (!from._internal_backupid().empty()) { backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_backupid(), GetArena()); } // @@protoc_insertion_point(copy_constructor:backup.CreateNewBackupResponse) } void CreateNewBackupResponse::SharedCtor() { backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } CreateNewBackupResponse::~CreateNewBackupResponse() { // @@protoc_insertion_point(destructor:backup.CreateNewBackupResponse) SharedDtor(); _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } void CreateNewBackupResponse::SharedDtor() { GOOGLE_DCHECK(GetArena() == nullptr); backupid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } void CreateNewBackupResponse::ArenaDtor(void* object) { CreateNewBackupResponse* _this = reinterpret_cast< CreateNewBackupResponse* >(object); (void)_this; } void CreateNewBackupResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) { } void CreateNewBackupResponse::SetCachedSize(int size) const { _cached_size_.Set(size); } void CreateNewBackupResponse::Clear() { // @@protoc_insertion_point(message_clear_start:backup.CreateNewBackupResponse) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; backupid_.ClearToEmpty(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } const char* CreateNewBackupResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure while (!ctx->Done(&ptr)) { ::PROTOBUF_NAMESPACE_ID::uint32 tag; ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); CHK_(ptr); switch (tag >> 3) { // string backupID = 1; case 1: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { auto str = _internal_mutable_backupid(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "backup.CreateNewBackupResponse.backupID")); CHK_(ptr); } else goto handle_unusual; continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { ctx->SetLastTag(tag); goto success; } ptr = UnknownFieldParse(tag, _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), ptr, ctx); CHK_(ptr != nullptr); continue; } } // switch } // while success: return ptr; failure: ptr = nullptr; goto success; #undef CHK_ } ::PROTOBUF_NAMESPACE_ID::uint8* CreateNewBackupResponse::_InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { // @@protoc_insertion_point(serialize_to_array_start:backup.CreateNewBackupResponse) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; // string backupID = 1; if (this->backupid().size() > 0) { ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( this->_internal_backupid().data(), static_cast(this->_internal_backupid().length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "backup.CreateNewBackupResponse.backupID"); target = stream->WriteStringMaybeAliased( 1, this->_internal_backupid(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); } // @@protoc_insertion_point(serialize_to_array_end:backup.CreateNewBackupResponse) return target; } size_t CreateNewBackupResponse::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:backup.CreateNewBackupResponse) size_t total_size = 0; ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; // string backupID = 1; if (this->backupid().size() > 0) { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( this->_internal_backupid()); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); } int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); SetCachedSize(cached_size); return total_size; } void CreateNewBackupResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:backup.CreateNewBackupResponse) GOOGLE_DCHECK_NE(&from, this); const CreateNewBackupResponse* source = ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated( &from); if (source == nullptr) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:backup.CreateNewBackupResponse) ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:backup.CreateNewBackupResponse) MergeFrom(*source); } } void CreateNewBackupResponse::MergeFrom(const CreateNewBackupResponse& from) { // @@protoc_insertion_point(class_specific_merge_from_start:backup.CreateNewBackupResponse) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; if (from.backupid().size() > 0) { _internal_set_backupid(from._internal_backupid()); } } void CreateNewBackupResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:backup.CreateNewBackupResponse) if (&from == this) return; Clear(); MergeFrom(from); } void CreateNewBackupResponse::CopyFrom(const CreateNewBackupResponse& from) { // @@protoc_insertion_point(class_specific_copy_from_start:backup.CreateNewBackupResponse) if (&from == this) return; Clear(); MergeFrom(from); } bool CreateNewBackupResponse::IsInitialized() const { return true; } void CreateNewBackupResponse::InternalSwap(CreateNewBackupResponse* other) { using std::swap; _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_); backupid_.Swap(&other->backupid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } ::PROTOBUF_NAMESPACE_ID::Metadata CreateNewBackupResponse::GetMetadata() const { return GetMetadataStatic(); } // =================================================================== class SendLogRequest::_Internal { public: }; SendLogRequest::SendLogRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena) : ::PROTOBUF_NAMESPACE_ID::Message(arena) { SharedCtor(); RegisterArenaDtor(arena); // @@protoc_insertion_point(arena_constructor:backup.SendLogRequest) } SendLogRequest::SendLogRequest(const SendLogRequest& from) : ::PROTOBUF_NAMESPACE_ID::Message() { _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); clear_has_data(); switch (from.data_case()) { case kUserID: { _internal_set_userid(from._internal_userid()); break; } case kBackupID: { _internal_set_backupid(from._internal_backupid()); break; } case kLogHash: { _internal_set_loghash(from._internal_loghash()); break; } case kLogData: { _internal_set_logdata(from._internal_logdata()); break; } case DATA_NOT_SET: { break; } } // @@protoc_insertion_point(copy_constructor:backup.SendLogRequest) } void SendLogRequest::SharedCtor() { clear_has_data(); } SendLogRequest::~SendLogRequest() { // @@protoc_insertion_point(destructor:backup.SendLogRequest) SharedDtor(); _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } void SendLogRequest::SharedDtor() { GOOGLE_DCHECK(GetArena() == nullptr); if (has_data()) { clear_data(); } } void SendLogRequest::ArenaDtor(void* object) { SendLogRequest* _this = reinterpret_cast< SendLogRequest* >(object); (void)_this; } void SendLogRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) { } void SendLogRequest::SetCachedSize(int size) const { _cached_size_.Set(size); } void SendLogRequest::clear_data() { // @@protoc_insertion_point(one_of_clear_start:backup.SendLogRequest) switch (data_case()) { case kUserID: { data_.userid_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case kBackupID: { data_.backupid_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case kLogHash: { data_.loghash_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case kLogData: { data_.logdata_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case DATA_NOT_SET: { break; } } _oneof_case_[0] = DATA_NOT_SET; } void SendLogRequest::Clear() { // @@protoc_insertion_point(message_clear_start:backup.SendLogRequest) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; clear_data(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } const char* SendLogRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure while (!ctx->Done(&ptr)) { ::PROTOBUF_NAMESPACE_ID::uint32 tag; ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); CHK_(ptr); switch (tag >> 3) { // string userID = 1; case 1: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { auto str = _internal_mutable_userid(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "backup.SendLogRequest.userID")); CHK_(ptr); } else goto handle_unusual; continue; // string backupID = 2; case 2: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) { auto str = _internal_mutable_backupid(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "backup.SendLogRequest.backupID")); CHK_(ptr); } else goto handle_unusual; continue; // bytes logHash = 3; case 3: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 26)) { auto str = _internal_mutable_loghash(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(ptr); } else goto handle_unusual; continue; // bytes logData = 4; case 4: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 34)) { auto str = _internal_mutable_logdata(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(ptr); } else goto handle_unusual; continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { ctx->SetLastTag(tag); goto success; } ptr = UnknownFieldParse(tag, _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), ptr, ctx); CHK_(ptr != nullptr); continue; } } // switch } // while success: return ptr; failure: ptr = nullptr; goto success; #undef CHK_ } ::PROTOBUF_NAMESPACE_ID::uint8* SendLogRequest::_InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { // @@protoc_insertion_point(serialize_to_array_start:backup.SendLogRequest) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; // string userID = 1; if (_internal_has_userid()) { ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( this->_internal_userid().data(), static_cast(this->_internal_userid().length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "backup.SendLogRequest.userID"); target = stream->WriteStringMaybeAliased( 1, this->_internal_userid(), target); } // string backupID = 2; if (_internal_has_backupid()) { ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( this->_internal_backupid().data(), static_cast(this->_internal_backupid().length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "backup.SendLogRequest.backupID"); target = stream->WriteStringMaybeAliased( 2, this->_internal_backupid(), target); } // bytes logHash = 3; if (_internal_has_loghash()) { target = stream->WriteBytesMaybeAliased( 3, this->_internal_loghash(), target); } // bytes logData = 4; if (_internal_has_logdata()) { target = stream->WriteBytesMaybeAliased( 4, this->_internal_logdata(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); } // @@protoc_insertion_point(serialize_to_array_end:backup.SendLogRequest) return target; } size_t SendLogRequest::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:backup.SendLogRequest) size_t total_size = 0; ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; switch (data_case()) { // string userID = 1; case kUserID: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( this->_internal_userid()); break; } // string backupID = 2; case kBackupID: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( this->_internal_backupid()); break; } // bytes logHash = 3; case kLogHash: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::BytesSize( this->_internal_loghash()); break; } // bytes logData = 4; case kLogData: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::BytesSize( this->_internal_logdata()); break; } case DATA_NOT_SET: { break; } } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); } int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); SetCachedSize(cached_size); return total_size; } void SendLogRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:backup.SendLogRequest) GOOGLE_DCHECK_NE(&from, this); const SendLogRequest* source = ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated( &from); if (source == nullptr) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:backup.SendLogRequest) ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:backup.SendLogRequest) MergeFrom(*source); } } void SendLogRequest::MergeFrom(const SendLogRequest& from) { // @@protoc_insertion_point(class_specific_merge_from_start:backup.SendLogRequest) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; switch (from.data_case()) { case kUserID: { _internal_set_userid(from._internal_userid()); break; } case kBackupID: { _internal_set_backupid(from._internal_backupid()); break; } case kLogHash: { _internal_set_loghash(from._internal_loghash()); break; } case kLogData: { _internal_set_logdata(from._internal_logdata()); break; } case DATA_NOT_SET: { break; } } } void SendLogRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:backup.SendLogRequest) if (&from == this) return; Clear(); MergeFrom(from); } void SendLogRequest::CopyFrom(const SendLogRequest& from) { // @@protoc_insertion_point(class_specific_copy_from_start:backup.SendLogRequest) if (&from == this) return; Clear(); MergeFrom(from); } bool SendLogRequest::IsInitialized() const { return true; } void SendLogRequest::InternalSwap(SendLogRequest* other) { using std::swap; _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_); swap(data_, other->data_); swap(_oneof_case_[0], other->_oneof_case_[0]); } ::PROTOBUF_NAMESPACE_ID::Metadata SendLogRequest::GetMetadata() const { return GetMetadataStatic(); } // =================================================================== class RecoverBackupKeyRequest::_Internal { public: }; RecoverBackupKeyRequest::RecoverBackupKeyRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena) : ::PROTOBUF_NAMESPACE_ID::Message(arena) { SharedCtor(); RegisterArenaDtor(arena); // @@protoc_insertion_point(arena_constructor:backup.RecoverBackupKeyRequest) } RecoverBackupKeyRequest::RecoverBackupKeyRequest(const RecoverBackupKeyRequest& from) : ::PROTOBUF_NAMESPACE_ID::Message() { _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); if (!from._internal_userid().empty()) { userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_userid(), GetArena()); } // @@protoc_insertion_point(copy_constructor:backup.RecoverBackupKeyRequest) } void RecoverBackupKeyRequest::SharedCtor() { userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } RecoverBackupKeyRequest::~RecoverBackupKeyRequest() { // @@protoc_insertion_point(destructor:backup.RecoverBackupKeyRequest) SharedDtor(); _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } void RecoverBackupKeyRequest::SharedDtor() { GOOGLE_DCHECK(GetArena() == nullptr); userid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } void RecoverBackupKeyRequest::ArenaDtor(void* object) { RecoverBackupKeyRequest* _this = reinterpret_cast< RecoverBackupKeyRequest* >(object); (void)_this; } void RecoverBackupKeyRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) { } void RecoverBackupKeyRequest::SetCachedSize(int size) const { _cached_size_.Set(size); } void RecoverBackupKeyRequest::Clear() { // @@protoc_insertion_point(message_clear_start:backup.RecoverBackupKeyRequest) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; userid_.ClearToEmpty(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } const char* RecoverBackupKeyRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure while (!ctx->Done(&ptr)) { ::PROTOBUF_NAMESPACE_ID::uint32 tag; ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); CHK_(ptr); switch (tag >> 3) { // string userID = 1; case 1: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { auto str = _internal_mutable_userid(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "backup.RecoverBackupKeyRequest.userID")); CHK_(ptr); } else goto handle_unusual; continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { ctx->SetLastTag(tag); goto success; } ptr = UnknownFieldParse(tag, _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), ptr, ctx); CHK_(ptr != nullptr); continue; } } // switch } // while success: return ptr; failure: ptr = nullptr; goto success; #undef CHK_ } ::PROTOBUF_NAMESPACE_ID::uint8* RecoverBackupKeyRequest::_InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { // @@protoc_insertion_point(serialize_to_array_start:backup.RecoverBackupKeyRequest) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; // string userID = 1; if (this->userid().size() > 0) { ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( this->_internal_userid().data(), static_cast(this->_internal_userid().length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "backup.RecoverBackupKeyRequest.userID"); target = stream->WriteStringMaybeAliased( 1, this->_internal_userid(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); } // @@protoc_insertion_point(serialize_to_array_end:backup.RecoverBackupKeyRequest) return target; } size_t RecoverBackupKeyRequest::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:backup.RecoverBackupKeyRequest) size_t total_size = 0; ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; // string userID = 1; if (this->userid().size() > 0) { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( this->_internal_userid()); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); } int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); SetCachedSize(cached_size); return total_size; } void RecoverBackupKeyRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:backup.RecoverBackupKeyRequest) GOOGLE_DCHECK_NE(&from, this); const RecoverBackupKeyRequest* source = ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated( &from); if (source == nullptr) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:backup.RecoverBackupKeyRequest) ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:backup.RecoverBackupKeyRequest) MergeFrom(*source); } } void RecoverBackupKeyRequest::MergeFrom(const RecoverBackupKeyRequest& from) { // @@protoc_insertion_point(class_specific_merge_from_start:backup.RecoverBackupKeyRequest) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; if (from.userid().size() > 0) { _internal_set_userid(from._internal_userid()); } } void RecoverBackupKeyRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:backup.RecoverBackupKeyRequest) if (&from == this) return; Clear(); MergeFrom(from); } void RecoverBackupKeyRequest::CopyFrom(const RecoverBackupKeyRequest& from) { // @@protoc_insertion_point(class_specific_copy_from_start:backup.RecoverBackupKeyRequest) if (&from == this) return; Clear(); MergeFrom(from); } bool RecoverBackupKeyRequest::IsInitialized() const { return true; } void RecoverBackupKeyRequest::InternalSwap(RecoverBackupKeyRequest* other) { using std::swap; _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_); userid_.Swap(&other->userid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } ::PROTOBUF_NAMESPACE_ID::Metadata RecoverBackupKeyRequest::GetMetadata() const { return GetMetadataStatic(); } // =================================================================== class RecoverBackupKeyResponse::_Internal { public: }; RecoverBackupKeyResponse::RecoverBackupKeyResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena) : ::PROTOBUF_NAMESPACE_ID::Message(arena) { SharedCtor(); RegisterArenaDtor(arena); // @@protoc_insertion_point(arena_constructor:backup.RecoverBackupKeyResponse) } RecoverBackupKeyResponse::RecoverBackupKeyResponse(const RecoverBackupKeyResponse& from) : ::PROTOBUF_NAMESPACE_ID::Message() { _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); - clear_has_data(); - switch (from.data_case()) { - case kBackupID: { - _internal_set_backupid(from._internal_backupid()); - break; - } - case DATA_NOT_SET: { - break; - } + backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); + if (!from._internal_backupid().empty()) { + backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_backupid(), + GetArena()); } // @@protoc_insertion_point(copy_constructor:backup.RecoverBackupKeyResponse) } void RecoverBackupKeyResponse::SharedCtor() { -clear_has_data(); +backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } RecoverBackupKeyResponse::~RecoverBackupKeyResponse() { // @@protoc_insertion_point(destructor:backup.RecoverBackupKeyResponse) SharedDtor(); _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } void RecoverBackupKeyResponse::SharedDtor() { GOOGLE_DCHECK(GetArena() == nullptr); - if (has_data()) { - clear_data(); - } + backupid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } void RecoverBackupKeyResponse::ArenaDtor(void* object) { RecoverBackupKeyResponse* _this = reinterpret_cast< RecoverBackupKeyResponse* >(object); (void)_this; } void RecoverBackupKeyResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) { } void RecoverBackupKeyResponse::SetCachedSize(int size) const { _cached_size_.Set(size); } -void RecoverBackupKeyResponse::clear_data() { -// @@protoc_insertion_point(one_of_clear_start:backup.RecoverBackupKeyResponse) - switch (data_case()) { - case kBackupID: { - data_.backupid_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); - break; - } - case DATA_NOT_SET: { - break; - } - } - _oneof_case_[0] = DATA_NOT_SET; -} - - void RecoverBackupKeyResponse::Clear() { // @@protoc_insertion_point(message_clear_start:backup.RecoverBackupKeyResponse) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; - clear_data(); + backupid_.ClearToEmpty(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } const char* RecoverBackupKeyResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure while (!ctx->Done(&ptr)) { ::PROTOBUF_NAMESPACE_ID::uint32 tag; ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); CHK_(ptr); switch (tag >> 3) { // string backupID = 4; case 4: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 34)) { auto str = _internal_mutable_backupid(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "backup.RecoverBackupKeyResponse.backupID")); CHK_(ptr); } else goto handle_unusual; continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { ctx->SetLastTag(tag); goto success; } ptr = UnknownFieldParse(tag, _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), ptr, ctx); CHK_(ptr != nullptr); continue; } } // switch } // while success: return ptr; failure: ptr = nullptr; goto success; #undef CHK_ } ::PROTOBUF_NAMESPACE_ID::uint8* RecoverBackupKeyResponse::_InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { // @@protoc_insertion_point(serialize_to_array_start:backup.RecoverBackupKeyResponse) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; // string backupID = 4; - if (_internal_has_backupid()) { + if (this->backupid().size() > 0) { ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( this->_internal_backupid().data(), static_cast(this->_internal_backupid().length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "backup.RecoverBackupKeyResponse.backupID"); target = stream->WriteStringMaybeAliased( 4, this->_internal_backupid(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); } // @@protoc_insertion_point(serialize_to_array_end:backup.RecoverBackupKeyResponse) return target; } size_t RecoverBackupKeyResponse::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:backup.RecoverBackupKeyResponse) size_t total_size = 0; ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; - switch (data_case()) { - // string backupID = 4; - case kBackupID: { - total_size += 1 + - ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( - this->_internal_backupid()); - break; - } - case DATA_NOT_SET: { - break; - } + // string backupID = 4; + if (this->backupid().size() > 0) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_backupid()); } + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); } int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); SetCachedSize(cached_size); return total_size; } void RecoverBackupKeyResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:backup.RecoverBackupKeyResponse) GOOGLE_DCHECK_NE(&from, this); const RecoverBackupKeyResponse* source = ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated( &from); if (source == nullptr) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:backup.RecoverBackupKeyResponse) ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:backup.RecoverBackupKeyResponse) MergeFrom(*source); } } void RecoverBackupKeyResponse::MergeFrom(const RecoverBackupKeyResponse& from) { // @@protoc_insertion_point(class_specific_merge_from_start:backup.RecoverBackupKeyResponse) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; - switch (from.data_case()) { - case kBackupID: { - _internal_set_backupid(from._internal_backupid()); - break; - } - case DATA_NOT_SET: { - break; - } + if (from.backupid().size() > 0) { + _internal_set_backupid(from._internal_backupid()); } } void RecoverBackupKeyResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:backup.RecoverBackupKeyResponse) if (&from == this) return; Clear(); MergeFrom(from); } void RecoverBackupKeyResponse::CopyFrom(const RecoverBackupKeyResponse& from) { // @@protoc_insertion_point(class_specific_copy_from_start:backup.RecoverBackupKeyResponse) if (&from == this) return; Clear(); MergeFrom(from); } bool RecoverBackupKeyResponse::IsInitialized() const { return true; } void RecoverBackupKeyResponse::InternalSwap(RecoverBackupKeyResponse* other) { using std::swap; _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_); - swap(data_, other->data_); - swap(_oneof_case_[0], other->_oneof_case_[0]); + backupid_.Swap(&other->backupid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } ::PROTOBUF_NAMESPACE_ID::Metadata RecoverBackupKeyResponse::GetMetadata() const { return GetMetadataStatic(); } // =================================================================== class PullBackupRequest::_Internal { public: }; PullBackupRequest::PullBackupRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena) : ::PROTOBUF_NAMESPACE_ID::Message(arena) { SharedCtor(); RegisterArenaDtor(arena); // @@protoc_insertion_point(arena_constructor:backup.PullBackupRequest) } PullBackupRequest::PullBackupRequest(const PullBackupRequest& from) : ::PROTOBUF_NAMESPACE_ID::Message() { _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); if (!from._internal_userid().empty()) { userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_userid(), GetArena()); } + backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); + if (!from._internal_backupid().empty()) { + backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_backupid(), + GetArena()); + } // @@protoc_insertion_point(copy_constructor:backup.PullBackupRequest) } void PullBackupRequest::SharedCtor() { userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); +backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } PullBackupRequest::~PullBackupRequest() { // @@protoc_insertion_point(destructor:backup.PullBackupRequest) SharedDtor(); _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } void PullBackupRequest::SharedDtor() { GOOGLE_DCHECK(GetArena() == nullptr); userid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); + backupid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } void PullBackupRequest::ArenaDtor(void* object) { PullBackupRequest* _this = reinterpret_cast< PullBackupRequest* >(object); (void)_this; } void PullBackupRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) { } void PullBackupRequest::SetCachedSize(int size) const { _cached_size_.Set(size); } void PullBackupRequest::Clear() { // @@protoc_insertion_point(message_clear_start:backup.PullBackupRequest) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; userid_.ClearToEmpty(); + backupid_.ClearToEmpty(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } const char* PullBackupRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure while (!ctx->Done(&ptr)) { ::PROTOBUF_NAMESPACE_ID::uint32 tag; ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); CHK_(ptr); switch (tag >> 3) { // string userID = 1; case 1: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { auto str = _internal_mutable_userid(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "backup.PullBackupRequest.userID")); CHK_(ptr); } else goto handle_unusual; continue; + // string backupID = 2; + case 2: + if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) { + auto str = _internal_mutable_backupid(); + ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); + CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "backup.PullBackupRequest.backupID")); + CHK_(ptr); + } else goto handle_unusual; + continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { ctx->SetLastTag(tag); goto success; } ptr = UnknownFieldParse(tag, _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), ptr, ctx); CHK_(ptr != nullptr); continue; } } // switch } // while success: return ptr; failure: ptr = nullptr; goto success; #undef CHK_ } ::PROTOBUF_NAMESPACE_ID::uint8* PullBackupRequest::_InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { // @@protoc_insertion_point(serialize_to_array_start:backup.PullBackupRequest) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; // string userID = 1; if (this->userid().size() > 0) { ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( this->_internal_userid().data(), static_cast(this->_internal_userid().length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "backup.PullBackupRequest.userID"); target = stream->WriteStringMaybeAliased( 1, this->_internal_userid(), target); } + // string backupID = 2; + if (this->backupid().size() > 0) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_backupid().data(), static_cast(this->_internal_backupid().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "backup.PullBackupRequest.backupID"); + target = stream->WriteStringMaybeAliased( + 2, this->_internal_backupid(), target); + } + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); } // @@protoc_insertion_point(serialize_to_array_end:backup.PullBackupRequest) return target; } size_t PullBackupRequest::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:backup.PullBackupRequest) size_t total_size = 0; ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; // string userID = 1; if (this->userid().size() > 0) { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( this->_internal_userid()); } + // string backupID = 2; + if (this->backupid().size() > 0) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_backupid()); + } + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); } int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); SetCachedSize(cached_size); return total_size; } void PullBackupRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:backup.PullBackupRequest) GOOGLE_DCHECK_NE(&from, this); const PullBackupRequest* source = ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated( &from); if (source == nullptr) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:backup.PullBackupRequest) ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:backup.PullBackupRequest) MergeFrom(*source); } } void PullBackupRequest::MergeFrom(const PullBackupRequest& from) { // @@protoc_insertion_point(class_specific_merge_from_start:backup.PullBackupRequest) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; if (from.userid().size() > 0) { _internal_set_userid(from._internal_userid()); } + if (from.backupid().size() > 0) { + _internal_set_backupid(from._internal_backupid()); + } } void PullBackupRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:backup.PullBackupRequest) if (&from == this) return; Clear(); MergeFrom(from); } void PullBackupRequest::CopyFrom(const PullBackupRequest& from) { // @@protoc_insertion_point(class_specific_copy_from_start:backup.PullBackupRequest) if (&from == this) return; Clear(); MergeFrom(from); } bool PullBackupRequest::IsInitialized() const { return true; } void PullBackupRequest::InternalSwap(PullBackupRequest* other) { using std::swap; _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_); userid_.Swap(&other->userid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); + backupid_.Swap(&other->backupid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } ::PROTOBUF_NAMESPACE_ID::Metadata PullBackupRequest::GetMetadata() const { return GetMetadataStatic(); } // =================================================================== class PullBackupResponse::_Internal { public: }; PullBackupResponse::PullBackupResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena) : ::PROTOBUF_NAMESPACE_ID::Message(arena) { SharedCtor(); RegisterArenaDtor(arena); // @@protoc_insertion_point(arena_constructor:backup.PullBackupResponse) } PullBackupResponse::PullBackupResponse(const PullBackupResponse& from) : ::PROTOBUF_NAMESPACE_ID::Message() { _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); clear_has_data(); switch (from.data_case()) { case kCompactionChunk: { _internal_set_compactionchunk(from._internal_compactionchunk()); break; } case kLogChunk: { _internal_set_logchunk(from._internal_logchunk()); break; } case DATA_NOT_SET: { break; } } // @@protoc_insertion_point(copy_constructor:backup.PullBackupResponse) } void PullBackupResponse::SharedCtor() { clear_has_data(); } PullBackupResponse::~PullBackupResponse() { // @@protoc_insertion_point(destructor:backup.PullBackupResponse) SharedDtor(); _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } void PullBackupResponse::SharedDtor() { GOOGLE_DCHECK(GetArena() == nullptr); if (has_data()) { clear_data(); } } void PullBackupResponse::ArenaDtor(void* object) { PullBackupResponse* _this = reinterpret_cast< PullBackupResponse* >(object); (void)_this; } void PullBackupResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) { } void PullBackupResponse::SetCachedSize(int size) const { _cached_size_.Set(size); } void PullBackupResponse::clear_data() { // @@protoc_insertion_point(one_of_clear_start:backup.PullBackupResponse) switch (data_case()) { case kCompactionChunk: { data_.compactionchunk_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case kLogChunk: { data_.logchunk_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); break; } case DATA_NOT_SET: { break; } } _oneof_case_[0] = DATA_NOT_SET; } void PullBackupResponse::Clear() { // @@protoc_insertion_point(message_clear_start:backup.PullBackupResponse) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; clear_data(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } const char* PullBackupResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure while (!ctx->Done(&ptr)) { ::PROTOBUF_NAMESPACE_ID::uint32 tag; ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); CHK_(ptr); switch (tag >> 3) { // bytes compactionChunk = 1; case 1: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { auto str = _internal_mutable_compactionchunk(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(ptr); } else goto handle_unusual; continue; // bytes logChunk = 2; case 2: if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) { auto str = _internal_mutable_logchunk(); ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); CHK_(ptr); } else goto handle_unusual; continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { ctx->SetLastTag(tag); goto success; } ptr = UnknownFieldParse(tag, _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), ptr, ctx); CHK_(ptr != nullptr); continue; } } // switch } // while success: return ptr; failure: ptr = nullptr; goto success; #undef CHK_ } ::PROTOBUF_NAMESPACE_ID::uint8* PullBackupResponse::_InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { // @@protoc_insertion_point(serialize_to_array_start:backup.PullBackupResponse) ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; // bytes compactionChunk = 1; if (_internal_has_compactionchunk()) { target = stream->WriteBytesMaybeAliased( 1, this->_internal_compactionchunk(), target); } // bytes logChunk = 2; if (_internal_has_logchunk()) { target = stream->WriteBytesMaybeAliased( 2, this->_internal_logchunk(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); } // @@protoc_insertion_point(serialize_to_array_end:backup.PullBackupResponse) return target; } size_t PullBackupResponse::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:backup.PullBackupResponse) size_t total_size = 0; ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; switch (data_case()) { // bytes compactionChunk = 1; case kCompactionChunk: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::BytesSize( this->_internal_compactionchunk()); break; } // bytes logChunk = 2; case kLogChunk: { total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::BytesSize( this->_internal_logchunk()); break; } case DATA_NOT_SET: { break; } } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); } int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); SetCachedSize(cached_size); return total_size; } void PullBackupResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:backup.PullBackupResponse) GOOGLE_DCHECK_NE(&from, this); const PullBackupResponse* source = ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated( &from); if (source == nullptr) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:backup.PullBackupResponse) ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:backup.PullBackupResponse) MergeFrom(*source); } } void PullBackupResponse::MergeFrom(const PullBackupResponse& from) { // @@protoc_insertion_point(class_specific_merge_from_start:backup.PullBackupResponse) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; (void) cached_has_bits; switch (from.data_case()) { case kCompactionChunk: { _internal_set_compactionchunk(from._internal_compactionchunk()); break; } case kLogChunk: { _internal_set_logchunk(from._internal_logchunk()); break; } case DATA_NOT_SET: { break; } } } void PullBackupResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:backup.PullBackupResponse) if (&from == this) return; Clear(); MergeFrom(from); } void PullBackupResponse::CopyFrom(const PullBackupResponse& from) { // @@protoc_insertion_point(class_specific_copy_from_start:backup.PullBackupResponse) if (&from == this) return; Clear(); MergeFrom(from); } bool PullBackupResponse::IsInitialized() const { return true; } void PullBackupResponse::InternalSwap(PullBackupResponse* other) { using std::swap; _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_); swap(data_, other->data_); swap(_oneof_case_[0], other->_oneof_case_[0]); } ::PROTOBUF_NAMESPACE_ID::Metadata PullBackupResponse::GetMetadata() const { return GetMetadataStatic(); } // @@protoc_insertion_point(namespace_scope) } // namespace backup PROTOBUF_NAMESPACE_OPEN template<> PROTOBUF_NOINLINE ::backup::CreateNewBackupRequest* Arena::CreateMaybeMessage< ::backup::CreateNewBackupRequest >(Arena* arena) { return Arena::CreateMessageInternal< ::backup::CreateNewBackupRequest >(arena); } template<> PROTOBUF_NOINLINE ::backup::CreateNewBackupResponse* Arena::CreateMaybeMessage< ::backup::CreateNewBackupResponse >(Arena* arena) { return Arena::CreateMessageInternal< ::backup::CreateNewBackupResponse >(arena); } template<> PROTOBUF_NOINLINE ::backup::SendLogRequest* Arena::CreateMaybeMessage< ::backup::SendLogRequest >(Arena* arena) { return Arena::CreateMessageInternal< ::backup::SendLogRequest >(arena); } template<> PROTOBUF_NOINLINE ::backup::RecoverBackupKeyRequest* Arena::CreateMaybeMessage< ::backup::RecoverBackupKeyRequest >(Arena* arena) { return Arena::CreateMessageInternal< ::backup::RecoverBackupKeyRequest >(arena); } template<> PROTOBUF_NOINLINE ::backup::RecoverBackupKeyResponse* Arena::CreateMaybeMessage< ::backup::RecoverBackupKeyResponse >(Arena* arena) { return Arena::CreateMessageInternal< ::backup::RecoverBackupKeyResponse >(arena); } template<> PROTOBUF_NOINLINE ::backup::PullBackupRequest* Arena::CreateMaybeMessage< ::backup::PullBackupRequest >(Arena* arena) { return Arena::CreateMessageInternal< ::backup::PullBackupRequest >(arena); } template<> PROTOBUF_NOINLINE ::backup::PullBackupResponse* Arena::CreateMaybeMessage< ::backup::PullBackupResponse >(Arena* arena) { return Arena::CreateMessageInternal< ::backup::PullBackupResponse >(arena); } PROTOBUF_NAMESPACE_CLOSE // @@protoc_insertion_point(global_scope) #include diff --git a/native/cpp/CommonCpp/grpc/_generated/backup.pb.h b/native/cpp/CommonCpp/grpc/_generated/backup.pb.h index 42a42b77b..5a9298c54 100644 --- a/native/cpp/CommonCpp/grpc/_generated/backup.pb.h +++ b/native/cpp/CommonCpp/grpc/_generated/backup.pb.h @@ -1,2839 +1,2839 @@ // @generated by the protocol buffer compiler. DO NOT EDIT! // source: backup.proto #ifndef GOOGLE_PROTOBUF_INCLUDED_backup_2eproto #define GOOGLE_PROTOBUF_INCLUDED_backup_2eproto #include #include #include #if PROTOBUF_VERSION < 3015000 #error This file was generated by a newer version of protoc which is #error incompatible with your Protocol Buffer headers. Please update #error your headers. #endif #if 3015008 < PROTOBUF_MIN_PROTOC_VERSION #error This file was generated by an older version of protoc which is #error incompatible with your Protocol Buffer headers. Please #error regenerate this file with a newer version of protoc. #endif #include #include #include #include #include #include #include #include #include #include // IWYU pragma: export #include // IWYU pragma: export #include #include // @@protoc_insertion_point(includes) #include #define PROTOBUF_INTERNAL_EXPORT_backup_2eproto PROTOBUF_NAMESPACE_OPEN namespace internal { class AnyMetadata; } // namespace internal PROTOBUF_NAMESPACE_CLOSE // Internal implementation detail -- do not use these members. struct TableStruct_backup_2eproto { static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTableField entries[] PROTOBUF_SECTION_VARIABLE(protodesc_cold); static const ::PROTOBUF_NAMESPACE_ID::internal::AuxiliaryParseTableField aux[] PROTOBUF_SECTION_VARIABLE(protodesc_cold); static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTable schema[7] PROTOBUF_SECTION_VARIABLE(protodesc_cold); static const ::PROTOBUF_NAMESPACE_ID::internal::FieldMetadata field_metadata[]; static const ::PROTOBUF_NAMESPACE_ID::internal::SerializationTable serialization_table[]; static const ::PROTOBUF_NAMESPACE_ID::uint32 offsets[]; }; extern const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_backup_2eproto; ::PROTOBUF_NAMESPACE_ID::Metadata descriptor_table_backup_2eproto_metadata_getter(int index); namespace backup { class CreateNewBackupRequest; struct CreateNewBackupRequestDefaultTypeInternal; extern CreateNewBackupRequestDefaultTypeInternal _CreateNewBackupRequest_default_instance_; class CreateNewBackupResponse; struct CreateNewBackupResponseDefaultTypeInternal; extern CreateNewBackupResponseDefaultTypeInternal _CreateNewBackupResponse_default_instance_; class PullBackupRequest; struct PullBackupRequestDefaultTypeInternal; extern PullBackupRequestDefaultTypeInternal _PullBackupRequest_default_instance_; class PullBackupResponse; struct PullBackupResponseDefaultTypeInternal; extern PullBackupResponseDefaultTypeInternal _PullBackupResponse_default_instance_; class RecoverBackupKeyRequest; struct RecoverBackupKeyRequestDefaultTypeInternal; extern RecoverBackupKeyRequestDefaultTypeInternal _RecoverBackupKeyRequest_default_instance_; class RecoverBackupKeyResponse; struct RecoverBackupKeyResponseDefaultTypeInternal; extern RecoverBackupKeyResponseDefaultTypeInternal _RecoverBackupKeyResponse_default_instance_; class SendLogRequest; struct SendLogRequestDefaultTypeInternal; extern SendLogRequestDefaultTypeInternal _SendLogRequest_default_instance_; } // namespace backup PROTOBUF_NAMESPACE_OPEN template<> ::backup::CreateNewBackupRequest* Arena::CreateMaybeMessage<::backup::CreateNewBackupRequest>(Arena*); template<> ::backup::CreateNewBackupResponse* Arena::CreateMaybeMessage<::backup::CreateNewBackupResponse>(Arena*); template<> ::backup::PullBackupRequest* Arena::CreateMaybeMessage<::backup::PullBackupRequest>(Arena*); template<> ::backup::PullBackupResponse* Arena::CreateMaybeMessage<::backup::PullBackupResponse>(Arena*); template<> ::backup::RecoverBackupKeyRequest* Arena::CreateMaybeMessage<::backup::RecoverBackupKeyRequest>(Arena*); template<> ::backup::RecoverBackupKeyResponse* Arena::CreateMaybeMessage<::backup::RecoverBackupKeyResponse>(Arena*); template<> ::backup::SendLogRequest* Arena::CreateMaybeMessage<::backup::SendLogRequest>(Arena*); PROTOBUF_NAMESPACE_CLOSE namespace backup { // =================================================================== class CreateNewBackupRequest PROTOBUF_FINAL : public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:backup.CreateNewBackupRequest) */ { public: inline CreateNewBackupRequest() : CreateNewBackupRequest(nullptr) {} virtual ~CreateNewBackupRequest(); explicit constexpr CreateNewBackupRequest(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); CreateNewBackupRequest(const CreateNewBackupRequest& from); CreateNewBackupRequest(CreateNewBackupRequest&& from) noexcept : CreateNewBackupRequest() { *this = ::std::move(from); } inline CreateNewBackupRequest& operator=(const CreateNewBackupRequest& from) { CopyFrom(from); return *this; } inline CreateNewBackupRequest& operator=(CreateNewBackupRequest&& from) noexcept { if (GetArena() == from.GetArena()) { if (this != &from) InternalSwap(&from); } else { CopyFrom(from); } return *this; } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { return GetDescriptor(); } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { return GetMetadataStatic().descriptor; } static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { return GetMetadataStatic().reflection; } static const CreateNewBackupRequest& default_instance() { return *internal_default_instance(); } enum DataCase { kUserID = 1, kKeyEntropy = 2, kNewCompactionHash = 3, kNewCompactionChunk = 4, DATA_NOT_SET = 0, }; static inline const CreateNewBackupRequest* internal_default_instance() { return reinterpret_cast( &_CreateNewBackupRequest_default_instance_); } static constexpr int kIndexInFileMessages = 0; friend void swap(CreateNewBackupRequest& a, CreateNewBackupRequest& b) { a.Swap(&b); } inline void Swap(CreateNewBackupRequest* other) { if (other == this) return; if (GetArena() == other->GetArena()) { InternalSwap(other); } else { ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); } } void UnsafeArenaSwap(CreateNewBackupRequest* other) { if (other == this) return; GOOGLE_DCHECK(GetArena() == other->GetArena()); InternalSwap(other); } // implements Message ---------------------------------------------- inline CreateNewBackupRequest* New() const final { return CreateMaybeMessage(nullptr); } CreateNewBackupRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final { return CreateMaybeMessage(arena); } void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void CopyFrom(const CreateNewBackupRequest& from); void MergeFrom(const CreateNewBackupRequest& from); PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; bool IsInitialized() const final; size_t ByteSizeLong() const final; const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; ::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; int GetCachedSize() const final { return _cached_size_.Get(); } private: inline void SharedCtor(); inline void SharedDtor(); void SetCachedSize(int size) const final; void InternalSwap(CreateNewBackupRequest* other); friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { return "backup.CreateNewBackupRequest"; } protected: explicit CreateNewBackupRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena); private: static void ArenaDtor(void* object); inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena); public: ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; private: static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() { return ::descriptor_table_backup_2eproto_metadata_getter(kIndexInFileMessages); } public: // nested types ---------------------------------------------------- // accessors ------------------------------------------------------- enum : int { kUserIDFieldNumber = 1, kKeyEntropyFieldNumber = 2, kNewCompactionHashFieldNumber = 3, kNewCompactionChunkFieldNumber = 4, }; // string userID = 1; bool has_userid() const; private: bool _internal_has_userid() const; public: void clear_userid(); const std::string& userid() const; void set_userid(const std::string& value); void set_userid(std::string&& value); void set_userid(const char* value); void set_userid(const char* value, size_t size); std::string* mutable_userid(); std::string* release_userid(); void set_allocated_userid(std::string* userid); private: const std::string& _internal_userid() const; void _internal_set_userid(const std::string& value); std::string* _internal_mutable_userid(); public: // bytes keyEntropy = 2; bool has_keyentropy() const; private: bool _internal_has_keyentropy() const; public: void clear_keyentropy(); const std::string& keyentropy() const; void set_keyentropy(const std::string& value); void set_keyentropy(std::string&& value); void set_keyentropy(const char* value); void set_keyentropy(const void* value, size_t size); std::string* mutable_keyentropy(); std::string* release_keyentropy(); void set_allocated_keyentropy(std::string* keyentropy); private: const std::string& _internal_keyentropy() const; void _internal_set_keyentropy(const std::string& value); std::string* _internal_mutable_keyentropy(); public: // bytes newCompactionHash = 3; bool has_newcompactionhash() const; private: bool _internal_has_newcompactionhash() const; public: void clear_newcompactionhash(); const std::string& newcompactionhash() const; void set_newcompactionhash(const std::string& value); void set_newcompactionhash(std::string&& value); void set_newcompactionhash(const char* value); void set_newcompactionhash(const void* value, size_t size); std::string* mutable_newcompactionhash(); std::string* release_newcompactionhash(); void set_allocated_newcompactionhash(std::string* newcompactionhash); private: const std::string& _internal_newcompactionhash() const; void _internal_set_newcompactionhash(const std::string& value); std::string* _internal_mutable_newcompactionhash(); public: // bytes newCompactionChunk = 4; bool has_newcompactionchunk() const; private: bool _internal_has_newcompactionchunk() const; public: void clear_newcompactionchunk(); const std::string& newcompactionchunk() const; void set_newcompactionchunk(const std::string& value); void set_newcompactionchunk(std::string&& value); void set_newcompactionchunk(const char* value); void set_newcompactionchunk(const void* value, size_t size); std::string* mutable_newcompactionchunk(); std::string* release_newcompactionchunk(); void set_allocated_newcompactionchunk(std::string* newcompactionchunk); private: const std::string& _internal_newcompactionchunk() const; void _internal_set_newcompactionchunk(const std::string& value); std::string* _internal_mutable_newcompactionchunk(); public: void clear_data(); DataCase data_case() const; // @@protoc_insertion_point(class_scope:backup.CreateNewBackupRequest) private: class _Internal; void set_has_userid(); void set_has_keyentropy(); void set_has_newcompactionhash(); void set_has_newcompactionchunk(); inline bool has_data() const; inline void clear_has_data(); template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; typedef void InternalArenaConstructable_; typedef void DestructorSkippable_; union DataUnion { constexpr DataUnion() : _constinit_{} {} ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized _constinit_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr userid_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr keyentropy_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr newcompactionhash_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr newcompactionchunk_; } data_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; ::PROTOBUF_NAMESPACE_ID::uint32 _oneof_case_[1]; friend struct ::TableStruct_backup_2eproto; }; // ------------------------------------------------------------------- class CreateNewBackupResponse PROTOBUF_FINAL : public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:backup.CreateNewBackupResponse) */ { public: inline CreateNewBackupResponse() : CreateNewBackupResponse(nullptr) {} virtual ~CreateNewBackupResponse(); explicit constexpr CreateNewBackupResponse(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); CreateNewBackupResponse(const CreateNewBackupResponse& from); CreateNewBackupResponse(CreateNewBackupResponse&& from) noexcept : CreateNewBackupResponse() { *this = ::std::move(from); } inline CreateNewBackupResponse& operator=(const CreateNewBackupResponse& from) { CopyFrom(from); return *this; } inline CreateNewBackupResponse& operator=(CreateNewBackupResponse&& from) noexcept { if (GetArena() == from.GetArena()) { if (this != &from) InternalSwap(&from); } else { CopyFrom(from); } return *this; } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { return GetDescriptor(); } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { return GetMetadataStatic().descriptor; } static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { return GetMetadataStatic().reflection; } static const CreateNewBackupResponse& default_instance() { return *internal_default_instance(); } static inline const CreateNewBackupResponse* internal_default_instance() { return reinterpret_cast( &_CreateNewBackupResponse_default_instance_); } static constexpr int kIndexInFileMessages = 1; friend void swap(CreateNewBackupResponse& a, CreateNewBackupResponse& b) { a.Swap(&b); } inline void Swap(CreateNewBackupResponse* other) { if (other == this) return; if (GetArena() == other->GetArena()) { InternalSwap(other); } else { ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); } } void UnsafeArenaSwap(CreateNewBackupResponse* other) { if (other == this) return; GOOGLE_DCHECK(GetArena() == other->GetArena()); InternalSwap(other); } // implements Message ---------------------------------------------- inline CreateNewBackupResponse* New() const final { return CreateMaybeMessage(nullptr); } CreateNewBackupResponse* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final { return CreateMaybeMessage(arena); } void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void CopyFrom(const CreateNewBackupResponse& from); void MergeFrom(const CreateNewBackupResponse& from); PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; bool IsInitialized() const final; size_t ByteSizeLong() const final; const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; ::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; int GetCachedSize() const final { return _cached_size_.Get(); } private: inline void SharedCtor(); inline void SharedDtor(); void SetCachedSize(int size) const final; void InternalSwap(CreateNewBackupResponse* other); friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { return "backup.CreateNewBackupResponse"; } protected: explicit CreateNewBackupResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena); private: static void ArenaDtor(void* object); inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena); public: ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; private: static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() { return ::descriptor_table_backup_2eproto_metadata_getter(kIndexInFileMessages); } public: // nested types ---------------------------------------------------- // accessors ------------------------------------------------------- enum : int { kBackupIDFieldNumber = 1, }; // string backupID = 1; void clear_backupid(); const std::string& backupid() const; void set_backupid(const std::string& value); void set_backupid(std::string&& value); void set_backupid(const char* value); void set_backupid(const char* value, size_t size); std::string* mutable_backupid(); std::string* release_backupid(); void set_allocated_backupid(std::string* backupid); private: const std::string& _internal_backupid() const; void _internal_set_backupid(const std::string& value); std::string* _internal_mutable_backupid(); public: // @@protoc_insertion_point(class_scope:backup.CreateNewBackupResponse) private: class _Internal; template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; typedef void InternalArenaConstructable_; typedef void DestructorSkippable_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr backupid_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; friend struct ::TableStruct_backup_2eproto; }; // ------------------------------------------------------------------- class SendLogRequest PROTOBUF_FINAL : public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:backup.SendLogRequest) */ { public: inline SendLogRequest() : SendLogRequest(nullptr) {} virtual ~SendLogRequest(); explicit constexpr SendLogRequest(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); SendLogRequest(const SendLogRequest& from); SendLogRequest(SendLogRequest&& from) noexcept : SendLogRequest() { *this = ::std::move(from); } inline SendLogRequest& operator=(const SendLogRequest& from) { CopyFrom(from); return *this; } inline SendLogRequest& operator=(SendLogRequest&& from) noexcept { if (GetArena() == from.GetArena()) { if (this != &from) InternalSwap(&from); } else { CopyFrom(from); } return *this; } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { return GetDescriptor(); } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { return GetMetadataStatic().descriptor; } static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { return GetMetadataStatic().reflection; } static const SendLogRequest& default_instance() { return *internal_default_instance(); } enum DataCase { kUserID = 1, kBackupID = 2, kLogHash = 3, kLogData = 4, DATA_NOT_SET = 0, }; static inline const SendLogRequest* internal_default_instance() { return reinterpret_cast( &_SendLogRequest_default_instance_); } static constexpr int kIndexInFileMessages = 2; friend void swap(SendLogRequest& a, SendLogRequest& b) { a.Swap(&b); } inline void Swap(SendLogRequest* other) { if (other == this) return; if (GetArena() == other->GetArena()) { InternalSwap(other); } else { ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); } } void UnsafeArenaSwap(SendLogRequest* other) { if (other == this) return; GOOGLE_DCHECK(GetArena() == other->GetArena()); InternalSwap(other); } // implements Message ---------------------------------------------- inline SendLogRequest* New() const final { return CreateMaybeMessage(nullptr); } SendLogRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final { return CreateMaybeMessage(arena); } void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void CopyFrom(const SendLogRequest& from); void MergeFrom(const SendLogRequest& from); PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; bool IsInitialized() const final; size_t ByteSizeLong() const final; const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; ::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; int GetCachedSize() const final { return _cached_size_.Get(); } private: inline void SharedCtor(); inline void SharedDtor(); void SetCachedSize(int size) const final; void InternalSwap(SendLogRequest* other); friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { return "backup.SendLogRequest"; } protected: explicit SendLogRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena); private: static void ArenaDtor(void* object); inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena); public: ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; private: static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() { return ::descriptor_table_backup_2eproto_metadata_getter(kIndexInFileMessages); } public: // nested types ---------------------------------------------------- // accessors ------------------------------------------------------- enum : int { kUserIDFieldNumber = 1, kBackupIDFieldNumber = 2, kLogHashFieldNumber = 3, kLogDataFieldNumber = 4, }; // string userID = 1; bool has_userid() const; private: bool _internal_has_userid() const; public: void clear_userid(); const std::string& userid() const; void set_userid(const std::string& value); void set_userid(std::string&& value); void set_userid(const char* value); void set_userid(const char* value, size_t size); std::string* mutable_userid(); std::string* release_userid(); void set_allocated_userid(std::string* userid); private: const std::string& _internal_userid() const; void _internal_set_userid(const std::string& value); std::string* _internal_mutable_userid(); public: // string backupID = 2; bool has_backupid() const; private: bool _internal_has_backupid() const; public: void clear_backupid(); const std::string& backupid() const; void set_backupid(const std::string& value); void set_backupid(std::string&& value); void set_backupid(const char* value); void set_backupid(const char* value, size_t size); std::string* mutable_backupid(); std::string* release_backupid(); void set_allocated_backupid(std::string* backupid); private: const std::string& _internal_backupid() const; void _internal_set_backupid(const std::string& value); std::string* _internal_mutable_backupid(); public: // bytes logHash = 3; bool has_loghash() const; private: bool _internal_has_loghash() const; public: void clear_loghash(); const std::string& loghash() const; void set_loghash(const std::string& value); void set_loghash(std::string&& value); void set_loghash(const char* value); void set_loghash(const void* value, size_t size); std::string* mutable_loghash(); std::string* release_loghash(); void set_allocated_loghash(std::string* loghash); private: const std::string& _internal_loghash() const; void _internal_set_loghash(const std::string& value); std::string* _internal_mutable_loghash(); public: // bytes logData = 4; bool has_logdata() const; private: bool _internal_has_logdata() const; public: void clear_logdata(); const std::string& logdata() const; void set_logdata(const std::string& value); void set_logdata(std::string&& value); void set_logdata(const char* value); void set_logdata(const void* value, size_t size); std::string* mutable_logdata(); std::string* release_logdata(); void set_allocated_logdata(std::string* logdata); private: const std::string& _internal_logdata() const; void _internal_set_logdata(const std::string& value); std::string* _internal_mutable_logdata(); public: void clear_data(); DataCase data_case() const; // @@protoc_insertion_point(class_scope:backup.SendLogRequest) private: class _Internal; void set_has_userid(); void set_has_backupid(); void set_has_loghash(); void set_has_logdata(); inline bool has_data() const; inline void clear_has_data(); template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; typedef void InternalArenaConstructable_; typedef void DestructorSkippable_; union DataUnion { constexpr DataUnion() : _constinit_{} {} ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized _constinit_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr userid_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr backupid_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr loghash_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr logdata_; } data_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; ::PROTOBUF_NAMESPACE_ID::uint32 _oneof_case_[1]; friend struct ::TableStruct_backup_2eproto; }; // ------------------------------------------------------------------- class RecoverBackupKeyRequest PROTOBUF_FINAL : public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:backup.RecoverBackupKeyRequest) */ { public: inline RecoverBackupKeyRequest() : RecoverBackupKeyRequest(nullptr) {} virtual ~RecoverBackupKeyRequest(); explicit constexpr RecoverBackupKeyRequest(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); RecoverBackupKeyRequest(const RecoverBackupKeyRequest& from); RecoverBackupKeyRequest(RecoverBackupKeyRequest&& from) noexcept : RecoverBackupKeyRequest() { *this = ::std::move(from); } inline RecoverBackupKeyRequest& operator=(const RecoverBackupKeyRequest& from) { CopyFrom(from); return *this; } inline RecoverBackupKeyRequest& operator=(RecoverBackupKeyRequest&& from) noexcept { if (GetArena() == from.GetArena()) { if (this != &from) InternalSwap(&from); } else { CopyFrom(from); } return *this; } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { return GetDescriptor(); } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { return GetMetadataStatic().descriptor; } static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { return GetMetadataStatic().reflection; } static const RecoverBackupKeyRequest& default_instance() { return *internal_default_instance(); } static inline const RecoverBackupKeyRequest* internal_default_instance() { return reinterpret_cast( &_RecoverBackupKeyRequest_default_instance_); } static constexpr int kIndexInFileMessages = 3; friend void swap(RecoverBackupKeyRequest& a, RecoverBackupKeyRequest& b) { a.Swap(&b); } inline void Swap(RecoverBackupKeyRequest* other) { if (other == this) return; if (GetArena() == other->GetArena()) { InternalSwap(other); } else { ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); } } void UnsafeArenaSwap(RecoverBackupKeyRequest* other) { if (other == this) return; GOOGLE_DCHECK(GetArena() == other->GetArena()); InternalSwap(other); } // implements Message ---------------------------------------------- inline RecoverBackupKeyRequest* New() const final { return CreateMaybeMessage(nullptr); } RecoverBackupKeyRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final { return CreateMaybeMessage(arena); } void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void CopyFrom(const RecoverBackupKeyRequest& from); void MergeFrom(const RecoverBackupKeyRequest& from); PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; bool IsInitialized() const final; size_t ByteSizeLong() const final; const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; ::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; int GetCachedSize() const final { return _cached_size_.Get(); } private: inline void SharedCtor(); inline void SharedDtor(); void SetCachedSize(int size) const final; void InternalSwap(RecoverBackupKeyRequest* other); friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { return "backup.RecoverBackupKeyRequest"; } protected: explicit RecoverBackupKeyRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena); private: static void ArenaDtor(void* object); inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena); public: ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; private: static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() { return ::descriptor_table_backup_2eproto_metadata_getter(kIndexInFileMessages); } public: // nested types ---------------------------------------------------- // accessors ------------------------------------------------------- enum : int { kUserIDFieldNumber = 1, }; // string userID = 1; void clear_userid(); const std::string& userid() const; void set_userid(const std::string& value); void set_userid(std::string&& value); void set_userid(const char* value); void set_userid(const char* value, size_t size); std::string* mutable_userid(); std::string* release_userid(); void set_allocated_userid(std::string* userid); private: const std::string& _internal_userid() const; void _internal_set_userid(const std::string& value); std::string* _internal_mutable_userid(); public: // @@protoc_insertion_point(class_scope:backup.RecoverBackupKeyRequest) private: class _Internal; template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; typedef void InternalArenaConstructable_; typedef void DestructorSkippable_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr userid_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; friend struct ::TableStruct_backup_2eproto; }; // ------------------------------------------------------------------- class RecoverBackupKeyResponse PROTOBUF_FINAL : public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:backup.RecoverBackupKeyResponse) */ { public: inline RecoverBackupKeyResponse() : RecoverBackupKeyResponse(nullptr) {} virtual ~RecoverBackupKeyResponse(); explicit constexpr RecoverBackupKeyResponse(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); RecoverBackupKeyResponse(const RecoverBackupKeyResponse& from); RecoverBackupKeyResponse(RecoverBackupKeyResponse&& from) noexcept : RecoverBackupKeyResponse() { *this = ::std::move(from); } inline RecoverBackupKeyResponse& operator=(const RecoverBackupKeyResponse& from) { CopyFrom(from); return *this; } inline RecoverBackupKeyResponse& operator=(RecoverBackupKeyResponse&& from) noexcept { if (GetArena() == from.GetArena()) { if (this != &from) InternalSwap(&from); } else { CopyFrom(from); } return *this; } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { return GetDescriptor(); } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { return GetMetadataStatic().descriptor; } static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { return GetMetadataStatic().reflection; } static const RecoverBackupKeyResponse& default_instance() { return *internal_default_instance(); } - enum DataCase { - kBackupID = 4, - DATA_NOT_SET = 0, - }; - static inline const RecoverBackupKeyResponse* internal_default_instance() { return reinterpret_cast( &_RecoverBackupKeyResponse_default_instance_); } static constexpr int kIndexInFileMessages = 4; friend void swap(RecoverBackupKeyResponse& a, RecoverBackupKeyResponse& b) { a.Swap(&b); } inline void Swap(RecoverBackupKeyResponse* other) { if (other == this) return; if (GetArena() == other->GetArena()) { InternalSwap(other); } else { ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); } } void UnsafeArenaSwap(RecoverBackupKeyResponse* other) { if (other == this) return; GOOGLE_DCHECK(GetArena() == other->GetArena()); InternalSwap(other); } // implements Message ---------------------------------------------- inline RecoverBackupKeyResponse* New() const final { return CreateMaybeMessage(nullptr); } RecoverBackupKeyResponse* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final { return CreateMaybeMessage(arena); } void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void CopyFrom(const RecoverBackupKeyResponse& from); void MergeFrom(const RecoverBackupKeyResponse& from); PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; bool IsInitialized() const final; size_t ByteSizeLong() const final; const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; ::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; int GetCachedSize() const final { return _cached_size_.Get(); } private: inline void SharedCtor(); inline void SharedDtor(); void SetCachedSize(int size) const final; void InternalSwap(RecoverBackupKeyResponse* other); friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { return "backup.RecoverBackupKeyResponse"; } protected: explicit RecoverBackupKeyResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena); private: static void ArenaDtor(void* object); inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena); public: ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; private: static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() { return ::descriptor_table_backup_2eproto_metadata_getter(kIndexInFileMessages); } public: // nested types ---------------------------------------------------- // accessors ------------------------------------------------------- enum : int { kBackupIDFieldNumber = 4, }; // string backupID = 4; - bool has_backupid() const; - private: - bool _internal_has_backupid() const; - public: void clear_backupid(); const std::string& backupid() const; void set_backupid(const std::string& value); void set_backupid(std::string&& value); void set_backupid(const char* value); void set_backupid(const char* value, size_t size); std::string* mutable_backupid(); std::string* release_backupid(); void set_allocated_backupid(std::string* backupid); private: const std::string& _internal_backupid() const; void _internal_set_backupid(const std::string& value); std::string* _internal_mutable_backupid(); public: - void clear_data(); - DataCase data_case() const; // @@protoc_insertion_point(class_scope:backup.RecoverBackupKeyResponse) private: class _Internal; - void set_has_backupid(); - - inline bool has_data() const; - inline void clear_has_data(); template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; typedef void InternalArenaConstructable_; typedef void DestructorSkippable_; - union DataUnion { - constexpr DataUnion() : _constinit_{} {} - ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized _constinit_; - ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr backupid_; - } data_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr backupid_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; - ::PROTOBUF_NAMESPACE_ID::uint32 _oneof_case_[1]; - friend struct ::TableStruct_backup_2eproto; }; // ------------------------------------------------------------------- class PullBackupRequest PROTOBUF_FINAL : public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:backup.PullBackupRequest) */ { public: inline PullBackupRequest() : PullBackupRequest(nullptr) {} virtual ~PullBackupRequest(); explicit constexpr PullBackupRequest(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); PullBackupRequest(const PullBackupRequest& from); PullBackupRequest(PullBackupRequest&& from) noexcept : PullBackupRequest() { *this = ::std::move(from); } inline PullBackupRequest& operator=(const PullBackupRequest& from) { CopyFrom(from); return *this; } inline PullBackupRequest& operator=(PullBackupRequest&& from) noexcept { if (GetArena() == from.GetArena()) { if (this != &from) InternalSwap(&from); } else { CopyFrom(from); } return *this; } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { return GetDescriptor(); } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { return GetMetadataStatic().descriptor; } static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { return GetMetadataStatic().reflection; } static const PullBackupRequest& default_instance() { return *internal_default_instance(); } static inline const PullBackupRequest* internal_default_instance() { return reinterpret_cast( &_PullBackupRequest_default_instance_); } static constexpr int kIndexInFileMessages = 5; friend void swap(PullBackupRequest& a, PullBackupRequest& b) { a.Swap(&b); } inline void Swap(PullBackupRequest* other) { if (other == this) return; if (GetArena() == other->GetArena()) { InternalSwap(other); } else { ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); } } void UnsafeArenaSwap(PullBackupRequest* other) { if (other == this) return; GOOGLE_DCHECK(GetArena() == other->GetArena()); InternalSwap(other); } // implements Message ---------------------------------------------- inline PullBackupRequest* New() const final { return CreateMaybeMessage(nullptr); } PullBackupRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final { return CreateMaybeMessage(arena); } void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void CopyFrom(const PullBackupRequest& from); void MergeFrom(const PullBackupRequest& from); PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; bool IsInitialized() const final; size_t ByteSizeLong() const final; const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; ::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; int GetCachedSize() const final { return _cached_size_.Get(); } private: inline void SharedCtor(); inline void SharedDtor(); void SetCachedSize(int size) const final; void InternalSwap(PullBackupRequest* other); friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { return "backup.PullBackupRequest"; } protected: explicit PullBackupRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena); private: static void ArenaDtor(void* object); inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena); public: ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; private: static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() { return ::descriptor_table_backup_2eproto_metadata_getter(kIndexInFileMessages); } public: // nested types ---------------------------------------------------- // accessors ------------------------------------------------------- enum : int { kUserIDFieldNumber = 1, + kBackupIDFieldNumber = 2, }; // string userID = 1; void clear_userid(); const std::string& userid() const; void set_userid(const std::string& value); void set_userid(std::string&& value); void set_userid(const char* value); void set_userid(const char* value, size_t size); std::string* mutable_userid(); std::string* release_userid(); void set_allocated_userid(std::string* userid); private: const std::string& _internal_userid() const; void _internal_set_userid(const std::string& value); std::string* _internal_mutable_userid(); public: + // string backupID = 2; + void clear_backupid(); + const std::string& backupid() const; + void set_backupid(const std::string& value); + void set_backupid(std::string&& value); + void set_backupid(const char* value); + void set_backupid(const char* value, size_t size); + std::string* mutable_backupid(); + std::string* release_backupid(); + void set_allocated_backupid(std::string* backupid); + private: + const std::string& _internal_backupid() const; + void _internal_set_backupid(const std::string& value); + std::string* _internal_mutable_backupid(); + public: + // @@protoc_insertion_point(class_scope:backup.PullBackupRequest) private: class _Internal; template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; typedef void InternalArenaConstructable_; typedef void DestructorSkippable_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr userid_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr backupid_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; friend struct ::TableStruct_backup_2eproto; }; // ------------------------------------------------------------------- class PullBackupResponse PROTOBUF_FINAL : public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:backup.PullBackupResponse) */ { public: inline PullBackupResponse() : PullBackupResponse(nullptr) {} virtual ~PullBackupResponse(); explicit constexpr PullBackupResponse(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); PullBackupResponse(const PullBackupResponse& from); PullBackupResponse(PullBackupResponse&& from) noexcept : PullBackupResponse() { *this = ::std::move(from); } inline PullBackupResponse& operator=(const PullBackupResponse& from) { CopyFrom(from); return *this; } inline PullBackupResponse& operator=(PullBackupResponse&& from) noexcept { if (GetArena() == from.GetArena()) { if (this != &from) InternalSwap(&from); } else { CopyFrom(from); } return *this; } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { return GetDescriptor(); } static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { return GetMetadataStatic().descriptor; } static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { return GetMetadataStatic().reflection; } static const PullBackupResponse& default_instance() { return *internal_default_instance(); } enum DataCase { kCompactionChunk = 1, kLogChunk = 2, DATA_NOT_SET = 0, }; static inline const PullBackupResponse* internal_default_instance() { return reinterpret_cast( &_PullBackupResponse_default_instance_); } static constexpr int kIndexInFileMessages = 6; friend void swap(PullBackupResponse& a, PullBackupResponse& b) { a.Swap(&b); } inline void Swap(PullBackupResponse* other) { if (other == this) return; if (GetArena() == other->GetArena()) { InternalSwap(other); } else { ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); } } void UnsafeArenaSwap(PullBackupResponse* other) { if (other == this) return; GOOGLE_DCHECK(GetArena() == other->GetArena()); InternalSwap(other); } // implements Message ---------------------------------------------- inline PullBackupResponse* New() const final { return CreateMaybeMessage(nullptr); } PullBackupResponse* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final { return CreateMaybeMessage(arena); } void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final; void CopyFrom(const PullBackupResponse& from); void MergeFrom(const PullBackupResponse& from); PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; bool IsInitialized() const final; size_t ByteSizeLong() const final; const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; ::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize( ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; int GetCachedSize() const final { return _cached_size_.Get(); } private: inline void SharedCtor(); inline void SharedDtor(); void SetCachedSize(int size) const final; void InternalSwap(PullBackupResponse* other); friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { return "backup.PullBackupResponse"; } protected: explicit PullBackupResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena); private: static void ArenaDtor(void* object); inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena); public: ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; private: static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() { return ::descriptor_table_backup_2eproto_metadata_getter(kIndexInFileMessages); } public: // nested types ---------------------------------------------------- // accessors ------------------------------------------------------- enum : int { kCompactionChunkFieldNumber = 1, kLogChunkFieldNumber = 2, }; // bytes compactionChunk = 1; bool has_compactionchunk() const; private: bool _internal_has_compactionchunk() const; public: void clear_compactionchunk(); const std::string& compactionchunk() const; void set_compactionchunk(const std::string& value); void set_compactionchunk(std::string&& value); void set_compactionchunk(const char* value); void set_compactionchunk(const void* value, size_t size); std::string* mutable_compactionchunk(); std::string* release_compactionchunk(); void set_allocated_compactionchunk(std::string* compactionchunk); private: const std::string& _internal_compactionchunk() const; void _internal_set_compactionchunk(const std::string& value); std::string* _internal_mutable_compactionchunk(); public: // bytes logChunk = 2; bool has_logchunk() const; private: bool _internal_has_logchunk() const; public: void clear_logchunk(); const std::string& logchunk() const; void set_logchunk(const std::string& value); void set_logchunk(std::string&& value); void set_logchunk(const char* value); void set_logchunk(const void* value, size_t size); std::string* mutable_logchunk(); std::string* release_logchunk(); void set_allocated_logchunk(std::string* logchunk); private: const std::string& _internal_logchunk() const; void _internal_set_logchunk(const std::string& value); std::string* _internal_mutable_logchunk(); public: void clear_data(); DataCase data_case() const; // @@protoc_insertion_point(class_scope:backup.PullBackupResponse) private: class _Internal; void set_has_compactionchunk(); void set_has_logchunk(); inline bool has_data() const; inline void clear_has_data(); template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; typedef void InternalArenaConstructable_; typedef void DestructorSkippable_; union DataUnion { constexpr DataUnion() : _constinit_{} {} ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized _constinit_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr compactionchunk_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr logchunk_; } data_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; ::PROTOBUF_NAMESPACE_ID::uint32 _oneof_case_[1]; friend struct ::TableStruct_backup_2eproto; }; // =================================================================== // =================================================================== #ifdef __GNUC__ #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wstrict-aliasing" #endif // __GNUC__ // CreateNewBackupRequest // string userID = 1; inline bool CreateNewBackupRequest::_internal_has_userid() const { return data_case() == kUserID; } inline bool CreateNewBackupRequest::has_userid() const { return _internal_has_userid(); } inline void CreateNewBackupRequest::set_has_userid() { _oneof_case_[0] = kUserID; } inline void CreateNewBackupRequest::clear_userid() { if (_internal_has_userid()) { data_.userid_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& CreateNewBackupRequest::userid() const { // @@protoc_insertion_point(field_get:backup.CreateNewBackupRequest.userID) return _internal_userid(); } inline void CreateNewBackupRequest::set_userid(const std::string& value) { _internal_set_userid(value); // @@protoc_insertion_point(field_set:backup.CreateNewBackupRequest.userID) } inline std::string* CreateNewBackupRequest::mutable_userid() { // @@protoc_insertion_point(field_mutable:backup.CreateNewBackupRequest.userID) return _internal_mutable_userid(); } inline const std::string& CreateNewBackupRequest::_internal_userid() const { if (_internal_has_userid()) { return data_.userid_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void CreateNewBackupRequest::_internal_set_userid(const std::string& value) { if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void CreateNewBackupRequest::set_userid(std::string&& value) { // @@protoc_insertion_point(field_set:backup.CreateNewBackupRequest.userID) if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.userid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.CreateNewBackupRequest.userID) } inline void CreateNewBackupRequest::set_userid(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.CreateNewBackupRequest.userID) } inline void CreateNewBackupRequest::set_userid(const char* value, size_t size) { if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.userid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.CreateNewBackupRequest.userID) } inline std::string* CreateNewBackupRequest::_internal_mutable_userid() { if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.userid_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* CreateNewBackupRequest::release_userid() { // @@protoc_insertion_point(field_release:backup.CreateNewBackupRequest.userID) if (_internal_has_userid()) { clear_has_data(); return data_.userid_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void CreateNewBackupRequest::set_allocated_userid(std::string* userid) { if (has_data()) { clear_data(); } if (userid != nullptr) { set_has_userid(); data_.userid_.UnsafeSetDefault(userid); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(userid); } } // @@protoc_insertion_point(field_set_allocated:backup.CreateNewBackupRequest.userID) } // bytes keyEntropy = 2; inline bool CreateNewBackupRequest::_internal_has_keyentropy() const { return data_case() == kKeyEntropy; } inline bool CreateNewBackupRequest::has_keyentropy() const { return _internal_has_keyentropy(); } inline void CreateNewBackupRequest::set_has_keyentropy() { _oneof_case_[0] = kKeyEntropy; } inline void CreateNewBackupRequest::clear_keyentropy() { if (_internal_has_keyentropy()) { data_.keyentropy_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& CreateNewBackupRequest::keyentropy() const { // @@protoc_insertion_point(field_get:backup.CreateNewBackupRequest.keyEntropy) return _internal_keyentropy(); } inline void CreateNewBackupRequest::set_keyentropy(const std::string& value) { _internal_set_keyentropy(value); // @@protoc_insertion_point(field_set:backup.CreateNewBackupRequest.keyEntropy) } inline std::string* CreateNewBackupRequest::mutable_keyentropy() { // @@protoc_insertion_point(field_mutable:backup.CreateNewBackupRequest.keyEntropy) return _internal_mutable_keyentropy(); } inline const std::string& CreateNewBackupRequest::_internal_keyentropy() const { if (_internal_has_keyentropy()) { return data_.keyentropy_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void CreateNewBackupRequest::_internal_set_keyentropy(const std::string& value) { if (!_internal_has_keyentropy()) { clear_data(); set_has_keyentropy(); data_.keyentropy_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.keyentropy_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void CreateNewBackupRequest::set_keyentropy(std::string&& value) { // @@protoc_insertion_point(field_set:backup.CreateNewBackupRequest.keyEntropy) if (!_internal_has_keyentropy()) { clear_data(); set_has_keyentropy(); data_.keyentropy_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.keyentropy_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.CreateNewBackupRequest.keyEntropy) } inline void CreateNewBackupRequest::set_keyentropy(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_keyentropy()) { clear_data(); set_has_keyentropy(); data_.keyentropy_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.keyentropy_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.CreateNewBackupRequest.keyEntropy) } inline void CreateNewBackupRequest::set_keyentropy(const void* value, size_t size) { if (!_internal_has_keyentropy()) { clear_data(); set_has_keyentropy(); data_.keyentropy_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.keyentropy_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.CreateNewBackupRequest.keyEntropy) } inline std::string* CreateNewBackupRequest::_internal_mutable_keyentropy() { if (!_internal_has_keyentropy()) { clear_data(); set_has_keyentropy(); data_.keyentropy_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.keyentropy_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* CreateNewBackupRequest::release_keyentropy() { // @@protoc_insertion_point(field_release:backup.CreateNewBackupRequest.keyEntropy) if (_internal_has_keyentropy()) { clear_has_data(); return data_.keyentropy_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void CreateNewBackupRequest::set_allocated_keyentropy(std::string* keyentropy) { if (has_data()) { clear_data(); } if (keyentropy != nullptr) { set_has_keyentropy(); data_.keyentropy_.UnsafeSetDefault(keyentropy); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(keyentropy); } } // @@protoc_insertion_point(field_set_allocated:backup.CreateNewBackupRequest.keyEntropy) } // bytes newCompactionHash = 3; inline bool CreateNewBackupRequest::_internal_has_newcompactionhash() const { return data_case() == kNewCompactionHash; } inline bool CreateNewBackupRequest::has_newcompactionhash() const { return _internal_has_newcompactionhash(); } inline void CreateNewBackupRequest::set_has_newcompactionhash() { _oneof_case_[0] = kNewCompactionHash; } inline void CreateNewBackupRequest::clear_newcompactionhash() { if (_internal_has_newcompactionhash()) { data_.newcompactionhash_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& CreateNewBackupRequest::newcompactionhash() const { // @@protoc_insertion_point(field_get:backup.CreateNewBackupRequest.newCompactionHash) return _internal_newcompactionhash(); } inline void CreateNewBackupRequest::set_newcompactionhash(const std::string& value) { _internal_set_newcompactionhash(value); // @@protoc_insertion_point(field_set:backup.CreateNewBackupRequest.newCompactionHash) } inline std::string* CreateNewBackupRequest::mutable_newcompactionhash() { // @@protoc_insertion_point(field_mutable:backup.CreateNewBackupRequest.newCompactionHash) return _internal_mutable_newcompactionhash(); } inline const std::string& CreateNewBackupRequest::_internal_newcompactionhash() const { if (_internal_has_newcompactionhash()) { return data_.newcompactionhash_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void CreateNewBackupRequest::_internal_set_newcompactionhash(const std::string& value) { if (!_internal_has_newcompactionhash()) { clear_data(); set_has_newcompactionhash(); data_.newcompactionhash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.newcompactionhash_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void CreateNewBackupRequest::set_newcompactionhash(std::string&& value) { // @@protoc_insertion_point(field_set:backup.CreateNewBackupRequest.newCompactionHash) if (!_internal_has_newcompactionhash()) { clear_data(); set_has_newcompactionhash(); data_.newcompactionhash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.newcompactionhash_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.CreateNewBackupRequest.newCompactionHash) } inline void CreateNewBackupRequest::set_newcompactionhash(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_newcompactionhash()) { clear_data(); set_has_newcompactionhash(); data_.newcompactionhash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.newcompactionhash_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.CreateNewBackupRequest.newCompactionHash) } inline void CreateNewBackupRequest::set_newcompactionhash(const void* value, size_t size) { if (!_internal_has_newcompactionhash()) { clear_data(); set_has_newcompactionhash(); data_.newcompactionhash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.newcompactionhash_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.CreateNewBackupRequest.newCompactionHash) } inline std::string* CreateNewBackupRequest::_internal_mutable_newcompactionhash() { if (!_internal_has_newcompactionhash()) { clear_data(); set_has_newcompactionhash(); data_.newcompactionhash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.newcompactionhash_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* CreateNewBackupRequest::release_newcompactionhash() { // @@protoc_insertion_point(field_release:backup.CreateNewBackupRequest.newCompactionHash) if (_internal_has_newcompactionhash()) { clear_has_data(); return data_.newcompactionhash_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void CreateNewBackupRequest::set_allocated_newcompactionhash(std::string* newcompactionhash) { if (has_data()) { clear_data(); } if (newcompactionhash != nullptr) { set_has_newcompactionhash(); data_.newcompactionhash_.UnsafeSetDefault(newcompactionhash); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(newcompactionhash); } } // @@protoc_insertion_point(field_set_allocated:backup.CreateNewBackupRequest.newCompactionHash) } // bytes newCompactionChunk = 4; inline bool CreateNewBackupRequest::_internal_has_newcompactionchunk() const { return data_case() == kNewCompactionChunk; } inline bool CreateNewBackupRequest::has_newcompactionchunk() const { return _internal_has_newcompactionchunk(); } inline void CreateNewBackupRequest::set_has_newcompactionchunk() { _oneof_case_[0] = kNewCompactionChunk; } inline void CreateNewBackupRequest::clear_newcompactionchunk() { if (_internal_has_newcompactionchunk()) { data_.newcompactionchunk_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& CreateNewBackupRequest::newcompactionchunk() const { // @@protoc_insertion_point(field_get:backup.CreateNewBackupRequest.newCompactionChunk) return _internal_newcompactionchunk(); } inline void CreateNewBackupRequest::set_newcompactionchunk(const std::string& value) { _internal_set_newcompactionchunk(value); // @@protoc_insertion_point(field_set:backup.CreateNewBackupRequest.newCompactionChunk) } inline std::string* CreateNewBackupRequest::mutable_newcompactionchunk() { // @@protoc_insertion_point(field_mutable:backup.CreateNewBackupRequest.newCompactionChunk) return _internal_mutable_newcompactionchunk(); } inline const std::string& CreateNewBackupRequest::_internal_newcompactionchunk() const { if (_internal_has_newcompactionchunk()) { return data_.newcompactionchunk_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void CreateNewBackupRequest::_internal_set_newcompactionchunk(const std::string& value) { if (!_internal_has_newcompactionchunk()) { clear_data(); set_has_newcompactionchunk(); data_.newcompactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.newcompactionchunk_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void CreateNewBackupRequest::set_newcompactionchunk(std::string&& value) { // @@protoc_insertion_point(field_set:backup.CreateNewBackupRequest.newCompactionChunk) if (!_internal_has_newcompactionchunk()) { clear_data(); set_has_newcompactionchunk(); data_.newcompactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.newcompactionchunk_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.CreateNewBackupRequest.newCompactionChunk) } inline void CreateNewBackupRequest::set_newcompactionchunk(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_newcompactionchunk()) { clear_data(); set_has_newcompactionchunk(); data_.newcompactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.newcompactionchunk_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.CreateNewBackupRequest.newCompactionChunk) } inline void CreateNewBackupRequest::set_newcompactionchunk(const void* value, size_t size) { if (!_internal_has_newcompactionchunk()) { clear_data(); set_has_newcompactionchunk(); data_.newcompactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.newcompactionchunk_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.CreateNewBackupRequest.newCompactionChunk) } inline std::string* CreateNewBackupRequest::_internal_mutable_newcompactionchunk() { if (!_internal_has_newcompactionchunk()) { clear_data(); set_has_newcompactionchunk(); data_.newcompactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.newcompactionchunk_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* CreateNewBackupRequest::release_newcompactionchunk() { // @@protoc_insertion_point(field_release:backup.CreateNewBackupRequest.newCompactionChunk) if (_internal_has_newcompactionchunk()) { clear_has_data(); return data_.newcompactionchunk_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void CreateNewBackupRequest::set_allocated_newcompactionchunk(std::string* newcompactionchunk) { if (has_data()) { clear_data(); } if (newcompactionchunk != nullptr) { set_has_newcompactionchunk(); data_.newcompactionchunk_.UnsafeSetDefault(newcompactionchunk); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(newcompactionchunk); } } // @@protoc_insertion_point(field_set_allocated:backup.CreateNewBackupRequest.newCompactionChunk) } inline bool CreateNewBackupRequest::has_data() const { return data_case() != DATA_NOT_SET; } inline void CreateNewBackupRequest::clear_has_data() { _oneof_case_[0] = DATA_NOT_SET; } inline CreateNewBackupRequest::DataCase CreateNewBackupRequest::data_case() const { return CreateNewBackupRequest::DataCase(_oneof_case_[0]); } // ------------------------------------------------------------------- // CreateNewBackupResponse // string backupID = 1; inline void CreateNewBackupResponse::clear_backupid() { backupid_.ClearToEmpty(); } inline const std::string& CreateNewBackupResponse::backupid() const { // @@protoc_insertion_point(field_get:backup.CreateNewBackupResponse.backupID) return _internal_backupid(); } inline void CreateNewBackupResponse::set_backupid(const std::string& value) { _internal_set_backupid(value); // @@protoc_insertion_point(field_set:backup.CreateNewBackupResponse.backupID) } inline std::string* CreateNewBackupResponse::mutable_backupid() { // @@protoc_insertion_point(field_mutable:backup.CreateNewBackupResponse.backupID) return _internal_mutable_backupid(); } inline const std::string& CreateNewBackupResponse::_internal_backupid() const { return backupid_.Get(); } inline void CreateNewBackupResponse::_internal_set_backupid(const std::string& value) { backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void CreateNewBackupResponse::set_backupid(std::string&& value) { backupid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.CreateNewBackupResponse.backupID) } inline void CreateNewBackupResponse::set_backupid(const char* value) { GOOGLE_DCHECK(value != nullptr); backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.CreateNewBackupResponse.backupID) } inline void CreateNewBackupResponse::set_backupid(const char* value, size_t size) { backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.CreateNewBackupResponse.backupID) } inline std::string* CreateNewBackupResponse::_internal_mutable_backupid() { return backupid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* CreateNewBackupResponse::release_backupid() { // @@protoc_insertion_point(field_release:backup.CreateNewBackupResponse.backupID) return backupid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } inline void CreateNewBackupResponse::set_allocated_backupid(std::string* backupid) { if (backupid != nullptr) { } else { } backupid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), backupid, GetArena()); // @@protoc_insertion_point(field_set_allocated:backup.CreateNewBackupResponse.backupID) } // ------------------------------------------------------------------- // SendLogRequest // string userID = 1; inline bool SendLogRequest::_internal_has_userid() const { return data_case() == kUserID; } inline bool SendLogRequest::has_userid() const { return _internal_has_userid(); } inline void SendLogRequest::set_has_userid() { _oneof_case_[0] = kUserID; } inline void SendLogRequest::clear_userid() { if (_internal_has_userid()) { data_.userid_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& SendLogRequest::userid() const { // @@protoc_insertion_point(field_get:backup.SendLogRequest.userID) return _internal_userid(); } inline void SendLogRequest::set_userid(const std::string& value) { _internal_set_userid(value); // @@protoc_insertion_point(field_set:backup.SendLogRequest.userID) } inline std::string* SendLogRequest::mutable_userid() { // @@protoc_insertion_point(field_mutable:backup.SendLogRequest.userID) return _internal_mutable_userid(); } inline const std::string& SendLogRequest::_internal_userid() const { if (_internal_has_userid()) { return data_.userid_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void SendLogRequest::_internal_set_userid(const std::string& value) { if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void SendLogRequest::set_userid(std::string&& value) { // @@protoc_insertion_point(field_set:backup.SendLogRequest.userID) if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.userid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.SendLogRequest.userID) } inline void SendLogRequest::set_userid(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.SendLogRequest.userID) } inline void SendLogRequest::set_userid(const char* value, size_t size) { if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.userid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.SendLogRequest.userID) } inline std::string* SendLogRequest::_internal_mutable_userid() { if (!_internal_has_userid()) { clear_data(); set_has_userid(); data_.userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.userid_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* SendLogRequest::release_userid() { // @@protoc_insertion_point(field_release:backup.SendLogRequest.userID) if (_internal_has_userid()) { clear_has_data(); return data_.userid_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void SendLogRequest::set_allocated_userid(std::string* userid) { if (has_data()) { clear_data(); } if (userid != nullptr) { set_has_userid(); data_.userid_.UnsafeSetDefault(userid); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(userid); } } // @@protoc_insertion_point(field_set_allocated:backup.SendLogRequest.userID) } // string backupID = 2; inline bool SendLogRequest::_internal_has_backupid() const { return data_case() == kBackupID; } inline bool SendLogRequest::has_backupid() const { return _internal_has_backupid(); } inline void SendLogRequest::set_has_backupid() { _oneof_case_[0] = kBackupID; } inline void SendLogRequest::clear_backupid() { if (_internal_has_backupid()) { data_.backupid_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& SendLogRequest::backupid() const { // @@protoc_insertion_point(field_get:backup.SendLogRequest.backupID) return _internal_backupid(); } inline void SendLogRequest::set_backupid(const std::string& value) { _internal_set_backupid(value); // @@protoc_insertion_point(field_set:backup.SendLogRequest.backupID) } inline std::string* SendLogRequest::mutable_backupid() { // @@protoc_insertion_point(field_mutable:backup.SendLogRequest.backupID) return _internal_mutable_backupid(); } inline const std::string& SendLogRequest::_internal_backupid() const { if (_internal_has_backupid()) { return data_.backupid_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void SendLogRequest::_internal_set_backupid(const std::string& value) { if (!_internal_has_backupid()) { clear_data(); set_has_backupid(); data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void SendLogRequest::set_backupid(std::string&& value) { // @@protoc_insertion_point(field_set:backup.SendLogRequest.backupID) if (!_internal_has_backupid()) { clear_data(); set_has_backupid(); data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.backupid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.SendLogRequest.backupID) } inline void SendLogRequest::set_backupid(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_backupid()) { clear_data(); set_has_backupid(); data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.SendLogRequest.backupID) } inline void SendLogRequest::set_backupid(const char* value, size_t size) { if (!_internal_has_backupid()) { clear_data(); set_has_backupid(); data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.backupid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.SendLogRequest.backupID) } inline std::string* SendLogRequest::_internal_mutable_backupid() { if (!_internal_has_backupid()) { clear_data(); set_has_backupid(); data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.backupid_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* SendLogRequest::release_backupid() { // @@protoc_insertion_point(field_release:backup.SendLogRequest.backupID) if (_internal_has_backupid()) { clear_has_data(); return data_.backupid_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void SendLogRequest::set_allocated_backupid(std::string* backupid) { if (has_data()) { clear_data(); } if (backupid != nullptr) { set_has_backupid(); data_.backupid_.UnsafeSetDefault(backupid); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(backupid); } } // @@protoc_insertion_point(field_set_allocated:backup.SendLogRequest.backupID) } // bytes logHash = 3; inline bool SendLogRequest::_internal_has_loghash() const { return data_case() == kLogHash; } inline bool SendLogRequest::has_loghash() const { return _internal_has_loghash(); } inline void SendLogRequest::set_has_loghash() { _oneof_case_[0] = kLogHash; } inline void SendLogRequest::clear_loghash() { if (_internal_has_loghash()) { data_.loghash_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& SendLogRequest::loghash() const { // @@protoc_insertion_point(field_get:backup.SendLogRequest.logHash) return _internal_loghash(); } inline void SendLogRequest::set_loghash(const std::string& value) { _internal_set_loghash(value); // @@protoc_insertion_point(field_set:backup.SendLogRequest.logHash) } inline std::string* SendLogRequest::mutable_loghash() { // @@protoc_insertion_point(field_mutable:backup.SendLogRequest.logHash) return _internal_mutable_loghash(); } inline const std::string& SendLogRequest::_internal_loghash() const { if (_internal_has_loghash()) { return data_.loghash_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void SendLogRequest::_internal_set_loghash(const std::string& value) { if (!_internal_has_loghash()) { clear_data(); set_has_loghash(); data_.loghash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.loghash_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void SendLogRequest::set_loghash(std::string&& value) { // @@protoc_insertion_point(field_set:backup.SendLogRequest.logHash) if (!_internal_has_loghash()) { clear_data(); set_has_loghash(); data_.loghash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.loghash_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.SendLogRequest.logHash) } inline void SendLogRequest::set_loghash(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_loghash()) { clear_data(); set_has_loghash(); data_.loghash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.loghash_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.SendLogRequest.logHash) } inline void SendLogRequest::set_loghash(const void* value, size_t size) { if (!_internal_has_loghash()) { clear_data(); set_has_loghash(); data_.loghash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.loghash_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.SendLogRequest.logHash) } inline std::string* SendLogRequest::_internal_mutable_loghash() { if (!_internal_has_loghash()) { clear_data(); set_has_loghash(); data_.loghash_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.loghash_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* SendLogRequest::release_loghash() { // @@protoc_insertion_point(field_release:backup.SendLogRequest.logHash) if (_internal_has_loghash()) { clear_has_data(); return data_.loghash_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void SendLogRequest::set_allocated_loghash(std::string* loghash) { if (has_data()) { clear_data(); } if (loghash != nullptr) { set_has_loghash(); data_.loghash_.UnsafeSetDefault(loghash); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(loghash); } } // @@protoc_insertion_point(field_set_allocated:backup.SendLogRequest.logHash) } // bytes logData = 4; inline bool SendLogRequest::_internal_has_logdata() const { return data_case() == kLogData; } inline bool SendLogRequest::has_logdata() const { return _internal_has_logdata(); } inline void SendLogRequest::set_has_logdata() { _oneof_case_[0] = kLogData; } inline void SendLogRequest::clear_logdata() { if (_internal_has_logdata()) { data_.logdata_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& SendLogRequest::logdata() const { // @@protoc_insertion_point(field_get:backup.SendLogRequest.logData) return _internal_logdata(); } inline void SendLogRequest::set_logdata(const std::string& value) { _internal_set_logdata(value); // @@protoc_insertion_point(field_set:backup.SendLogRequest.logData) } inline std::string* SendLogRequest::mutable_logdata() { // @@protoc_insertion_point(field_mutable:backup.SendLogRequest.logData) return _internal_mutable_logdata(); } inline const std::string& SendLogRequest::_internal_logdata() const { if (_internal_has_logdata()) { return data_.logdata_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void SendLogRequest::_internal_set_logdata(const std::string& value) { if (!_internal_has_logdata()) { clear_data(); set_has_logdata(); data_.logdata_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.logdata_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void SendLogRequest::set_logdata(std::string&& value) { // @@protoc_insertion_point(field_set:backup.SendLogRequest.logData) if (!_internal_has_logdata()) { clear_data(); set_has_logdata(); data_.logdata_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.logdata_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.SendLogRequest.logData) } inline void SendLogRequest::set_logdata(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_logdata()) { clear_data(); set_has_logdata(); data_.logdata_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.logdata_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.SendLogRequest.logData) } inline void SendLogRequest::set_logdata(const void* value, size_t size) { if (!_internal_has_logdata()) { clear_data(); set_has_logdata(); data_.logdata_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.logdata_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.SendLogRequest.logData) } inline std::string* SendLogRequest::_internal_mutable_logdata() { if (!_internal_has_logdata()) { clear_data(); set_has_logdata(); data_.logdata_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.logdata_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* SendLogRequest::release_logdata() { // @@protoc_insertion_point(field_release:backup.SendLogRequest.logData) if (_internal_has_logdata()) { clear_has_data(); return data_.logdata_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void SendLogRequest::set_allocated_logdata(std::string* logdata) { if (has_data()) { clear_data(); } if (logdata != nullptr) { set_has_logdata(); data_.logdata_.UnsafeSetDefault(logdata); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(logdata); } } // @@protoc_insertion_point(field_set_allocated:backup.SendLogRequest.logData) } inline bool SendLogRequest::has_data() const { return data_case() != DATA_NOT_SET; } inline void SendLogRequest::clear_has_data() { _oneof_case_[0] = DATA_NOT_SET; } inline SendLogRequest::DataCase SendLogRequest::data_case() const { return SendLogRequest::DataCase(_oneof_case_[0]); } // ------------------------------------------------------------------- // RecoverBackupKeyRequest // string userID = 1; inline void RecoverBackupKeyRequest::clear_userid() { userid_.ClearToEmpty(); } inline const std::string& RecoverBackupKeyRequest::userid() const { // @@protoc_insertion_point(field_get:backup.RecoverBackupKeyRequest.userID) return _internal_userid(); } inline void RecoverBackupKeyRequest::set_userid(const std::string& value) { _internal_set_userid(value); // @@protoc_insertion_point(field_set:backup.RecoverBackupKeyRequest.userID) } inline std::string* RecoverBackupKeyRequest::mutable_userid() { // @@protoc_insertion_point(field_mutable:backup.RecoverBackupKeyRequest.userID) return _internal_mutable_userid(); } inline const std::string& RecoverBackupKeyRequest::_internal_userid() const { return userid_.Get(); } inline void RecoverBackupKeyRequest::_internal_set_userid(const std::string& value) { userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void RecoverBackupKeyRequest::set_userid(std::string&& value) { userid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.RecoverBackupKeyRequest.userID) } inline void RecoverBackupKeyRequest::set_userid(const char* value) { GOOGLE_DCHECK(value != nullptr); userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.RecoverBackupKeyRequest.userID) } inline void RecoverBackupKeyRequest::set_userid(const char* value, size_t size) { userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.RecoverBackupKeyRequest.userID) } inline std::string* RecoverBackupKeyRequest::_internal_mutable_userid() { return userid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* RecoverBackupKeyRequest::release_userid() { // @@protoc_insertion_point(field_release:backup.RecoverBackupKeyRequest.userID) return userid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } inline void RecoverBackupKeyRequest::set_allocated_userid(std::string* userid) { if (userid != nullptr) { } else { } userid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), userid, GetArena()); // @@protoc_insertion_point(field_set_allocated:backup.RecoverBackupKeyRequest.userID) } // ------------------------------------------------------------------- // RecoverBackupKeyResponse // string backupID = 4; -inline bool RecoverBackupKeyResponse::_internal_has_backupid() const { - return data_case() == kBackupID; -} -inline bool RecoverBackupKeyResponse::has_backupid() const { - return _internal_has_backupid(); -} -inline void RecoverBackupKeyResponse::set_has_backupid() { - _oneof_case_[0] = kBackupID; -} inline void RecoverBackupKeyResponse::clear_backupid() { - if (_internal_has_backupid()) { - data_.backupid_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); - clear_has_data(); - } + backupid_.ClearToEmpty(); } inline const std::string& RecoverBackupKeyResponse::backupid() const { // @@protoc_insertion_point(field_get:backup.RecoverBackupKeyResponse.backupID) return _internal_backupid(); } inline void RecoverBackupKeyResponse::set_backupid(const std::string& value) { _internal_set_backupid(value); // @@protoc_insertion_point(field_set:backup.RecoverBackupKeyResponse.backupID) } inline std::string* RecoverBackupKeyResponse::mutable_backupid() { // @@protoc_insertion_point(field_mutable:backup.RecoverBackupKeyResponse.backupID) return _internal_mutable_backupid(); } inline const std::string& RecoverBackupKeyResponse::_internal_backupid() const { - if (_internal_has_backupid()) { - return data_.backupid_.Get(); - } - return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); + return backupid_.Get(); } inline void RecoverBackupKeyResponse::_internal_set_backupid(const std::string& value) { - if (!_internal_has_backupid()) { - clear_data(); - set_has_backupid(); - data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); - } - data_.backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); + + backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void RecoverBackupKeyResponse::set_backupid(std::string&& value) { - // @@protoc_insertion_point(field_set:backup.RecoverBackupKeyResponse.backupID) - if (!_internal_has_backupid()) { - clear_data(); - set_has_backupid(); - data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); - } - data_.backupid_.Set( + + backupid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.RecoverBackupKeyResponse.backupID) } inline void RecoverBackupKeyResponse::set_backupid(const char* value) { GOOGLE_DCHECK(value != nullptr); - if (!_internal_has_backupid()) { - clear_data(); - set_has_backupid(); - data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); - } - data_.backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, - ::std::string(value), GetArena()); + + backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.RecoverBackupKeyResponse.backupID) } inline void RecoverBackupKeyResponse::set_backupid(const char* value, - size_t size) { - if (!_internal_has_backupid()) { - clear_data(); - set_has_backupid(); - data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); - } - data_.backupid_.Set( - ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( - reinterpret_cast(value), size), - GetArena()); + size_t size) { + + backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( + reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.RecoverBackupKeyResponse.backupID) } inline std::string* RecoverBackupKeyResponse::_internal_mutable_backupid() { - if (!_internal_has_backupid()) { - clear_data(); - set_has_backupid(); - data_.backupid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); - } - return data_.backupid_.Mutable( - ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); + + return backupid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* RecoverBackupKeyResponse::release_backupid() { // @@protoc_insertion_point(field_release:backup.RecoverBackupKeyResponse.backupID) - if (_internal_has_backupid()) { - clear_has_data(); - return data_.backupid_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); - } else { - return nullptr; - } + return backupid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } inline void RecoverBackupKeyResponse::set_allocated_backupid(std::string* backupid) { - if (has_data()) { - clear_data(); - } if (backupid != nullptr) { - set_has_backupid(); - data_.backupid_.UnsafeSetDefault(backupid); - ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); - if (arena != nullptr) { - arena->Own(backupid); - } + + } else { + } + backupid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), backupid, + GetArena()); // @@protoc_insertion_point(field_set_allocated:backup.RecoverBackupKeyResponse.backupID) } -inline bool RecoverBackupKeyResponse::has_data() const { - return data_case() != DATA_NOT_SET; -} -inline void RecoverBackupKeyResponse::clear_has_data() { - _oneof_case_[0] = DATA_NOT_SET; -} -inline RecoverBackupKeyResponse::DataCase RecoverBackupKeyResponse::data_case() const { - return RecoverBackupKeyResponse::DataCase(_oneof_case_[0]); -} // ------------------------------------------------------------------- // PullBackupRequest // string userID = 1; inline void PullBackupRequest::clear_userid() { userid_.ClearToEmpty(); } inline const std::string& PullBackupRequest::userid() const { // @@protoc_insertion_point(field_get:backup.PullBackupRequest.userID) return _internal_userid(); } inline void PullBackupRequest::set_userid(const std::string& value) { _internal_set_userid(value); // @@protoc_insertion_point(field_set:backup.PullBackupRequest.userID) } inline std::string* PullBackupRequest::mutable_userid() { // @@protoc_insertion_point(field_mutable:backup.PullBackupRequest.userID) return _internal_mutable_userid(); } inline const std::string& PullBackupRequest::_internal_userid() const { return userid_.Get(); } inline void PullBackupRequest::_internal_set_userid(const std::string& value) { userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void PullBackupRequest::set_userid(std::string&& value) { userid_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.PullBackupRequest.userID) } inline void PullBackupRequest::set_userid(const char* value) { GOOGLE_DCHECK(value != nullptr); userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.PullBackupRequest.userID) } inline void PullBackupRequest::set_userid(const char* value, size_t size) { userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.PullBackupRequest.userID) } inline std::string* PullBackupRequest::_internal_mutable_userid() { return userid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* PullBackupRequest::release_userid() { // @@protoc_insertion_point(field_release:backup.PullBackupRequest.userID) return userid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } inline void PullBackupRequest::set_allocated_userid(std::string* userid) { if (userid != nullptr) { } else { } userid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), userid, GetArena()); // @@protoc_insertion_point(field_set_allocated:backup.PullBackupRequest.userID) } +// string backupID = 2; +inline void PullBackupRequest::clear_backupid() { + backupid_.ClearToEmpty(); +} +inline const std::string& PullBackupRequest::backupid() const { + // @@protoc_insertion_point(field_get:backup.PullBackupRequest.backupID) + return _internal_backupid(); +} +inline void PullBackupRequest::set_backupid(const std::string& value) { + _internal_set_backupid(value); + // @@protoc_insertion_point(field_set:backup.PullBackupRequest.backupID) +} +inline std::string* PullBackupRequest::mutable_backupid() { + // @@protoc_insertion_point(field_mutable:backup.PullBackupRequest.backupID) + return _internal_mutable_backupid(); +} +inline const std::string& PullBackupRequest::_internal_backupid() const { + return backupid_.Get(); +} +inline void PullBackupRequest::_internal_set_backupid(const std::string& value) { + + backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); +} +inline void PullBackupRequest::set_backupid(std::string&& value) { + + backupid_.Set( + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); + // @@protoc_insertion_point(field_set_rvalue:backup.PullBackupRequest.backupID) +} +inline void PullBackupRequest::set_backupid(const char* value) { + GOOGLE_DCHECK(value != nullptr); + + backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); + // @@protoc_insertion_point(field_set_char:backup.PullBackupRequest.backupID) +} +inline void PullBackupRequest::set_backupid(const char* value, + size_t size) { + + backupid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( + reinterpret_cast(value), size), GetArena()); + // @@protoc_insertion_point(field_set_pointer:backup.PullBackupRequest.backupID) +} +inline std::string* PullBackupRequest::_internal_mutable_backupid() { + + return backupid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); +} +inline std::string* PullBackupRequest::release_backupid() { + // @@protoc_insertion_point(field_release:backup.PullBackupRequest.backupID) + return backupid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); +} +inline void PullBackupRequest::set_allocated_backupid(std::string* backupid) { + if (backupid != nullptr) { + + } else { + + } + backupid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), backupid, + GetArena()); + // @@protoc_insertion_point(field_set_allocated:backup.PullBackupRequest.backupID) +} + // ------------------------------------------------------------------- // PullBackupResponse // bytes compactionChunk = 1; inline bool PullBackupResponse::_internal_has_compactionchunk() const { return data_case() == kCompactionChunk; } inline bool PullBackupResponse::has_compactionchunk() const { return _internal_has_compactionchunk(); } inline void PullBackupResponse::set_has_compactionchunk() { _oneof_case_[0] = kCompactionChunk; } inline void PullBackupResponse::clear_compactionchunk() { if (_internal_has_compactionchunk()) { data_.compactionchunk_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& PullBackupResponse::compactionchunk() const { // @@protoc_insertion_point(field_get:backup.PullBackupResponse.compactionChunk) return _internal_compactionchunk(); } inline void PullBackupResponse::set_compactionchunk(const std::string& value) { _internal_set_compactionchunk(value); // @@protoc_insertion_point(field_set:backup.PullBackupResponse.compactionChunk) } inline std::string* PullBackupResponse::mutable_compactionchunk() { // @@protoc_insertion_point(field_mutable:backup.PullBackupResponse.compactionChunk) return _internal_mutable_compactionchunk(); } inline const std::string& PullBackupResponse::_internal_compactionchunk() const { if (_internal_has_compactionchunk()) { return data_.compactionchunk_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void PullBackupResponse::_internal_set_compactionchunk(const std::string& value) { if (!_internal_has_compactionchunk()) { clear_data(); set_has_compactionchunk(); data_.compactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.compactionchunk_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void PullBackupResponse::set_compactionchunk(std::string&& value) { // @@protoc_insertion_point(field_set:backup.PullBackupResponse.compactionChunk) if (!_internal_has_compactionchunk()) { clear_data(); set_has_compactionchunk(); data_.compactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.compactionchunk_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.PullBackupResponse.compactionChunk) } inline void PullBackupResponse::set_compactionchunk(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_compactionchunk()) { clear_data(); set_has_compactionchunk(); data_.compactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.compactionchunk_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.PullBackupResponse.compactionChunk) } inline void PullBackupResponse::set_compactionchunk(const void* value, size_t size) { if (!_internal_has_compactionchunk()) { clear_data(); set_has_compactionchunk(); data_.compactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.compactionchunk_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.PullBackupResponse.compactionChunk) } inline std::string* PullBackupResponse::_internal_mutable_compactionchunk() { if (!_internal_has_compactionchunk()) { clear_data(); set_has_compactionchunk(); data_.compactionchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.compactionchunk_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* PullBackupResponse::release_compactionchunk() { // @@protoc_insertion_point(field_release:backup.PullBackupResponse.compactionChunk) if (_internal_has_compactionchunk()) { clear_has_data(); return data_.compactionchunk_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void PullBackupResponse::set_allocated_compactionchunk(std::string* compactionchunk) { if (has_data()) { clear_data(); } if (compactionchunk != nullptr) { set_has_compactionchunk(); data_.compactionchunk_.UnsafeSetDefault(compactionchunk); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(compactionchunk); } } // @@protoc_insertion_point(field_set_allocated:backup.PullBackupResponse.compactionChunk) } // bytes logChunk = 2; inline bool PullBackupResponse::_internal_has_logchunk() const { return data_case() == kLogChunk; } inline bool PullBackupResponse::has_logchunk() const { return _internal_has_logchunk(); } inline void PullBackupResponse::set_has_logchunk() { _oneof_case_[0] = kLogChunk; } inline void PullBackupResponse::clear_logchunk() { if (_internal_has_logchunk()) { data_.logchunk_.Destroy(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); clear_has_data(); } } inline const std::string& PullBackupResponse::logchunk() const { // @@protoc_insertion_point(field_get:backup.PullBackupResponse.logChunk) return _internal_logchunk(); } inline void PullBackupResponse::set_logchunk(const std::string& value) { _internal_set_logchunk(value); // @@protoc_insertion_point(field_set:backup.PullBackupResponse.logChunk) } inline std::string* PullBackupResponse::mutable_logchunk() { // @@protoc_insertion_point(field_mutable:backup.PullBackupResponse.logChunk) return _internal_mutable_logchunk(); } inline const std::string& PullBackupResponse::_internal_logchunk() const { if (_internal_has_logchunk()) { return data_.logchunk_.Get(); } return ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(); } inline void PullBackupResponse::_internal_set_logchunk(const std::string& value) { if (!_internal_has_logchunk()) { clear_data(); set_has_logchunk(); data_.logchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.logchunk_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); } inline void PullBackupResponse::set_logchunk(std::string&& value) { // @@protoc_insertion_point(field_set:backup.PullBackupResponse.logChunk) if (!_internal_has_logchunk()) { clear_data(); set_has_logchunk(); data_.logchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.logchunk_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); // @@protoc_insertion_point(field_set_rvalue:backup.PullBackupResponse.logChunk) } inline void PullBackupResponse::set_logchunk(const char* value) { GOOGLE_DCHECK(value != nullptr); if (!_internal_has_logchunk()) { clear_data(); set_has_logchunk(); data_.logchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.logchunk_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); // @@protoc_insertion_point(field_set_char:backup.PullBackupResponse.logChunk) } inline void PullBackupResponse::set_logchunk(const void* value, size_t size) { if (!_internal_has_logchunk()) { clear_data(); set_has_logchunk(); data_.logchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } data_.logchunk_.Set( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( reinterpret_cast(value), size), GetArena()); // @@protoc_insertion_point(field_set_pointer:backup.PullBackupResponse.logChunk) } inline std::string* PullBackupResponse::_internal_mutable_logchunk() { if (!_internal_has_logchunk()) { clear_data(); set_has_logchunk(); data_.logchunk_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } return data_.logchunk_.Mutable( ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); } inline std::string* PullBackupResponse::release_logchunk() { // @@protoc_insertion_point(field_release:backup.PullBackupResponse.logChunk) if (_internal_has_logchunk()) { clear_has_data(); return data_.logchunk_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } else { return nullptr; } } inline void PullBackupResponse::set_allocated_logchunk(std::string* logchunk) { if (has_data()) { clear_data(); } if (logchunk != nullptr) { set_has_logchunk(); data_.logchunk_.UnsafeSetDefault(logchunk); ::PROTOBUF_NAMESPACE_ID::Arena* arena = GetArena(); if (arena != nullptr) { arena->Own(logchunk); } } // @@protoc_insertion_point(field_set_allocated:backup.PullBackupResponse.logChunk) } inline bool PullBackupResponse::has_data() const { return data_case() != DATA_NOT_SET; } inline void PullBackupResponse::clear_has_data() { _oneof_case_[0] = DATA_NOT_SET; } inline PullBackupResponse::DataCase PullBackupResponse::data_case() const { return PullBackupResponse::DataCase(_oneof_case_[0]); } #ifdef __GNUC__ #pragma GCC diagnostic pop #endif // __GNUC__ // ------------------------------------------------------------------- // ------------------------------------------------------------------- // ------------------------------------------------------------------- // ------------------------------------------------------------------- // ------------------------------------------------------------------- // ------------------------------------------------------------------- // @@protoc_insertion_point(namespace_scope) } // namespace backup // @@protoc_insertion_point(global_scope) #include #endif // GOOGLE_PROTOBUF_INCLUDED_GOOGLE_PROTOBUF_INCLUDED_backup_2eproto diff --git a/native/cpp/CommonCpp/grpc/protos/backup.proto b/native/cpp/CommonCpp/grpc/protos/backup.proto index ff0ed75e3..e6c151ef1 100644 --- a/native/cpp/CommonCpp/grpc/protos/backup.proto +++ b/native/cpp/CommonCpp/grpc/protos/backup.proto @@ -1,77 +1,76 @@ syntax = "proto3"; package backup; import "google/protobuf/empty.proto"; /** * API - description * CreateNewBackup - This method is called when we want to create a new backup. * We send a new backup key encrypted with the user's password and also the * new compaction. New logs that will be sent from now on will be assigned to * this backup. * SendLog - User sends a new log to the backup service. The log is being * assigned to the latest(or desired) backup's compaction item. * RecoverBackupKey - Pulls data necessary for regenerating the backup key * on the client-side for the latest(or desired) backup * PullBackup - Fetches compaction + all logs assigned to it for the * specified backup(default is the last backup) */ service BackupService { rpc CreateNewBackup(stream CreateNewBackupRequest) returns (stream CreateNewBackupResponse) {} rpc SendLog(stream SendLogRequest) returns (google.protobuf.Empty) {} rpc RecoverBackupKey(stream RecoverBackupKeyRequest) returns (stream RecoverBackupKeyResponse) {} - rpc PullBackup(stream PullBackupRequest) returns (stream PullBackupResponse) {} + rpc PullBackup(PullBackupRequest) returns (stream PullBackupResponse) {} } // CreateNewBackup message CreateNewBackupRequest { oneof data { string userID = 1; bytes keyEntropy = 2; bytes newCompactionHash = 3; bytes newCompactionChunk = 4; } } message CreateNewBackupResponse { string backupID = 1; } // SendLog message SendLogRequest { oneof data { string userID = 1; string backupID = 2; bytes logHash = 3; bytes logData = 4; } } // RecoverBackupKey message RecoverBackupKeyRequest { string userID = 1; } message RecoverBackupKeyResponse { - oneof data { - string backupID = 4; - } + string backupID = 4; } // PullBackup message PullBackupRequest { string userID = 1; + string backupID = 2; } message PullBackupResponse { oneof data { bytes compactionChunk = 1; bytes logChunk = 2; } } diff --git a/services/backup/docker-server/contents/server/src/BackupServiceImpl.cpp b/services/backup/docker-server/contents/server/src/BackupServiceImpl.cpp index 8813a0026..58648a942 100644 --- a/services/backup/docker-server/contents/server/src/BackupServiceImpl.cpp +++ b/services/backup/docker-server/contents/server/src/BackupServiceImpl.cpp @@ -1,47 +1,51 @@ #include "BackupServiceImpl.h" #include "CreateNewBackupReactor.h" #include "PullBackupReactor.h" #include "RecoverBackupKeyReactor.h" #include "SendLogReactor.h" #include namespace comm { namespace network { BackupServiceImpl::BackupServiceImpl() { Aws::InitAPI({}); } BackupServiceImpl::~BackupServiceImpl() { Aws::ShutdownAPI({}); } grpc::ServerBidiReactor< backup::CreateNewBackupRequest, backup::CreateNewBackupResponse> * BackupServiceImpl::CreateNewBackup(grpc::CallbackServerContext *context) { return new reactor::CreateNewBackupReactor(); } grpc::ServerReadReactor *BackupServiceImpl::SendLog( grpc::CallbackServerContext *context, google::protobuf::Empty *response) { return new reactor::SendLogReactor(response); } grpc::ServerBidiReactor< backup::RecoverBackupKeyRequest, backup::RecoverBackupKeyResponse> * BackupServiceImpl::RecoverBackupKey(grpc::CallbackServerContext *context) { return new reactor::RecoverBackupKeyReactor(); } -grpc::ServerBidiReactor * -BackupServiceImpl::PullBackup(grpc::CallbackServerContext *context) { - return new reactor::PullBackupReactor(); +grpc::ServerWriteReactor * +BackupServiceImpl::PullBackup( + grpc::CallbackServerContext *context, + const backup::PullBackupRequest *request) { + reactor::PullBackupReactor *reactor = new reactor::PullBackupReactor(request); + reactor->NextWrite(); + return reactor; } } // namespace network } // namespace comm diff --git a/services/backup/docker-server/contents/server/src/BackupServiceImpl.h b/services/backup/docker-server/contents/server/src/BackupServiceImpl.h index caa197aa1..683910679 100644 --- a/services/backup/docker-server/contents/server/src/BackupServiceImpl.h +++ b/services/backup/docker-server/contents/server/src/BackupServiceImpl.h @@ -1,36 +1,37 @@ #pragma once #include "../_generated/backup.grpc.pb.h" #include "../_generated/backup.pb.h" #include namespace comm { namespace network { class BackupServiceImpl final : public backup::BackupService::CallbackService { public: BackupServiceImpl(); virtual ~BackupServiceImpl(); grpc::ServerBidiReactor< backup::CreateNewBackupRequest, backup::CreateNewBackupResponse> * CreateNewBackup(grpc::CallbackServerContext *context) override; grpc::ServerReadReactor *SendLog( grpc::CallbackServerContext *context, google::protobuf::Empty *response) override; grpc::ServerBidiReactor< backup::RecoverBackupKeyRequest, backup::RecoverBackupKeyResponse> * RecoverBackupKey(grpc::CallbackServerContext *context) override; - grpc::ServerBidiReactor - *PullBackup(grpc::CallbackServerContext *context) override; + grpc::ServerWriteReactor *PullBackup( + grpc::CallbackServerContext *context, + const backup::PullBackupRequest *request) override; }; } // namespace network } // namespace comm diff --git a/services/backup/docker-server/contents/server/src/Reactors/client/base-reactors/ClientReadReactorBase.h b/services/backup/docker-server/contents/server/src/Reactors/client/base-reactors/ClientReadReactorBase.h index 33433f28e..56c661a3f 100644 --- a/services/backup/docker-server/contents/server/src/Reactors/client/base-reactors/ClientReadReactorBase.h +++ b/services/backup/docker-server/contents/server/src/Reactors/client/base-reactors/ClientReadReactorBase.h @@ -1,97 +1,96 @@ #include namespace comm { namespace network { namespace reactor { template class ClientReadReactorBase : public grpc::ClientReadReactor { Response response; grpc::Status status = grpc::Status::OK; bool done = false; bool initialized = false; void terminate(const grpc::Status &status); public: Request request; grpc::ClientContext context; void start(); void OnReadDone(bool ok) override; void OnDone(const grpc::Status &status) override; bool isDone(); - virtual std::unique_ptr - readResponse(const Response &response) = 0; + virtual std::unique_ptr readResponse(Response &response) = 0; virtual void validate(){}; virtual void doneCallback(){}; virtual void terminateCallback(){}; }; template void ClientReadReactorBase::terminate( const grpc::Status &status) { if (this->status.ok()) { this->status = status; } if (!this->status.ok()) { std::cout << "error: " << this->status.error_message() << std::endl; } if (this->done) { return; } this->terminateCallback(); try { this->validate(); } catch (std::runtime_error &e) { this->status = grpc::Status(grpc::StatusCode::INTERNAL, e.what()); } this->done = true; } template void ClientReadReactorBase::start() { this->StartRead(&this->response); if (!this->initialized) { this->StartCall(); this->initialized = true; } } template void ClientReadReactorBase::OnReadDone(bool ok) { if (!ok) { // Ending a connection on the other side results in the `ok` flag being set // to false. It makes it impossible to detect a failure based just on the // flag. We should manually check if the data we received is valid this->terminate(grpc::Status::OK); return; } try { std::unique_ptr status = this->readResponse(this->response); if (status != nullptr) { this->terminate(*status); return; } } catch (std::runtime_error &e) { this->terminate(grpc::Status(grpc::StatusCode::INTERNAL, e.what())); } this->StartRead(&this->response); } template void ClientReadReactorBase::OnDone( const grpc::Status &status) { this->terminate(status); this->doneCallback(); } template bool ClientReadReactorBase::isDone() { return this->done; } } // namespace reactor } // namespace network } // namespace comm diff --git a/services/backup/docker-server/contents/server/src/Reactors/client/blob/BlobGetClientReactor.h b/services/backup/docker-server/contents/server/src/Reactors/client/blob/BlobGetClientReactor.h new file mode 100644 index 000000000..64c06a49c --- /dev/null +++ b/services/backup/docker-server/contents/server/src/Reactors/client/blob/BlobGetClientReactor.h @@ -0,0 +1,57 @@ +#pragma once + +#include "ClientReadReactorBase.h" +#include "Constants.h" + +#include "../_generated/blob.grpc.pb.h" +#include "../_generated/blob.pb.h" + +#include +#include + +#include +#include +#include +#include + +namespace comm { +namespace network { +namespace reactor { + +class BlobGetClientReactor + : public ClientReadReactorBase { + std::string holder; + std::shared_ptr> dataChunks; + +public: + BlobGetClientReactor( + const std::string &holder, + std::shared_ptr> dataChunks); + + std::unique_ptr + readResponse(blob::GetResponse &response) override; + void doneCallback() override; +}; + +BlobGetClientReactor::BlobGetClientReactor( + const std::string &holder, + std::shared_ptr> dataChunks) + : holder(holder), dataChunks(dataChunks) { +} + +std::unique_ptr +BlobGetClientReactor::readResponse(blob::GetResponse &response) { + if (!this->dataChunks->write(std::move(*response.mutable_datachunk()))) { + throw std::runtime_error( + "error reading compaction data from the blob service"); + } + return nullptr; +} + +void BlobGetClientReactor::doneCallback() { + this->dataChunks->write(""); +} + +} // namespace reactor +} // namespace network +} // namespace comm diff --git a/services/backup/docker-server/contents/server/src/Reactors/server/PullBackupReactor.h b/services/backup/docker-server/contents/server/src/Reactors/server/PullBackupReactor.h index 022ad2f7c..a9d0bd7a0 100644 --- a/services/backup/docker-server/contents/server/src/Reactors/server/PullBackupReactor.h +++ b/services/backup/docker-server/contents/server/src/Reactors/server/PullBackupReactor.h @@ -1,35 +1,36 @@ #pragma once -#include "ServerBidiReactorBase.h" +#include "ServerWriteReactorBase.h" #include "../_generated/backup.grpc.pb.h" #include "../_generated/backup.pb.h" #include #include #include namespace comm { namespace network { namespace reactor { -class PullBackupReactor : public ServerBidiReactorBase< +class PullBackupReactor : public ServerWriteReactorBase< backup::PullBackupRequest, backup::PullBackupResponse> { public: - std::unique_ptr handleRequest( - backup::PullBackupRequest request, - backup::PullBackupResponse *response) override; + using ServerWriteReactorBase< + backup::PullBackupRequest, + backup::PullBackupResponse>::ServerWriteReactorBase; + + std::unique_ptr + writeResponse(backup::PullBackupResponse *response) override; }; -std::unique_ptr PullBackupReactor::handleRequest( - backup::PullBackupRequest request, - backup::PullBackupResponse *response) { +std::unique_ptr +PullBackupReactor::writeResponse(backup::PullBackupResponse *response) { // TODO handle request - return std::make_unique( - grpc::Status(grpc::StatusCode::UNIMPLEMENTED, "unimplemented")); + return std::make_unique(grpc::Status(grpc::StatusCode::UNIMPLEMENTED, "unimplemented")); } } // namespace reactor } // namespace network } // namespace comm