Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3509036
D5596.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
216 KB
Referenced Files
None
Subscribers
None
D5596.diff
View Options
diff --git a/native/android/app/src/cpp/GlobalNetworkSingletonJNIHelper.cpp b/native/android/app/src/cpp/GlobalNetworkSingletonJNIHelper.cpp
--- a/native/android/app/src/cpp/GlobalNetworkSingletonJNIHelper.cpp
+++ b/native/android/app/src/cpp/GlobalNetworkSingletonJNIHelper.cpp
@@ -2,16 +2,7 @@
#include <InternalModules/GlobalNetworkSingletonJNIHelper.h>
namespace comm {
-void GlobalNetworkSingletonJNIHelper::sendPong(
- facebook::jni::alias_ref<GlobalNetworkSingletonJNIHelper> jThis) {
- GlobalNetworkSingleton::instance.scheduleOrRun(
- [](NetworkModule &networkModule) { networkModule.sendPong(); });
-}
-
void GlobalNetworkSingletonJNIHelper::registerNatives() {
- javaClassStatic()->registerNatives({
- makeNativeMethod("sendPong", GlobalNetworkSingletonJNIHelper::sendPong),
- });
}
} // namespace comm
diff --git a/native/android/app/src/main/java/app/comm/android/CommNotificationsHandler.java b/native/android/app/src/main/java/app/comm/android/CommNotificationsHandler.java
--- a/native/android/app/src/main/java/app/comm/android/CommNotificationsHandler.java
+++ b/native/android/app/src/main/java/app/comm/android/CommNotificationsHandler.java
@@ -91,10 +91,6 @@
String backgroundNotifType =
message.getData().get(BACKGROUND_NOTIF_TYPE_KEY);
- if ("PING".equals(backgroundNotifType)) {
- NetworkModule.sendPong();
- return;
- }
String rawMessageInfosString = message.getData().get(MESSAGE_INFOS_KEY);
File sqliteFile =
diff --git a/native/android/app/src/main/java/app/comm/android/fbjni/NetworkModule.java b/native/android/app/src/main/java/app/comm/android/fbjni/NetworkModule.java
--- a/native/android/app/src/main/java/app/comm/android/fbjni/NetworkModule.java
+++ b/native/android/app/src/main/java/app/comm/android/fbjni/NetworkModule.java
@@ -1,5 +1,3 @@
package app.comm.android.fbjni;
-public class NetworkModule {
- public static native void sendPong();
-}
+public class NetworkModule {}
diff --git a/native/cpp/CommonCpp/NativeModules/InternalModules/GlobalNetworkSingletonJNIHelper.h b/native/cpp/CommonCpp/NativeModules/InternalModules/GlobalNetworkSingletonJNIHelper.h
--- a/native/cpp/CommonCpp/NativeModules/InternalModules/GlobalNetworkSingletonJNIHelper.h
+++ b/native/cpp/CommonCpp/NativeModules/InternalModules/GlobalNetworkSingletonJNIHelper.h
@@ -8,9 +8,6 @@
public:
static auto constexpr kJavaDescriptor =
"Lapp/comm/android/fbjni/NetworkModule;";
-
- static void
- sendPong(facebook::jni::alias_ref<GlobalNetworkSingletonJNIHelper> jThis);
static void registerNatives();
};
} // namespace comm
diff --git a/native/cpp/CommonCpp/NativeModules/InternalModules/NetworkModule.h b/native/cpp/CommonCpp/NativeModules/InternalModules/NetworkModule.h
--- a/native/cpp/CommonCpp/NativeModules/InternalModules/NetworkModule.h
+++ b/native/cpp/CommonCpp/NativeModules/InternalModules/NetworkModule.h
@@ -14,7 +14,6 @@
const std::string &userId,
const std::string &deviceToken,
const std::string &hostname = "");
- void sendPong();
grpc::Status send(
std::string sessionID,
std::string toDeviceID,
diff --git a/native/cpp/CommonCpp/NativeModules/InternalModules/NetworkModule.cpp b/native/cpp/CommonCpp/NativeModules/InternalModules/NetworkModule.cpp
--- a/native/cpp/CommonCpp/NativeModules/InternalModules/NetworkModule.cpp
+++ b/native/cpp/CommonCpp/NativeModules/InternalModules/NetworkModule.cpp
@@ -19,10 +19,6 @@
new network::Client(host, "50051", credentials, userId, deviceToken));
}
-void NetworkModule::sendPong() {
- this->networkClient->sendPong();
-}
-
void NetworkModule::get(std::string sessionID) {
if (!this->networkClient) {
return;
diff --git a/native/cpp/CommonCpp/grpc/Client.h b/native/cpp/CommonCpp/grpc/Client.h
--- a/native/cpp/CommonCpp/grpc/Client.h
+++ b/native/cpp/CommonCpp/grpc/Client.h
@@ -13,7 +13,6 @@
namespace network {
using grpc::Channel;
-using tunnelbroker::CheckResponseType;
using tunnelbroker::TunnelbrokerService;
class Client {
@@ -30,10 +29,6 @@
const std::string id,
const std::string deviceToken);
- CheckResponseType checkIfPrimaryDeviceOnline();
- bool becomeNewPrimaryDevice();
- void sendPong();
-
grpc::Status send(
std::string sessionID,
std::string toDeviceID,
diff --git a/native/cpp/CommonCpp/grpc/Client.cpp b/native/cpp/CommonCpp/grpc/Client.cpp
--- a/native/cpp/CommonCpp/grpc/Client.cpp
+++ b/native/cpp/CommonCpp/grpc/Client.cpp
@@ -17,55 +17,6 @@
this->stub_ = TunnelbrokerService::NewStub(channel);
}
-tunnelbroker::CheckResponseType Client::checkIfPrimaryDeviceOnline() {
- grpc::ClientContext context;
- tunnelbroker::CheckRequest request;
- tunnelbroker::CheckResponse response;
-
- request.set_userid(this->id);
- request.set_devicetoken(this->deviceToken);
-
- grpc::Status status =
- stub_->CheckIfPrimaryDeviceOnline(&context, request, &response);
- if (!status.ok()) {
- throw std::runtime_error(status.error_message());
- }
- return response.checkresponsetype();
-}
-
-bool Client::becomeNewPrimaryDevice() {
- grpc::ClientContext context;
- tunnelbroker::NewPrimaryRequest request;
- tunnelbroker::NewPrimaryResponse response;
-
- request.set_userid(this->id);
- request.set_devicetoken(this->deviceToken);
-
- grpc::Status status =
- stub_->BecomeNewPrimaryDevice(&context, request, &response);
- if (!status.ok()) {
- throw std::runtime_error(status.error_message());
- }
- return response.success();
-}
-
-void Client::sendPong() {
- grpc::ClientContext context;
- tunnelbroker::PongRequest request;
- google::protobuf::Empty response;
-
- request.set_userid(this->id);
- request.set_devicetoken(this->deviceToken);
-
- Logger::log("Sending PONG");
- grpc::Status status = this->stub_->SendPong(&context, request, &response);
- if (!status.ok()) {
- std::ostringstream errorMsg;
- errorMsg << "Sending PONG failed: " << status.error_message() << std::endl;
- Logger::log(errorMsg.str());
- }
-}
-
grpc::Status Client::send(
std::string sessionID,
std::string toDeviceID,
diff --git a/native/ios/Comm/AppDelegate.mm b/native/ios/Comm/AppDelegate.mm
--- a/native/ios/Comm/AppDelegate.mm
+++ b/native/ios/Comm/AppDelegate.mm
@@ -152,17 +152,7 @@
- (BOOL)handleBackgroundNotification:(NSDictionary *)notification
fetchCompletionHandler:
(void (^)(UIBackgroundFetchResult))completionHandler {
- if ([notification[backgroundNotificationTypeKey] isEqualToString:@"PING"]) {
- comm::GlobalNetworkSingleton::instance.scheduleOrRun(
- [=](comm::NetworkModule &networkModule) {
- networkModule.sendPong();
- dispatch_async(dispatch_get_main_queue(), ^{
- completionHandler(UIBackgroundFetchResultNewData);
- });
- });
- return YES;
- } else if ([notification[backgroundNotificationTypeKey]
- isEqualToString:@"CLEAR"]) {
+ if ([notification[backgroundNotificationTypeKey] isEqualToString:@"CLEAR"]) {
if (notification[setUnreadStatusKey] && notification[@"threadID"]) {
std::string threadID =
std::string([notification[@"threadID"] UTF8String]);
diff --git a/services/tunnelbroker/src/server/mod.rs b/services/tunnelbroker/src/server/mod.rs
--- a/services/tunnelbroker/src/server/mod.rs
+++ b/services/tunnelbroker/src/server/mod.rs
@@ -371,27 +371,6 @@
// These empty old API handlers are deprecated and should be removed.
// They are implemented only to fix the building process.
- async fn check_if_primary_device_online(
- &self,
- _request: Request<tunnelbroker::CheckRequest>,
- ) -> Result<Response<tunnelbroker::CheckResponse>, Status> {
- Err(Status::cancelled("Deprecated"))
- }
-
- async fn become_new_primary_device(
- &self,
- _request: Request<tunnelbroker::NewPrimaryRequest>,
- ) -> Result<Response<tunnelbroker::NewPrimaryResponse>, Status> {
- Err(Status::cancelled("Deprecated"))
- }
-
- async fn send_pong(
- &self,
- _request: Request<tunnelbroker::PongRequest>,
- ) -> Result<Response<()>, Status> {
- Err(Status::cancelled("Deprecated"))
- }
-
async fn send(
&self,
_request: Request<tunnelbroker::SendRequest>,
diff --git a/shared/protos/_generated/tunnelbroker.grpc.pb.h b/shared/protos/_generated/tunnelbroker.grpc.pb.h
--- a/shared/protos/_generated/tunnelbroker.grpc.pb.h
+++ b/shared/protos/_generated/tunnelbroker.grpc.pb.h
@@ -35,33 +35,6 @@
class StubInterface {
public:
virtual ~StubInterface() {}
- // The old API service methods
- // to support the native client build
- // until we switch to the new one
- //
- virtual ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::tunnelbroker::CheckResponse* response) = 0;
- std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::CheckResponse>> AsyncCheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::CheckResponse>>(AsyncCheckIfPrimaryDeviceOnlineRaw(context, request, cq));
- }
- std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::CheckResponse>> PrepareAsyncCheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::CheckResponse>>(PrepareAsyncCheckIfPrimaryDeviceOnlineRaw(context, request, cq));
- }
- virtual ::grpc::Status BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::tunnelbroker::NewPrimaryResponse* response) = 0;
- std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::NewPrimaryResponse>> AsyncBecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::NewPrimaryResponse>>(AsyncBecomeNewPrimaryDeviceRaw(context, request, cq));
- }
- std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::NewPrimaryResponse>> PrepareAsyncBecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::NewPrimaryResponse>>(PrepareAsyncBecomeNewPrimaryDeviceRaw(context, request, cq));
- }
- virtual ::grpc::Status SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::google::protobuf::Empty* response) = 0;
- std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::google::protobuf::Empty>> AsyncSendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::google::protobuf::Empty>>(AsyncSendPongRaw(context, request, cq));
- }
- std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::google::protobuf::Empty>> PrepareAsyncSendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::google::protobuf::Empty>>(PrepareAsyncSendPongRaw(context, request, cq));
- }
- // New API service methods
- //
virtual ::grpc::Status SessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::tunnelbroker::SessionSignatureResponse* response) = 0;
std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::SessionSignatureResponse>> AsyncSessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::grpc::CompletionQueue* cq) {
return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::SessionSignatureResponse>>(AsyncSessionSignatureRaw(context, request, cq));
@@ -107,18 +80,6 @@
class async_interface {
public:
virtual ~async_interface() {}
- // The old API service methods
- // to support the native client build
- // until we switch to the new one
- //
- virtual void CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response, std::function<void(::grpc::Status)>) = 0;
- virtual void CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response, ::grpc::ClientUnaryReactor* reactor) = 0;
- virtual void BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response, std::function<void(::grpc::Status)>) = 0;
- virtual void BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response, ::grpc::ClientUnaryReactor* reactor) = 0;
- virtual void SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response, std::function<void(::grpc::Status)>) = 0;
- virtual void SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response, ::grpc::ClientUnaryReactor* reactor) = 0;
- // New API service methods
- //
virtual void SessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest* request, ::tunnelbroker::SessionSignatureResponse* response, std::function<void(::grpc::Status)>) = 0;
virtual void SessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest* request, ::tunnelbroker::SessionSignatureResponse* response, ::grpc::ClientUnaryReactor* reactor) = 0;
virtual void NewSession(::grpc::ClientContext* context, const ::tunnelbroker::NewSessionRequest* request, ::tunnelbroker::NewSessionResponse* response, std::function<void(::grpc::Status)>) = 0;
@@ -135,12 +96,6 @@
virtual class async_interface* async() { return nullptr; }
class async_interface* experimental_async() { return async(); }
private:
- virtual ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::CheckResponse>* AsyncCheckIfPrimaryDeviceOnlineRaw(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) = 0;
- virtual ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::CheckResponse>* PrepareAsyncCheckIfPrimaryDeviceOnlineRaw(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) = 0;
- virtual ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::NewPrimaryResponse>* AsyncBecomeNewPrimaryDeviceRaw(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) = 0;
- virtual ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::NewPrimaryResponse>* PrepareAsyncBecomeNewPrimaryDeviceRaw(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) = 0;
- virtual ::grpc::ClientAsyncResponseReaderInterface< ::google::protobuf::Empty>* AsyncSendPongRaw(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) = 0;
- virtual ::grpc::ClientAsyncResponseReaderInterface< ::google::protobuf::Empty>* PrepareAsyncSendPongRaw(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) = 0;
virtual ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::SessionSignatureResponse>* AsyncSessionSignatureRaw(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::grpc::CompletionQueue* cq) = 0;
virtual ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::SessionSignatureResponse>* PrepareAsyncSessionSignatureRaw(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::grpc::CompletionQueue* cq) = 0;
virtual ::grpc::ClientAsyncResponseReaderInterface< ::tunnelbroker::NewSessionResponse>* AsyncNewSessionRaw(::grpc::ClientContext* context, const ::tunnelbroker::NewSessionRequest& request, ::grpc::CompletionQueue* cq) = 0;
@@ -157,27 +112,6 @@
class Stub final : public StubInterface {
public:
Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options = ::grpc::StubOptions());
- ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::tunnelbroker::CheckResponse* response) override;
- std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::CheckResponse>> AsyncCheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::CheckResponse>>(AsyncCheckIfPrimaryDeviceOnlineRaw(context, request, cq));
- }
- std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::CheckResponse>> PrepareAsyncCheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::CheckResponse>>(PrepareAsyncCheckIfPrimaryDeviceOnlineRaw(context, request, cq));
- }
- ::grpc::Status BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::tunnelbroker::NewPrimaryResponse* response) override;
- std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewPrimaryResponse>> AsyncBecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewPrimaryResponse>>(AsyncBecomeNewPrimaryDeviceRaw(context, request, cq));
- }
- std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewPrimaryResponse>> PrepareAsyncBecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewPrimaryResponse>>(PrepareAsyncBecomeNewPrimaryDeviceRaw(context, request, cq));
- }
- ::grpc::Status SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::google::protobuf::Empty* response) override;
- std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::google::protobuf::Empty>> AsyncSendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::google::protobuf::Empty>>(AsyncSendPongRaw(context, request, cq));
- }
- std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::google::protobuf::Empty>> PrepareAsyncSendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) {
- return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::google::protobuf::Empty>>(PrepareAsyncSendPongRaw(context, request, cq));
- }
::grpc::Status SessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::tunnelbroker::SessionSignatureResponse* response) override;
std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::SessionSignatureResponse>> AsyncSessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::grpc::CompletionQueue* cq) {
return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::tunnelbroker::SessionSignatureResponse>>(AsyncSessionSignatureRaw(context, request, cq));
@@ -220,12 +154,6 @@
class async final :
public StubInterface::async_interface {
public:
- void CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response, std::function<void(::grpc::Status)>) override;
- void CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response, ::grpc::ClientUnaryReactor* reactor) override;
- void BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response, std::function<void(::grpc::Status)>) override;
- void BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response, ::grpc::ClientUnaryReactor* reactor) override;
- void SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response, std::function<void(::grpc::Status)>) override;
- void SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response, ::grpc::ClientUnaryReactor* reactor) override;
void SessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest* request, ::tunnelbroker::SessionSignatureResponse* response, std::function<void(::grpc::Status)>) override;
void SessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest* request, ::tunnelbroker::SessionSignatureResponse* response, ::grpc::ClientUnaryReactor* reactor) override;
void NewSession(::grpc::ClientContext* context, const ::tunnelbroker::NewSessionRequest* request, ::tunnelbroker::NewSessionResponse* response, std::function<void(::grpc::Status)>) override;
@@ -245,12 +173,6 @@
private:
std::shared_ptr< ::grpc::ChannelInterface> channel_;
class async async_stub_{this};
- ::grpc::ClientAsyncResponseReader< ::tunnelbroker::CheckResponse>* AsyncCheckIfPrimaryDeviceOnlineRaw(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) override;
- ::grpc::ClientAsyncResponseReader< ::tunnelbroker::CheckResponse>* PrepareAsyncCheckIfPrimaryDeviceOnlineRaw(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) override;
- ::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewPrimaryResponse>* AsyncBecomeNewPrimaryDeviceRaw(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) override;
- ::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewPrimaryResponse>* PrepareAsyncBecomeNewPrimaryDeviceRaw(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) override;
- ::grpc::ClientAsyncResponseReader< ::google::protobuf::Empty>* AsyncSendPongRaw(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) override;
- ::grpc::ClientAsyncResponseReader< ::google::protobuf::Empty>* PrepareAsyncSendPongRaw(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) override;
::grpc::ClientAsyncResponseReader< ::tunnelbroker::SessionSignatureResponse>* AsyncSessionSignatureRaw(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::grpc::CompletionQueue* cq) override;
::grpc::ClientAsyncResponseReader< ::tunnelbroker::SessionSignatureResponse>* PrepareAsyncSessionSignatureRaw(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::grpc::CompletionQueue* cq) override;
::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewSessionResponse>* AsyncNewSessionRaw(::grpc::ClientContext* context, const ::tunnelbroker::NewSessionRequest& request, ::grpc::CompletionQueue* cq) override;
@@ -263,9 +185,6 @@
::grpc::ClientReaderWriter< ::tunnelbroker::MessageToTunnelbroker, ::tunnelbroker::MessageToClient>* MessagesStreamRaw(::grpc::ClientContext* context) override;
::grpc::ClientAsyncReaderWriter< ::tunnelbroker::MessageToTunnelbroker, ::tunnelbroker::MessageToClient>* AsyncMessagesStreamRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq, void* tag) override;
::grpc::ClientAsyncReaderWriter< ::tunnelbroker::MessageToTunnelbroker, ::tunnelbroker::MessageToClient>* PrepareAsyncMessagesStreamRaw(::grpc::ClientContext* context, ::grpc::CompletionQueue* cq) override;
- const ::grpc::internal::RpcMethod rpcmethod_CheckIfPrimaryDeviceOnline_;
- const ::grpc::internal::RpcMethod rpcmethod_BecomeNewPrimaryDevice_;
- const ::grpc::internal::RpcMethod rpcmethod_SendPong_;
const ::grpc::internal::RpcMethod rpcmethod_SessionSignature_;
const ::grpc::internal::RpcMethod rpcmethod_NewSession_;
const ::grpc::internal::RpcMethod rpcmethod_Send_;
@@ -278,15 +197,6 @@
public:
Service();
virtual ~Service();
- // The old API service methods
- // to support the native client build
- // until we switch to the new one
- //
- virtual ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ServerContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response);
- virtual ::grpc::Status BecomeNewPrimaryDevice(::grpc::ServerContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response);
- virtual ::grpc::Status SendPong(::grpc::ServerContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response);
- // New API service methods
- //
virtual ::grpc::Status SessionSignature(::grpc::ServerContext* context, const ::tunnelbroker::SessionSignatureRequest* request, ::tunnelbroker::SessionSignatureResponse* response);
virtual ::grpc::Status NewSession(::grpc::ServerContext* context, const ::tunnelbroker::NewSessionRequest* request, ::tunnelbroker::NewSessionResponse* response);
virtual ::grpc::Status Send(::grpc::ServerContext* context, const ::tunnelbroker::SendRequest* request, ::google::protobuf::Empty* response);
@@ -297,72 +207,12 @@
virtual ::grpc::Status MessagesStream(::grpc::ServerContext* context, ::grpc::ServerReaderWriter< ::tunnelbroker::MessageToClient, ::tunnelbroker::MessageToTunnelbroker>* stream);
};
template <class BaseClass>
- class WithAsyncMethod_CheckIfPrimaryDeviceOnline : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithAsyncMethod_CheckIfPrimaryDeviceOnline() {
- ::grpc::Service::MarkMethodAsync(0);
- }
- ~WithAsyncMethod_CheckIfPrimaryDeviceOnline() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ServerContext* /*context*/, const ::tunnelbroker::CheckRequest* /*request*/, ::tunnelbroker::CheckResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- void RequestCheckIfPrimaryDeviceOnline(::grpc::ServerContext* context, ::tunnelbroker::CheckRequest* request, ::grpc::ServerAsyncResponseWriter< ::tunnelbroker::CheckResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
- }
- };
- template <class BaseClass>
- class WithAsyncMethod_BecomeNewPrimaryDevice : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithAsyncMethod_BecomeNewPrimaryDevice() {
- ::grpc::Service::MarkMethodAsync(1);
- }
- ~WithAsyncMethod_BecomeNewPrimaryDevice() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status BecomeNewPrimaryDevice(::grpc::ServerContext* /*context*/, const ::tunnelbroker::NewPrimaryRequest* /*request*/, ::tunnelbroker::NewPrimaryResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- void RequestBecomeNewPrimaryDevice(::grpc::ServerContext* context, ::tunnelbroker::NewPrimaryRequest* request, ::grpc::ServerAsyncResponseWriter< ::tunnelbroker::NewPrimaryResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(1, context, request, response, new_call_cq, notification_cq, tag);
- }
- };
- template <class BaseClass>
- class WithAsyncMethod_SendPong : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithAsyncMethod_SendPong() {
- ::grpc::Service::MarkMethodAsync(2);
- }
- ~WithAsyncMethod_SendPong() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status SendPong(::grpc::ServerContext* /*context*/, const ::tunnelbroker::PongRequest* /*request*/, ::google::protobuf::Empty* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- void RequestSendPong(::grpc::ServerContext* context, ::tunnelbroker::PongRequest* request, ::grpc::ServerAsyncResponseWriter< ::google::protobuf::Empty>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(2, context, request, response, new_call_cq, notification_cq, tag);
- }
- };
- template <class BaseClass>
class WithAsyncMethod_SessionSignature : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithAsyncMethod_SessionSignature() {
- ::grpc::Service::MarkMethodAsync(3);
+ ::grpc::Service::MarkMethodAsync(0);
}
~WithAsyncMethod_SessionSignature() override {
BaseClassMustBeDerivedFromService(this);
@@ -373,7 +223,7 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestSessionSignature(::grpc::ServerContext* context, ::tunnelbroker::SessionSignatureRequest* request, ::grpc::ServerAsyncResponseWriter< ::tunnelbroker::SessionSignatureResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(3, context, request, response, new_call_cq, notification_cq, tag);
+ ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
@@ -382,7 +232,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithAsyncMethod_NewSession() {
- ::grpc::Service::MarkMethodAsync(4);
+ ::grpc::Service::MarkMethodAsync(1);
}
~WithAsyncMethod_NewSession() override {
BaseClassMustBeDerivedFromService(this);
@@ -393,7 +243,7 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestNewSession(::grpc::ServerContext* context, ::tunnelbroker::NewSessionRequest* request, ::grpc::ServerAsyncResponseWriter< ::tunnelbroker::NewSessionResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(4, context, request, response, new_call_cq, notification_cq, tag);
+ ::grpc::Service::RequestAsyncUnary(1, context, request, response, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
@@ -402,7 +252,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithAsyncMethod_Send() {
- ::grpc::Service::MarkMethodAsync(5);
+ ::grpc::Service::MarkMethodAsync(2);
}
~WithAsyncMethod_Send() override {
BaseClassMustBeDerivedFromService(this);
@@ -413,7 +263,7 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestSend(::grpc::ServerContext* context, ::tunnelbroker::SendRequest* request, ::grpc::ServerAsyncResponseWriter< ::google::protobuf::Empty>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(5, context, request, response, new_call_cq, notification_cq, tag);
+ ::grpc::Service::RequestAsyncUnary(2, context, request, response, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
@@ -422,7 +272,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithAsyncMethod_Get() {
- ::grpc::Service::MarkMethodAsync(6);
+ ::grpc::Service::MarkMethodAsync(3);
}
~WithAsyncMethod_Get() override {
BaseClassMustBeDerivedFromService(this);
@@ -433,7 +283,7 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestGet(::grpc::ServerContext* context, ::tunnelbroker::GetRequest* request, ::grpc::ServerAsyncWriter< ::tunnelbroker::GetResponse>* writer, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncServerStreaming(6, context, request, writer, new_call_cq, notification_cq, tag);
+ ::grpc::Service::RequestAsyncServerStreaming(3, context, request, writer, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
@@ -442,7 +292,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithAsyncMethod_MessagesStream() {
- ::grpc::Service::MarkMethodAsync(7);
+ ::grpc::Service::MarkMethodAsync(4);
}
~WithAsyncMethod_MessagesStream() override {
BaseClassMustBeDerivedFromService(this);
@@ -453,104 +303,23 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestMessagesStream(::grpc::ServerContext* context, ::grpc::ServerAsyncReaderWriter< ::tunnelbroker::MessageToClient, ::tunnelbroker::MessageToTunnelbroker>* stream, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncBidiStreaming(7, context, stream, new_call_cq, notification_cq, tag);
- }
- };
- typedef WithAsyncMethod_CheckIfPrimaryDeviceOnline<WithAsyncMethod_BecomeNewPrimaryDevice<WithAsyncMethod_SendPong<WithAsyncMethod_SessionSignature<WithAsyncMethod_NewSession<WithAsyncMethod_Send<WithAsyncMethod_Get<WithAsyncMethod_MessagesStream<Service > > > > > > > > AsyncService;
- template <class BaseClass>
- class WithCallbackMethod_CheckIfPrimaryDeviceOnline : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithCallbackMethod_CheckIfPrimaryDeviceOnline() {
- ::grpc::Service::MarkMethodCallback(0,
- new ::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::CheckRequest, ::tunnelbroker::CheckResponse>(
- [this](
- ::grpc::CallbackServerContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response) { return this->CheckIfPrimaryDeviceOnline(context, request, response); }));}
- void SetMessageAllocatorFor_CheckIfPrimaryDeviceOnline(
- ::grpc::MessageAllocator< ::tunnelbroker::CheckRequest, ::tunnelbroker::CheckResponse>* allocator) {
- ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(0);
- static_cast<::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::CheckRequest, ::tunnelbroker::CheckResponse>*>(handler)
- ->SetMessageAllocator(allocator);
- }
- ~WithCallbackMethod_CheckIfPrimaryDeviceOnline() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ServerContext* /*context*/, const ::tunnelbroker::CheckRequest* /*request*/, ::tunnelbroker::CheckResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- virtual ::grpc::ServerUnaryReactor* CheckIfPrimaryDeviceOnline(
- ::grpc::CallbackServerContext* /*context*/, const ::tunnelbroker::CheckRequest* /*request*/, ::tunnelbroker::CheckResponse* /*response*/) { return nullptr; }
- };
- template <class BaseClass>
- class WithCallbackMethod_BecomeNewPrimaryDevice : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithCallbackMethod_BecomeNewPrimaryDevice() {
- ::grpc::Service::MarkMethodCallback(1,
- new ::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::NewPrimaryRequest, ::tunnelbroker::NewPrimaryResponse>(
- [this](
- ::grpc::CallbackServerContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response) { return this->BecomeNewPrimaryDevice(context, request, response); }));}
- void SetMessageAllocatorFor_BecomeNewPrimaryDevice(
- ::grpc::MessageAllocator< ::tunnelbroker::NewPrimaryRequest, ::tunnelbroker::NewPrimaryResponse>* allocator) {
- ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(1);
- static_cast<::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::NewPrimaryRequest, ::tunnelbroker::NewPrimaryResponse>*>(handler)
- ->SetMessageAllocator(allocator);
- }
- ~WithCallbackMethod_BecomeNewPrimaryDevice() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status BecomeNewPrimaryDevice(::grpc::ServerContext* /*context*/, const ::tunnelbroker::NewPrimaryRequest* /*request*/, ::tunnelbroker::NewPrimaryResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
+ ::grpc::Service::RequestAsyncBidiStreaming(4, context, stream, new_call_cq, notification_cq, tag);
}
- virtual ::grpc::ServerUnaryReactor* BecomeNewPrimaryDevice(
- ::grpc::CallbackServerContext* /*context*/, const ::tunnelbroker::NewPrimaryRequest* /*request*/, ::tunnelbroker::NewPrimaryResponse* /*response*/) { return nullptr; }
- };
- template <class BaseClass>
- class WithCallbackMethod_SendPong : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithCallbackMethod_SendPong() {
- ::grpc::Service::MarkMethodCallback(2,
- new ::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::PongRequest, ::google::protobuf::Empty>(
- [this](
- ::grpc::CallbackServerContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response) { return this->SendPong(context, request, response); }));}
- void SetMessageAllocatorFor_SendPong(
- ::grpc::MessageAllocator< ::tunnelbroker::PongRequest, ::google::protobuf::Empty>* allocator) {
- ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(2);
- static_cast<::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::PongRequest, ::google::protobuf::Empty>*>(handler)
- ->SetMessageAllocator(allocator);
- }
- ~WithCallbackMethod_SendPong() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status SendPong(::grpc::ServerContext* /*context*/, const ::tunnelbroker::PongRequest* /*request*/, ::google::protobuf::Empty* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- virtual ::grpc::ServerUnaryReactor* SendPong(
- ::grpc::CallbackServerContext* /*context*/, const ::tunnelbroker::PongRequest* /*request*/, ::google::protobuf::Empty* /*response*/) { return nullptr; }
};
+ typedef WithAsyncMethod_SessionSignature<WithAsyncMethod_NewSession<WithAsyncMethod_Send<WithAsyncMethod_Get<WithAsyncMethod_MessagesStream<Service > > > > > AsyncService;
template <class BaseClass>
class WithCallbackMethod_SessionSignature : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithCallbackMethod_SessionSignature() {
- ::grpc::Service::MarkMethodCallback(3,
+ ::grpc::Service::MarkMethodCallback(0,
new ::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::SessionSignatureRequest, ::tunnelbroker::SessionSignatureResponse>(
[this](
::grpc::CallbackServerContext* context, const ::tunnelbroker::SessionSignatureRequest* request, ::tunnelbroker::SessionSignatureResponse* response) { return this->SessionSignature(context, request, response); }));}
void SetMessageAllocatorFor_SessionSignature(
::grpc::MessageAllocator< ::tunnelbroker::SessionSignatureRequest, ::tunnelbroker::SessionSignatureResponse>* allocator) {
- ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(3);
+ ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(0);
static_cast<::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::SessionSignatureRequest, ::tunnelbroker::SessionSignatureResponse>*>(handler)
->SetMessageAllocator(allocator);
}
@@ -571,13 +340,13 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithCallbackMethod_NewSession() {
- ::grpc::Service::MarkMethodCallback(4,
+ ::grpc::Service::MarkMethodCallback(1,
new ::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::NewSessionRequest, ::tunnelbroker::NewSessionResponse>(
[this](
::grpc::CallbackServerContext* context, const ::tunnelbroker::NewSessionRequest* request, ::tunnelbroker::NewSessionResponse* response) { return this->NewSession(context, request, response); }));}
void SetMessageAllocatorFor_NewSession(
::grpc::MessageAllocator< ::tunnelbroker::NewSessionRequest, ::tunnelbroker::NewSessionResponse>* allocator) {
- ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(4);
+ ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(1);
static_cast<::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::NewSessionRequest, ::tunnelbroker::NewSessionResponse>*>(handler)
->SetMessageAllocator(allocator);
}
@@ -598,13 +367,13 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithCallbackMethod_Send() {
- ::grpc::Service::MarkMethodCallback(5,
+ ::grpc::Service::MarkMethodCallback(2,
new ::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::SendRequest, ::google::protobuf::Empty>(
[this](
::grpc::CallbackServerContext* context, const ::tunnelbroker::SendRequest* request, ::google::protobuf::Empty* response) { return this->Send(context, request, response); }));}
void SetMessageAllocatorFor_Send(
::grpc::MessageAllocator< ::tunnelbroker::SendRequest, ::google::protobuf::Empty>* allocator) {
- ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(5);
+ ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(2);
static_cast<::grpc::internal::CallbackUnaryHandler< ::tunnelbroker::SendRequest, ::google::protobuf::Empty>*>(handler)
->SetMessageAllocator(allocator);
}
@@ -625,7 +394,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithCallbackMethod_Get() {
- ::grpc::Service::MarkMethodCallback(6,
+ ::grpc::Service::MarkMethodCallback(3,
new ::grpc::internal::CallbackServerStreamingHandler< ::tunnelbroker::GetRequest, ::tunnelbroker::GetResponse>(
[this](
::grpc::CallbackServerContext* context, const ::tunnelbroker::GetRequest* request) { return this->Get(context, request); }));
@@ -647,7 +416,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithCallbackMethod_MessagesStream() {
- ::grpc::Service::MarkMethodCallback(7,
+ ::grpc::Service::MarkMethodCallback(4,
new ::grpc::internal::CallbackBidiHandler< ::tunnelbroker::MessageToTunnelbroker, ::tunnelbroker::MessageToClient>(
[this](
::grpc::CallbackServerContext* context) { return this->MessagesStream(context); }));
@@ -664,66 +433,15 @@
::grpc::CallbackServerContext* /*context*/)
{ return nullptr; }
};
- typedef WithCallbackMethod_CheckIfPrimaryDeviceOnline<WithCallbackMethod_BecomeNewPrimaryDevice<WithCallbackMethod_SendPong<WithCallbackMethod_SessionSignature<WithCallbackMethod_NewSession<WithCallbackMethod_Send<WithCallbackMethod_Get<WithCallbackMethod_MessagesStream<Service > > > > > > > > CallbackService;
+ typedef WithCallbackMethod_SessionSignature<WithCallbackMethod_NewSession<WithCallbackMethod_Send<WithCallbackMethod_Get<WithCallbackMethod_MessagesStream<Service > > > > > CallbackService;
typedef CallbackService ExperimentalCallbackService;
template <class BaseClass>
- class WithGenericMethod_CheckIfPrimaryDeviceOnline : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithGenericMethod_CheckIfPrimaryDeviceOnline() {
- ::grpc::Service::MarkMethodGeneric(0);
- }
- ~WithGenericMethod_CheckIfPrimaryDeviceOnline() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ServerContext* /*context*/, const ::tunnelbroker::CheckRequest* /*request*/, ::tunnelbroker::CheckResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- };
- template <class BaseClass>
- class WithGenericMethod_BecomeNewPrimaryDevice : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithGenericMethod_BecomeNewPrimaryDevice() {
- ::grpc::Service::MarkMethodGeneric(1);
- }
- ~WithGenericMethod_BecomeNewPrimaryDevice() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status BecomeNewPrimaryDevice(::grpc::ServerContext* /*context*/, const ::tunnelbroker::NewPrimaryRequest* /*request*/, ::tunnelbroker::NewPrimaryResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- };
- template <class BaseClass>
- class WithGenericMethod_SendPong : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithGenericMethod_SendPong() {
- ::grpc::Service::MarkMethodGeneric(2);
- }
- ~WithGenericMethod_SendPong() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status SendPong(::grpc::ServerContext* /*context*/, const ::tunnelbroker::PongRequest* /*request*/, ::google::protobuf::Empty* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- };
- template <class BaseClass>
class WithGenericMethod_SessionSignature : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithGenericMethod_SessionSignature() {
- ::grpc::Service::MarkMethodGeneric(3);
+ ::grpc::Service::MarkMethodGeneric(0);
}
~WithGenericMethod_SessionSignature() override {
BaseClassMustBeDerivedFromService(this);
@@ -740,7 +458,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithGenericMethod_NewSession() {
- ::grpc::Service::MarkMethodGeneric(4);
+ ::grpc::Service::MarkMethodGeneric(1);
}
~WithGenericMethod_NewSession() override {
BaseClassMustBeDerivedFromService(this);
@@ -757,7 +475,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithGenericMethod_Send() {
- ::grpc::Service::MarkMethodGeneric(5);
+ ::grpc::Service::MarkMethodGeneric(2);
}
~WithGenericMethod_Send() override {
BaseClassMustBeDerivedFromService(this);
@@ -774,7 +492,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithGenericMethod_Get() {
- ::grpc::Service::MarkMethodGeneric(6);
+ ::grpc::Service::MarkMethodGeneric(3);
}
~WithGenericMethod_Get() override {
BaseClassMustBeDerivedFromService(this);
@@ -791,7 +509,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithGenericMethod_MessagesStream() {
- ::grpc::Service::MarkMethodGeneric(7);
+ ::grpc::Service::MarkMethodGeneric(4);
}
~WithGenericMethod_MessagesStream() override {
BaseClassMustBeDerivedFromService(this);
@@ -803,72 +521,12 @@
}
};
template <class BaseClass>
- class WithRawMethod_CheckIfPrimaryDeviceOnline : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithRawMethod_CheckIfPrimaryDeviceOnline() {
- ::grpc::Service::MarkMethodRaw(0);
- }
- ~WithRawMethod_CheckIfPrimaryDeviceOnline() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ServerContext* /*context*/, const ::tunnelbroker::CheckRequest* /*request*/, ::tunnelbroker::CheckResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- void RequestCheckIfPrimaryDeviceOnline(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
- }
- };
- template <class BaseClass>
- class WithRawMethod_BecomeNewPrimaryDevice : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithRawMethod_BecomeNewPrimaryDevice() {
- ::grpc::Service::MarkMethodRaw(1);
- }
- ~WithRawMethod_BecomeNewPrimaryDevice() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status BecomeNewPrimaryDevice(::grpc::ServerContext* /*context*/, const ::tunnelbroker::NewPrimaryRequest* /*request*/, ::tunnelbroker::NewPrimaryResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- void RequestBecomeNewPrimaryDevice(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(1, context, request, response, new_call_cq, notification_cq, tag);
- }
- };
- template <class BaseClass>
- class WithRawMethod_SendPong : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithRawMethod_SendPong() {
- ::grpc::Service::MarkMethodRaw(2);
- }
- ~WithRawMethod_SendPong() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status SendPong(::grpc::ServerContext* /*context*/, const ::tunnelbroker::PongRequest* /*request*/, ::google::protobuf::Empty* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- void RequestSendPong(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(2, context, request, response, new_call_cq, notification_cq, tag);
- }
- };
- template <class BaseClass>
class WithRawMethod_SessionSignature : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawMethod_SessionSignature() {
- ::grpc::Service::MarkMethodRaw(3);
+ ::grpc::Service::MarkMethodRaw(0);
}
~WithRawMethod_SessionSignature() override {
BaseClassMustBeDerivedFromService(this);
@@ -879,7 +537,7 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestSessionSignature(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(3, context, request, response, new_call_cq, notification_cq, tag);
+ ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
@@ -888,7 +546,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawMethod_NewSession() {
- ::grpc::Service::MarkMethodRaw(4);
+ ::grpc::Service::MarkMethodRaw(1);
}
~WithRawMethod_NewSession() override {
BaseClassMustBeDerivedFromService(this);
@@ -899,7 +557,7 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestNewSession(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(4, context, request, response, new_call_cq, notification_cq, tag);
+ ::grpc::Service::RequestAsyncUnary(1, context, request, response, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
@@ -908,7 +566,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawMethod_Send() {
- ::grpc::Service::MarkMethodRaw(5);
+ ::grpc::Service::MarkMethodRaw(2);
}
~WithRawMethod_Send() override {
BaseClassMustBeDerivedFromService(this);
@@ -919,7 +577,7 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestSend(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncUnary(5, context, request, response, new_call_cq, notification_cq, tag);
+ ::grpc::Service::RequestAsyncUnary(2, context, request, response, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
@@ -928,7 +586,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawMethod_Get() {
- ::grpc::Service::MarkMethodRaw(6);
+ ::grpc::Service::MarkMethodRaw(3);
}
~WithRawMethod_Get() override {
BaseClassMustBeDerivedFromService(this);
@@ -939,7 +597,7 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestGet(::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(6, context, request, writer, new_call_cq, notification_cq, tag);
+ ::grpc::Service::RequestAsyncServerStreaming(3, context, request, writer, new_call_cq, notification_cq, tag);
}
};
template <class BaseClass>
@@ -948,7 +606,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawMethod_MessagesStream() {
- ::grpc::Service::MarkMethodRaw(7);
+ ::grpc::Service::MarkMethodRaw(4);
}
~WithRawMethod_MessagesStream() override {
BaseClassMustBeDerivedFromService(this);
@@ -959,74 +617,8 @@
return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
}
void RequestMessagesStream(::grpc::ServerContext* context, ::grpc::ServerAsyncReaderWriter< ::grpc::ByteBuffer, ::grpc::ByteBuffer>* stream, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) {
- ::grpc::Service::RequestAsyncBidiStreaming(7, context, stream, new_call_cq, notification_cq, tag);
- }
- };
- template <class BaseClass>
- class WithRawCallbackMethod_CheckIfPrimaryDeviceOnline : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithRawCallbackMethod_CheckIfPrimaryDeviceOnline() {
- ::grpc::Service::MarkMethodRawCallback(0,
- new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
- [this](
- ::grpc::CallbackServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response) { return this->CheckIfPrimaryDeviceOnline(context, request, response); }));
- }
- ~WithRawCallbackMethod_CheckIfPrimaryDeviceOnline() override {
- BaseClassMustBeDerivedFromService(this);
+ ::grpc::Service::RequestAsyncBidiStreaming(4, context, stream, new_call_cq, notification_cq, tag);
}
- // disable synchronous version of this method
- ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ServerContext* /*context*/, const ::tunnelbroker::CheckRequest* /*request*/, ::tunnelbroker::CheckResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- virtual ::grpc::ServerUnaryReactor* CheckIfPrimaryDeviceOnline(
- ::grpc::CallbackServerContext* /*context*/, const ::grpc::ByteBuffer* /*request*/, ::grpc::ByteBuffer* /*response*/) { return nullptr; }
- };
- template <class BaseClass>
- class WithRawCallbackMethod_BecomeNewPrimaryDevice : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithRawCallbackMethod_BecomeNewPrimaryDevice() {
- ::grpc::Service::MarkMethodRawCallback(1,
- new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
- [this](
- ::grpc::CallbackServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response) { return this->BecomeNewPrimaryDevice(context, request, response); }));
- }
- ~WithRawCallbackMethod_BecomeNewPrimaryDevice() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status BecomeNewPrimaryDevice(::grpc::ServerContext* /*context*/, const ::tunnelbroker::NewPrimaryRequest* /*request*/, ::tunnelbroker::NewPrimaryResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- virtual ::grpc::ServerUnaryReactor* BecomeNewPrimaryDevice(
- ::grpc::CallbackServerContext* /*context*/, const ::grpc::ByteBuffer* /*request*/, ::grpc::ByteBuffer* /*response*/) { return nullptr; }
- };
- template <class BaseClass>
- class WithRawCallbackMethod_SendPong : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithRawCallbackMethod_SendPong() {
- ::grpc::Service::MarkMethodRawCallback(2,
- new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
- [this](
- ::grpc::CallbackServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response) { return this->SendPong(context, request, response); }));
- }
- ~WithRawCallbackMethod_SendPong() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable synchronous version of this method
- ::grpc::Status SendPong(::grpc::ServerContext* /*context*/, const ::tunnelbroker::PongRequest* /*request*/, ::google::protobuf::Empty* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- virtual ::grpc::ServerUnaryReactor* SendPong(
- ::grpc::CallbackServerContext* /*context*/, const ::grpc::ByteBuffer* /*request*/, ::grpc::ByteBuffer* /*response*/) { return nullptr; }
};
template <class BaseClass>
class WithRawCallbackMethod_SessionSignature : public BaseClass {
@@ -1034,7 +626,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawCallbackMethod_SessionSignature() {
- ::grpc::Service::MarkMethodRawCallback(3,
+ ::grpc::Service::MarkMethodRawCallback(0,
new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
[this](
::grpc::CallbackServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response) { return this->SessionSignature(context, request, response); }));
@@ -1056,7 +648,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawCallbackMethod_NewSession() {
- ::grpc::Service::MarkMethodRawCallback(4,
+ ::grpc::Service::MarkMethodRawCallback(1,
new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
[this](
::grpc::CallbackServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response) { return this->NewSession(context, request, response); }));
@@ -1078,7 +670,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawCallbackMethod_Send() {
- ::grpc::Service::MarkMethodRawCallback(5,
+ ::grpc::Service::MarkMethodRawCallback(2,
new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
[this](
::grpc::CallbackServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response) { return this->Send(context, request, response); }));
@@ -1100,7 +692,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawCallbackMethod_Get() {
- ::grpc::Service::MarkMethodRawCallback(6,
+ ::grpc::Service::MarkMethodRawCallback(3,
new ::grpc::internal::CallbackServerStreamingHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
[this](
::grpc::CallbackServerContext* context, const::grpc::ByteBuffer* request) { return this->Get(context, request); }));
@@ -1122,7 +714,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithRawCallbackMethod_MessagesStream() {
- ::grpc::Service::MarkMethodRawCallback(7,
+ ::grpc::Service::MarkMethodRawCallback(4,
new ::grpc::internal::CallbackBidiHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>(
[this](
::grpc::CallbackServerContext* context) { return this->MessagesStream(context); }));
@@ -1140,93 +732,12 @@
{ return nullptr; }
};
template <class BaseClass>
- class WithStreamedUnaryMethod_CheckIfPrimaryDeviceOnline : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithStreamedUnaryMethod_CheckIfPrimaryDeviceOnline() {
- ::grpc::Service::MarkMethodStreamed(0,
- new ::grpc::internal::StreamedUnaryHandler<
- ::tunnelbroker::CheckRequest, ::tunnelbroker::CheckResponse>(
- [this](::grpc::ServerContext* context,
- ::grpc::ServerUnaryStreamer<
- ::tunnelbroker::CheckRequest, ::tunnelbroker::CheckResponse>* streamer) {
- return this->StreamedCheckIfPrimaryDeviceOnline(context,
- streamer);
- }));
- }
- ~WithStreamedUnaryMethod_CheckIfPrimaryDeviceOnline() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable regular version of this method
- ::grpc::Status CheckIfPrimaryDeviceOnline(::grpc::ServerContext* /*context*/, const ::tunnelbroker::CheckRequest* /*request*/, ::tunnelbroker::CheckResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- // replace default version of method with streamed unary
- virtual ::grpc::Status StreamedCheckIfPrimaryDeviceOnline(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::tunnelbroker::CheckRequest,::tunnelbroker::CheckResponse>* server_unary_streamer) = 0;
- };
- template <class BaseClass>
- class WithStreamedUnaryMethod_BecomeNewPrimaryDevice : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithStreamedUnaryMethod_BecomeNewPrimaryDevice() {
- ::grpc::Service::MarkMethodStreamed(1,
- new ::grpc::internal::StreamedUnaryHandler<
- ::tunnelbroker::NewPrimaryRequest, ::tunnelbroker::NewPrimaryResponse>(
- [this](::grpc::ServerContext* context,
- ::grpc::ServerUnaryStreamer<
- ::tunnelbroker::NewPrimaryRequest, ::tunnelbroker::NewPrimaryResponse>* streamer) {
- return this->StreamedBecomeNewPrimaryDevice(context,
- streamer);
- }));
- }
- ~WithStreamedUnaryMethod_BecomeNewPrimaryDevice() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable regular version of this method
- ::grpc::Status BecomeNewPrimaryDevice(::grpc::ServerContext* /*context*/, const ::tunnelbroker::NewPrimaryRequest* /*request*/, ::tunnelbroker::NewPrimaryResponse* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- // replace default version of method with streamed unary
- virtual ::grpc::Status StreamedBecomeNewPrimaryDevice(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::tunnelbroker::NewPrimaryRequest,::tunnelbroker::NewPrimaryResponse>* server_unary_streamer) = 0;
- };
- template <class BaseClass>
- class WithStreamedUnaryMethod_SendPong : public BaseClass {
- private:
- void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
- public:
- WithStreamedUnaryMethod_SendPong() {
- ::grpc::Service::MarkMethodStreamed(2,
- new ::grpc::internal::StreamedUnaryHandler<
- ::tunnelbroker::PongRequest, ::google::protobuf::Empty>(
- [this](::grpc::ServerContext* context,
- ::grpc::ServerUnaryStreamer<
- ::tunnelbroker::PongRequest, ::google::protobuf::Empty>* streamer) {
- return this->StreamedSendPong(context,
- streamer);
- }));
- }
- ~WithStreamedUnaryMethod_SendPong() override {
- BaseClassMustBeDerivedFromService(this);
- }
- // disable regular version of this method
- ::grpc::Status SendPong(::grpc::ServerContext* /*context*/, const ::tunnelbroker::PongRequest* /*request*/, ::google::protobuf::Empty* /*response*/) override {
- abort();
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
- }
- // replace default version of method with streamed unary
- virtual ::grpc::Status StreamedSendPong(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::tunnelbroker::PongRequest,::google::protobuf::Empty>* server_unary_streamer) = 0;
- };
- template <class BaseClass>
class WithStreamedUnaryMethod_SessionSignature : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithStreamedUnaryMethod_SessionSignature() {
- ::grpc::Service::MarkMethodStreamed(3,
+ ::grpc::Service::MarkMethodStreamed(0,
new ::grpc::internal::StreamedUnaryHandler<
::tunnelbroker::SessionSignatureRequest, ::tunnelbroker::SessionSignatureResponse>(
[this](::grpc::ServerContext* context,
@@ -1253,7 +764,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithStreamedUnaryMethod_NewSession() {
- ::grpc::Service::MarkMethodStreamed(4,
+ ::grpc::Service::MarkMethodStreamed(1,
new ::grpc::internal::StreamedUnaryHandler<
::tunnelbroker::NewSessionRequest, ::tunnelbroker::NewSessionResponse>(
[this](::grpc::ServerContext* context,
@@ -1280,7 +791,7 @@
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithStreamedUnaryMethod_Send() {
- ::grpc::Service::MarkMethodStreamed(5,
+ ::grpc::Service::MarkMethodStreamed(2,
new ::grpc::internal::StreamedUnaryHandler<
::tunnelbroker::SendRequest, ::google::protobuf::Empty>(
[this](::grpc::ServerContext* context,
@@ -1301,14 +812,14 @@
// replace default version of method with streamed unary
virtual ::grpc::Status StreamedSend(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::tunnelbroker::SendRequest,::google::protobuf::Empty>* server_unary_streamer) = 0;
};
- typedef WithStreamedUnaryMethod_CheckIfPrimaryDeviceOnline<WithStreamedUnaryMethod_BecomeNewPrimaryDevice<WithStreamedUnaryMethod_SendPong<WithStreamedUnaryMethod_SessionSignature<WithStreamedUnaryMethod_NewSession<WithStreamedUnaryMethod_Send<Service > > > > > > StreamedUnaryService;
+ typedef WithStreamedUnaryMethod_SessionSignature<WithStreamedUnaryMethod_NewSession<WithStreamedUnaryMethod_Send<Service > > > StreamedUnaryService;
template <class BaseClass>
class WithSplitStreamingMethod_Get : public BaseClass {
private:
void BaseClassMustBeDerivedFromService(const Service* /*service*/) {}
public:
WithSplitStreamingMethod_Get() {
- ::grpc::Service::MarkMethodStreamed(6,
+ ::grpc::Service::MarkMethodStreamed(3,
new ::grpc::internal::SplitServerStreamingHandler<
::tunnelbroker::GetRequest, ::tunnelbroker::GetResponse>(
[this](::grpc::ServerContext* context,
@@ -1330,7 +841,7 @@
virtual ::grpc::Status StreamedGet(::grpc::ServerContext* context, ::grpc::ServerSplitStreamer< ::tunnelbroker::GetRequest,::tunnelbroker::GetResponse>* server_split_streamer) = 0;
};
typedef WithSplitStreamingMethod_Get<Service > SplitStreamedService;
- typedef WithStreamedUnaryMethod_CheckIfPrimaryDeviceOnline<WithStreamedUnaryMethod_BecomeNewPrimaryDevice<WithStreamedUnaryMethod_SendPong<WithStreamedUnaryMethod_SessionSignature<WithStreamedUnaryMethod_NewSession<WithStreamedUnaryMethod_Send<WithSplitStreamingMethod_Get<Service > > > > > > > StreamedService;
+ typedef WithStreamedUnaryMethod_SessionSignature<WithStreamedUnaryMethod_NewSession<WithStreamedUnaryMethod_Send<WithSplitStreamingMethod_Get<Service > > > > StreamedService;
};
} // namespace tunnelbroker
diff --git a/shared/protos/_generated/tunnelbroker.grpc.pb.cc b/shared/protos/_generated/tunnelbroker.grpc.pb.cc
--- a/shared/protos/_generated/tunnelbroker.grpc.pb.cc
+++ b/shared/protos/_generated/tunnelbroker.grpc.pb.cc
@@ -22,9 +22,6 @@
namespace tunnelbroker {
static const char* TunnelbrokerService_method_names[] = {
- "/tunnelbroker.TunnelbrokerService/CheckIfPrimaryDeviceOnline",
- "/tunnelbroker.TunnelbrokerService/BecomeNewPrimaryDevice",
- "/tunnelbroker.TunnelbrokerService/SendPong",
"/tunnelbroker.TunnelbrokerService/SessionSignature",
"/tunnelbroker.TunnelbrokerService/NewSession",
"/tunnelbroker.TunnelbrokerService/Send",
@@ -39,85 +36,13 @@
}
TunnelbrokerService::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options)
- : channel_(channel), rpcmethod_CheckIfPrimaryDeviceOnline_(TunnelbrokerService_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
- , rpcmethod_BecomeNewPrimaryDevice_(TunnelbrokerService_method_names[1], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
- , rpcmethod_SendPong_(TunnelbrokerService_method_names[2], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
- , rpcmethod_SessionSignature_(TunnelbrokerService_method_names[3], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
- , rpcmethod_NewSession_(TunnelbrokerService_method_names[4], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
- , rpcmethod_Send_(TunnelbrokerService_method_names[5], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
- , rpcmethod_Get_(TunnelbrokerService_method_names[6], options.suffix_for_stats(),::grpc::internal::RpcMethod::SERVER_STREAMING, channel)
- , rpcmethod_MessagesStream_(TunnelbrokerService_method_names[7], options.suffix_for_stats(),::grpc::internal::RpcMethod::BIDI_STREAMING, channel)
+ : channel_(channel), rpcmethod_SessionSignature_(TunnelbrokerService_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
+ , rpcmethod_NewSession_(TunnelbrokerService_method_names[1], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
+ , rpcmethod_Send_(TunnelbrokerService_method_names[2], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel)
+ , rpcmethod_Get_(TunnelbrokerService_method_names[3], options.suffix_for_stats(),::grpc::internal::RpcMethod::SERVER_STREAMING, channel)
+ , rpcmethod_MessagesStream_(TunnelbrokerService_method_names[4], options.suffix_for_stats(),::grpc::internal::RpcMethod::BIDI_STREAMING, channel)
{}
-::grpc::Status TunnelbrokerService::Stub::CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::tunnelbroker::CheckResponse* response) {
- return ::grpc::internal::BlockingUnaryCall< ::tunnelbroker::CheckRequest, ::tunnelbroker::CheckResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_CheckIfPrimaryDeviceOnline_, context, request, response);
-}
-
-void TunnelbrokerService::Stub::async::CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response, std::function<void(::grpc::Status)> f) {
- ::grpc::internal::CallbackUnaryCall< ::tunnelbroker::CheckRequest, ::tunnelbroker::CheckResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_CheckIfPrimaryDeviceOnline_, context, request, response, std::move(f));
-}
-
-void TunnelbrokerService::Stub::async::CheckIfPrimaryDeviceOnline(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response, ::grpc::ClientUnaryReactor* reactor) {
- ::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_CheckIfPrimaryDeviceOnline_, context, request, response, reactor);
-}
-
-::grpc::ClientAsyncResponseReader< ::tunnelbroker::CheckResponse>* TunnelbrokerService::Stub::PrepareAsyncCheckIfPrimaryDeviceOnlineRaw(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) {
- return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::tunnelbroker::CheckResponse, ::tunnelbroker::CheckRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_CheckIfPrimaryDeviceOnline_, context, request);
-}
-
-::grpc::ClientAsyncResponseReader< ::tunnelbroker::CheckResponse>* TunnelbrokerService::Stub::AsyncCheckIfPrimaryDeviceOnlineRaw(::grpc::ClientContext* context, const ::tunnelbroker::CheckRequest& request, ::grpc::CompletionQueue* cq) {
- auto* result =
- this->PrepareAsyncCheckIfPrimaryDeviceOnlineRaw(context, request, cq);
- result->StartCall();
- return result;
-}
-
-::grpc::Status TunnelbrokerService::Stub::BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::tunnelbroker::NewPrimaryResponse* response) {
- return ::grpc::internal::BlockingUnaryCall< ::tunnelbroker::NewPrimaryRequest, ::tunnelbroker::NewPrimaryResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_BecomeNewPrimaryDevice_, context, request, response);
-}
-
-void TunnelbrokerService::Stub::async::BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response, std::function<void(::grpc::Status)> f) {
- ::grpc::internal::CallbackUnaryCall< ::tunnelbroker::NewPrimaryRequest, ::tunnelbroker::NewPrimaryResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_BecomeNewPrimaryDevice_, context, request, response, std::move(f));
-}
-
-void TunnelbrokerService::Stub::async::BecomeNewPrimaryDevice(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response, ::grpc::ClientUnaryReactor* reactor) {
- ::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_BecomeNewPrimaryDevice_, context, request, response, reactor);
-}
-
-::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewPrimaryResponse>* TunnelbrokerService::Stub::PrepareAsyncBecomeNewPrimaryDeviceRaw(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) {
- return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::tunnelbroker::NewPrimaryResponse, ::tunnelbroker::NewPrimaryRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_BecomeNewPrimaryDevice_, context, request);
-}
-
-::grpc::ClientAsyncResponseReader< ::tunnelbroker::NewPrimaryResponse>* TunnelbrokerService::Stub::AsyncBecomeNewPrimaryDeviceRaw(::grpc::ClientContext* context, const ::tunnelbroker::NewPrimaryRequest& request, ::grpc::CompletionQueue* cq) {
- auto* result =
- this->PrepareAsyncBecomeNewPrimaryDeviceRaw(context, request, cq);
- result->StartCall();
- return result;
-}
-
-::grpc::Status TunnelbrokerService::Stub::SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::google::protobuf::Empty* response) {
- return ::grpc::internal::BlockingUnaryCall< ::tunnelbroker::PongRequest, ::google::protobuf::Empty, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_SendPong_, context, request, response);
-}
-
-void TunnelbrokerService::Stub::async::SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response, std::function<void(::grpc::Status)> f) {
- ::grpc::internal::CallbackUnaryCall< ::tunnelbroker::PongRequest, ::google::protobuf::Empty, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SendPong_, context, request, response, std::move(f));
-}
-
-void TunnelbrokerService::Stub::async::SendPong(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response, ::grpc::ClientUnaryReactor* reactor) {
- ::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_SendPong_, context, request, response, reactor);
-}
-
-::grpc::ClientAsyncResponseReader< ::google::protobuf::Empty>* TunnelbrokerService::Stub::PrepareAsyncSendPongRaw(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) {
- return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::google::protobuf::Empty, ::tunnelbroker::PongRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_SendPong_, context, request);
-}
-
-::grpc::ClientAsyncResponseReader< ::google::protobuf::Empty>* TunnelbrokerService::Stub::AsyncSendPongRaw(::grpc::ClientContext* context, const ::tunnelbroker::PongRequest& request, ::grpc::CompletionQueue* cq) {
- auto* result =
- this->PrepareAsyncSendPongRaw(context, request, cq);
- result->StartCall();
- return result;
-}
-
::grpc::Status TunnelbrokerService::Stub::SessionSignature(::grpc::ClientContext* context, const ::tunnelbroker::SessionSignatureRequest& request, ::tunnelbroker::SessionSignatureResponse* response) {
return ::grpc::internal::BlockingUnaryCall< ::tunnelbroker::SessionSignatureRequest, ::tunnelbroker::SessionSignatureResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_SessionSignature_, context, request, response);
}
@@ -223,36 +148,6 @@
AddMethod(new ::grpc::internal::RpcServiceMethod(
TunnelbrokerService_method_names[0],
::grpc::internal::RpcMethod::NORMAL_RPC,
- new ::grpc::internal::RpcMethodHandler< TunnelbrokerService::Service, ::tunnelbroker::CheckRequest, ::tunnelbroker::CheckResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
- [](TunnelbrokerService::Service* service,
- ::grpc::ServerContext* ctx,
- const ::tunnelbroker::CheckRequest* req,
- ::tunnelbroker::CheckResponse* resp) {
- return service->CheckIfPrimaryDeviceOnline(ctx, req, resp);
- }, this)));
- AddMethod(new ::grpc::internal::RpcServiceMethod(
- TunnelbrokerService_method_names[1],
- ::grpc::internal::RpcMethod::NORMAL_RPC,
- new ::grpc::internal::RpcMethodHandler< TunnelbrokerService::Service, ::tunnelbroker::NewPrimaryRequest, ::tunnelbroker::NewPrimaryResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
- [](TunnelbrokerService::Service* service,
- ::grpc::ServerContext* ctx,
- const ::tunnelbroker::NewPrimaryRequest* req,
- ::tunnelbroker::NewPrimaryResponse* resp) {
- return service->BecomeNewPrimaryDevice(ctx, req, resp);
- }, this)));
- AddMethod(new ::grpc::internal::RpcServiceMethod(
- TunnelbrokerService_method_names[2],
- ::grpc::internal::RpcMethod::NORMAL_RPC,
- new ::grpc::internal::RpcMethodHandler< TunnelbrokerService::Service, ::tunnelbroker::PongRequest, ::google::protobuf::Empty, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
- [](TunnelbrokerService::Service* service,
- ::grpc::ServerContext* ctx,
- const ::tunnelbroker::PongRequest* req,
- ::google::protobuf::Empty* resp) {
- return service->SendPong(ctx, req, resp);
- }, this)));
- AddMethod(new ::grpc::internal::RpcServiceMethod(
- TunnelbrokerService_method_names[3],
- ::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TunnelbrokerService::Service, ::tunnelbroker::SessionSignatureRequest, ::tunnelbroker::SessionSignatureResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TunnelbrokerService::Service* service,
::grpc::ServerContext* ctx,
@@ -261,7 +156,7 @@
return service->SessionSignature(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
- TunnelbrokerService_method_names[4],
+ TunnelbrokerService_method_names[1],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TunnelbrokerService::Service, ::tunnelbroker::NewSessionRequest, ::tunnelbroker::NewSessionResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TunnelbrokerService::Service* service,
@@ -271,7 +166,7 @@
return service->NewSession(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
- TunnelbrokerService_method_names[5],
+ TunnelbrokerService_method_names[2],
::grpc::internal::RpcMethod::NORMAL_RPC,
new ::grpc::internal::RpcMethodHandler< TunnelbrokerService::Service, ::tunnelbroker::SendRequest, ::google::protobuf::Empty, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(
[](TunnelbrokerService::Service* service,
@@ -281,7 +176,7 @@
return service->Send(ctx, req, resp);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
- TunnelbrokerService_method_names[6],
+ TunnelbrokerService_method_names[3],
::grpc::internal::RpcMethod::SERVER_STREAMING,
new ::grpc::internal::ServerStreamingHandler< TunnelbrokerService::Service, ::tunnelbroker::GetRequest, ::tunnelbroker::GetResponse>(
[](TunnelbrokerService::Service* service,
@@ -291,7 +186,7 @@
return service->Get(ctx, req, writer);
}, this)));
AddMethod(new ::grpc::internal::RpcServiceMethod(
- TunnelbrokerService_method_names[7],
+ TunnelbrokerService_method_names[4],
::grpc::internal::RpcMethod::BIDI_STREAMING,
new ::grpc::internal::BidiStreamingHandler< TunnelbrokerService::Service, ::tunnelbroker::MessageToTunnelbroker, ::tunnelbroker::MessageToClient>(
[](TunnelbrokerService::Service* service,
@@ -305,27 +200,6 @@
TunnelbrokerService::Service::~Service() {
}
-::grpc::Status TunnelbrokerService::Service::CheckIfPrimaryDeviceOnline(::grpc::ServerContext* context, const ::tunnelbroker::CheckRequest* request, ::tunnelbroker::CheckResponse* response) {
- (void) context;
- (void) request;
- (void) response;
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
-}
-
-::grpc::Status TunnelbrokerService::Service::BecomeNewPrimaryDevice(::grpc::ServerContext* context, const ::tunnelbroker::NewPrimaryRequest* request, ::tunnelbroker::NewPrimaryResponse* response) {
- (void) context;
- (void) request;
- (void) response;
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
-}
-
-::grpc::Status TunnelbrokerService::Service::SendPong(::grpc::ServerContext* context, const ::tunnelbroker::PongRequest* request, ::google::protobuf::Empty* response) {
- (void) context;
- (void) request;
- (void) response;
- return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "");
-}
-
::grpc::Status TunnelbrokerService::Service::SessionSignature(::grpc::ServerContext* context, const ::tunnelbroker::SessionSignatureRequest* request, ::tunnelbroker::SessionSignatureResponse* response) {
(void) context;
(void) request;
diff --git a/shared/protos/_generated/tunnelbroker.pb.h b/shared/protos/_generated/tunnelbroker.pb.h
--- a/shared/protos/_generated/tunnelbroker.pb.h
+++ b/shared/protos/_generated/tunnelbroker.pb.h
@@ -48,7 +48,7 @@
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[20]
+ static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTable schema[15]
PROTOBUF_SECTION_VARIABLE(protodesc_cold);
static const ::PROTOBUF_NAMESPACE_ID::internal::FieldMetadata field_metadata[];
static const ::PROTOBUF_NAMESPACE_ID::internal::SerializationTable serialization_table[];
@@ -57,12 +57,6 @@
extern const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_tunnelbroker_2eproto;
::PROTOBUF_NAMESPACE_ID::Metadata descriptor_table_tunnelbroker_2eproto_metadata_getter(int index);
namespace tunnelbroker {
-class CheckRequest;
-struct CheckRequestDefaultTypeInternal;
-extern CheckRequestDefaultTypeInternal _CheckRequest_default_instance_;
-class CheckResponse;
-struct CheckResponseDefaultTypeInternal;
-extern CheckResponseDefaultTypeInternal _CheckResponse_default_instance_;
class GetRequest;
struct GetRequestDefaultTypeInternal;
extern GetRequestDefaultTypeInternal _GetRequest_default_instance_;
@@ -90,21 +84,12 @@
class MessagesToSend;
struct MessagesToSendDefaultTypeInternal;
extern MessagesToSendDefaultTypeInternal _MessagesToSend_default_instance_;
-class NewPrimaryRequest;
-struct NewPrimaryRequestDefaultTypeInternal;
-extern NewPrimaryRequestDefaultTypeInternal _NewPrimaryRequest_default_instance_;
-class NewPrimaryResponse;
-struct NewPrimaryResponseDefaultTypeInternal;
-extern NewPrimaryResponseDefaultTypeInternal _NewPrimaryResponse_default_instance_;
class NewSessionRequest;
struct NewSessionRequestDefaultTypeInternal;
extern NewSessionRequestDefaultTypeInternal _NewSessionRequest_default_instance_;
class NewSessionResponse;
struct NewSessionResponseDefaultTypeInternal;
extern NewSessionResponseDefaultTypeInternal _NewSessionResponse_default_instance_;
-class PongRequest;
-struct PongRequestDefaultTypeInternal;
-extern PongRequestDefaultTypeInternal _PongRequest_default_instance_;
class ProcessedMessages;
struct ProcessedMessagesDefaultTypeInternal;
extern ProcessedMessagesDefaultTypeInternal _ProcessedMessages_default_instance_;
@@ -119,8 +104,6 @@
extern SessionSignatureResponseDefaultTypeInternal _SessionSignatureResponse_default_instance_;
} // namespace tunnelbroker
PROTOBUF_NAMESPACE_OPEN
-template<> ::tunnelbroker::CheckRequest* Arena::CreateMaybeMessage<::tunnelbroker::CheckRequest>(Arena*);
-template<> ::tunnelbroker::CheckResponse* Arena::CreateMaybeMessage<::tunnelbroker::CheckResponse>(Arena*);
template<> ::tunnelbroker::GetRequest* Arena::CreateMaybeMessage<::tunnelbroker::GetRequest>(Arena*);
template<> ::tunnelbroker::GetResponse* Arena::CreateMaybeMessage<::tunnelbroker::GetResponse>(Arena*);
template<> ::tunnelbroker::GetResponseMessage* Arena::CreateMaybeMessage<::tunnelbroker::GetResponseMessage>(Arena*);
@@ -130,11 +113,8 @@
template<> ::tunnelbroker::MessageToTunnelbrokerStruct* Arena::CreateMaybeMessage<::tunnelbroker::MessageToTunnelbrokerStruct>(Arena*);
template<> ::tunnelbroker::MessagesToDeliver* Arena::CreateMaybeMessage<::tunnelbroker::MessagesToDeliver>(Arena*);
template<> ::tunnelbroker::MessagesToSend* Arena::CreateMaybeMessage<::tunnelbroker::MessagesToSend>(Arena*);
-template<> ::tunnelbroker::NewPrimaryRequest* Arena::CreateMaybeMessage<::tunnelbroker::NewPrimaryRequest>(Arena*);
-template<> ::tunnelbroker::NewPrimaryResponse* Arena::CreateMaybeMessage<::tunnelbroker::NewPrimaryResponse>(Arena*);
template<> ::tunnelbroker::NewSessionRequest* Arena::CreateMaybeMessage<::tunnelbroker::NewSessionRequest>(Arena*);
template<> ::tunnelbroker::NewSessionResponse* Arena::CreateMaybeMessage<::tunnelbroker::NewSessionResponse>(Arena*);
-template<> ::tunnelbroker::PongRequest* Arena::CreateMaybeMessage<::tunnelbroker::PongRequest>(Arena*);
template<> ::tunnelbroker::ProcessedMessages* Arena::CreateMaybeMessage<::tunnelbroker::ProcessedMessages>(Arena*);
template<> ::tunnelbroker::SendRequest* Arena::CreateMaybeMessage<::tunnelbroker::SendRequest>(Arena*);
template<> ::tunnelbroker::SessionSignatureRequest* Arena::CreateMaybeMessage<::tunnelbroker::SessionSignatureRequest>(Arena*);
@@ -168,33 +148,6 @@
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<NewSessionRequest_DeviceTypes>(
NewSessionRequest_DeviceTypes_descriptor(), name, value);
}
-enum CheckResponseType : int {
- PRIMARY_DOESNT_EXIST = 0,
- PRIMARY_ONLINE = 1,
- PRIMARY_OFFLINE = 2,
- CURRENT_IS_PRIMARY = 3,
- CheckResponseType_INT_MIN_SENTINEL_DO_NOT_USE_ = std::numeric_limits<::PROTOBUF_NAMESPACE_ID::int32>::min(),
- CheckResponseType_INT_MAX_SENTINEL_DO_NOT_USE_ = std::numeric_limits<::PROTOBUF_NAMESPACE_ID::int32>::max()
-};
-bool CheckResponseType_IsValid(int value);
-constexpr CheckResponseType CheckResponseType_MIN = PRIMARY_DOESNT_EXIST;
-constexpr CheckResponseType CheckResponseType_MAX = CURRENT_IS_PRIMARY;
-constexpr int CheckResponseType_ARRAYSIZE = CheckResponseType_MAX + 1;
-
-const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* CheckResponseType_descriptor();
-template<typename T>
-inline const std::string& CheckResponseType_Name(T enum_t_value) {
- static_assert(::std::is_same<T, CheckResponseType>::value ||
- ::std::is_integral<T>::value,
- "Incorrect type passed to function CheckResponseType_Name.");
- return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
- CheckResponseType_descriptor(), enum_t_value);
-}
-inline bool CheckResponseType_Parse(
- ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, CheckResponseType* value) {
- return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<CheckResponseType>(
- CheckResponseType_descriptor(), name, value);
-}
// ===================================================================
class SessionSignatureRequest PROTOBUF_FINAL :
@@ -2971,967 +2924,207 @@
friend struct ::TableStruct_tunnelbroker_2eproto;
};
-// -------------------------------------------------------------------
+// ===================================================================
-class CheckRequest PROTOBUF_FINAL :
- public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:tunnelbroker.CheckRequest) */ {
- public:
- inline CheckRequest() : CheckRequest(nullptr) {}
- virtual ~CheckRequest();
- explicit constexpr CheckRequest(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);
- CheckRequest(const CheckRequest& from);
- CheckRequest(CheckRequest&& from) noexcept
- : CheckRequest() {
- *this = ::std::move(from);
- }
+// ===================================================================
- inline CheckRequest& operator=(const CheckRequest& from) {
- CopyFrom(from);
- return *this;
- }
- inline CheckRequest& operator=(CheckRequest&& from) noexcept {
- if (GetArena() == from.GetArena()) {
- if (this != &from) InternalSwap(&from);
- } else {
- CopyFrom(from);
- }
- return *this;
- }
+#ifdef __GNUC__
+ #pragma GCC diagnostic push
+ #pragma GCC diagnostic ignored "-Wstrict-aliasing"
+#endif // __GNUC__
+// SessionSignatureRequest
- 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 CheckRequest& default_instance() {
- return *internal_default_instance();
- }
- static inline const CheckRequest* internal_default_instance() {
- return reinterpret_cast<const CheckRequest*>(
- &_CheckRequest_default_instance_);
+// string deviceID = 1;
+inline void SessionSignatureRequest::clear_deviceid() {
+ deviceid_.ClearToEmpty();
+}
+inline const std::string& SessionSignatureRequest::deviceid() const {
+ // @@protoc_insertion_point(field_get:tunnelbroker.SessionSignatureRequest.deviceID)
+ return _internal_deviceid();
+}
+inline void SessionSignatureRequest::set_deviceid(const std::string& value) {
+ _internal_set_deviceid(value);
+ // @@protoc_insertion_point(field_set:tunnelbroker.SessionSignatureRequest.deviceID)
+}
+inline std::string* SessionSignatureRequest::mutable_deviceid() {
+ // @@protoc_insertion_point(field_mutable:tunnelbroker.SessionSignatureRequest.deviceID)
+ return _internal_mutable_deviceid();
+}
+inline const std::string& SessionSignatureRequest::_internal_deviceid() const {
+ return deviceid_.Get();
+}
+inline void SessionSignatureRequest::_internal_set_deviceid(const std::string& value) {
+
+ deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
+}
+inline void SessionSignatureRequest::set_deviceid(std::string&& value) {
+
+ deviceid_.Set(
+ ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
+ // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.SessionSignatureRequest.deviceID)
+}
+inline void SessionSignatureRequest::set_deviceid(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
+ // @@protoc_insertion_point(field_set_char:tunnelbroker.SessionSignatureRequest.deviceID)
+}
+inline void SessionSignatureRequest::set_deviceid(const char* value,
+ size_t size) {
+
+ deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
+ reinterpret_cast<const char*>(value), size), GetArena());
+ // @@protoc_insertion_point(field_set_pointer:tunnelbroker.SessionSignatureRequest.deviceID)
+}
+inline std::string* SessionSignatureRequest::_internal_mutable_deviceid() {
+
+ return deviceid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
+}
+inline std::string* SessionSignatureRequest::release_deviceid() {
+ // @@protoc_insertion_point(field_release:tunnelbroker.SessionSignatureRequest.deviceID)
+ return deviceid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
+}
+inline void SessionSignatureRequest::set_allocated_deviceid(std::string* deviceid) {
+ if (deviceid != nullptr) {
+
+ } else {
+
}
- static constexpr int kIndexInFileMessages =
- 15;
+ deviceid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), deviceid,
+ GetArena());
+ // @@protoc_insertion_point(field_set_allocated:tunnelbroker.SessionSignatureRequest.deviceID)
+}
- friend void swap(CheckRequest& a, CheckRequest& b) {
- a.Swap(&b);
- }
- inline void Swap(CheckRequest* other) {
- if (other == this) return;
- if (GetArena() == other->GetArena()) {
- InternalSwap(other);
- } else {
- ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
- }
- }
- void UnsafeArenaSwap(CheckRequest* other) {
- if (other == this) return;
- GOOGLE_DCHECK(GetArena() == other->GetArena());
- InternalSwap(other);
- }
+// -------------------------------------------------------------------
- // implements Message ----------------------------------------------
+// SessionSignatureResponse
- inline CheckRequest* New() const final {
- return CreateMaybeMessage<CheckRequest>(nullptr);
+// string toSign = 1;
+inline void SessionSignatureResponse::clear_tosign() {
+ tosign_.ClearToEmpty();
+}
+inline const std::string& SessionSignatureResponse::tosign() const {
+ // @@protoc_insertion_point(field_get:tunnelbroker.SessionSignatureResponse.toSign)
+ return _internal_tosign();
+}
+inline void SessionSignatureResponse::set_tosign(const std::string& value) {
+ _internal_set_tosign(value);
+ // @@protoc_insertion_point(field_set:tunnelbroker.SessionSignatureResponse.toSign)
+}
+inline std::string* SessionSignatureResponse::mutable_tosign() {
+ // @@protoc_insertion_point(field_mutable:tunnelbroker.SessionSignatureResponse.toSign)
+ return _internal_mutable_tosign();
+}
+inline const std::string& SessionSignatureResponse::_internal_tosign() const {
+ return tosign_.Get();
+}
+inline void SessionSignatureResponse::_internal_set_tosign(const std::string& value) {
+
+ tosign_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
+}
+inline void SessionSignatureResponse::set_tosign(std::string&& value) {
+
+ tosign_.Set(
+ ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
+ // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.SessionSignatureResponse.toSign)
+}
+inline void SessionSignatureResponse::set_tosign(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ tosign_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
+ // @@protoc_insertion_point(field_set_char:tunnelbroker.SessionSignatureResponse.toSign)
+}
+inline void SessionSignatureResponse::set_tosign(const char* value,
+ size_t size) {
+
+ tosign_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
+ reinterpret_cast<const char*>(value), size), GetArena());
+ // @@protoc_insertion_point(field_set_pointer:tunnelbroker.SessionSignatureResponse.toSign)
+}
+inline std::string* SessionSignatureResponse::_internal_mutable_tosign() {
+
+ return tosign_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
+}
+inline std::string* SessionSignatureResponse::release_tosign() {
+ // @@protoc_insertion_point(field_release:tunnelbroker.SessionSignatureResponse.toSign)
+ return tosign_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
+}
+inline void SessionSignatureResponse::set_allocated_tosign(std::string* tosign) {
+ if (tosign != nullptr) {
+
+ } else {
+
}
+ tosign_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), tosign,
+ GetArena());
+ // @@protoc_insertion_point(field_set_allocated:tunnelbroker.SessionSignatureResponse.toSign)
+}
- CheckRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
- return CreateMaybeMessage<CheckRequest>(arena);
- }
- void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void CopyFrom(const CheckRequest& from);
- void MergeFrom(const CheckRequest& 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(); }
+// NewSessionRequest
- private:
- inline void SharedCtor();
- inline void SharedDtor();
- void SetCachedSize(int size) const final;
- void InternalSwap(CheckRequest* other);
- friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
- static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
- return "tunnelbroker.CheckRequest";
+// string deviceID = 1;
+inline void NewSessionRequest::clear_deviceid() {
+ deviceid_.ClearToEmpty();
+}
+inline const std::string& NewSessionRequest::deviceid() const {
+ // @@protoc_insertion_point(field_get:tunnelbroker.NewSessionRequest.deviceID)
+ return _internal_deviceid();
+}
+inline void NewSessionRequest::set_deviceid(const std::string& value) {
+ _internal_set_deviceid(value);
+ // @@protoc_insertion_point(field_set:tunnelbroker.NewSessionRequest.deviceID)
+}
+inline std::string* NewSessionRequest::mutable_deviceid() {
+ // @@protoc_insertion_point(field_mutable:tunnelbroker.NewSessionRequest.deviceID)
+ return _internal_mutable_deviceid();
+}
+inline const std::string& NewSessionRequest::_internal_deviceid() const {
+ return deviceid_.Get();
+}
+inline void NewSessionRequest::_internal_set_deviceid(const std::string& value) {
+
+ deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
+}
+inline void NewSessionRequest::set_deviceid(std::string&& value) {
+
+ deviceid_.Set(
+ ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
+ // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.NewSessionRequest.deviceID)
+}
+inline void NewSessionRequest::set_deviceid(const char* value) {
+ GOOGLE_DCHECK(value != nullptr);
+
+ deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
+ // @@protoc_insertion_point(field_set_char:tunnelbroker.NewSessionRequest.deviceID)
+}
+inline void NewSessionRequest::set_deviceid(const char* value,
+ size_t size) {
+
+ deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
+ reinterpret_cast<const char*>(value), size), GetArena());
+ // @@protoc_insertion_point(field_set_pointer:tunnelbroker.NewSessionRequest.deviceID)
+}
+inline std::string* NewSessionRequest::_internal_mutable_deviceid() {
+
+ return deviceid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
+}
+inline std::string* NewSessionRequest::release_deviceid() {
+ // @@protoc_insertion_point(field_release:tunnelbroker.NewSessionRequest.deviceID)
+ return deviceid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
+}
+inline void NewSessionRequest::set_allocated_deviceid(std::string* deviceid) {
+ if (deviceid != nullptr) {
+
+ } else {
+
}
- protected:
- explicit CheckRequest(::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_tunnelbroker_2eproto_metadata_getter(kIndexInFileMessages);
- }
-
- public:
-
- // nested types ----------------------------------------------------
-
- // accessors -------------------------------------------------------
-
- enum : int {
- kUserIdFieldNumber = 1,
- kDeviceTokenFieldNumber = 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 deviceToken = 2;
- void clear_devicetoken();
- const std::string& devicetoken() const;
- void set_devicetoken(const std::string& value);
- void set_devicetoken(std::string&& value);
- void set_devicetoken(const char* value);
- void set_devicetoken(const char* value, size_t size);
- std::string* mutable_devicetoken();
- std::string* release_devicetoken();
- void set_allocated_devicetoken(std::string* devicetoken);
- private:
- const std::string& _internal_devicetoken() const;
- void _internal_set_devicetoken(const std::string& value);
- std::string* _internal_mutable_devicetoken();
- public:
-
- // @@protoc_insertion_point(class_scope:tunnelbroker.CheckRequest)
- private:
- class _Internal;
-
- template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
- typedef void InternalArenaConstructable_;
- typedef void DestructorSkippable_;
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr userid_;
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr devicetoken_;
- mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
- friend struct ::TableStruct_tunnelbroker_2eproto;
-};
-// -------------------------------------------------------------------
-
-class CheckResponse PROTOBUF_FINAL :
- public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:tunnelbroker.CheckResponse) */ {
- public:
- inline CheckResponse() : CheckResponse(nullptr) {}
- virtual ~CheckResponse();
- explicit constexpr CheckResponse(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);
-
- CheckResponse(const CheckResponse& from);
- CheckResponse(CheckResponse&& from) noexcept
- : CheckResponse() {
- *this = ::std::move(from);
- }
-
- inline CheckResponse& operator=(const CheckResponse& from) {
- CopyFrom(from);
- return *this;
- }
- inline CheckResponse& operator=(CheckResponse&& 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 CheckResponse& default_instance() {
- return *internal_default_instance();
- }
- static inline const CheckResponse* internal_default_instance() {
- return reinterpret_cast<const CheckResponse*>(
- &_CheckResponse_default_instance_);
- }
- static constexpr int kIndexInFileMessages =
- 16;
-
- friend void swap(CheckResponse& a, CheckResponse& b) {
- a.Swap(&b);
- }
- inline void Swap(CheckResponse* other) {
- if (other == this) return;
- if (GetArena() == other->GetArena()) {
- InternalSwap(other);
- } else {
- ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
- }
- }
- void UnsafeArenaSwap(CheckResponse* other) {
- if (other == this) return;
- GOOGLE_DCHECK(GetArena() == other->GetArena());
- InternalSwap(other);
- }
-
- // implements Message ----------------------------------------------
-
- inline CheckResponse* New() const final {
- return CreateMaybeMessage<CheckResponse>(nullptr);
- }
-
- CheckResponse* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
- return CreateMaybeMessage<CheckResponse>(arena);
- }
- void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void CopyFrom(const CheckResponse& from);
- void MergeFrom(const CheckResponse& 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(CheckResponse* other);
- friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
- static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
- return "tunnelbroker.CheckResponse";
- }
- protected:
- explicit CheckResponse(::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_tunnelbroker_2eproto_metadata_getter(kIndexInFileMessages);
- }
-
- public:
-
- // nested types ----------------------------------------------------
-
- // accessors -------------------------------------------------------
-
- enum : int {
- kCheckResponseTypeFieldNumber = 1,
- };
- // .tunnelbroker.CheckResponseType checkResponseType = 1;
- void clear_checkresponsetype();
- ::tunnelbroker::CheckResponseType checkresponsetype() const;
- void set_checkresponsetype(::tunnelbroker::CheckResponseType value);
- private:
- ::tunnelbroker::CheckResponseType _internal_checkresponsetype() const;
- void _internal_set_checkresponsetype(::tunnelbroker::CheckResponseType value);
- public:
-
- // @@protoc_insertion_point(class_scope:tunnelbroker.CheckResponse)
- private:
- class _Internal;
-
- template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
- typedef void InternalArenaConstructable_;
- typedef void DestructorSkippable_;
- int checkresponsetype_;
- mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
- friend struct ::TableStruct_tunnelbroker_2eproto;
-};
-// -------------------------------------------------------------------
-
-class NewPrimaryRequest PROTOBUF_FINAL :
- public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:tunnelbroker.NewPrimaryRequest) */ {
- public:
- inline NewPrimaryRequest() : NewPrimaryRequest(nullptr) {}
- virtual ~NewPrimaryRequest();
- explicit constexpr NewPrimaryRequest(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);
-
- NewPrimaryRequest(const NewPrimaryRequest& from);
- NewPrimaryRequest(NewPrimaryRequest&& from) noexcept
- : NewPrimaryRequest() {
- *this = ::std::move(from);
- }
-
- inline NewPrimaryRequest& operator=(const NewPrimaryRequest& from) {
- CopyFrom(from);
- return *this;
- }
- inline NewPrimaryRequest& operator=(NewPrimaryRequest&& 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 NewPrimaryRequest& default_instance() {
- return *internal_default_instance();
- }
- static inline const NewPrimaryRequest* internal_default_instance() {
- return reinterpret_cast<const NewPrimaryRequest*>(
- &_NewPrimaryRequest_default_instance_);
- }
- static constexpr int kIndexInFileMessages =
- 17;
-
- friend void swap(NewPrimaryRequest& a, NewPrimaryRequest& b) {
- a.Swap(&b);
- }
- inline void Swap(NewPrimaryRequest* other) {
- if (other == this) return;
- if (GetArena() == other->GetArena()) {
- InternalSwap(other);
- } else {
- ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
- }
- }
- void UnsafeArenaSwap(NewPrimaryRequest* other) {
- if (other == this) return;
- GOOGLE_DCHECK(GetArena() == other->GetArena());
- InternalSwap(other);
- }
-
- // implements Message ----------------------------------------------
-
- inline NewPrimaryRequest* New() const final {
- return CreateMaybeMessage<NewPrimaryRequest>(nullptr);
- }
-
- NewPrimaryRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
- return CreateMaybeMessage<NewPrimaryRequest>(arena);
- }
- void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void CopyFrom(const NewPrimaryRequest& from);
- void MergeFrom(const NewPrimaryRequest& 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(NewPrimaryRequest* other);
- friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
- static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
- return "tunnelbroker.NewPrimaryRequest";
- }
- protected:
- explicit NewPrimaryRequest(::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_tunnelbroker_2eproto_metadata_getter(kIndexInFileMessages);
- }
-
- public:
-
- // nested types ----------------------------------------------------
-
- // accessors -------------------------------------------------------
-
- enum : int {
- kUserIdFieldNumber = 1,
- kDeviceTokenFieldNumber = 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 deviceToken = 2;
- void clear_devicetoken();
- const std::string& devicetoken() const;
- void set_devicetoken(const std::string& value);
- void set_devicetoken(std::string&& value);
- void set_devicetoken(const char* value);
- void set_devicetoken(const char* value, size_t size);
- std::string* mutable_devicetoken();
- std::string* release_devicetoken();
- void set_allocated_devicetoken(std::string* devicetoken);
- private:
- const std::string& _internal_devicetoken() const;
- void _internal_set_devicetoken(const std::string& value);
- std::string* _internal_mutable_devicetoken();
- public:
-
- // @@protoc_insertion_point(class_scope:tunnelbroker.NewPrimaryRequest)
- private:
- class _Internal;
-
- template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
- typedef void InternalArenaConstructable_;
- typedef void DestructorSkippable_;
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr userid_;
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr devicetoken_;
- mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
- friend struct ::TableStruct_tunnelbroker_2eproto;
-};
-// -------------------------------------------------------------------
-
-class NewPrimaryResponse PROTOBUF_FINAL :
- public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:tunnelbroker.NewPrimaryResponse) */ {
- public:
- inline NewPrimaryResponse() : NewPrimaryResponse(nullptr) {}
- virtual ~NewPrimaryResponse();
- explicit constexpr NewPrimaryResponse(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);
-
- NewPrimaryResponse(const NewPrimaryResponse& from);
- NewPrimaryResponse(NewPrimaryResponse&& from) noexcept
- : NewPrimaryResponse() {
- *this = ::std::move(from);
- }
-
- inline NewPrimaryResponse& operator=(const NewPrimaryResponse& from) {
- CopyFrom(from);
- return *this;
- }
- inline NewPrimaryResponse& operator=(NewPrimaryResponse&& 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 NewPrimaryResponse& default_instance() {
- return *internal_default_instance();
- }
- static inline const NewPrimaryResponse* internal_default_instance() {
- return reinterpret_cast<const NewPrimaryResponse*>(
- &_NewPrimaryResponse_default_instance_);
- }
- static constexpr int kIndexInFileMessages =
- 18;
-
- friend void swap(NewPrimaryResponse& a, NewPrimaryResponse& b) {
- a.Swap(&b);
- }
- inline void Swap(NewPrimaryResponse* other) {
- if (other == this) return;
- if (GetArena() == other->GetArena()) {
- InternalSwap(other);
- } else {
- ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
- }
- }
- void UnsafeArenaSwap(NewPrimaryResponse* other) {
- if (other == this) return;
- GOOGLE_DCHECK(GetArena() == other->GetArena());
- InternalSwap(other);
- }
-
- // implements Message ----------------------------------------------
-
- inline NewPrimaryResponse* New() const final {
- return CreateMaybeMessage<NewPrimaryResponse>(nullptr);
- }
-
- NewPrimaryResponse* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
- return CreateMaybeMessage<NewPrimaryResponse>(arena);
- }
- void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void CopyFrom(const NewPrimaryResponse& from);
- void MergeFrom(const NewPrimaryResponse& 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(NewPrimaryResponse* other);
- friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
- static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
- return "tunnelbroker.NewPrimaryResponse";
- }
- protected:
- explicit NewPrimaryResponse(::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_tunnelbroker_2eproto_metadata_getter(kIndexInFileMessages);
- }
-
- public:
-
- // nested types ----------------------------------------------------
-
- // accessors -------------------------------------------------------
-
- enum : int {
- kSuccessFieldNumber = 1,
- };
- // bool success = 1;
- void clear_success();
- bool success() const;
- void set_success(bool value);
- private:
- bool _internal_success() const;
- void _internal_set_success(bool value);
- public:
-
- // @@protoc_insertion_point(class_scope:tunnelbroker.NewPrimaryResponse)
- private:
- class _Internal;
-
- template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
- typedef void InternalArenaConstructable_;
- typedef void DestructorSkippable_;
- bool success_;
- mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
- friend struct ::TableStruct_tunnelbroker_2eproto;
-};
-// -------------------------------------------------------------------
-
-class PongRequest PROTOBUF_FINAL :
- public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:tunnelbroker.PongRequest) */ {
- public:
- inline PongRequest() : PongRequest(nullptr) {}
- virtual ~PongRequest();
- explicit constexpr PongRequest(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized);
-
- PongRequest(const PongRequest& from);
- PongRequest(PongRequest&& from) noexcept
- : PongRequest() {
- *this = ::std::move(from);
- }
-
- inline PongRequest& operator=(const PongRequest& from) {
- CopyFrom(from);
- return *this;
- }
- inline PongRequest& operator=(PongRequest&& 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 PongRequest& default_instance() {
- return *internal_default_instance();
- }
- static inline const PongRequest* internal_default_instance() {
- return reinterpret_cast<const PongRequest*>(
- &_PongRequest_default_instance_);
- }
- static constexpr int kIndexInFileMessages =
- 19;
-
- friend void swap(PongRequest& a, PongRequest& b) {
- a.Swap(&b);
- }
- inline void Swap(PongRequest* other) {
- if (other == this) return;
- if (GetArena() == other->GetArena()) {
- InternalSwap(other);
- } else {
- ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
- }
- }
- void UnsafeArenaSwap(PongRequest* other) {
- if (other == this) return;
- GOOGLE_DCHECK(GetArena() == other->GetArena());
- InternalSwap(other);
- }
-
- // implements Message ----------------------------------------------
-
- inline PongRequest* New() const final {
- return CreateMaybeMessage<PongRequest>(nullptr);
- }
-
- PongRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
- return CreateMaybeMessage<PongRequest>(arena);
- }
- void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
- void CopyFrom(const PongRequest& from);
- void MergeFrom(const PongRequest& 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(PongRequest* other);
- friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
- static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
- return "tunnelbroker.PongRequest";
- }
- protected:
- explicit PongRequest(::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_tunnelbroker_2eproto_metadata_getter(kIndexInFileMessages);
- }
-
- public:
-
- // nested types ----------------------------------------------------
-
- // accessors -------------------------------------------------------
-
- enum : int {
- kUserIdFieldNumber = 1,
- kDeviceTokenFieldNumber = 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 deviceToken = 2;
- void clear_devicetoken();
- const std::string& devicetoken() const;
- void set_devicetoken(const std::string& value);
- void set_devicetoken(std::string&& value);
- void set_devicetoken(const char* value);
- void set_devicetoken(const char* value, size_t size);
- std::string* mutable_devicetoken();
- std::string* release_devicetoken();
- void set_allocated_devicetoken(std::string* devicetoken);
- private:
- const std::string& _internal_devicetoken() const;
- void _internal_set_devicetoken(const std::string& value);
- std::string* _internal_mutable_devicetoken();
- public:
-
- // @@protoc_insertion_point(class_scope:tunnelbroker.PongRequest)
- private:
- class _Internal;
-
- template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
- typedef void InternalArenaConstructable_;
- typedef void DestructorSkippable_;
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr userid_;
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr devicetoken_;
- mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
- friend struct ::TableStruct_tunnelbroker_2eproto;
-};
-// ===================================================================
-
-
-// ===================================================================
-
-#ifdef __GNUC__
- #pragma GCC diagnostic push
- #pragma GCC diagnostic ignored "-Wstrict-aliasing"
-#endif // __GNUC__
-// SessionSignatureRequest
-
-// string deviceID = 1;
-inline void SessionSignatureRequest::clear_deviceid() {
- deviceid_.ClearToEmpty();
-}
-inline const std::string& SessionSignatureRequest::deviceid() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.SessionSignatureRequest.deviceID)
- return _internal_deviceid();
-}
-inline void SessionSignatureRequest::set_deviceid(const std::string& value) {
- _internal_set_deviceid(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.SessionSignatureRequest.deviceID)
-}
-inline std::string* SessionSignatureRequest::mutable_deviceid() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.SessionSignatureRequest.deviceID)
- return _internal_mutable_deviceid();
-}
-inline const std::string& SessionSignatureRequest::_internal_deviceid() const {
- return deviceid_.Get();
-}
-inline void SessionSignatureRequest::_internal_set_deviceid(const std::string& value) {
-
- deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void SessionSignatureRequest::set_deviceid(std::string&& value) {
-
- deviceid_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.SessionSignatureRequest.deviceID)
-}
-inline void SessionSignatureRequest::set_deviceid(const char* value) {
- GOOGLE_DCHECK(value != nullptr);
-
- deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
- // @@protoc_insertion_point(field_set_char:tunnelbroker.SessionSignatureRequest.deviceID)
-}
-inline void SessionSignatureRequest::set_deviceid(const char* value,
- size_t size) {
-
- deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.SessionSignatureRequest.deviceID)
-}
-inline std::string* SessionSignatureRequest::_internal_mutable_deviceid() {
-
- return deviceid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* SessionSignatureRequest::release_deviceid() {
- // @@protoc_insertion_point(field_release:tunnelbroker.SessionSignatureRequest.deviceID)
- return deviceid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void SessionSignatureRequest::set_allocated_deviceid(std::string* deviceid) {
- if (deviceid != nullptr) {
-
- } else {
-
- }
- deviceid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), deviceid,
- GetArena());
- // @@protoc_insertion_point(field_set_allocated:tunnelbroker.SessionSignatureRequest.deviceID)
-}
-
-// -------------------------------------------------------------------
-
-// SessionSignatureResponse
-
-// string toSign = 1;
-inline void SessionSignatureResponse::clear_tosign() {
- tosign_.ClearToEmpty();
-}
-inline const std::string& SessionSignatureResponse::tosign() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.SessionSignatureResponse.toSign)
- return _internal_tosign();
-}
-inline void SessionSignatureResponse::set_tosign(const std::string& value) {
- _internal_set_tosign(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.SessionSignatureResponse.toSign)
-}
-inline std::string* SessionSignatureResponse::mutable_tosign() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.SessionSignatureResponse.toSign)
- return _internal_mutable_tosign();
-}
-inline const std::string& SessionSignatureResponse::_internal_tosign() const {
- return tosign_.Get();
-}
-inline void SessionSignatureResponse::_internal_set_tosign(const std::string& value) {
-
- tosign_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void SessionSignatureResponse::set_tosign(std::string&& value) {
-
- tosign_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.SessionSignatureResponse.toSign)
-}
-inline void SessionSignatureResponse::set_tosign(const char* value) {
- GOOGLE_DCHECK(value != nullptr);
-
- tosign_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
- // @@protoc_insertion_point(field_set_char:tunnelbroker.SessionSignatureResponse.toSign)
-}
-inline void SessionSignatureResponse::set_tosign(const char* value,
- size_t size) {
-
- tosign_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.SessionSignatureResponse.toSign)
-}
-inline std::string* SessionSignatureResponse::_internal_mutable_tosign() {
-
- return tosign_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* SessionSignatureResponse::release_tosign() {
- // @@protoc_insertion_point(field_release:tunnelbroker.SessionSignatureResponse.toSign)
- return tosign_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void SessionSignatureResponse::set_allocated_tosign(std::string* tosign) {
- if (tosign != nullptr) {
-
- } else {
-
- }
- tosign_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), tosign,
- GetArena());
- // @@protoc_insertion_point(field_set_allocated:tunnelbroker.SessionSignatureResponse.toSign)
-}
-
-// -------------------------------------------------------------------
-
-// NewSessionRequest
-
-// string deviceID = 1;
-inline void NewSessionRequest::clear_deviceid() {
- deviceid_.ClearToEmpty();
-}
-inline const std::string& NewSessionRequest::deviceid() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.NewSessionRequest.deviceID)
- return _internal_deviceid();
-}
-inline void NewSessionRequest::set_deviceid(const std::string& value) {
- _internal_set_deviceid(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.NewSessionRequest.deviceID)
-}
-inline std::string* NewSessionRequest::mutable_deviceid() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.NewSessionRequest.deviceID)
- return _internal_mutable_deviceid();
-}
-inline const std::string& NewSessionRequest::_internal_deviceid() const {
- return deviceid_.Get();
-}
-inline void NewSessionRequest::_internal_set_deviceid(const std::string& value) {
-
- deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void NewSessionRequest::set_deviceid(std::string&& value) {
-
- deviceid_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.NewSessionRequest.deviceID)
-}
-inline void NewSessionRequest::set_deviceid(const char* value) {
- GOOGLE_DCHECK(value != nullptr);
-
- deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
- // @@protoc_insertion_point(field_set_char:tunnelbroker.NewSessionRequest.deviceID)
-}
-inline void NewSessionRequest::set_deviceid(const char* value,
- size_t size) {
-
- deviceid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.NewSessionRequest.deviceID)
-}
-inline std::string* NewSessionRequest::_internal_mutable_deviceid() {
-
- return deviceid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* NewSessionRequest::release_deviceid() {
- // @@protoc_insertion_point(field_release:tunnelbroker.NewSessionRequest.deviceID)
- return deviceid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void NewSessionRequest::set_allocated_deviceid(std::string* deviceid) {
- if (deviceid != nullptr) {
-
- } else {
-
- }
- deviceid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), deviceid,
- GetArena());
- // @@protoc_insertion_point(field_set_allocated:tunnelbroker.NewSessionRequest.deviceID)
-}
+ deviceid_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), deviceid,
+ GetArena());
+ // @@protoc_insertion_point(field_set_allocated:tunnelbroker.NewSessionRequest.deviceID)
+}
// string publicKey = 2;
inline void NewSessionRequest::clear_publickey() {
@@ -6394,432 +5587,6 @@
inline MessageToClient::DataCase MessageToClient::data_case() const {
return MessageToClient::DataCase(_oneof_case_[0]);
}
-// -------------------------------------------------------------------
-
-// CheckRequest
-
-// string userId = 1;
-inline void CheckRequest::clear_userid() {
- userid_.ClearToEmpty();
-}
-inline const std::string& CheckRequest::userid() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.CheckRequest.userId)
- return _internal_userid();
-}
-inline void CheckRequest::set_userid(const std::string& value) {
- _internal_set_userid(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.CheckRequest.userId)
-}
-inline std::string* CheckRequest::mutable_userid() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.CheckRequest.userId)
- return _internal_mutable_userid();
-}
-inline const std::string& CheckRequest::_internal_userid() const {
- return userid_.Get();
-}
-inline void CheckRequest::_internal_set_userid(const std::string& value) {
-
- userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void CheckRequest::set_userid(std::string&& value) {
-
- userid_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.CheckRequest.userId)
-}
-inline void CheckRequest::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:tunnelbroker.CheckRequest.userId)
-}
-inline void CheckRequest::set_userid(const char* value,
- size_t size) {
-
- userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.CheckRequest.userId)
-}
-inline std::string* CheckRequest::_internal_mutable_userid() {
-
- return userid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* CheckRequest::release_userid() {
- // @@protoc_insertion_point(field_release:tunnelbroker.CheckRequest.userId)
- return userid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void CheckRequest::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:tunnelbroker.CheckRequest.userId)
-}
-
-// string deviceToken = 2;
-inline void CheckRequest::clear_devicetoken() {
- devicetoken_.ClearToEmpty();
-}
-inline const std::string& CheckRequest::devicetoken() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.CheckRequest.deviceToken)
- return _internal_devicetoken();
-}
-inline void CheckRequest::set_devicetoken(const std::string& value) {
- _internal_set_devicetoken(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.CheckRequest.deviceToken)
-}
-inline std::string* CheckRequest::mutable_devicetoken() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.CheckRequest.deviceToken)
- return _internal_mutable_devicetoken();
-}
-inline const std::string& CheckRequest::_internal_devicetoken() const {
- return devicetoken_.Get();
-}
-inline void CheckRequest::_internal_set_devicetoken(const std::string& value) {
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void CheckRequest::set_devicetoken(std::string&& value) {
-
- devicetoken_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.CheckRequest.deviceToken)
-}
-inline void CheckRequest::set_devicetoken(const char* value) {
- GOOGLE_DCHECK(value != nullptr);
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
- // @@protoc_insertion_point(field_set_char:tunnelbroker.CheckRequest.deviceToken)
-}
-inline void CheckRequest::set_devicetoken(const char* value,
- size_t size) {
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.CheckRequest.deviceToken)
-}
-inline std::string* CheckRequest::_internal_mutable_devicetoken() {
-
- return devicetoken_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* CheckRequest::release_devicetoken() {
- // @@protoc_insertion_point(field_release:tunnelbroker.CheckRequest.deviceToken)
- return devicetoken_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void CheckRequest::set_allocated_devicetoken(std::string* devicetoken) {
- if (devicetoken != nullptr) {
-
- } else {
-
- }
- devicetoken_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), devicetoken,
- GetArena());
- // @@protoc_insertion_point(field_set_allocated:tunnelbroker.CheckRequest.deviceToken)
-}
-
-// -------------------------------------------------------------------
-
-// CheckResponse
-
-// .tunnelbroker.CheckResponseType checkResponseType = 1;
-inline void CheckResponse::clear_checkresponsetype() {
- checkresponsetype_ = 0;
-}
-inline ::tunnelbroker::CheckResponseType CheckResponse::_internal_checkresponsetype() const {
- return static_cast< ::tunnelbroker::CheckResponseType >(checkresponsetype_);
-}
-inline ::tunnelbroker::CheckResponseType CheckResponse::checkresponsetype() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.CheckResponse.checkResponseType)
- return _internal_checkresponsetype();
-}
-inline void CheckResponse::_internal_set_checkresponsetype(::tunnelbroker::CheckResponseType value) {
-
- checkresponsetype_ = value;
-}
-inline void CheckResponse::set_checkresponsetype(::tunnelbroker::CheckResponseType value) {
- _internal_set_checkresponsetype(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.CheckResponse.checkResponseType)
-}
-
-// -------------------------------------------------------------------
-
-// NewPrimaryRequest
-
-// string userId = 1;
-inline void NewPrimaryRequest::clear_userid() {
- userid_.ClearToEmpty();
-}
-inline const std::string& NewPrimaryRequest::userid() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.NewPrimaryRequest.userId)
- return _internal_userid();
-}
-inline void NewPrimaryRequest::set_userid(const std::string& value) {
- _internal_set_userid(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.NewPrimaryRequest.userId)
-}
-inline std::string* NewPrimaryRequest::mutable_userid() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.NewPrimaryRequest.userId)
- return _internal_mutable_userid();
-}
-inline const std::string& NewPrimaryRequest::_internal_userid() const {
- return userid_.Get();
-}
-inline void NewPrimaryRequest::_internal_set_userid(const std::string& value) {
-
- userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void NewPrimaryRequest::set_userid(std::string&& value) {
-
- userid_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.NewPrimaryRequest.userId)
-}
-inline void NewPrimaryRequest::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:tunnelbroker.NewPrimaryRequest.userId)
-}
-inline void NewPrimaryRequest::set_userid(const char* value,
- size_t size) {
-
- userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.NewPrimaryRequest.userId)
-}
-inline std::string* NewPrimaryRequest::_internal_mutable_userid() {
-
- return userid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* NewPrimaryRequest::release_userid() {
- // @@protoc_insertion_point(field_release:tunnelbroker.NewPrimaryRequest.userId)
- return userid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void NewPrimaryRequest::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:tunnelbroker.NewPrimaryRequest.userId)
-}
-
-// string deviceToken = 2;
-inline void NewPrimaryRequest::clear_devicetoken() {
- devicetoken_.ClearToEmpty();
-}
-inline const std::string& NewPrimaryRequest::devicetoken() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.NewPrimaryRequest.deviceToken)
- return _internal_devicetoken();
-}
-inline void NewPrimaryRequest::set_devicetoken(const std::string& value) {
- _internal_set_devicetoken(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.NewPrimaryRequest.deviceToken)
-}
-inline std::string* NewPrimaryRequest::mutable_devicetoken() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.NewPrimaryRequest.deviceToken)
- return _internal_mutable_devicetoken();
-}
-inline const std::string& NewPrimaryRequest::_internal_devicetoken() const {
- return devicetoken_.Get();
-}
-inline void NewPrimaryRequest::_internal_set_devicetoken(const std::string& value) {
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void NewPrimaryRequest::set_devicetoken(std::string&& value) {
-
- devicetoken_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.NewPrimaryRequest.deviceToken)
-}
-inline void NewPrimaryRequest::set_devicetoken(const char* value) {
- GOOGLE_DCHECK(value != nullptr);
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
- // @@protoc_insertion_point(field_set_char:tunnelbroker.NewPrimaryRequest.deviceToken)
-}
-inline void NewPrimaryRequest::set_devicetoken(const char* value,
- size_t size) {
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.NewPrimaryRequest.deviceToken)
-}
-inline std::string* NewPrimaryRequest::_internal_mutable_devicetoken() {
-
- return devicetoken_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* NewPrimaryRequest::release_devicetoken() {
- // @@protoc_insertion_point(field_release:tunnelbroker.NewPrimaryRequest.deviceToken)
- return devicetoken_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void NewPrimaryRequest::set_allocated_devicetoken(std::string* devicetoken) {
- if (devicetoken != nullptr) {
-
- } else {
-
- }
- devicetoken_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), devicetoken,
- GetArena());
- // @@protoc_insertion_point(field_set_allocated:tunnelbroker.NewPrimaryRequest.deviceToken)
-}
-
-// -------------------------------------------------------------------
-
-// NewPrimaryResponse
-
-// bool success = 1;
-inline void NewPrimaryResponse::clear_success() {
- success_ = false;
-}
-inline bool NewPrimaryResponse::_internal_success() const {
- return success_;
-}
-inline bool NewPrimaryResponse::success() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.NewPrimaryResponse.success)
- return _internal_success();
-}
-inline void NewPrimaryResponse::_internal_set_success(bool value) {
-
- success_ = value;
-}
-inline void NewPrimaryResponse::set_success(bool value) {
- _internal_set_success(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.NewPrimaryResponse.success)
-}
-
-// -------------------------------------------------------------------
-
-// PongRequest
-
-// string userId = 1;
-inline void PongRequest::clear_userid() {
- userid_.ClearToEmpty();
-}
-inline const std::string& PongRequest::userid() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.PongRequest.userId)
- return _internal_userid();
-}
-inline void PongRequest::set_userid(const std::string& value) {
- _internal_set_userid(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.PongRequest.userId)
-}
-inline std::string* PongRequest::mutable_userid() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.PongRequest.userId)
- return _internal_mutable_userid();
-}
-inline const std::string& PongRequest::_internal_userid() const {
- return userid_.Get();
-}
-inline void PongRequest::_internal_set_userid(const std::string& value) {
-
- userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void PongRequest::set_userid(std::string&& value) {
-
- userid_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.PongRequest.userId)
-}
-inline void PongRequest::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:tunnelbroker.PongRequest.userId)
-}
-inline void PongRequest::set_userid(const char* value,
- size_t size) {
-
- userid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.PongRequest.userId)
-}
-inline std::string* PongRequest::_internal_mutable_userid() {
-
- return userid_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* PongRequest::release_userid() {
- // @@protoc_insertion_point(field_release:tunnelbroker.PongRequest.userId)
- return userid_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void PongRequest::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:tunnelbroker.PongRequest.userId)
-}
-
-// string deviceToken = 2;
-inline void PongRequest::clear_devicetoken() {
- devicetoken_.ClearToEmpty();
-}
-inline const std::string& PongRequest::devicetoken() const {
- // @@protoc_insertion_point(field_get:tunnelbroker.PongRequest.deviceToken)
- return _internal_devicetoken();
-}
-inline void PongRequest::set_devicetoken(const std::string& value) {
- _internal_set_devicetoken(value);
- // @@protoc_insertion_point(field_set:tunnelbroker.PongRequest.deviceToken)
-}
-inline std::string* PongRequest::mutable_devicetoken() {
- // @@protoc_insertion_point(field_mutable:tunnelbroker.PongRequest.deviceToken)
- return _internal_mutable_devicetoken();
-}
-inline const std::string& PongRequest::_internal_devicetoken() const {
- return devicetoken_.Get();
-}
-inline void PongRequest::_internal_set_devicetoken(const std::string& value) {
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena());
-}
-inline void PongRequest::set_devicetoken(std::string&& value) {
-
- devicetoken_.Set(
- ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena());
- // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.PongRequest.deviceToken)
-}
-inline void PongRequest::set_devicetoken(const char* value) {
- GOOGLE_DCHECK(value != nullptr);
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena());
- // @@protoc_insertion_point(field_set_char:tunnelbroker.PongRequest.deviceToken)
-}
-inline void PongRequest::set_devicetoken(const char* value,
- size_t size) {
-
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(
- reinterpret_cast<const char*>(value), size), GetArena());
- // @@protoc_insertion_point(field_set_pointer:tunnelbroker.PongRequest.deviceToken)
-}
-inline std::string* PongRequest::_internal_mutable_devicetoken() {
-
- return devicetoken_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena());
-}
-inline std::string* PongRequest::release_devicetoken() {
- // @@protoc_insertion_point(field_release:tunnelbroker.PongRequest.deviceToken)
- return devicetoken_.Release(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-inline void PongRequest::set_allocated_devicetoken(std::string* devicetoken) {
- if (devicetoken != nullptr) {
-
- } else {
-
- }
- devicetoken_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), devicetoken,
- GetArena());
- // @@protoc_insertion_point(field_set_allocated:tunnelbroker.PongRequest.deviceToken)
-}
-
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif // __GNUC__
@@ -6851,16 +5618,6 @@
// -------------------------------------------------------------------
-// -------------------------------------------------------------------
-
-// -------------------------------------------------------------------
-
-// -------------------------------------------------------------------
-
-// -------------------------------------------------------------------
-
-// -------------------------------------------------------------------
-
// @@protoc_insertion_point(namespace_scope)
@@ -6873,11 +5630,6 @@
inline const EnumDescriptor* GetEnumDescriptor< ::tunnelbroker::NewSessionRequest_DeviceTypes>() {
return ::tunnelbroker::NewSessionRequest_DeviceTypes_descriptor();
}
-template <> struct is_proto_enum< ::tunnelbroker::CheckResponseType> : ::std::true_type {};
-template <>
-inline const EnumDescriptor* GetEnumDescriptor< ::tunnelbroker::CheckResponseType>() {
- return ::tunnelbroker::CheckResponseType_descriptor();
-}
PROTOBUF_NAMESPACE_CLOSE
diff --git a/shared/protos/_generated/tunnelbroker.pb.cc b/shared/protos/_generated/tunnelbroker.pb.cc
--- a/shared/protos/_generated/tunnelbroker.pb.cc
+++ b/shared/protos/_generated/tunnelbroker.pb.cc
@@ -216,73 +216,9 @@
};
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT MessageToClientDefaultTypeInternal _MessageToClient_default_instance_;
-constexpr CheckRequest::CheckRequest(
- ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
- : userid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string)
- , devicetoken_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){}
-struct CheckRequestDefaultTypeInternal {
- constexpr CheckRequestDefaultTypeInternal()
- : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
- ~CheckRequestDefaultTypeInternal() {}
- union {
- CheckRequest _instance;
- };
-};
-PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT CheckRequestDefaultTypeInternal _CheckRequest_default_instance_;
-constexpr CheckResponse::CheckResponse(
- ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
- : checkresponsetype_(0)
-{}
-struct CheckResponseDefaultTypeInternal {
- constexpr CheckResponseDefaultTypeInternal()
- : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
- ~CheckResponseDefaultTypeInternal() {}
- union {
- CheckResponse _instance;
- };
-};
-PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT CheckResponseDefaultTypeInternal _CheckResponse_default_instance_;
-constexpr NewPrimaryRequest::NewPrimaryRequest(
- ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
- : userid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string)
- , devicetoken_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){}
-struct NewPrimaryRequestDefaultTypeInternal {
- constexpr NewPrimaryRequestDefaultTypeInternal()
- : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
- ~NewPrimaryRequestDefaultTypeInternal() {}
- union {
- NewPrimaryRequest _instance;
- };
-};
-PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT NewPrimaryRequestDefaultTypeInternal _NewPrimaryRequest_default_instance_;
-constexpr NewPrimaryResponse::NewPrimaryResponse(
- ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
- : success_(false){}
-struct NewPrimaryResponseDefaultTypeInternal {
- constexpr NewPrimaryResponseDefaultTypeInternal()
- : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
- ~NewPrimaryResponseDefaultTypeInternal() {}
- union {
- NewPrimaryResponse _instance;
- };
-};
-PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT NewPrimaryResponseDefaultTypeInternal _NewPrimaryResponse_default_instance_;
-constexpr PongRequest::PongRequest(
- ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
- : userid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string)
- , devicetoken_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){}
-struct PongRequestDefaultTypeInternal {
- constexpr PongRequestDefaultTypeInternal()
- : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
- ~PongRequestDefaultTypeInternal() {}
- union {
- PongRequest _instance;
- };
-};
-PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PongRequestDefaultTypeInternal _PongRequest_default_instance_;
} // namespace tunnelbroker
-static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_tunnelbroker_2eproto[20];
-static const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* file_level_enum_descriptors_tunnelbroker_2eproto[2];
+static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_tunnelbroker_2eproto[15];
+static const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* file_level_enum_descriptors_tunnelbroker_2eproto[1];
static constexpr ::PROTOBUF_NAMESPACE_ID::ServiceDescriptor const** file_level_service_descriptors_tunnelbroker_2eproto = nullptr;
const ::PROTOBUF_NAMESPACE_ID::uint32 TableStruct_tunnelbroker_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
@@ -413,39 +349,6 @@
::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag,
::PROTOBUF_NAMESPACE_ID::internal::kInvalidFieldOffsetTag,
PROTOBUF_FIELD_OFFSET(::tunnelbroker::MessageToClient, data_),
- ~0u, // no _has_bits_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::CheckRequest, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::CheckRequest, userid_),
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::CheckRequest, devicetoken_),
- ~0u, // no _has_bits_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::CheckResponse, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::CheckResponse, checkresponsetype_),
- ~0u, // no _has_bits_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::NewPrimaryRequest, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::NewPrimaryRequest, userid_),
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::NewPrimaryRequest, devicetoken_),
- ~0u, // no _has_bits_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::NewPrimaryResponse, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::NewPrimaryResponse, success_),
- ~0u, // no _has_bits_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::PongRequest, _internal_metadata_),
- ~0u, // no _extensions_
- ~0u, // no _oneof_case_
- ~0u, // no _weak_field_map_
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::PongRequest, userid_),
- PROTOBUF_FIELD_OFFSET(::tunnelbroker::PongRequest, devicetoken_),
};
static const ::PROTOBUF_NAMESPACE_ID::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
{ 0, -1, sizeof(::tunnelbroker::SessionSignatureRequest)},
@@ -463,11 +366,6 @@
{ 102, -1, sizeof(::tunnelbroker::MessageToClientStruct)},
{ 111, -1, sizeof(::tunnelbroker::MessagesToDeliver)},
{ 117, -1, sizeof(::tunnelbroker::MessageToClient)},
- { 127, -1, sizeof(::tunnelbroker::CheckRequest)},
- { 134, -1, sizeof(::tunnelbroker::CheckResponse)},
- { 140, -1, sizeof(::tunnelbroker::NewPrimaryRequest)},
- { 147, -1, sizeof(::tunnelbroker::NewPrimaryResponse)},
- { 153, -1, sizeof(::tunnelbroker::PongRequest)},
};
static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = {
@@ -486,11 +384,6 @@
reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tunnelbroker::_MessageToClientStruct_default_instance_),
reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tunnelbroker::_MessagesToDeliver_default_instance_),
reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tunnelbroker::_MessageToClient_default_instance_),
- reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tunnelbroker::_CheckRequest_default_instance_),
- reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tunnelbroker::_CheckResponse_default_instance_),
- reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tunnelbroker::_NewPrimaryRequest_default_instance_),
- reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tunnelbroker::_NewPrimaryResponse_default_instance_),
- reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tunnelbroker::_PongRequest_default_instance_),
};
const char descriptor_table_protodef_tunnelbroker_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) =
@@ -537,24 +430,8 @@
"\0132\037.tunnelbroker.ProcessedMessagesH\000\0228\n\026"
"newNotifyTokenRequired\030\003 \001(\0132\026.google.pr"
"otobuf.EmptyH\000\022&\n\004ping\030\004 \001(\0132\026.google.pr"
- "otobuf.EmptyH\000B\006\n\004data\"3\n\014CheckRequest\022\016"
- "\n\006userId\030\001 \001(\t\022\023\n\013deviceToken\030\002 \001(\t\"K\n\rC"
- "heckResponse\022:\n\021checkResponseType\030\001 \001(\0162"
- "\037.tunnelbroker.CheckResponseType\"8\n\021NewP"
- "rimaryRequest\022\016\n\006userId\030\001 \001(\t\022\023\n\013deviceT"
- "oken\030\002 \001(\t\"%\n\022NewPrimaryResponse\022\017\n\007succ"
- "ess\030\001 \001(\010\"2\n\013PongRequest\022\016\n\006userId\030\001 \001(\t"
- "\022\023\n\013deviceToken\030\002 \001(\t*n\n\021CheckResponseTy"
- "pe\022\030\n\024PRIMARY_DOESNT_EXIST\020\000\022\022\n\016PRIMARY_"
- "ONLINE\020\001\022\023\n\017PRIMARY_OFFLINE\020\002\022\026\n\022CURRENT"
- "_IS_PRIMARY\020\0032\237\005\n\023TunnelbrokerService\022W\n"
- "\032CheckIfPrimaryDeviceOnline\022\032.tunnelbrok"
- "er.CheckRequest\032\033.tunnelbroker.CheckResp"
- "onse\"\000\022]\n\026BecomeNewPrimaryDevice\022\037.tunne"
- "lbroker.NewPrimaryRequest\032 .tunnelbroker"
- ".NewPrimaryResponse\"\000\022\?\n\010SendPong\022\031.tunn"
- "elbroker.PongRequest\032\026.google.protobuf.E"
- "mpty\"\000\022c\n\020SessionSignature\022%.tunnelbroke"
+ "otobuf.EmptyH\000B\006\n\004data2\246\003\n\023TunnelbrokerS"
+ "ervice\022c\n\020SessionSignature\022%.tunnelbroke"
"r.SessionSignatureRequest\032&.tunnelbroker"
".SessionSignatureResponse\"\000\022Q\n\nNewSessio"
"n\022\037.tunnelbroker.NewSessionRequest\032 .tun"
@@ -571,8 +448,8 @@
};
static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_tunnelbroker_2eproto_once;
const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_tunnelbroker_2eproto = {
- false, false, 2815, descriptor_table_protodef_tunnelbroker_2eproto, "tunnelbroker.proto",
- &descriptor_table_tunnelbroker_2eproto_once, descriptor_table_tunnelbroker_2eproto_deps, 1, 20,
+ false, false, 2175, descriptor_table_protodef_tunnelbroker_2eproto, "tunnelbroker.proto",
+ &descriptor_table_tunnelbroker_2eproto_once, descriptor_table_tunnelbroker_2eproto_deps, 1, 15,
schemas, file_default_instances, TableStruct_tunnelbroker_2eproto::offsets,
file_level_metadata_tunnelbroker_2eproto, file_level_enum_descriptors_tunnelbroker_2eproto, file_level_service_descriptors_tunnelbroker_2eproto,
};
@@ -608,22 +485,6 @@
constexpr NewSessionRequest_DeviceTypes NewSessionRequest::DeviceTypes_MAX;
constexpr int NewSessionRequest::DeviceTypes_ARRAYSIZE;
#endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || _MSC_VER >= 1900)
-const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* CheckResponseType_descriptor() {
- ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_tunnelbroker_2eproto);
- return file_level_enum_descriptors_tunnelbroker_2eproto[1];
-}
-bool CheckResponseType_IsValid(int value) {
- switch (value) {
- case 0:
- case 1:
- case 2:
- case 3:
- return true;
- default:
- return false;
- }
-}
-
// ===================================================================
@@ -4860,1160 +4721,54 @@
}
-// ===================================================================
-
-class CheckRequest::_Internal {
- public:
-};
-
-CheckRequest::CheckRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena)
- : ::PROTOBUF_NAMESPACE_ID::Message(arena) {
- SharedCtor();
- RegisterArenaDtor(arena);
- // @@protoc_insertion_point(arena_constructor:tunnelbroker.CheckRequest)
-}
-CheckRequest::CheckRequest(const CheckRequest& 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());
- }
- devicetoken_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
- if (!from._internal_devicetoken().empty()) {
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_devicetoken(),
- GetArena());
- }
- // @@protoc_insertion_point(copy_constructor:tunnelbroker.CheckRequest)
-}
-
-void CheckRequest::SharedCtor() {
-userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-devicetoken_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-}
-
-CheckRequest::~CheckRequest() {
- // @@protoc_insertion_point(destructor:tunnelbroker.CheckRequest)
- SharedDtor();
- _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-void CheckRequest::SharedDtor() {
- GOOGLE_DCHECK(GetArena() == nullptr);
- userid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
- devicetoken_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-}
-
-void CheckRequest::ArenaDtor(void* object) {
- CheckRequest* _this = reinterpret_cast< CheckRequest* >(object);
- (void)_this;
-}
-void CheckRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
-}
-void CheckRequest::SetCachedSize(int size) const {
- _cached_size_.Set(size);
-}
-
-void CheckRequest::Clear() {
-// @@protoc_insertion_point(message_clear_start:tunnelbroker.CheckRequest)
- ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
-
- userid_.ClearToEmpty();
- devicetoken_.ClearToEmpty();
- _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-const char* CheckRequest::_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, "tunnelbroker.CheckRequest.userId"));
- CHK_(ptr);
- } else goto handle_unusual;
- continue;
- // string deviceToken = 2;
- case 2:
- if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
- auto str = _internal_mutable_devicetoken();
- ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
- CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "tunnelbroker.CheckRequest.deviceToken"));
- 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_
+// @@protoc_insertion_point(namespace_scope)
+} // namespace tunnelbroker
+PROTOBUF_NAMESPACE_OPEN
+template<> PROTOBUF_NOINLINE ::tunnelbroker::SessionSignatureRequest* Arena::CreateMaybeMessage< ::tunnelbroker::SessionSignatureRequest >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::SessionSignatureRequest >(arena);
}
-
-::PROTOBUF_NAMESPACE_ID::uint8* CheckRequest::_InternalSerialize(
- ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
- // @@protoc_insertion_point(serialize_to_array_start:tunnelbroker.CheckRequest)
- ::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<int>(this->_internal_userid().length()),
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
- "tunnelbroker.CheckRequest.userId");
- target = stream->WriteStringMaybeAliased(
- 1, this->_internal_userid(), target);
- }
-
- // string deviceToken = 2;
- if (this->devicetoken().size() > 0) {
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
- this->_internal_devicetoken().data(), static_cast<int>(this->_internal_devicetoken().length()),
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
- "tunnelbroker.CheckRequest.deviceToken");
- target = stream->WriteStringMaybeAliased(
- 2, this->_internal_devicetoken(), 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:tunnelbroker.CheckRequest)
- return target;
+template<> PROTOBUF_NOINLINE ::tunnelbroker::SessionSignatureResponse* Arena::CreateMaybeMessage< ::tunnelbroker::SessionSignatureResponse >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::SessionSignatureResponse >(arena);
}
-
-size_t CheckRequest::ByteSizeLong() const {
-// @@protoc_insertion_point(message_byte_size_start:tunnelbroker.CheckRequest)
- 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 deviceToken = 2;
- if (this->devicetoken().size() > 0) {
- total_size += 1 +
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
- this->_internal_devicetoken());
- }
-
- 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;
+template<> PROTOBUF_NOINLINE ::tunnelbroker::NewSessionRequest* Arena::CreateMaybeMessage< ::tunnelbroker::NewSessionRequest >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::NewSessionRequest >(arena);
}
-
-void CheckRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_merge_from_start:tunnelbroker.CheckRequest)
- GOOGLE_DCHECK_NE(&from, this);
- const CheckRequest* source =
- ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<CheckRequest>(
- &from);
- if (source == nullptr) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:tunnelbroker.CheckRequest)
- ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:tunnelbroker.CheckRequest)
- MergeFrom(*source);
- }
+template<> PROTOBUF_NOINLINE ::tunnelbroker::NewSessionResponse* Arena::CreateMaybeMessage< ::tunnelbroker::NewSessionResponse >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::NewSessionResponse >(arena);
}
-
-void CheckRequest::MergeFrom(const CheckRequest& from) {
-// @@protoc_insertion_point(class_specific_merge_from_start:tunnelbroker.CheckRequest)
- 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.devicetoken().size() > 0) {
- _internal_set_devicetoken(from._internal_devicetoken());
- }
+template<> PROTOBUF_NOINLINE ::tunnelbroker::SendRequest* Arena::CreateMaybeMessage< ::tunnelbroker::SendRequest >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::SendRequest >(arena);
}
-
-void CheckRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_copy_from_start:tunnelbroker.CheckRequest)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
+template<> PROTOBUF_NOINLINE ::tunnelbroker::GetRequest* Arena::CreateMaybeMessage< ::tunnelbroker::GetRequest >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::GetRequest >(arena);
}
-
-void CheckRequest::CopyFrom(const CheckRequest& from) {
-// @@protoc_insertion_point(class_specific_copy_from_start:tunnelbroker.CheckRequest)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
+template<> PROTOBUF_NOINLINE ::tunnelbroker::GetResponseMessage* Arena::CreateMaybeMessage< ::tunnelbroker::GetResponseMessage >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::GetResponseMessage >(arena);
}
-
-bool CheckRequest::IsInitialized() const {
- return true;
+template<> PROTOBUF_NOINLINE ::tunnelbroker::GetResponse* Arena::CreateMaybeMessage< ::tunnelbroker::GetResponse >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::GetResponse >(arena);
}
-
-void CheckRequest::InternalSwap(CheckRequest* other) {
- using std::swap;
- _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_);
- userid_.Swap(&other->userid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
- devicetoken_.Swap(&other->devicetoken_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
+template<> PROTOBUF_NOINLINE ::tunnelbroker::ProcessedMessages* Arena::CreateMaybeMessage< ::tunnelbroker::ProcessedMessages >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::ProcessedMessages >(arena);
}
-
-::PROTOBUF_NAMESPACE_ID::Metadata CheckRequest::GetMetadata() const {
- return GetMetadataStatic();
+template<> PROTOBUF_NOINLINE ::tunnelbroker::MessageToTunnelbrokerStruct* Arena::CreateMaybeMessage< ::tunnelbroker::MessageToTunnelbrokerStruct >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::MessageToTunnelbrokerStruct >(arena);
}
-
-
-// ===================================================================
-
-class CheckResponse::_Internal {
- public:
-};
-
-CheckResponse::CheckResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena)
- : ::PROTOBUF_NAMESPACE_ID::Message(arena) {
- SharedCtor();
- RegisterArenaDtor(arena);
- // @@protoc_insertion_point(arena_constructor:tunnelbroker.CheckResponse)
+template<> PROTOBUF_NOINLINE ::tunnelbroker::MessagesToSend* Arena::CreateMaybeMessage< ::tunnelbroker::MessagesToSend >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::MessagesToSend >(arena);
}
-CheckResponse::CheckResponse(const CheckResponse& from)
- : ::PROTOBUF_NAMESPACE_ID::Message() {
- _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
- checkresponsetype_ = from.checkresponsetype_;
- // @@protoc_insertion_point(copy_constructor:tunnelbroker.CheckResponse)
+template<> PROTOBUF_NOINLINE ::tunnelbroker::MessageToTunnelbroker* Arena::CreateMaybeMessage< ::tunnelbroker::MessageToTunnelbroker >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::MessageToTunnelbroker >(arena);
}
-
-void CheckResponse::SharedCtor() {
-checkresponsetype_ = 0;
+template<> PROTOBUF_NOINLINE ::tunnelbroker::MessageToClientStruct* Arena::CreateMaybeMessage< ::tunnelbroker::MessageToClientStruct >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::MessageToClientStruct >(arena);
}
-
-CheckResponse::~CheckResponse() {
- // @@protoc_insertion_point(destructor:tunnelbroker.CheckResponse)
- SharedDtor();
- _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-void CheckResponse::SharedDtor() {
- GOOGLE_DCHECK(GetArena() == nullptr);
-}
-
-void CheckResponse::ArenaDtor(void* object) {
- CheckResponse* _this = reinterpret_cast< CheckResponse* >(object);
- (void)_this;
-}
-void CheckResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
-}
-void CheckResponse::SetCachedSize(int size) const {
- _cached_size_.Set(size);
-}
-
-void CheckResponse::Clear() {
-// @@protoc_insertion_point(message_clear_start:tunnelbroker.CheckResponse)
- ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
-
- checkresponsetype_ = 0;
- _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-const char* CheckResponse::_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) {
- // .tunnelbroker.CheckResponseType checkResponseType = 1;
- case 1:
- if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 8)) {
- ::PROTOBUF_NAMESPACE_ID::uint64 val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
- CHK_(ptr);
- _internal_set_checkresponsetype(static_cast<::tunnelbroker::CheckResponseType>(val));
- } 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* CheckResponse::_InternalSerialize(
- ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
- // @@protoc_insertion_point(serialize_to_array_start:tunnelbroker.CheckResponse)
- ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
-
- // .tunnelbroker.CheckResponseType checkResponseType = 1;
- if (this->checkresponsetype() != 0) {
- target = stream->EnsureSpace(target);
- target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteEnumToArray(
- 1, this->_internal_checkresponsetype(), 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:tunnelbroker.CheckResponse)
- return target;
-}
-
-size_t CheckResponse::ByteSizeLong() const {
-// @@protoc_insertion_point(message_byte_size_start:tunnelbroker.CheckResponse)
- 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;
-
- // .tunnelbroker.CheckResponseType checkResponseType = 1;
- if (this->checkresponsetype() != 0) {
- total_size += 1 +
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::EnumSize(this->_internal_checkresponsetype());
- }
-
- 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 CheckResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_merge_from_start:tunnelbroker.CheckResponse)
- GOOGLE_DCHECK_NE(&from, this);
- const CheckResponse* source =
- ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<CheckResponse>(
- &from);
- if (source == nullptr) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:tunnelbroker.CheckResponse)
- ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:tunnelbroker.CheckResponse)
- MergeFrom(*source);
- }
-}
-
-void CheckResponse::MergeFrom(const CheckResponse& from) {
-// @@protoc_insertion_point(class_specific_merge_from_start:tunnelbroker.CheckResponse)
- 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.checkresponsetype() != 0) {
- _internal_set_checkresponsetype(from._internal_checkresponsetype());
- }
-}
-
-void CheckResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_copy_from_start:tunnelbroker.CheckResponse)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
-}
-
-void CheckResponse::CopyFrom(const CheckResponse& from) {
-// @@protoc_insertion_point(class_specific_copy_from_start:tunnelbroker.CheckResponse)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
-}
-
-bool CheckResponse::IsInitialized() const {
- return true;
-}
-
-void CheckResponse::InternalSwap(CheckResponse* other) {
- using std::swap;
- _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_);
- swap(checkresponsetype_, other->checkresponsetype_);
-}
-
-::PROTOBUF_NAMESPACE_ID::Metadata CheckResponse::GetMetadata() const {
- return GetMetadataStatic();
-}
-
-
-// ===================================================================
-
-class NewPrimaryRequest::_Internal {
- public:
-};
-
-NewPrimaryRequest::NewPrimaryRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena)
- : ::PROTOBUF_NAMESPACE_ID::Message(arena) {
- SharedCtor();
- RegisterArenaDtor(arena);
- // @@protoc_insertion_point(arena_constructor:tunnelbroker.NewPrimaryRequest)
-}
-NewPrimaryRequest::NewPrimaryRequest(const NewPrimaryRequest& 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());
- }
- devicetoken_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
- if (!from._internal_devicetoken().empty()) {
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_devicetoken(),
- GetArena());
- }
- // @@protoc_insertion_point(copy_constructor:tunnelbroker.NewPrimaryRequest)
-}
-
-void NewPrimaryRequest::SharedCtor() {
-userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-devicetoken_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-}
-
-NewPrimaryRequest::~NewPrimaryRequest() {
- // @@protoc_insertion_point(destructor:tunnelbroker.NewPrimaryRequest)
- SharedDtor();
- _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-void NewPrimaryRequest::SharedDtor() {
- GOOGLE_DCHECK(GetArena() == nullptr);
- userid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
- devicetoken_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-}
-
-void NewPrimaryRequest::ArenaDtor(void* object) {
- NewPrimaryRequest* _this = reinterpret_cast< NewPrimaryRequest* >(object);
- (void)_this;
-}
-void NewPrimaryRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
-}
-void NewPrimaryRequest::SetCachedSize(int size) const {
- _cached_size_.Set(size);
-}
-
-void NewPrimaryRequest::Clear() {
-// @@protoc_insertion_point(message_clear_start:tunnelbroker.NewPrimaryRequest)
- ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
-
- userid_.ClearToEmpty();
- devicetoken_.ClearToEmpty();
- _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-const char* NewPrimaryRequest::_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, "tunnelbroker.NewPrimaryRequest.userId"));
- CHK_(ptr);
- } else goto handle_unusual;
- continue;
- // string deviceToken = 2;
- case 2:
- if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
- auto str = _internal_mutable_devicetoken();
- ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
- CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "tunnelbroker.NewPrimaryRequest.deviceToken"));
- 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* NewPrimaryRequest::_InternalSerialize(
- ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
- // @@protoc_insertion_point(serialize_to_array_start:tunnelbroker.NewPrimaryRequest)
- ::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<int>(this->_internal_userid().length()),
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
- "tunnelbroker.NewPrimaryRequest.userId");
- target = stream->WriteStringMaybeAliased(
- 1, this->_internal_userid(), target);
- }
-
- // string deviceToken = 2;
- if (this->devicetoken().size() > 0) {
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
- this->_internal_devicetoken().data(), static_cast<int>(this->_internal_devicetoken().length()),
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
- "tunnelbroker.NewPrimaryRequest.deviceToken");
- target = stream->WriteStringMaybeAliased(
- 2, this->_internal_devicetoken(), 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:tunnelbroker.NewPrimaryRequest)
- return target;
-}
-
-size_t NewPrimaryRequest::ByteSizeLong() const {
-// @@protoc_insertion_point(message_byte_size_start:tunnelbroker.NewPrimaryRequest)
- 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 deviceToken = 2;
- if (this->devicetoken().size() > 0) {
- total_size += 1 +
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
- this->_internal_devicetoken());
- }
-
- 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 NewPrimaryRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_merge_from_start:tunnelbroker.NewPrimaryRequest)
- GOOGLE_DCHECK_NE(&from, this);
- const NewPrimaryRequest* source =
- ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<NewPrimaryRequest>(
- &from);
- if (source == nullptr) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:tunnelbroker.NewPrimaryRequest)
- ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:tunnelbroker.NewPrimaryRequest)
- MergeFrom(*source);
- }
-}
-
-void NewPrimaryRequest::MergeFrom(const NewPrimaryRequest& from) {
-// @@protoc_insertion_point(class_specific_merge_from_start:tunnelbroker.NewPrimaryRequest)
- 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.devicetoken().size() > 0) {
- _internal_set_devicetoken(from._internal_devicetoken());
- }
-}
-
-void NewPrimaryRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_copy_from_start:tunnelbroker.NewPrimaryRequest)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
-}
-
-void NewPrimaryRequest::CopyFrom(const NewPrimaryRequest& from) {
-// @@protoc_insertion_point(class_specific_copy_from_start:tunnelbroker.NewPrimaryRequest)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
-}
-
-bool NewPrimaryRequest::IsInitialized() const {
- return true;
-}
-
-void NewPrimaryRequest::InternalSwap(NewPrimaryRequest* other) {
- using std::swap;
- _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_);
- userid_.Swap(&other->userid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
- devicetoken_.Swap(&other->devicetoken_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-
-::PROTOBUF_NAMESPACE_ID::Metadata NewPrimaryRequest::GetMetadata() const {
- return GetMetadataStatic();
-}
-
-
-// ===================================================================
-
-class NewPrimaryResponse::_Internal {
- public:
-};
-
-NewPrimaryResponse::NewPrimaryResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena)
- : ::PROTOBUF_NAMESPACE_ID::Message(arena) {
- SharedCtor();
- RegisterArenaDtor(arena);
- // @@protoc_insertion_point(arena_constructor:tunnelbroker.NewPrimaryResponse)
-}
-NewPrimaryResponse::NewPrimaryResponse(const NewPrimaryResponse& from)
- : ::PROTOBUF_NAMESPACE_ID::Message() {
- _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
- success_ = from.success_;
- // @@protoc_insertion_point(copy_constructor:tunnelbroker.NewPrimaryResponse)
-}
-
-void NewPrimaryResponse::SharedCtor() {
-success_ = false;
-}
-
-NewPrimaryResponse::~NewPrimaryResponse() {
- // @@protoc_insertion_point(destructor:tunnelbroker.NewPrimaryResponse)
- SharedDtor();
- _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-void NewPrimaryResponse::SharedDtor() {
- GOOGLE_DCHECK(GetArena() == nullptr);
-}
-
-void NewPrimaryResponse::ArenaDtor(void* object) {
- NewPrimaryResponse* _this = reinterpret_cast< NewPrimaryResponse* >(object);
- (void)_this;
-}
-void NewPrimaryResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
-}
-void NewPrimaryResponse::SetCachedSize(int size) const {
- _cached_size_.Set(size);
-}
-
-void NewPrimaryResponse::Clear() {
-// @@protoc_insertion_point(message_clear_start:tunnelbroker.NewPrimaryResponse)
- ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
-
- success_ = false;
- _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-const char* NewPrimaryResponse::_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) {
- // bool success = 1;
- case 1:
- if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 8)) {
- success_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
- 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* NewPrimaryResponse::_InternalSerialize(
- ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
- // @@protoc_insertion_point(serialize_to_array_start:tunnelbroker.NewPrimaryResponse)
- ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
- (void) cached_has_bits;
-
- // bool success = 1;
- if (this->success() != 0) {
- target = stream->EnsureSpace(target);
- target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBoolToArray(1, this->_internal_success(), 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:tunnelbroker.NewPrimaryResponse)
- return target;
-}
-
-size_t NewPrimaryResponse::ByteSizeLong() const {
-// @@protoc_insertion_point(message_byte_size_start:tunnelbroker.NewPrimaryResponse)
- 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;
-
- // bool success = 1;
- if (this->success() != 0) {
- total_size += 1 + 1;
- }
-
- 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 NewPrimaryResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_merge_from_start:tunnelbroker.NewPrimaryResponse)
- GOOGLE_DCHECK_NE(&from, this);
- const NewPrimaryResponse* source =
- ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<NewPrimaryResponse>(
- &from);
- if (source == nullptr) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:tunnelbroker.NewPrimaryResponse)
- ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:tunnelbroker.NewPrimaryResponse)
- MergeFrom(*source);
- }
-}
-
-void NewPrimaryResponse::MergeFrom(const NewPrimaryResponse& from) {
-// @@protoc_insertion_point(class_specific_merge_from_start:tunnelbroker.NewPrimaryResponse)
- 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.success() != 0) {
- _internal_set_success(from._internal_success());
- }
-}
-
-void NewPrimaryResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_copy_from_start:tunnelbroker.NewPrimaryResponse)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
-}
-
-void NewPrimaryResponse::CopyFrom(const NewPrimaryResponse& from) {
-// @@protoc_insertion_point(class_specific_copy_from_start:tunnelbroker.NewPrimaryResponse)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
-}
-
-bool NewPrimaryResponse::IsInitialized() const {
- return true;
-}
-
-void NewPrimaryResponse::InternalSwap(NewPrimaryResponse* other) {
- using std::swap;
- _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_);
- swap(success_, other->success_);
-}
-
-::PROTOBUF_NAMESPACE_ID::Metadata NewPrimaryResponse::GetMetadata() const {
- return GetMetadataStatic();
-}
-
-
-// ===================================================================
-
-class PongRequest::_Internal {
- public:
-};
-
-PongRequest::PongRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena)
- : ::PROTOBUF_NAMESPACE_ID::Message(arena) {
- SharedCtor();
- RegisterArenaDtor(arena);
- // @@protoc_insertion_point(arena_constructor:tunnelbroker.PongRequest)
-}
-PongRequest::PongRequest(const PongRequest& 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());
- }
- devicetoken_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
- if (!from._internal_devicetoken().empty()) {
- devicetoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_devicetoken(),
- GetArena());
- }
- // @@protoc_insertion_point(copy_constructor:tunnelbroker.PongRequest)
-}
-
-void PongRequest::SharedCtor() {
-userid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-devicetoken_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-}
-
-PongRequest::~PongRequest() {
- // @@protoc_insertion_point(destructor:tunnelbroker.PongRequest)
- SharedDtor();
- _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-void PongRequest::SharedDtor() {
- GOOGLE_DCHECK(GetArena() == nullptr);
- userid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
- devicetoken_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
-}
-
-void PongRequest::ArenaDtor(void* object) {
- PongRequest* _this = reinterpret_cast< PongRequest* >(object);
- (void)_this;
-}
-void PongRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
-}
-void PongRequest::SetCachedSize(int size) const {
- _cached_size_.Set(size);
-}
-
-void PongRequest::Clear() {
-// @@protoc_insertion_point(message_clear_start:tunnelbroker.PongRequest)
- ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
- // Prevent compiler warnings about cached_has_bits being unused
- (void) cached_has_bits;
-
- userid_.ClearToEmpty();
- devicetoken_.ClearToEmpty();
- _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
-}
-
-const char* PongRequest::_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, "tunnelbroker.PongRequest.userId"));
- CHK_(ptr);
- } else goto handle_unusual;
- continue;
- // string deviceToken = 2;
- case 2:
- if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
- auto str = _internal_mutable_devicetoken();
- ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
- CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "tunnelbroker.PongRequest.deviceToken"));
- 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* PongRequest::_InternalSerialize(
- ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
- // @@protoc_insertion_point(serialize_to_array_start:tunnelbroker.PongRequest)
- ::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<int>(this->_internal_userid().length()),
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
- "tunnelbroker.PongRequest.userId");
- target = stream->WriteStringMaybeAliased(
- 1, this->_internal_userid(), target);
- }
-
- // string deviceToken = 2;
- if (this->devicetoken().size() > 0) {
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
- this->_internal_devicetoken().data(), static_cast<int>(this->_internal_devicetoken().length()),
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
- "tunnelbroker.PongRequest.deviceToken");
- target = stream->WriteStringMaybeAliased(
- 2, this->_internal_devicetoken(), 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:tunnelbroker.PongRequest)
- return target;
-}
-
-size_t PongRequest::ByteSizeLong() const {
-// @@protoc_insertion_point(message_byte_size_start:tunnelbroker.PongRequest)
- 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 deviceToken = 2;
- if (this->devicetoken().size() > 0) {
- total_size += 1 +
- ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
- this->_internal_devicetoken());
- }
-
- 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 PongRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_merge_from_start:tunnelbroker.PongRequest)
- GOOGLE_DCHECK_NE(&from, this);
- const PongRequest* source =
- ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<PongRequest>(
- &from);
- if (source == nullptr) {
- // @@protoc_insertion_point(generalized_merge_from_cast_fail:tunnelbroker.PongRequest)
- ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this);
- } else {
- // @@protoc_insertion_point(generalized_merge_from_cast_success:tunnelbroker.PongRequest)
- MergeFrom(*source);
- }
-}
-
-void PongRequest::MergeFrom(const PongRequest& from) {
-// @@protoc_insertion_point(class_specific_merge_from_start:tunnelbroker.PongRequest)
- 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.devicetoken().size() > 0) {
- _internal_set_devicetoken(from._internal_devicetoken());
- }
-}
-
-void PongRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
-// @@protoc_insertion_point(generalized_copy_from_start:tunnelbroker.PongRequest)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
-}
-
-void PongRequest::CopyFrom(const PongRequest& from) {
-// @@protoc_insertion_point(class_specific_copy_from_start:tunnelbroker.PongRequest)
- if (&from == this) return;
- Clear();
- MergeFrom(from);
-}
-
-bool PongRequest::IsInitialized() const {
- return true;
-}
-
-void PongRequest::InternalSwap(PongRequest* other) {
- using std::swap;
- _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_);
- userid_.Swap(&other->userid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
- devicetoken_.Swap(&other->devicetoken_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
-}
-
-::PROTOBUF_NAMESPACE_ID::Metadata PongRequest::GetMetadata() const {
- return GetMetadataStatic();
-}
-
-
-// @@protoc_insertion_point(namespace_scope)
-} // namespace tunnelbroker
-PROTOBUF_NAMESPACE_OPEN
-template<> PROTOBUF_NOINLINE ::tunnelbroker::SessionSignatureRequest* Arena::CreateMaybeMessage< ::tunnelbroker::SessionSignatureRequest >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::SessionSignatureRequest >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::SessionSignatureResponse* Arena::CreateMaybeMessage< ::tunnelbroker::SessionSignatureResponse >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::SessionSignatureResponse >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::NewSessionRequest* Arena::CreateMaybeMessage< ::tunnelbroker::NewSessionRequest >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::NewSessionRequest >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::NewSessionResponse* Arena::CreateMaybeMessage< ::tunnelbroker::NewSessionResponse >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::NewSessionResponse >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::SendRequest* Arena::CreateMaybeMessage< ::tunnelbroker::SendRequest >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::SendRequest >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::GetRequest* Arena::CreateMaybeMessage< ::tunnelbroker::GetRequest >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::GetRequest >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::GetResponseMessage* Arena::CreateMaybeMessage< ::tunnelbroker::GetResponseMessage >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::GetResponseMessage >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::GetResponse* Arena::CreateMaybeMessage< ::tunnelbroker::GetResponse >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::GetResponse >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::ProcessedMessages* Arena::CreateMaybeMessage< ::tunnelbroker::ProcessedMessages >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::ProcessedMessages >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::MessageToTunnelbrokerStruct* Arena::CreateMaybeMessage< ::tunnelbroker::MessageToTunnelbrokerStruct >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::MessageToTunnelbrokerStruct >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::MessagesToSend* Arena::CreateMaybeMessage< ::tunnelbroker::MessagesToSend >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::MessagesToSend >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::MessageToTunnelbroker* Arena::CreateMaybeMessage< ::tunnelbroker::MessageToTunnelbroker >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::MessageToTunnelbroker >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::MessageToClientStruct* Arena::CreateMaybeMessage< ::tunnelbroker::MessageToClientStruct >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::MessageToClientStruct >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::MessagesToDeliver* Arena::CreateMaybeMessage< ::tunnelbroker::MessagesToDeliver >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::MessagesToDeliver >(arena);
+template<> PROTOBUF_NOINLINE ::tunnelbroker::MessagesToDeliver* Arena::CreateMaybeMessage< ::tunnelbroker::MessagesToDeliver >(Arena* arena) {
+ return Arena::CreateMessageInternal< ::tunnelbroker::MessagesToDeliver >(arena);
}
template<> PROTOBUF_NOINLINE ::tunnelbroker::MessageToClient* Arena::CreateMaybeMessage< ::tunnelbroker::MessageToClient >(Arena* arena) {
return Arena::CreateMessageInternal< ::tunnelbroker::MessageToClient >(arena);
}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::CheckRequest* Arena::CreateMaybeMessage< ::tunnelbroker::CheckRequest >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::CheckRequest >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::CheckResponse* Arena::CreateMaybeMessage< ::tunnelbroker::CheckResponse >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::CheckResponse >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::NewPrimaryRequest* Arena::CreateMaybeMessage< ::tunnelbroker::NewPrimaryRequest >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::NewPrimaryRequest >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::NewPrimaryResponse* Arena::CreateMaybeMessage< ::tunnelbroker::NewPrimaryResponse >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::NewPrimaryResponse >(arena);
-}
-template<> PROTOBUF_NOINLINE ::tunnelbroker::PongRequest* Arena::CreateMaybeMessage< ::tunnelbroker::PongRequest >(Arena* arena) {
- return Arena::CreateMessageInternal< ::tunnelbroker::PongRequest >(arena);
-}
PROTOBUF_NAMESPACE_CLOSE
// @@protoc_insertion_point(global_scope)
diff --git a/shared/protos/tunnelbroker.proto b/shared/protos/tunnelbroker.proto
--- a/shared/protos/tunnelbroker.proto
+++ b/shared/protos/tunnelbroker.proto
@@ -5,17 +5,6 @@
import "google/protobuf/empty.proto";
service TunnelbrokerService {
-
- // The old API service methods
- // to support the native client build
- // until we switch to the new one
-
- rpc CheckIfPrimaryDeviceOnline(CheckRequest) returns (CheckResponse) {}
- rpc BecomeNewPrimaryDevice(NewPrimaryRequest) returns (NewPrimaryResponse) {}
- rpc SendPong (PongRequest) returns (google.protobuf.Empty) {}
-
- // New API service methods
-
rpc SessionSignature(SessionSignatureRequest) returns (SessionSignatureResponse) {}
rpc NewSession(NewSessionRequest) returns (NewSessionResponse) {}
rpc Send(SendRequest) returns (google.protobuf.Empty) {}
@@ -135,35 +124,3 @@
google.protobuf.Empty ping = 4;
}
}
-
-// Old API structures
-
-enum CheckResponseType {
- PRIMARY_DOESNT_EXIST = 0;
- PRIMARY_ONLINE = 1;
- PRIMARY_OFFLINE = 2;
- CURRENT_IS_PRIMARY = 3;
-}
-
-message CheckRequest {
- string userId = 1;
- string deviceToken = 2;
-}
-
-message CheckResponse {
- CheckResponseType checkResponseType = 1;
-}
-
-message NewPrimaryRequest {
- string userId = 1;
- string deviceToken = 2;
-}
-
-message NewPrimaryResponse {
- bool success = 1;
-}
-
-message PongRequest {
- string userId = 1;
- string deviceToken = 2;
-}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Dec 22, 12:38 AM (21 h, 19 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2690086
Default Alt Text
D5596.diff (216 KB)
Attached To
Mode
D5596: [services] Tunnelbroker - Removing the old API
Attached
Detach File
Event Timeline
Log In to Comment