#include "shell/shell.pb.h"

#include <algorithm>

#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/extension_set.h>
#include <google/protobuf/wire_format_lite.h>
#include <google/protobuf/descriptor.h>
#include <google/protobuf/generated_message_reflection.h>
#include <google/protobuf/reflection_ops.h>
#include <google/protobuf/wire_format.h>

#include <google/protobuf/port_def.inc>

PROTOBUF_PRAGMA_INIT_SEG
namespace mavsdk {
namespace rpc {
namespace shell {
constexpr SendRequest::SendRequest(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
  : command_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){}
struct SendRequestDefaultTypeInternal {
  constexpr SendRequestDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~SendRequestDefaultTypeInternal() {}
  union {
    SendRequest _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT SendRequestDefaultTypeInternal _SendRequest_default_instance_;
constexpr SendResponse::SendResponse(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
  : shell_result_(nullptr){}
struct SendResponseDefaultTypeInternal {
  constexpr SendResponseDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~SendResponseDefaultTypeInternal() {}
  union {
    SendResponse _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT SendResponseDefaultTypeInternal _SendResponse_default_instance_;
constexpr SubscribeReceiveRequest::SubscribeReceiveRequest(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized){}
struct SubscribeReceiveRequestDefaultTypeInternal {
  constexpr SubscribeReceiveRequestDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~SubscribeReceiveRequestDefaultTypeInternal() {}
  union {
    SubscribeReceiveRequest _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT SubscribeReceiveRequestDefaultTypeInternal _SubscribeReceiveRequest_default_instance_;
constexpr ReceiveResponse::ReceiveResponse(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
  : data_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){}
struct ReceiveResponseDefaultTypeInternal {
  constexpr ReceiveResponseDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~ReceiveResponseDefaultTypeInternal() {}
  union {
    ReceiveResponse _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT ReceiveResponseDefaultTypeInternal _ReceiveResponse_default_instance_;
constexpr ShellResult::ShellResult(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
  : result_str_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string)
  , result_(0)
{}
struct ShellResultDefaultTypeInternal {
  constexpr ShellResultDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~ShellResultDefaultTypeInternal() {}
  union {
    ShellResult _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT ShellResultDefaultTypeInternal _ShellResult_default_instance_;
}  
}  
}  
static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_shell_2fshell_2eproto[5];
static const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* file_level_enum_descriptors_shell_2fshell_2eproto[1];
static constexpr ::PROTOBUF_NAMESPACE_ID::ServiceDescriptor const** file_level_service_descriptors_shell_2fshell_2eproto = nullptr;

const ::PROTOBUF_NAMESPACE_ID::uint32 TableStruct_shell_2fshell_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SendRequest, _internal_metadata_),
  ~0u,  
  ~0u,  
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SendRequest, command_),
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SendResponse, _internal_metadata_),
  ~0u,  
  ~0u,  
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SendResponse, shell_result_),
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SubscribeReceiveRequest, _internal_metadata_),
  ~0u,  
  ~0u,  
  ~0u,  
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ReceiveResponse, _internal_metadata_),
  ~0u,  
  ~0u,  
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ReceiveResponse, data_),
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ShellResult, _internal_metadata_),
  ~0u,  
  ~0u,  
  ~0u,  
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ShellResult, result_),
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ShellResult, result_str_),
};
static const ::PROTOBUF_NAMESPACE_ID::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
  { 0, -1, sizeof(::mavsdk::rpc::shell::SendRequest)},
  { 6, -1, sizeof(::mavsdk::rpc::shell::SendResponse)},
  { 12, -1, sizeof(::mavsdk::rpc::shell::SubscribeReceiveRequest)},
  { 17, -1, sizeof(::mavsdk::rpc::shell::ReceiveResponse)},
  { 23, -1, sizeof(::mavsdk::rpc::shell::ShellResult)},
};

static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = {
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_SendRequest_default_instance_),
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_SendResponse_default_instance_),
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_SubscribeReceiveRequest_default_instance_),
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_ReceiveResponse_default_instance_),
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_ShellResult_default_instance_),
};

const char descriptor_table_protodef_shell_2fshell_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) =
  "\n\021shell/shell.proto\022\020mavsdk.rpc.shell\032\024m"
  "avsdk_options.proto\"\036\n\013SendRequest\022\017\n\007co"
  "mmand\030\001 \001(\t\"C\n\014SendResponse\0223\n\014shell_res"
  "ult\030\001 \001(\0132\035.mavsdk.rpc.shell.ShellResult"
  "\"\031\n\027SubscribeReceiveRequest\"\037\n\017ReceiveRe"
  "sponse\022\014\n\004data\030\001 \001(\t\"\346\001\n\013ShellResult\0224\n\006"
  "result\030\001 \001(\0162$.mavsdk.rpc.shell.ShellRes"
  "ult.Result\022\022\n\nresult_str\030\002 \001(\t\"\214\001\n\006Resul"
  "t\022\022\n\016RESULT_UNKNOWN\020\000\022\022\n\016RESULT_SUCCESS\020"
  "\001\022\024\n\020RESULT_NO_SYSTEM\020\002\022\033\n\027RESULT_CONNEC"
  "TION_ERROR\020\003\022\026\n\022RESULT_NO_RESPONSE\020\004\022\017\n\013"
  "RESULT_BUSY\020\0052\305\001\n\014ShellService\022K\n\004Send\022\035"
  ".mavsdk.rpc.shell.SendRequest\032\036.mavsdk.r"
  "pc.shell.SendResponse\"\004\200\265\030\001\022h\n\020Subscribe"
  "Receive\022).mavsdk.rpc.shell.SubscribeRece"
  "iveRequest\032!.mavsdk.rpc.shell.ReceiveRes"
  "ponse\"\004\200\265\030\0000\001B\035\n\017io.mavsdk.shellB\nShellP"
  "rotob\006proto3"
  ;
static const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable*const descriptor_table_shell_2fshell_2eproto_deps[1] = {
  &::descriptor_table_mavsdk_5foptions_2eproto,
};
static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_shell_2fshell_2eproto_once;
const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_shell_2fshell_2eproto = {
  false, false, 692, descriptor_table_protodef_shell_2fshell_2eproto, "shell/shell.proto", 
  &descriptor_table_shell_2fshell_2eproto_once, descriptor_table_shell_2fshell_2eproto_deps, 1, 5,
  schemas, file_default_instances, TableStruct_shell_2fshell_2eproto::offsets,
  file_level_metadata_shell_2fshell_2eproto, file_level_enum_descriptors_shell_2fshell_2eproto, file_level_service_descriptors_shell_2fshell_2eproto,
};
PROTOBUF_ATTRIBUTE_WEAK const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable* descriptor_table_shell_2fshell_2eproto_getter() {
  return &descriptor_table_shell_2fshell_2eproto;
}

PROTOBUF_ATTRIBUTE_INIT_PRIORITY static ::PROTOBUF_NAMESPACE_ID::internal::AddDescriptorsRunner dynamic_init_dummy_shell_2fshell_2eproto(&descriptor_table_shell_2fshell_2eproto);
namespace mavsdk {
namespace rpc {
namespace shell {
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ShellResult_Result_descriptor() {
  ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_shell_2fshell_2eproto);
  return file_level_enum_descriptors_shell_2fshell_2eproto[0];
}
bool ShellResult_Result_IsValid(int value) {
  switch (value) {
    case 0:
    case 1:
    case 2:
    case 3:
    case 4:
    case 5:
      return true;
    default:
      return false;
  }
}

#if (__cplusplus < 201703) && (!defined(_MSC_VER) || _MSC_VER >= 1900)
constexpr ShellResult_Result ShellResult::RESULT_UNKNOWN;
constexpr ShellResult_Result ShellResult::RESULT_SUCCESS;
constexpr ShellResult_Result ShellResult::RESULT_NO_SYSTEM;
constexpr ShellResult_Result ShellResult::RESULT_CONNECTION_ERROR;
constexpr ShellResult_Result ShellResult::RESULT_NO_RESPONSE;
constexpr ShellResult_Result ShellResult::RESULT_BUSY;
constexpr ShellResult_Result ShellResult::Result_MIN;
constexpr ShellResult_Result ShellResult::Result_MAX;
constexpr int ShellResult::Result_ARRAYSIZE;
#endif  

class SendRequest::_Internal {
 public:
};

SendRequest::SendRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }

}
SendRequest::SendRequest(const SendRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  command_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_command().empty()) {
    command_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_command(), 
      GetArenaForAllocation());
  }

}

inline void SendRequest::SharedCtor() {
command_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

SendRequest::~SendRequest() {

  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void SendRequest::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  command_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

void SendRequest::ArenaDtor(void* object) {
  SendRequest* _this = reinterpret_cast< SendRequest* >(object);
  (void)_this;
}
void SendRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void SendRequest::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void SendRequest::Clear() {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  command_.ClearToEmpty();
  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* SendRequest::_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);
    switch (tag >> 3) {

      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
          auto str = _internal_mutable_command();
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "mavsdk.rpc.shell.SendRequest.command"));
          CHK_(ptr);
        } else goto handle_unusual;
        continue;
      default: {
      handle_unusual:
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          ctx->SetLastTag(tag);
          goto success;
        }
        ptr = UnknownFieldParse(tag,
            _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
            ptr, ctx);
        CHK_(ptr != nullptr);
        continue;
      }
    }  
  }  
success:
  return ptr;
failure:
  ptr = nullptr;
  goto success;
#undef CHK_
}

::PROTOBUF_NAMESPACE_ID::uint8* SendRequest::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!this->_internal_command().empty()) {
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_command().data(), static_cast<int>(this->_internal_command().length()),
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
      "mavsdk.rpc.shell.SendRequest.command");
    target = stream->WriteStringMaybeAliased(
        1, this->_internal_command(), 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);
  }

  return target;
}

size_t SendRequest::ByteSizeLong() const {

  size_t total_size = 0;

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  if (!this->_internal_command().empty()) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        this->_internal_command());
  }

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData SendRequest::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    SendRequest::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*SendRequest::GetClassData() const { return &_class_data_; }

void SendRequest::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<SendRequest *>(to)->MergeFrom(
      static_cast<const SendRequest &>(from));
}

void SendRequest::MergeFrom(const SendRequest& from) {

  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_command().empty()) {
    _internal_set_command(from._internal_command());
  }
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void SendRequest::CopyFrom(const SendRequest& from) {

  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool SendRequest::IsInitialized() const {
  return true;
}

void SendRequest::InternalSwap(SendRequest* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
      &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
      &command_, GetArenaForAllocation(),
      &other->command_, other->GetArenaForAllocation()
  );
}

::PROTOBUF_NAMESPACE_ID::Metadata SendRequest::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[0]);
}

class SendResponse::_Internal {
 public:
  static const ::mavsdk::rpc::shell::ShellResult& shell_result(const SendResponse* msg);
};

const ::mavsdk::rpc::shell::ShellResult&
SendResponse::_Internal::shell_result(const SendResponse* msg) {
  return *msg->shell_result_;
}
SendResponse::SendResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }

}
SendResponse::SendResponse(const SendResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  if (from._internal_has_shell_result()) {
    shell_result_ = new ::mavsdk::rpc::shell::ShellResult(*from.shell_result_);
  } else {
    shell_result_ = nullptr;
  }

}

inline void SendResponse::SharedCtor() {
shell_result_ = nullptr;
}

SendResponse::~SendResponse() {

  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void SendResponse::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  if (this != internal_default_instance()) delete shell_result_;
}

void SendResponse::ArenaDtor(void* object) {
  SendResponse* _this = reinterpret_cast< SendResponse* >(object);
  (void)_this;
}
void SendResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void SendResponse::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void SendResponse::Clear() {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  if (GetArenaForAllocation() == nullptr && shell_result_ != nullptr) {
    delete shell_result_;
  }
  shell_result_ = nullptr;
  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* SendResponse::_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);
    switch (tag >> 3) {

      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_shell_result(), ptr);
          CHK_(ptr);
        } else goto handle_unusual;
        continue;
      default: {
      handle_unusual:
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          ctx->SetLastTag(tag);
          goto success;
        }
        ptr = UnknownFieldParse(tag,
            _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
            ptr, ctx);
        CHK_(ptr != nullptr);
        continue;
      }
    }  
  }  
success:
  return ptr;
failure:
  ptr = nullptr;
  goto success;
#undef CHK_
}

::PROTOBUF_NAMESPACE_ID::uint8* SendResponse::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (this->_internal_has_shell_result()) {
    target = stream->EnsureSpace(target);
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(
        1, _Internal::shell_result(this), target, stream);
  }

  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);
  }

  return target;
}

size_t SendResponse::ByteSizeLong() const {

  size_t total_size = 0;

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  if (this->_internal_has_shell_result()) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
        *shell_result_);
  }

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData SendResponse::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    SendResponse::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*SendResponse::GetClassData() const { return &_class_data_; }

void SendResponse::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<SendResponse *>(to)->MergeFrom(
      static_cast<const SendResponse &>(from));
}

void SendResponse::MergeFrom(const SendResponse& from) {

  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (from._internal_has_shell_result()) {
    _internal_mutable_shell_result()->::mavsdk::rpc::shell::ShellResult::MergeFrom(from._internal_shell_result());
  }
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void SendResponse::CopyFrom(const SendResponse& from) {

  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool SendResponse::IsInitialized() const {
  return true;
}

void SendResponse::InternalSwap(SendResponse* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(shell_result_, other->shell_result_);
}

::PROTOBUF_NAMESPACE_ID::Metadata SendResponse::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[1]);
}

class SubscribeReceiveRequest::_Internal {
 public:
};

SubscribeReceiveRequest::SubscribeReceiveRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }

}
SubscribeReceiveRequest::SubscribeReceiveRequest(const SubscribeReceiveRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);

}

inline void SubscribeReceiveRequest::SharedCtor() {
}

SubscribeReceiveRequest::~SubscribeReceiveRequest() {

  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void SubscribeReceiveRequest::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
}

void SubscribeReceiveRequest::ArenaDtor(void* object) {
  SubscribeReceiveRequest* _this = reinterpret_cast< SubscribeReceiveRequest* >(object);
  (void)_this;
}
void SubscribeReceiveRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void SubscribeReceiveRequest::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void SubscribeReceiveRequest::Clear() {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* SubscribeReceiveRequest::_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);
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          ctx->SetLastTag(tag);
          goto success;
        }
        ptr = UnknownFieldParse(tag,
            _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
            ptr, ctx);
        CHK_(ptr != nullptr);
        continue;
  }  
success:
  return ptr;
failure:
  ptr = nullptr;
  goto success;
#undef CHK_
}

::PROTOBUF_NAMESPACE_ID::uint8* SubscribeReceiveRequest::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  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);
  }

  return target;
}

size_t SubscribeReceiveRequest::ByteSizeLong() const {

  size_t total_size = 0;

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData SubscribeReceiveRequest::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    SubscribeReceiveRequest::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*SubscribeReceiveRequest::GetClassData() const { return &_class_data_; }

void SubscribeReceiveRequest::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<SubscribeReceiveRequest *>(to)->MergeFrom(
      static_cast<const SubscribeReceiveRequest &>(from));
}

void SubscribeReceiveRequest::MergeFrom(const SubscribeReceiveRequest& from) {

  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void SubscribeReceiveRequest::CopyFrom(const SubscribeReceiveRequest& from) {

  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool SubscribeReceiveRequest::IsInitialized() const {
  return true;
}

void SubscribeReceiveRequest::InternalSwap(SubscribeReceiveRequest* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
}

::PROTOBUF_NAMESPACE_ID::Metadata SubscribeReceiveRequest::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[2]);
}

class ReceiveResponse::_Internal {
 public:
};

ReceiveResponse::ReceiveResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }

}
ReceiveResponse::ReceiveResponse(const ReceiveResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  data_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_data().empty()) {
    data_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_data(), 
      GetArenaForAllocation());
  }

}

inline void ReceiveResponse::SharedCtor() {
data_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

ReceiveResponse::~ReceiveResponse() {

  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void ReceiveResponse::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  data_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

void ReceiveResponse::ArenaDtor(void* object) {
  ReceiveResponse* _this = reinterpret_cast< ReceiveResponse* >(object);
  (void)_this;
}
void ReceiveResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void ReceiveResponse::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void ReceiveResponse::Clear() {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  data_.ClearToEmpty();
  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* ReceiveResponse::_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);
    switch (tag >> 3) {

      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
          auto str = _internal_mutable_data();
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "mavsdk.rpc.shell.ReceiveResponse.data"));
          CHK_(ptr);
        } else goto handle_unusual;
        continue;
      default: {
      handle_unusual:
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          ctx->SetLastTag(tag);
          goto success;
        }
        ptr = UnknownFieldParse(tag,
            _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
            ptr, ctx);
        CHK_(ptr != nullptr);
        continue;
      }
    }  
  }  
success:
  return ptr;
failure:
  ptr = nullptr;
  goto success;
#undef CHK_
}

::PROTOBUF_NAMESPACE_ID::uint8* ReceiveResponse::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!this->_internal_data().empty()) {
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_data().data(), static_cast<int>(this->_internal_data().length()),
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
      "mavsdk.rpc.shell.ReceiveResponse.data");
    target = stream->WriteStringMaybeAliased(
        1, this->_internal_data(), 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);
  }

  return target;
}

size_t ReceiveResponse::ByteSizeLong() const {

  size_t total_size = 0;

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  if (!this->_internal_data().empty()) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        this->_internal_data());
  }

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData ReceiveResponse::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    ReceiveResponse::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*ReceiveResponse::GetClassData() const { return &_class_data_; }

void ReceiveResponse::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<ReceiveResponse *>(to)->MergeFrom(
      static_cast<const ReceiveResponse &>(from));
}

void ReceiveResponse::MergeFrom(const ReceiveResponse& from) {

  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_data().empty()) {
    _internal_set_data(from._internal_data());
  }
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void ReceiveResponse::CopyFrom(const ReceiveResponse& from) {

  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool ReceiveResponse::IsInitialized() const {
  return true;
}

void ReceiveResponse::InternalSwap(ReceiveResponse* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
      &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
      &data_, GetArenaForAllocation(),
      &other->data_, other->GetArenaForAllocation()
  );
}

::PROTOBUF_NAMESPACE_ID::Metadata ReceiveResponse::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[3]);
}

class ShellResult::_Internal {
 public:
};

ShellResult::ShellResult(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }

}
ShellResult::ShellResult(const ShellResult& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  result_str_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_result_str().empty()) {
    result_str_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_result_str(), 
      GetArenaForAllocation());
  }
  result_ = from.result_;

}

inline void ShellResult::SharedCtor() {
result_str_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
result_ = 0;
}

ShellResult::~ShellResult() {

  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void ShellResult::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  result_str_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

void ShellResult::ArenaDtor(void* object) {
  ShellResult* _this = reinterpret_cast< ShellResult* >(object);
  (void)_this;
}
void ShellResult::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void ShellResult::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void ShellResult::Clear() {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  result_str_.ClearToEmpty();
  result_ = 0;
  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* ShellResult::_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);
    switch (tag >> 3) {

      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_result(static_cast<::mavsdk::rpc::shell::ShellResult_Result>(val));
        } else goto handle_unusual;
        continue;

      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
          auto str = _internal_mutable_result_str();
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "mavsdk.rpc.shell.ShellResult.result_str"));
          CHK_(ptr);
        } else goto handle_unusual;
        continue;
      default: {
      handle_unusual:
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          ctx->SetLastTag(tag);
          goto success;
        }
        ptr = UnknownFieldParse(tag,
            _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
            ptr, ctx);
        CHK_(ptr != nullptr);
        continue;
      }
    }  
  }  
success:
  return ptr;
failure:
  ptr = nullptr;
  goto success;
#undef CHK_
}

::PROTOBUF_NAMESPACE_ID::uint8* ShellResult::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (this->_internal_result() != 0) {
    target = stream->EnsureSpace(target);
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteEnumToArray(
      1, this->_internal_result(), target);
  }

  if (!this->_internal_result_str().empty()) {
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_result_str().data(), static_cast<int>(this->_internal_result_str().length()),
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
      "mavsdk.rpc.shell.ShellResult.result_str");
    target = stream->WriteStringMaybeAliased(
        2, this->_internal_result_str(), 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);
  }

  return target;
}

size_t ShellResult::ByteSizeLong() const {

  size_t total_size = 0;

  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;

  (void) cached_has_bits;

  if (!this->_internal_result_str().empty()) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        this->_internal_result_str());
  }

  if (this->_internal_result() != 0) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::EnumSize(this->_internal_result());
  }

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData ShellResult::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    ShellResult::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*ShellResult::GetClassData() const { return &_class_data_; }

void ShellResult::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<ShellResult *>(to)->MergeFrom(
      static_cast<const ShellResult &>(from));
}

void ShellResult::MergeFrom(const ShellResult& from) {

  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_result_str().empty()) {
    _internal_set_result_str(from._internal_result_str());
  }
  if (from._internal_result() != 0) {
    _internal_set_result(from._internal_result());
  }
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void ShellResult::CopyFrom(const ShellResult& from) {

  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool ShellResult::IsInitialized() const {
  return true;
}

void ShellResult::InternalSwap(ShellResult* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
      &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
      &result_str_, GetArenaForAllocation(),
      &other->result_str_, other->GetArenaForAllocation()
  );
  swap(result_, other->result_);
}

::PROTOBUF_NAMESPACE_ID::Metadata ShellResult::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[4]);
}

}  
}  
}  
PROTOBUF_NAMESPACE_OPEN
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::SendRequest* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::SendRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::SendRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::SendResponse* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::SendResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::SendResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::SubscribeReceiveRequest* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::SubscribeReceiveRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::SubscribeReceiveRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::ReceiveResponse* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::ReceiveResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::ReceiveResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::ShellResult* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::ShellResult >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::ShellResult >(arena);
}
PROTOBUF_NAMESPACE_CLOSE

#include <google/protobuf/port_undef.inc>
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: shell/shell.proto

#include "shell/shell.pb.h"

#include <algorithm>

#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/extension_set.h>
#include <google/protobuf/wire_format_lite.h>
#include <google/protobuf/descriptor.h>
#include <google/protobuf/generated_message_reflection.h>
#include <google/protobuf/reflection_ops.h>
#include <google/protobuf/wire_format.h>
// @@protoc_insertion_point(includes)
#include <google/protobuf/port_def.inc>

PROTOBUF_PRAGMA_INIT_SEG
namespace mavsdk {
namespace rpc {
namespace shell {
constexpr SendRequest::SendRequest(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
  : command_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){}
struct SendRequestDefaultTypeInternal {
  constexpr SendRequestDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~SendRequestDefaultTypeInternal() {}
  union {
    SendRequest _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT SendRequestDefaultTypeInternal _SendRequest_default_instance_;
constexpr SendResponse::SendResponse(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
  : shell_result_(nullptr){}
struct SendResponseDefaultTypeInternal {
  constexpr SendResponseDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~SendResponseDefaultTypeInternal() {}
  union {
    SendResponse _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT SendResponseDefaultTypeInternal _SendResponse_default_instance_;
constexpr SubscribeReceiveRequest::SubscribeReceiveRequest(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized){}
struct SubscribeReceiveRequestDefaultTypeInternal {
  constexpr SubscribeReceiveRequestDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~SubscribeReceiveRequestDefaultTypeInternal() {}
  union {
    SubscribeReceiveRequest _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT SubscribeReceiveRequestDefaultTypeInternal _SubscribeReceiveRequest_default_instance_;
constexpr ReceiveResponse::ReceiveResponse(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
  : data_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){}
struct ReceiveResponseDefaultTypeInternal {
  constexpr ReceiveResponseDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~ReceiveResponseDefaultTypeInternal() {}
  union {
    ReceiveResponse _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT ReceiveResponseDefaultTypeInternal _ReceiveResponse_default_instance_;
constexpr ShellResult::ShellResult(
  ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized)
  : result_str_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string)
  , result_(0)
{}
struct ShellResultDefaultTypeInternal {
  constexpr ShellResultDefaultTypeInternal()
    : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {}
  ~ShellResultDefaultTypeInternal() {}
  union {
    ShellResult _instance;
  };
};
PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT ShellResultDefaultTypeInternal _ShellResult_default_instance_;
}  // namespace shell
}  // namespace rpc
}  // namespace mavsdk
static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_shell_2fshell_2eproto[5];
static const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* file_level_enum_descriptors_shell_2fshell_2eproto[1];
static constexpr ::PROTOBUF_NAMESPACE_ID::ServiceDescriptor const** file_level_service_descriptors_shell_2fshell_2eproto = nullptr;

const ::PROTOBUF_NAMESPACE_ID::uint32 TableStruct_shell_2fshell_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
  ~0u,  // no _has_bits_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SendRequest, _internal_metadata_),
  ~0u,  // no _extensions_
  ~0u,  // no _oneof_case_
  ~0u,  // no _weak_field_map_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SendRequest, command_),
  ~0u,  // no _has_bits_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SendResponse, _internal_metadata_),
  ~0u,  // no _extensions_
  ~0u,  // no _oneof_case_
  ~0u,  // no _weak_field_map_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SendResponse, shell_result_),
  ~0u,  // no _has_bits_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::SubscribeReceiveRequest, _internal_metadata_),
  ~0u,  // no _extensions_
  ~0u,  // no _oneof_case_
  ~0u,  // no _weak_field_map_
  ~0u,  // no _has_bits_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ReceiveResponse, _internal_metadata_),
  ~0u,  // no _extensions_
  ~0u,  // no _oneof_case_
  ~0u,  // no _weak_field_map_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ReceiveResponse, data_),
  ~0u,  // no _has_bits_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ShellResult, _internal_metadata_),
  ~0u,  // no _extensions_
  ~0u,  // no _oneof_case_
  ~0u,  // no _weak_field_map_
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ShellResult, result_),
  PROTOBUF_FIELD_OFFSET(::mavsdk::rpc::shell::ShellResult, result_str_),
};
static const ::PROTOBUF_NAMESPACE_ID::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
  { 0, -1, sizeof(::mavsdk::rpc::shell::SendRequest)},
  { 6, -1, sizeof(::mavsdk::rpc::shell::SendResponse)},
  { 12, -1, sizeof(::mavsdk::rpc::shell::SubscribeReceiveRequest)},
  { 17, -1, sizeof(::mavsdk::rpc::shell::ReceiveResponse)},
  { 23, -1, sizeof(::mavsdk::rpc::shell::ShellResult)},
};

static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = {
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_SendRequest_default_instance_),
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_SendResponse_default_instance_),
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_SubscribeReceiveRequest_default_instance_),
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_ReceiveResponse_default_instance_),
  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::mavsdk::rpc::shell::_ShellResult_default_instance_),
};

const char descriptor_table_protodef_shell_2fshell_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) =
  "\n\021shell/shell.proto\022\020mavsdk.rpc.shell\032\024m"
  "avsdk_options.proto\"\036\n\013SendRequest\022\017\n\007co"
  "mmand\030\001 \001(\t\"C\n\014SendResponse\0223\n\014shell_res"
  "ult\030\001 \001(\0132\035.mavsdk.rpc.shell.ShellResult"
  "\"\031\n\027SubscribeReceiveRequest\"\037\n\017ReceiveRe"
  "sponse\022\014\n\004data\030\001 \001(\t\"\346\001\n\013ShellResult\0224\n\006"
  "result\030\001 \001(\0162$.mavsdk.rpc.shell.ShellRes"
  "ult.Result\022\022\n\nresult_str\030\002 \001(\t\"\214\001\n\006Resul"
  "t\022\022\n\016RESULT_UNKNOWN\020\000\022\022\n\016RESULT_SUCCESS\020"
  "\001\022\024\n\020RESULT_NO_SYSTEM\020\002\022\033\n\027RESULT_CONNEC"
  "TION_ERROR\020\003\022\026\n\022RESULT_NO_RESPONSE\020\004\022\017\n\013"
  "RESULT_BUSY\020\0052\305\001\n\014ShellService\022K\n\004Send\022\035"
  ".mavsdk.rpc.shell.SendRequest\032\036.mavsdk.r"
  "pc.shell.SendResponse\"\004\200\265\030\001\022h\n\020Subscribe"
  "Receive\022).mavsdk.rpc.shell.SubscribeRece"
  "iveRequest\032!.mavsdk.rpc.shell.ReceiveRes"
  "ponse\"\004\200\265\030\0000\001B\035\n\017io.mavsdk.shellB\nShellP"
  "rotob\006proto3"
  ;
static const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable*const descriptor_table_shell_2fshell_2eproto_deps[1] = {
  &::descriptor_table_mavsdk_5foptions_2eproto,
};
static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_shell_2fshell_2eproto_once;
const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_shell_2fshell_2eproto = {
  false, false, 692, descriptor_table_protodef_shell_2fshell_2eproto, "shell/shell.proto", 
  &descriptor_table_shell_2fshell_2eproto_once, descriptor_table_shell_2fshell_2eproto_deps, 1, 5,
  schemas, file_default_instances, TableStruct_shell_2fshell_2eproto::offsets,
  file_level_metadata_shell_2fshell_2eproto, file_level_enum_descriptors_shell_2fshell_2eproto, file_level_service_descriptors_shell_2fshell_2eproto,
};
PROTOBUF_ATTRIBUTE_WEAK const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable* descriptor_table_shell_2fshell_2eproto_getter() {
  return &descriptor_table_shell_2fshell_2eproto;
}

// Force running AddDescriptors() at dynamic initialization time.
PROTOBUF_ATTRIBUTE_INIT_PRIORITY static ::PROTOBUF_NAMESPACE_ID::internal::AddDescriptorsRunner dynamic_init_dummy_shell_2fshell_2eproto(&descriptor_table_shell_2fshell_2eproto);
namespace mavsdk {
namespace rpc {
namespace shell {
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ShellResult_Result_descriptor() {
  ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_shell_2fshell_2eproto);
  return file_level_enum_descriptors_shell_2fshell_2eproto[0];
}
bool ShellResult_Result_IsValid(int value) {
  switch (value) {
    case 0:
    case 1:
    case 2:
    case 3:
    case 4:
    case 5:
      return true;
    default:
      return false;
  }
}

#if (__cplusplus < 201703) && (!defined(_MSC_VER) || _MSC_VER >= 1900)
constexpr ShellResult_Result ShellResult::RESULT_UNKNOWN;
constexpr ShellResult_Result ShellResult::RESULT_SUCCESS;
constexpr ShellResult_Result ShellResult::RESULT_NO_SYSTEM;
constexpr ShellResult_Result ShellResult::RESULT_CONNECTION_ERROR;
constexpr ShellResult_Result ShellResult::RESULT_NO_RESPONSE;
constexpr ShellResult_Result ShellResult::RESULT_BUSY;
constexpr ShellResult_Result ShellResult::Result_MIN;
constexpr ShellResult_Result ShellResult::Result_MAX;
constexpr int ShellResult::Result_ARRAYSIZE;
#endif  // (__cplusplus < 201703) && (!defined(_MSC_VER) || _MSC_VER >= 1900)

// ===================================================================

class SendRequest::_Internal {
 public:
};

SendRequest::SendRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }
  // @@protoc_insertion_point(arena_constructor:mavsdk.rpc.shell.SendRequest)
}
SendRequest::SendRequest(const SendRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  command_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_command().empty()) {
    command_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_command(), 
      GetArenaForAllocation());
  }
  // @@protoc_insertion_point(copy_constructor:mavsdk.rpc.shell.SendRequest)
}

inline void SendRequest::SharedCtor() {
command_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

SendRequest::~SendRequest() {
  // @@protoc_insertion_point(destructor:mavsdk.rpc.shell.SendRequest)
  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void SendRequest::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  command_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

void SendRequest::ArenaDtor(void* object) {
  SendRequest* _this = reinterpret_cast< SendRequest* >(object);
  (void)_this;
}
void SendRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void SendRequest::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void SendRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:mavsdk.rpc.shell.SendRequest)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  command_.ClearToEmpty();
  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* SendRequest::_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);
    switch (tag >> 3) {
      // string command = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
          auto str = _internal_mutable_command();
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "mavsdk.rpc.shell.SendRequest.command"));
          CHK_(ptr);
        } else goto handle_unusual;
        continue;
      default: {
      handle_unusual:
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          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* SendRequest::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:mavsdk.rpc.shell.SendRequest)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  // string command = 1;
  if (!this->_internal_command().empty()) {
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_command().data(), static_cast<int>(this->_internal_command().length()),
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
      "mavsdk.rpc.shell.SendRequest.command");
    target = stream->WriteStringMaybeAliased(
        1, this->_internal_command(), 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:mavsdk.rpc.shell.SendRequest)
  return target;
}

size_t SendRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:mavsdk.rpc.shell.SendRequest)
  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 command = 1;
  if (!this->_internal_command().empty()) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        this->_internal_command());
  }

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData SendRequest::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    SendRequest::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*SendRequest::GetClassData() const { return &_class_data_; }

void SendRequest::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<SendRequest *>(to)->MergeFrom(
      static_cast<const SendRequest &>(from));
}


void SendRequest::MergeFrom(const SendRequest& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:mavsdk.rpc.shell.SendRequest)
  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_command().empty()) {
    _internal_set_command(from._internal_command());
  }
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void SendRequest::CopyFrom(const SendRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:mavsdk.rpc.shell.SendRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool SendRequest::IsInitialized() const {
  return true;
}

void SendRequest::InternalSwap(SendRequest* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
      &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
      &command_, GetArenaForAllocation(),
      &other->command_, other->GetArenaForAllocation()
  );
}

::PROTOBUF_NAMESPACE_ID::Metadata SendRequest::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[0]);
}

// ===================================================================

class SendResponse::_Internal {
 public:
  static const ::mavsdk::rpc::shell::ShellResult& shell_result(const SendResponse* msg);
};

const ::mavsdk::rpc::shell::ShellResult&
SendResponse::_Internal::shell_result(const SendResponse* msg) {
  return *msg->shell_result_;
}
SendResponse::SendResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }
  // @@protoc_insertion_point(arena_constructor:mavsdk.rpc.shell.SendResponse)
}
SendResponse::SendResponse(const SendResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  if (from._internal_has_shell_result()) {
    shell_result_ = new ::mavsdk::rpc::shell::ShellResult(*from.shell_result_);
  } else {
    shell_result_ = nullptr;
  }
  // @@protoc_insertion_point(copy_constructor:mavsdk.rpc.shell.SendResponse)
}

inline void SendResponse::SharedCtor() {
shell_result_ = nullptr;
}

SendResponse::~SendResponse() {
  // @@protoc_insertion_point(destructor:mavsdk.rpc.shell.SendResponse)
  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void SendResponse::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  if (this != internal_default_instance()) delete shell_result_;
}

void SendResponse::ArenaDtor(void* object) {
  SendResponse* _this = reinterpret_cast< SendResponse* >(object);
  (void)_this;
}
void SendResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void SendResponse::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void SendResponse::Clear() {
// @@protoc_insertion_point(message_clear_start:mavsdk.rpc.shell.SendResponse)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  if (GetArenaForAllocation() == nullptr && shell_result_ != nullptr) {
    delete shell_result_;
  }
  shell_result_ = nullptr;
  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* SendResponse::_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);
    switch (tag >> 3) {
      // .mavsdk.rpc.shell.ShellResult shell_result = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_shell_result(), ptr);
          CHK_(ptr);
        } else goto handle_unusual;
        continue;
      default: {
      handle_unusual:
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          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* SendResponse::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:mavsdk.rpc.shell.SendResponse)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  // .mavsdk.rpc.shell.ShellResult shell_result = 1;
  if (this->_internal_has_shell_result()) {
    target = stream->EnsureSpace(target);
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(
        1, _Internal::shell_result(this), target, stream);
  }

  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:mavsdk.rpc.shell.SendResponse)
  return target;
}

size_t SendResponse::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:mavsdk.rpc.shell.SendResponse)
  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;

  // .mavsdk.rpc.shell.ShellResult shell_result = 1;
  if (this->_internal_has_shell_result()) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
        *shell_result_);
  }

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData SendResponse::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    SendResponse::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*SendResponse::GetClassData() const { return &_class_data_; }

void SendResponse::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<SendResponse *>(to)->MergeFrom(
      static_cast<const SendResponse &>(from));
}


void SendResponse::MergeFrom(const SendResponse& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:mavsdk.rpc.shell.SendResponse)
  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (from._internal_has_shell_result()) {
    _internal_mutable_shell_result()->::mavsdk::rpc::shell::ShellResult::MergeFrom(from._internal_shell_result());
  }
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void SendResponse::CopyFrom(const SendResponse& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:mavsdk.rpc.shell.SendResponse)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool SendResponse::IsInitialized() const {
  return true;
}

void SendResponse::InternalSwap(SendResponse* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(shell_result_, other->shell_result_);
}

::PROTOBUF_NAMESPACE_ID::Metadata SendResponse::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[1]);
}

// ===================================================================

class SubscribeReceiveRequest::_Internal {
 public:
};

SubscribeReceiveRequest::SubscribeReceiveRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }
  // @@protoc_insertion_point(arena_constructor:mavsdk.rpc.shell.SubscribeReceiveRequest)
}
SubscribeReceiveRequest::SubscribeReceiveRequest(const SubscribeReceiveRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  // @@protoc_insertion_point(copy_constructor:mavsdk.rpc.shell.SubscribeReceiveRequest)
}

inline void SubscribeReceiveRequest::SharedCtor() {
}

SubscribeReceiveRequest::~SubscribeReceiveRequest() {
  // @@protoc_insertion_point(destructor:mavsdk.rpc.shell.SubscribeReceiveRequest)
  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void SubscribeReceiveRequest::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
}

void SubscribeReceiveRequest::ArenaDtor(void* object) {
  SubscribeReceiveRequest* _this = reinterpret_cast< SubscribeReceiveRequest* >(object);
  (void)_this;
}
void SubscribeReceiveRequest::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void SubscribeReceiveRequest::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void SubscribeReceiveRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:mavsdk.rpc.shell.SubscribeReceiveRequest)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* SubscribeReceiveRequest::_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);
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          ctx->SetLastTag(tag);
          goto success;
        }
        ptr = UnknownFieldParse(tag,
            _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
            ptr, ctx);
        CHK_(ptr != nullptr);
        continue;
  }  // while
success:
  return ptr;
failure:
  ptr = nullptr;
  goto success;
#undef CHK_
}

::PROTOBUF_NAMESPACE_ID::uint8* SubscribeReceiveRequest::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:mavsdk.rpc.shell.SubscribeReceiveRequest)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  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:mavsdk.rpc.shell.SubscribeReceiveRequest)
  return target;
}

size_t SubscribeReceiveRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:mavsdk.rpc.shell.SubscribeReceiveRequest)
  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;

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData SubscribeReceiveRequest::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    SubscribeReceiveRequest::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*SubscribeReceiveRequest::GetClassData() const { return &_class_data_; }

void SubscribeReceiveRequest::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<SubscribeReceiveRequest *>(to)->MergeFrom(
      static_cast<const SubscribeReceiveRequest &>(from));
}


void SubscribeReceiveRequest::MergeFrom(const SubscribeReceiveRequest& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:mavsdk.rpc.shell.SubscribeReceiveRequest)
  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void SubscribeReceiveRequest::CopyFrom(const SubscribeReceiveRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:mavsdk.rpc.shell.SubscribeReceiveRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool SubscribeReceiveRequest::IsInitialized() const {
  return true;
}

void SubscribeReceiveRequest::InternalSwap(SubscribeReceiveRequest* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
}

::PROTOBUF_NAMESPACE_ID::Metadata SubscribeReceiveRequest::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[2]);
}

// ===================================================================

class ReceiveResponse::_Internal {
 public:
};

ReceiveResponse::ReceiveResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }
  // @@protoc_insertion_point(arena_constructor:mavsdk.rpc.shell.ReceiveResponse)
}
ReceiveResponse::ReceiveResponse(const ReceiveResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  data_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_data().empty()) {
    data_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_data(), 
      GetArenaForAllocation());
  }
  // @@protoc_insertion_point(copy_constructor:mavsdk.rpc.shell.ReceiveResponse)
}

inline void ReceiveResponse::SharedCtor() {
data_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

ReceiveResponse::~ReceiveResponse() {
  // @@protoc_insertion_point(destructor:mavsdk.rpc.shell.ReceiveResponse)
  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void ReceiveResponse::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  data_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

void ReceiveResponse::ArenaDtor(void* object) {
  ReceiveResponse* _this = reinterpret_cast< ReceiveResponse* >(object);
  (void)_this;
}
void ReceiveResponse::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void ReceiveResponse::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void ReceiveResponse::Clear() {
// @@protoc_insertion_point(message_clear_start:mavsdk.rpc.shell.ReceiveResponse)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  data_.ClearToEmpty();
  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* ReceiveResponse::_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);
    switch (tag >> 3) {
      // string data = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
          auto str = _internal_mutable_data();
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "mavsdk.rpc.shell.ReceiveResponse.data"));
          CHK_(ptr);
        } else goto handle_unusual;
        continue;
      default: {
      handle_unusual:
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          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* ReceiveResponse::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:mavsdk.rpc.shell.ReceiveResponse)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  // string data = 1;
  if (!this->_internal_data().empty()) {
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_data().data(), static_cast<int>(this->_internal_data().length()),
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
      "mavsdk.rpc.shell.ReceiveResponse.data");
    target = stream->WriteStringMaybeAliased(
        1, this->_internal_data(), 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:mavsdk.rpc.shell.ReceiveResponse)
  return target;
}

size_t ReceiveResponse::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:mavsdk.rpc.shell.ReceiveResponse)
  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 data = 1;
  if (!this->_internal_data().empty()) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        this->_internal_data());
  }

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData ReceiveResponse::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    ReceiveResponse::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*ReceiveResponse::GetClassData() const { return &_class_data_; }

void ReceiveResponse::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<ReceiveResponse *>(to)->MergeFrom(
      static_cast<const ReceiveResponse &>(from));
}


void ReceiveResponse::MergeFrom(const ReceiveResponse& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:mavsdk.rpc.shell.ReceiveResponse)
  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_data().empty()) {
    _internal_set_data(from._internal_data());
  }
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void ReceiveResponse::CopyFrom(const ReceiveResponse& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:mavsdk.rpc.shell.ReceiveResponse)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool ReceiveResponse::IsInitialized() const {
  return true;
}

void ReceiveResponse::InternalSwap(ReceiveResponse* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
      &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
      &data_, GetArenaForAllocation(),
      &other->data_, other->GetArenaForAllocation()
  );
}

::PROTOBUF_NAMESPACE_ID::Metadata ReceiveResponse::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[3]);
}

// ===================================================================

class ShellResult::_Internal {
 public:
};

ShellResult::ShellResult(::PROTOBUF_NAMESPACE_ID::Arena* arena,
                         bool is_message_owned)
  : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
  SharedCtor();
  if (!is_message_owned) {
    RegisterArenaDtor(arena);
  }
  // @@protoc_insertion_point(arena_constructor:mavsdk.rpc.shell.ShellResult)
}
ShellResult::ShellResult(const ShellResult& from)
  : ::PROTOBUF_NAMESPACE_ID::Message() {
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
  result_str_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
  if (!from._internal_result_str().empty()) {
    result_str_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_result_str(), 
      GetArenaForAllocation());
  }
  result_ = from.result_;
  // @@protoc_insertion_point(copy_constructor:mavsdk.rpc.shell.ShellResult)
}

inline void ShellResult::SharedCtor() {
result_str_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
result_ = 0;
}

ShellResult::~ShellResult() {
  // @@protoc_insertion_point(destructor:mavsdk.rpc.shell.ShellResult)
  if (GetArenaForAllocation() != nullptr) return;
  SharedDtor();
  _internal_metadata_.Delete<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

inline void ShellResult::SharedDtor() {
  GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
  result_str_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
}

void ShellResult::ArenaDtor(void* object) {
  ShellResult* _this = reinterpret_cast< ShellResult* >(object);
  (void)_this;
}
void ShellResult::RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena*) {
}
void ShellResult::SetCachedSize(int size) const {
  _cached_size_.Set(size);
}

void ShellResult::Clear() {
// @@protoc_insertion_point(message_clear_start:mavsdk.rpc.shell.ShellResult)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  result_str_.ClearToEmpty();
  result_ = 0;
  _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}

const char* ShellResult::_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);
    switch (tag >> 3) {
      // .mavsdk.rpc.shell.ShellResult.Result result = 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_result(static_cast<::mavsdk::rpc::shell::ShellResult_Result>(val));
        } else goto handle_unusual;
        continue;
      // string result_str = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
          auto str = _internal_mutable_result_str();
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "mavsdk.rpc.shell.ShellResult.result_str"));
          CHK_(ptr);
        } else goto handle_unusual;
        continue;
      default: {
      handle_unusual:
        if ((tag == 0) || ((tag & 7) == 4)) {
          CHK_(ptr);
          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* ShellResult::_InternalSerialize(
    ::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:mavsdk.rpc.shell.ShellResult)
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  // .mavsdk.rpc.shell.ShellResult.Result result = 1;
  if (this->_internal_result() != 0) {
    target = stream->EnsureSpace(target);
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteEnumToArray(
      1, this->_internal_result(), target);
  }

  // string result_str = 2;
  if (!this->_internal_result_str().empty()) {
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
      this->_internal_result_str().data(), static_cast<int>(this->_internal_result_str().length()),
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
      "mavsdk.rpc.shell.ShellResult.result_str");
    target = stream->WriteStringMaybeAliased(
        2, this->_internal_result_str(), 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:mavsdk.rpc.shell.ShellResult)
  return target;
}

size_t ShellResult::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:mavsdk.rpc.shell.ShellResult)
  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 result_str = 2;
  if (!this->_internal_result_str().empty()) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        this->_internal_result_str());
  }

  // .mavsdk.rpc.shell.ShellResult.Result result = 1;
  if (this->_internal_result() != 0) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::EnumSize(this->_internal_result());
  }

  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;
}

const ::PROTOBUF_NAMESPACE_ID::Message::ClassData ShellResult::_class_data_ = {
    ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSizeCheck,
    ShellResult::MergeImpl
};
const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*ShellResult::GetClassData() const { return &_class_data_; }

void ShellResult::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message*to,
                      const ::PROTOBUF_NAMESPACE_ID::Message&from) {
  static_cast<ShellResult *>(to)->MergeFrom(
      static_cast<const ShellResult &>(from));
}


void ShellResult::MergeFrom(const ShellResult& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:mavsdk.rpc.shell.ShellResult)
  GOOGLE_DCHECK_NE(&from, this);
  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_result_str().empty()) {
    _internal_set_result_str(from._internal_result_str());
  }
  if (from._internal_result() != 0) {
    _internal_set_result(from._internal_result());
  }
  _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
}

void ShellResult::CopyFrom(const ShellResult& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:mavsdk.rpc.shell.ShellResult)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool ShellResult::IsInitialized() const {
  return true;
}

void ShellResult::InternalSwap(ShellResult* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
      &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
      &result_str_, GetArenaForAllocation(),
      &other->result_str_, other->GetArenaForAllocation()
  );
  swap(result_, other->result_);
}

::PROTOBUF_NAMESPACE_ID::Metadata ShellResult::GetMetadata() const {
  return ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(
      &descriptor_table_shell_2fshell_2eproto_getter, &descriptor_table_shell_2fshell_2eproto_once,
      file_level_metadata_shell_2fshell_2eproto[4]);
}

// @@protoc_insertion_point(namespace_scope)
}  // namespace shell
}  // namespace rpc
}  // namespace mavsdk
PROTOBUF_NAMESPACE_OPEN
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::SendRequest* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::SendRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::SendRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::SendResponse* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::SendResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::SendResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::SubscribeReceiveRequest* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::SubscribeReceiveRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::SubscribeReceiveRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::ReceiveResponse* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::ReceiveResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::ReceiveResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::mavsdk::rpc::shell::ShellResult* Arena::CreateMaybeMessage< ::mavsdk::rpc::shell::ShellResult >(Arena* arena) {
  return Arena::CreateMessageInternal< ::mavsdk::rpc::shell::ShellResult >(arena);
}
PROTOBUF_NAMESPACE_CLOSE

// @@protoc_insertion_point(global_scope)
#include <google/protobuf/port_undef.inc>
