// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: keyapis/telemetry_control/v1/keyapis_telemetry_control_metric_point_v1.proto

#include "keyapis/telemetry_control/v1/keyapis_telemetry_control_metric_point_v1.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/io/zero_copy_stream_impl_lite.h"
// @@protoc_insertion_point(includes)

// Must be included last.
#include "google/protobuf/port_def.inc"
PROTOBUF_PRAGMA_INIT_SEG
namespace _pb = ::PROTOBUF_NAMESPACE_ID;
namespace _pbi = ::PROTOBUF_NAMESPACE_ID::internal;
namespace keyapis {
namespace telemetry_control {
namespace v1 {
template <typename>
PROTOBUF_CONSTEXPR GetMetricPointRequest::GetMetricPointRequest(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.id_)*/ {
    &::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized {}
  }

  , /*decltype(_impl_._cached_size_)*/{}} {}
struct GetMetricPointRequestDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GetMetricPointRequestDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GetMetricPointRequestDefaultTypeInternal() {}
  union {
    GetMetricPointRequest _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GetMetricPointRequestDefaultTypeInternal _GetMetricPointRequest_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR GetMetricPointResponse::GetMetricPointResponse(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.type_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct GetMetricPointResponseDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GetMetricPointResponseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GetMetricPointResponseDefaultTypeInternal() {}
  union {
    GetMetricPointResponse _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GetMetricPointResponseDefaultTypeInternal _GetMetricPointResponse_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR GetMetricPointListRequest::GetMetricPointListRequest(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_._has_bits_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_.filter_)*/nullptr
  , /*decltype(_impl_.pagination_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct GetMetricPointListRequestDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GetMetricPointListRequestDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GetMetricPointListRequestDefaultTypeInternal() {}
  union {
    GetMetricPointListRequest _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GetMetricPointListRequestDefaultTypeInternal _GetMetricPointListRequest_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR MetricPointPaging_ValidationError_LimitInvalid::MetricPointPaging_ValidationError_LimitInvalid(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_._cached_size_)*/{}} {}
struct MetricPointPaging_ValidationError_LimitInvalidDefaultTypeInternal {
  PROTOBUF_CONSTEXPR MetricPointPaging_ValidationError_LimitInvalidDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~MetricPointPaging_ValidationError_LimitInvalidDefaultTypeInternal() {}
  union {
    MetricPointPaging_ValidationError_LimitInvalid _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MetricPointPaging_ValidationError_LimitInvalidDefaultTypeInternal _MetricPointPaging_ValidationError_LimitInvalid_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR MetricPointPaging_ValidationError_OffsetInvalid::MetricPointPaging_ValidationError_OffsetInvalid(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_._cached_size_)*/{}} {}
struct MetricPointPaging_ValidationError_OffsetInvalidDefaultTypeInternal {
  PROTOBUF_CONSTEXPR MetricPointPaging_ValidationError_OffsetInvalidDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~MetricPointPaging_ValidationError_OffsetInvalidDefaultTypeInternal() {}
  union {
    MetricPointPaging_ValidationError_OffsetInvalid _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MetricPointPaging_ValidationError_OffsetInvalidDefaultTypeInternal _MetricPointPaging_ValidationError_OffsetInvalid_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR MetricPointPaging_ValidationError::MetricPointPaging_ValidationError(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.reason_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct MetricPointPaging_ValidationErrorDefaultTypeInternal {
  PROTOBUF_CONSTEXPR MetricPointPaging_ValidationErrorDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~MetricPointPaging_ValidationErrorDefaultTypeInternal() {}
  union {
    MetricPointPaging_ValidationError _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MetricPointPaging_ValidationErrorDefaultTypeInternal _MetricPointPaging_ValidationError_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR MetricPointPaging::MetricPointPaging(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.order_by_type_)*/ 0

  , /*decltype(_impl_.direction_type_)*/ 0

  , /*decltype(_impl_.limit_)*/ 0

  , /*decltype(_impl_.offset_)*/ 0

  , /*decltype(_impl_._cached_size_)*/{}} {}
struct MetricPointPagingDefaultTypeInternal {
  PROTOBUF_CONSTEXPR MetricPointPagingDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~MetricPointPagingDefaultTypeInternal() {}
  union {
    MetricPointPaging _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MetricPointPagingDefaultTypeInternal _MetricPointPaging_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR MetricPointFilter_ValidationError::MetricPointFilter_ValidationError(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.path_)*/ {
    &::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized {}
  }

  , /*decltype(_impl_.message_)*/ {
    &::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized {}
  }

  , /*decltype(_impl_._cached_size_)*/{}} {}
struct MetricPointFilter_ValidationErrorDefaultTypeInternal {
  PROTOBUF_CONSTEXPR MetricPointFilter_ValidationErrorDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~MetricPointFilter_ValidationErrorDefaultTypeInternal() {}
  union {
    MetricPointFilter_ValidationError _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MetricPointFilter_ValidationErrorDefaultTypeInternal _MetricPointFilter_ValidationError_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR MetricPointFilter::MetricPointFilter(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.device_metric_point_metric_types_)*/ {}
  , /*decltype(_impl_._device_metric_point_metric_types_cached_byte_size_)*/ { 0 }

  , /*decltype(_impl_.device_metric_point_status_types_)*/ {}
  , /*decltype(_impl_._device_metric_point_status_types_cached_byte_size_)*/ { 0 }

  , /*decltype(_impl_.room_numbers_)*/{}
  , /*decltype(_impl_.room_labels_)*/{}
  , /*decltype(_impl_.building_ids_)*/ {}
  ,/* _impl_._building_ids_cached_byte_size_ = */ { 0 }

  , /*decltype(_impl_.fias_ids_)*/{}
  , /*decltype(_impl_.device_ids_)*/ {}
  ,/* _impl_._device_ids_cached_byte_size_ = */ { 0 }

  , /*decltype(_impl_.device_serial_numbers_)*/{}
  , /*decltype(_impl_.orpons_)*/ {}
  ,/* _impl_._orpons_cached_byte_size_ = */ { 0 }

  , /*decltype(_impl_._cached_size_)*/{}} {}
struct MetricPointFilterDefaultTypeInternal {
  PROTOBUF_CONSTEXPR MetricPointFilterDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~MetricPointFilterDefaultTypeInternal() {}
  union {
    MetricPointFilter _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 MetricPointFilterDefaultTypeInternal _MetricPointFilter_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR GetMetricPointListResponse_Error::GetMetricPointListResponse_Error(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.reason_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct GetMetricPointListResponse_ErrorDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GetMetricPointListResponse_ErrorDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GetMetricPointListResponse_ErrorDefaultTypeInternal() {}
  union {
    GetMetricPointListResponse_Error _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GetMetricPointListResponse_ErrorDefaultTypeInternal _GetMetricPointListResponse_Error_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR GetMetricPointListResponse::GetMetricPointListResponse(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.type_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct GetMetricPointListResponseDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GetMetricPointListResponseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GetMetricPointListResponseDefaultTypeInternal() {}
  union {
    GetMetricPointListResponse _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GetMetricPointListResponseDefaultTypeInternal _GetMetricPointListResponse_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR GetMetricPointCountRequest::GetMetricPointCountRequest(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_._has_bits_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_.filter_)*/nullptr} {}
struct GetMetricPointCountRequestDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GetMetricPointCountRequestDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GetMetricPointCountRequestDefaultTypeInternal() {}
  union {
    GetMetricPointCountRequest _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GetMetricPointCountRequestDefaultTypeInternal _GetMetricPointCountRequest_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR GetMetricPointCountResponse_Error::GetMetricPointCountResponse_Error(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.reason_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct GetMetricPointCountResponse_ErrorDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GetMetricPointCountResponse_ErrorDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GetMetricPointCountResponse_ErrorDefaultTypeInternal() {}
  union {
    GetMetricPointCountResponse_Error _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GetMetricPointCountResponse_ErrorDefaultTypeInternal _GetMetricPointCountResponse_Error_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR GetMetricPointCountResponse::GetMetricPointCountResponse(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.type_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct GetMetricPointCountResponseDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GetMetricPointCountResponseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GetMetricPointCountResponseDefaultTypeInternal() {}
  union {
    GetMetricPointCountResponse _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GetMetricPointCountResponseDefaultTypeInternal _GetMetricPointCountResponse_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR PostMetricPointRequest::PostMetricPointRequest(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_._has_bits_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_.data_)*/nullptr} {}
struct PostMetricPointRequestDefaultTypeInternal {
  PROTOBUF_CONSTEXPR PostMetricPointRequestDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~PostMetricPointRequestDefaultTypeInternal() {}
  union {
    PostMetricPointRequest _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 PostMetricPointRequestDefaultTypeInternal _PostMetricPointRequest_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR PostMetricPointResponse_Error::PostMetricPointResponse_Error(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.reason_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct PostMetricPointResponse_ErrorDefaultTypeInternal {
  PROTOBUF_CONSTEXPR PostMetricPointResponse_ErrorDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~PostMetricPointResponse_ErrorDefaultTypeInternal() {}
  union {
    PostMetricPointResponse_Error _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 PostMetricPointResponse_ErrorDefaultTypeInternal _PostMetricPointResponse_Error_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR PostMetricPointResponse::PostMetricPointResponse(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.type_)*/{}
  , /*decltype(_impl_._cached_size_)*/{}
  , /*decltype(_impl_._oneof_case_)*/{}} {}
struct PostMetricPointResponseDefaultTypeInternal {
  PROTOBUF_CONSTEXPR PostMetricPointResponseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~PostMetricPointResponseDefaultTypeInternal() {}
  union {
    PostMetricPointResponse _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 PostMetricPointResponseDefaultTypeInternal _PostMetricPointResponse_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR DeleteMetricPointRequest::DeleteMetricPointRequest(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.id_)*/ {
    &::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized {}
  }

  , /*decltype(_impl_._cached_size_)*/{}} {}
struct DeleteMetricPointRequestDefaultTypeInternal {
  PROTOBUF_CONSTEXPR DeleteMetricPointRequestDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~DeleteMetricPointRequestDefaultTypeInternal() {}
  union {
    DeleteMetricPointRequest _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 DeleteMetricPointRequestDefaultTypeInternal _DeleteMetricPointRequest_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR DeleteMetricPointResponse::DeleteMetricPointResponse(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_._cached_size_)*/{}} {}
struct DeleteMetricPointResponseDefaultTypeInternal {
  PROTOBUF_CONSTEXPR DeleteMetricPointResponseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~DeleteMetricPointResponseDefaultTypeInternal() {}
  union {
    DeleteMetricPointResponse _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 DeleteMetricPointResponseDefaultTypeInternal _DeleteMetricPointResponse_default_instance_;
template <typename>
PROTOBUF_CONSTEXPR ValidationError::ValidationError(
    ::_pbi::ConstantInitialized): _impl_{
    /*decltype(_impl_.path_)*/ {
    &::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized {}
  }

  , /*decltype(_impl_.message_)*/ {
    &::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized {}
  }

  , /*decltype(_impl_._cached_size_)*/{}} {}
struct ValidationErrorDefaultTypeInternal {
  PROTOBUF_CONSTEXPR ValidationErrorDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~ValidationErrorDefaultTypeInternal() {}
  union {
    ValidationError _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ValidationErrorDefaultTypeInternal _ValidationError_default_instance_;
}  // namespace v1
}  // namespace telemetry_control
}  // namespace keyapis
namespace keyapis {
namespace telemetry_control {
namespace v1 {
bool MetricPointPaging_OrderByType_IsValid(int value) {
  switch (value) {
    case 0:
    case 1:
    case 2:
    case 3:
    case 4:
    case 5:
    case 6:
      return true;
    default:
      return false;
  }
}
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string>
    MetricPointPaging_OrderByType_strings[7] = {};

static const char MetricPointPaging_OrderByType_names[] = {
    "BUILDING_ID"
    "ID"
    "METRIC_TYPE"
    "ORDER_BY_TYPE_UNKNOWN"
    "ROOM_LABEL"
    "ROOM_NUMBER"
    "STATUS_TYPE"
};

static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry MetricPointPaging_OrderByType_entries[] =
    {
        {{&MetricPointPaging_OrderByType_names[0], 11}, 6},
        {{&MetricPointPaging_OrderByType_names[11], 2}, 1},
        {{&MetricPointPaging_OrderByType_names[13], 11}, 2},
        {{&MetricPointPaging_OrderByType_names[24], 21}, 0},
        {{&MetricPointPaging_OrderByType_names[45], 10}, 5},
        {{&MetricPointPaging_OrderByType_names[55], 11}, 4},
        {{&MetricPointPaging_OrderByType_names[66], 11}, 3},
};

static const int MetricPointPaging_OrderByType_entries_by_number[] = {
    3,  // 0 -> ORDER_BY_TYPE_UNKNOWN
    1,  // 1 -> ID
    2,  // 2 -> METRIC_TYPE
    6,  // 3 -> STATUS_TYPE
    5,  // 4 -> ROOM_NUMBER
    4,  // 5 -> ROOM_LABEL
    0,  // 6 -> BUILDING_ID
};

const std::string& MetricPointPaging_OrderByType_Name(MetricPointPaging_OrderByType value) {
  static const bool kDummy =
      ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
          MetricPointPaging_OrderByType_entries, MetricPointPaging_OrderByType_entries_by_number,
          7, MetricPointPaging_OrderByType_strings);
  (void)kDummy;

  int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
      MetricPointPaging_OrderByType_entries, MetricPointPaging_OrderByType_entries_by_number, 7,
      value);
  return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString()
                   : MetricPointPaging_OrderByType_strings[idx].get();
}

bool MetricPointPaging_OrderByType_Parse(absl::string_view name, MetricPointPaging_OrderByType* value) {
  int int_value;
  bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
      MetricPointPaging_OrderByType_entries, 7, name, &int_value);
  if (success) {
    *value = static_cast<MetricPointPaging_OrderByType>(int_value);
  }
  return success;
}
#if (__cplusplus < 201703) && \
  (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))

constexpr MetricPointPaging_OrderByType MetricPointPaging::ORDER_BY_TYPE_UNKNOWN;
constexpr MetricPointPaging_OrderByType MetricPointPaging::ID;
constexpr MetricPointPaging_OrderByType MetricPointPaging::METRIC_TYPE;
constexpr MetricPointPaging_OrderByType MetricPointPaging::STATUS_TYPE;
constexpr MetricPointPaging_OrderByType MetricPointPaging::ROOM_NUMBER;
constexpr MetricPointPaging_OrderByType MetricPointPaging::ROOM_LABEL;
constexpr MetricPointPaging_OrderByType MetricPointPaging::BUILDING_ID;
constexpr MetricPointPaging_OrderByType MetricPointPaging::OrderByType_MIN;
constexpr MetricPointPaging_OrderByType MetricPointPaging::OrderByType_MAX;
constexpr int MetricPointPaging::OrderByType_ARRAYSIZE;

#endif  // (__cplusplus < 201703) &&
        // (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
bool MetricPointPaging_DirectionType_IsValid(int value) {
  switch (value) {
    case 0:
    case 1:
    case 2:
      return true;
    default:
      return false;
  }
}
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string>
    MetricPointPaging_DirectionType_strings[3] = {};

static const char MetricPointPaging_DirectionType_names[] = {
    "ASC"
    "DESC"
    "DIRECTION_TYPE_UNKNOWN"
};

static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry MetricPointPaging_DirectionType_entries[] =
    {
        {{&MetricPointPaging_DirectionType_names[0], 3}, 2},
        {{&MetricPointPaging_DirectionType_names[3], 4}, 1},
        {{&MetricPointPaging_DirectionType_names[7], 22}, 0},
};

static const int MetricPointPaging_DirectionType_entries_by_number[] = {
    2,  // 0 -> DIRECTION_TYPE_UNKNOWN
    1,  // 1 -> DESC
    0,  // 2 -> ASC
};

const std::string& MetricPointPaging_DirectionType_Name(MetricPointPaging_DirectionType value) {
  static const bool kDummy =
      ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
          MetricPointPaging_DirectionType_entries, MetricPointPaging_DirectionType_entries_by_number,
          3, MetricPointPaging_DirectionType_strings);
  (void)kDummy;

  int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
      MetricPointPaging_DirectionType_entries, MetricPointPaging_DirectionType_entries_by_number, 3,
      value);
  return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString()
                   : MetricPointPaging_DirectionType_strings[idx].get();
}

bool MetricPointPaging_DirectionType_Parse(absl::string_view name, MetricPointPaging_DirectionType* value) {
  int int_value;
  bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
      MetricPointPaging_DirectionType_entries, 3, name, &int_value);
  if (success) {
    *value = static_cast<MetricPointPaging_DirectionType>(int_value);
  }
  return success;
}
#if (__cplusplus < 201703) && \
  (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))

constexpr MetricPointPaging_DirectionType MetricPointPaging::DIRECTION_TYPE_UNKNOWN;
constexpr MetricPointPaging_DirectionType MetricPointPaging::DESC;
constexpr MetricPointPaging_DirectionType MetricPointPaging::ASC;
constexpr MetricPointPaging_DirectionType MetricPointPaging::DirectionType_MIN;
constexpr MetricPointPaging_DirectionType MetricPointPaging::DirectionType_MAX;
constexpr int MetricPointPaging::DirectionType_ARRAYSIZE;

#endif  // (__cplusplus < 201703) &&
        // (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
// ===================================================================

class GetMetricPointRequest::_Internal {
 public:
};

GetMetricPointRequest::GetMetricPointRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.GetMetricPointRequest)
}
GetMetricPointRequest::GetMetricPointRequest(const GetMetricPointRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  GetMetricPointRequest* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.id_) {}

    , /*decltype(_impl_._cached_size_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  _impl_.id_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.id_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (!from._internal_id().empty()) {
    _this->_impl_.id_.Set(from._internal_id(), _this->GetArenaForAllocation());
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.GetMetricPointRequest)
}

inline void GetMetricPointRequest::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.id_) {}

    , /*decltype(_impl_._cached_size_)*/{}
  };
  _impl_.id_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.id_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
}

GetMetricPointRequest::~GetMetricPointRequest() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.GetMetricPointRequest)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void GetMetricPointRequest::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  _impl_.id_.Destroy();
}

void GetMetricPointRequest::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void GetMetricPointRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.GetMetricPointRequest)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _impl_.id_.ClearToEmpty();
  _internal_metadata_.Clear<std::string>();
}

const char* GetMetricPointRequest::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // string id = 1 [(.google.api.field_behavior) = REQUIRED];
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          auto str = _internal_mutable_id();
          ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(ptr);
          CHK_(::_pbi::VerifyUTF8(str, nullptr));
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* GetMetricPointRequest::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.GetMetricPointRequest)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // string id = 1 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_id().empty()) {
    const std::string& _s = this->_internal_id();
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        _s.data(), static_cast<int>(_s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.GetMetricPointRequest.id");
    target = stream->WriteStringMaybeAliased(1, _s, target);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.GetMetricPointRequest)
  return target;
}

::size_t GetMetricPointRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.GetMetricPointRequest)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // string id = 1 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_id().empty()) {
    total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
                                    this->_internal_id());
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void GetMetricPointRequest::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const GetMetricPointRequest*>(
      &from));
}

void GetMetricPointRequest::MergeFrom(const GetMetricPointRequest& from) {
  GetMetricPointRequest* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.GetMetricPointRequest)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_id().empty()) {
    _this->_internal_set_id(from._internal_id());
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void GetMetricPointRequest::CopyFrom(const GetMetricPointRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.GetMetricPointRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void GetMetricPointRequest::InternalSwap(GetMetricPointRequest* other) {
  using std::swap;
  auto* lhs_arena = GetArenaForAllocation();
  auto* rhs_arena = other->GetArenaForAllocation();
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.id_, lhs_arena,
                                       &other->_impl_.id_, rhs_arena);
}

std::string GetMetricPointRequest::GetTypeName() const {
  return "keyapis.telemetry_control.v1.GetMetricPointRequest";
}

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

class GetMetricPointResponse::_Internal {
 public:
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::GetMetricPointResponse, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::Device_MetricPoint& data(const GetMetricPointResponse* msg);
};

const ::keyapis::telemetry_control::v1::Device_MetricPoint&
GetMetricPointResponse::_Internal::data(const GetMetricPointResponse* msg) {
  return *msg->_impl_.type_.data_;
}
void GetMetricPointResponse::set_allocated_data(::keyapis::telemetry_control::v1::Device_MetricPoint* data) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_type();
  if (data) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
        ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(
                reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(data));
    if (message_arena != submessage_arena) {
      data = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, data, submessage_arena);
    }
    set_has_data();
    _impl_.type_.data_ = data;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.GetMetricPointResponse.data)
}
void GetMetricPointResponse::clear_data() {
  if (type_case() == kData) {
    if (GetArenaForAllocation() == nullptr) {
      delete _impl_.type_.data_;
    }
    clear_has_type();
  }
}
GetMetricPointResponse::GetMetricPointResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.GetMetricPointResponse)
}
GetMetricPointResponse::GetMetricPointResponse(const GetMetricPointResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  GetMetricPointResponse* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.type_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  clear_has_type();
  switch (from.type_case()) {
    case kData: {
      _this->_internal_mutable_data()->::keyapis::telemetry_control::v1::Device_MetricPoint::MergeFrom(
          from._internal_data());
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.GetMetricPointResponse)
}

inline void GetMetricPointResponse::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.type_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_type();
}

GetMetricPointResponse::~GetMetricPointResponse() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.GetMetricPointResponse)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void GetMetricPointResponse::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (has_type()) {
    clear_type();
  }
}

void GetMetricPointResponse::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void GetMetricPointResponse::clear_type() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.GetMetricPointResponse)
  switch (type_case()) {
    case kData: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.type_.data_;
      }
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = TYPE_NOT_SET;
}


void GetMetricPointResponse::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.GetMetricPointResponse)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  clear_type();
  _internal_metadata_.Clear<std::string>();
}

const char* GetMetricPointResponse::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_data(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* GetMetricPointResponse::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.GetMetricPointResponse)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1;
  if (type_case() == kData) {
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(1, _Internal::data(this),
        _Internal::data(this).GetCachedSize(), target, stream);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.GetMetricPointResponse)
  return target;
}

::size_t GetMetricPointResponse::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.GetMetricPointResponse)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  switch (type_case()) {
    // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1;
    case kData: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.type_.data_);
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void GetMetricPointResponse::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const GetMetricPointResponse*>(
      &from));
}

void GetMetricPointResponse::MergeFrom(const GetMetricPointResponse& from) {
  GetMetricPointResponse* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.GetMetricPointResponse)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (from.type_case()) {
    case kData: {
      _this->_internal_mutable_data()->::keyapis::telemetry_control::v1::Device_MetricPoint::MergeFrom(
          from._internal_data());
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void GetMetricPointResponse::CopyFrom(const GetMetricPointResponse& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.GetMetricPointResponse)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void GetMetricPointResponse::InternalSwap(GetMetricPointResponse* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_.type_, other->_impl_.type_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string GetMetricPointResponse::GetTypeName() const {
  return "keyapis.telemetry_control.v1.GetMetricPointResponse";
}

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

class GetMetricPointListRequest::_Internal {
 public:
  using HasBits = decltype(std::declval<GetMetricPointListRequest>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
    8 * PROTOBUF_FIELD_OFFSET(GetMetricPointListRequest, _impl_._has_bits_);
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::GetMetricPointListRequest, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::MetricPointFilter& filter(const GetMetricPointListRequest* msg);
  static void set_has_filter(HasBits* has_bits) {
    (*has_bits)[0] |= 1u;
  }
  static const ::keyapis::telemetry_control::v1::MetricPointPaging& paging(const GetMetricPointListRequest* msg);
};

const ::keyapis::telemetry_control::v1::MetricPointFilter&
GetMetricPointListRequest::_Internal::filter(const GetMetricPointListRequest* msg) {
  return *msg->_impl_.filter_;
}
const ::keyapis::telemetry_control::v1::MetricPointPaging&
GetMetricPointListRequest::_Internal::paging(const GetMetricPointListRequest* msg) {
  return *msg->_impl_.pagination_.paging_;
}
void GetMetricPointListRequest::set_allocated_paging(::keyapis::telemetry_control::v1::MetricPointPaging* paging) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_pagination();
  if (paging) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(paging);
    if (message_arena != submessage_arena) {
      paging = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, paging, submessage_arena);
    }
    set_has_paging();
    _impl_.pagination_.paging_ = paging;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.GetMetricPointListRequest.paging)
}
GetMetricPointListRequest::GetMetricPointListRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.GetMetricPointListRequest)
}
GetMetricPointListRequest::GetMetricPointListRequest(const GetMetricPointListRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  GetMetricPointListRequest* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_._has_bits_){from._impl_._has_bits_}
    , /*decltype(_impl_._cached_size_)*/{}
    , decltype(_impl_.filter_){nullptr}
    , decltype(_impl_.pagination_){}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  if ((from._impl_._has_bits_[0] & 0x00000001u) != 0) {
    _this->_impl_.filter_ = new ::keyapis::telemetry_control::v1::MetricPointFilter(*from._impl_.filter_);
  }
  clear_has_pagination();
  switch (from.pagination_case()) {
    case kPaging: {
      _this->_internal_mutable_paging()->::keyapis::telemetry_control::v1::MetricPointPaging::MergeFrom(
          from._internal_paging());
      break;
    }
    case PAGINATION_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.GetMetricPointListRequest)
}

inline void GetMetricPointListRequest::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_._has_bits_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , decltype(_impl_.filter_){nullptr}
    , decltype(_impl_.pagination_){}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_pagination();
}

GetMetricPointListRequest::~GetMetricPointListRequest() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.GetMetricPointListRequest)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void GetMetricPointListRequest::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (this != internal_default_instance()) delete _impl_.filter_;
  if (has_pagination()) {
    clear_pagination();
  }
}

void GetMetricPointListRequest::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void GetMetricPointListRequest::clear_pagination() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.GetMetricPointListRequest)
  switch (pagination_case()) {
    case kPaging: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.pagination_.paging_;
      }
      break;
    }
    case PAGINATION_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = PAGINATION_NOT_SET;
}


void GetMetricPointListRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.GetMetricPointListRequest)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  cached_has_bits = _impl_._has_bits_[0];
  if (cached_has_bits & 0x00000001u) {
    ABSL_DCHECK(_impl_.filter_ != nullptr);
    _impl_.filter_->Clear();
  }
  clear_pagination();
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<std::string>();
}

const char* GetMetricPointListRequest::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  _Internal::HasBits has_bits{};
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.MetricPointFilter filter = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_filter(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // .keyapis.telemetry_control.v1.MetricPointPaging paging = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          ptr = ctx->ParseMessage(_internal_mutable_paging(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  _impl_._has_bits_.Or(has_bits);
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* GetMetricPointListRequest::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.GetMetricPointListRequest)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _impl_._has_bits_[0];
  // .keyapis.telemetry_control.v1.MetricPointFilter filter = 1;
  if (cached_has_bits & 0x00000001u) {
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(1, _Internal::filter(this),
        _Internal::filter(this).GetCachedSize(), target, stream);
  }

  // .keyapis.telemetry_control.v1.MetricPointPaging paging = 2;
  if (pagination_case() == kPaging) {
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(2, _Internal::paging(this),
        _Internal::paging(this).GetCachedSize(), target, stream);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.GetMetricPointListRequest)
  return target;
}

::size_t GetMetricPointListRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.GetMetricPointListRequest)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // .keyapis.telemetry_control.v1.MetricPointFilter filter = 1;
  cached_has_bits = _impl_._has_bits_[0];
  if (cached_has_bits & 0x00000001u) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
        *_impl_.filter_);
  }

  switch (pagination_case()) {
    // .keyapis.telemetry_control.v1.MetricPointPaging paging = 2;
    case kPaging: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.pagination_.paging_);
      break;
    }
    case PAGINATION_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void GetMetricPointListRequest::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const GetMetricPointListRequest*>(
      &from));
}

void GetMetricPointListRequest::MergeFrom(const GetMetricPointListRequest& from) {
  GetMetricPointListRequest* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.GetMetricPointListRequest)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if ((from._impl_._has_bits_[0] & 0x00000001u) != 0) {
    _this->_internal_mutable_filter()->::keyapis::telemetry_control::v1::MetricPointFilter::MergeFrom(
        from._internal_filter());
  }
  switch (from.pagination_case()) {
    case kPaging: {
      _this->_internal_mutable_paging()->::keyapis::telemetry_control::v1::MetricPointPaging::MergeFrom(
          from._internal_paging());
      break;
    }
    case PAGINATION_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void GetMetricPointListRequest::CopyFrom(const GetMetricPointListRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.GetMetricPointListRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void GetMetricPointListRequest::InternalSwap(GetMetricPointListRequest* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  swap(_impl_.filter_, other->_impl_.filter_);
  swap(_impl_.pagination_, other->_impl_.pagination_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string GetMetricPointListRequest::GetTypeName() const {
  return "keyapis.telemetry_control.v1.GetMetricPointListRequest";
}

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

class MetricPointPaging_ValidationError_LimitInvalid::_Internal {
 public:
};

MetricPointPaging_ValidationError_LimitInvalid::MetricPointPaging_ValidationError_LimitInvalid(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
}
MetricPointPaging_ValidationError_LimitInvalid::MetricPointPaging_ValidationError_LimitInvalid(const MetricPointPaging_ValidationError_LimitInvalid& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(), _impl_(from._impl_) {
  _internal_metadata_.MergeFrom<std::string>(
      from._internal_metadata_);
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
}

inline void MetricPointPaging_ValidationError_LimitInvalid::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      /*decltype(_impl_._cached_size_)*/{}
  };
}

MetricPointPaging_ValidationError_LimitInvalid::~MetricPointPaging_ValidationError_LimitInvalid() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void MetricPointPaging_ValidationError_LimitInvalid::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
}

void MetricPointPaging_ValidationError_LimitInvalid::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void MetricPointPaging_ValidationError_LimitInvalid::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _internal_metadata_.Clear<std::string>();
}

const char* MetricPointPaging_ValidationError_LimitInvalid::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* MetricPointPaging_ValidationError_LimitInvalid::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
  return target;
}

::size_t MetricPointPaging_ValidationError_LimitInvalid::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
  ::size_t total_size = 0;

  ::uint32_t 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())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void MetricPointPaging_ValidationError_LimitInvalid::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const MetricPointPaging_ValidationError_LimitInvalid*>(
      &from));
}

void MetricPointPaging_ValidationError_LimitInvalid::MergeFrom(const MetricPointPaging_ValidationError_LimitInvalid& from) {
  MetricPointPaging_ValidationError_LimitInvalid* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void MetricPointPaging_ValidationError_LimitInvalid::CopyFrom(const MetricPointPaging_ValidationError_LimitInvalid& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

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

std::string MetricPointPaging_ValidationError_LimitInvalid::GetTypeName() const {
  return "keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid";
}

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

class MetricPointPaging_ValidationError_OffsetInvalid::_Internal {
 public:
};

MetricPointPaging_ValidationError_OffsetInvalid::MetricPointPaging_ValidationError_OffsetInvalid(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
}
MetricPointPaging_ValidationError_OffsetInvalid::MetricPointPaging_ValidationError_OffsetInvalid(const MetricPointPaging_ValidationError_OffsetInvalid& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(), _impl_(from._impl_) {
  _internal_metadata_.MergeFrom<std::string>(
      from._internal_metadata_);
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
}

inline void MetricPointPaging_ValidationError_OffsetInvalid::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      /*decltype(_impl_._cached_size_)*/{}
  };
}

MetricPointPaging_ValidationError_OffsetInvalid::~MetricPointPaging_ValidationError_OffsetInvalid() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void MetricPointPaging_ValidationError_OffsetInvalid::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
}

void MetricPointPaging_ValidationError_OffsetInvalid::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void MetricPointPaging_ValidationError_OffsetInvalid::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _internal_metadata_.Clear<std::string>();
}

const char* MetricPointPaging_ValidationError_OffsetInvalid::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* MetricPointPaging_ValidationError_OffsetInvalid::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
  return target;
}

::size_t MetricPointPaging_ValidationError_OffsetInvalid::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
  ::size_t total_size = 0;

  ::uint32_t 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())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void MetricPointPaging_ValidationError_OffsetInvalid::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const MetricPointPaging_ValidationError_OffsetInvalid*>(
      &from));
}

void MetricPointPaging_ValidationError_OffsetInvalid::MergeFrom(const MetricPointPaging_ValidationError_OffsetInvalid& from) {
  MetricPointPaging_ValidationError_OffsetInvalid* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void MetricPointPaging_ValidationError_OffsetInvalid::CopyFrom(const MetricPointPaging_ValidationError_OffsetInvalid& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

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

std::string MetricPointPaging_ValidationError_OffsetInvalid::GetTypeName() const {
  return "keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid";
}

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

class MetricPointPaging_ValidationError::_Internal {
 public:
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_LimitInvalid& limit(const MetricPointPaging_ValidationError* msg);
  static const ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_OffsetInvalid& offset(const MetricPointPaging_ValidationError* msg);
};

const ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_LimitInvalid&
MetricPointPaging_ValidationError::_Internal::limit(const MetricPointPaging_ValidationError* msg) {
  return *msg->_impl_.reason_.limit_;
}
const ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_OffsetInvalid&
MetricPointPaging_ValidationError::_Internal::offset(const MetricPointPaging_ValidationError* msg) {
  return *msg->_impl_.reason_.offset_;
}
void MetricPointPaging_ValidationError::set_allocated_limit(::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_LimitInvalid* limit) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_reason();
  if (limit) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(limit);
    if (message_arena != submessage_arena) {
      limit = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, limit, submessage_arena);
    }
    set_has_limit();
    _impl_.reason_.limit_ = limit;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.limit)
}
void MetricPointPaging_ValidationError::set_allocated_offset(::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_OffsetInvalid* offset) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_reason();
  if (offset) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(offset);
    if (message_arena != submessage_arena) {
      offset = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, offset, submessage_arena);
    }
    set_has_offset();
    _impl_.reason_.offset_ = offset;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.offset)
}
MetricPointPaging_ValidationError::MetricPointPaging_ValidationError(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
}
MetricPointPaging_ValidationError::MetricPointPaging_ValidationError(const MetricPointPaging_ValidationError& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  MetricPointPaging_ValidationError* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.reason_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  clear_has_reason();
  switch (from.reason_case()) {
    case kLimit: {
      _this->_internal_mutable_limit()->::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_LimitInvalid::MergeFrom(
          from._internal_limit());
      break;
    }
    case kOffset: {
      _this->_internal_mutable_offset()->::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_OffsetInvalid::MergeFrom(
          from._internal_offset());
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
}

inline void MetricPointPaging_ValidationError::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.reason_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_reason();
}

MetricPointPaging_ValidationError::~MetricPointPaging_ValidationError() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void MetricPointPaging_ValidationError::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (has_reason()) {
    clear_reason();
  }
}

void MetricPointPaging_ValidationError::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void MetricPointPaging_ValidationError::clear_reason() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
  switch (reason_case()) {
    case kLimit: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.reason_.limit_;
      }
      break;
    }
    case kOffset: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.reason_.offset_;
      }
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = REASON_NOT_SET;
}


void MetricPointPaging_ValidationError::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  clear_reason();
  _internal_metadata_.Clear<std::string>();
}

const char* MetricPointPaging_ValidationError::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid limit = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_limit(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // .keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid offset = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          ptr = ctx->ParseMessage(_internal_mutable_offset(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* MetricPointPaging_ValidationError::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (reason_case()) {
    case kLimit: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(1, _Internal::limit(this),
          _Internal::limit(this).GetCachedSize(), target, stream);
      break;
    }
    case kOffset: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(2, _Internal::offset(this),
          _Internal::offset(this).GetCachedSize(), target, stream);
      break;
    }
    default: ;
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
  return target;
}

::size_t MetricPointPaging_ValidationError::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  switch (reason_case()) {
    // .keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.LimitInvalid limit = 1;
    case kLimit: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.reason_.limit_);
      break;
    }
    // .keyapis.telemetry_control.v1.MetricPointPaging.ValidationError.OffsetInvalid offset = 2;
    case kOffset: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.reason_.offset_);
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void MetricPointPaging_ValidationError::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const MetricPointPaging_ValidationError*>(
      &from));
}

void MetricPointPaging_ValidationError::MergeFrom(const MetricPointPaging_ValidationError& from) {
  MetricPointPaging_ValidationError* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (from.reason_case()) {
    case kLimit: {
      _this->_internal_mutable_limit()->::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_LimitInvalid::MergeFrom(
          from._internal_limit());
      break;
    }
    case kOffset: {
      _this->_internal_mutable_offset()->::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_OffsetInvalid::MergeFrom(
          from._internal_offset());
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void MetricPointPaging_ValidationError::CopyFrom(const MetricPointPaging_ValidationError& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.MetricPointPaging.ValidationError)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void MetricPointPaging_ValidationError::InternalSwap(MetricPointPaging_ValidationError* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_.reason_, other->_impl_.reason_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string MetricPointPaging_ValidationError::GetTypeName() const {
  return "keyapis.telemetry_control.v1.MetricPointPaging.ValidationError";
}

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

class MetricPointPaging::_Internal {
 public:
};

MetricPointPaging::MetricPointPaging(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.MetricPointPaging)
}
MetricPointPaging::MetricPointPaging(const MetricPointPaging& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(), _impl_(from._impl_) {
  _internal_metadata_.MergeFrom<std::string>(
      from._internal_metadata_);
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.MetricPointPaging)
}

inline void MetricPointPaging::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.order_by_type_) { 0 }

    , decltype(_impl_.direction_type_) { 0 }

    , decltype(_impl_.limit_) { 0 }

    , decltype(_impl_.offset_) { 0 }

    , /*decltype(_impl_._cached_size_)*/{}
  };
}

MetricPointPaging::~MetricPointPaging() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.MetricPointPaging)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void MetricPointPaging::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
}

void MetricPointPaging::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void MetricPointPaging::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.MetricPointPaging)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  ::memset(&_impl_.order_by_type_, 0, static_cast<::size_t>(
      reinterpret_cast<char*>(&_impl_.offset_) -
      reinterpret_cast<char*>(&_impl_.order_by_type_)) + sizeof(_impl_.offset_));
  _internal_metadata_.Clear<std::string>();
}

const char* MetricPointPaging::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.MetricPointPaging.OrderByType order_by_type = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
          ::int32_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
          CHK_(ptr);
          _internal_set_order_by_type(static_cast<::keyapis::telemetry_control::v1::MetricPointPaging_OrderByType>(val));
        } else {
          goto handle_unusual;
        }
        continue;
      // .keyapis.telemetry_control.v1.MetricPointPaging.DirectionType direction_type = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
          ::int32_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
          CHK_(ptr);
          _internal_set_direction_type(static_cast<::keyapis::telemetry_control::v1::MetricPointPaging_DirectionType>(val));
        } else {
          goto handle_unusual;
        }
        continue;
      // int32 limit = 3;
      case 3:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
          _impl_.limit_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // int32 offset = 4;
      case 4:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
          _impl_.offset_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* MetricPointPaging::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.MetricPointPaging)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // .keyapis.telemetry_control.v1.MetricPointPaging.OrderByType order_by_type = 1;
  if (this->_internal_order_by_type() != 0) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteEnumToArray(
        1, this->_internal_order_by_type(), target);
  }

  // .keyapis.telemetry_control.v1.MetricPointPaging.DirectionType direction_type = 2;
  if (this->_internal_direction_type() != 0) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteEnumToArray(
        2, this->_internal_direction_type(), target);
  }

  // int32 limit = 3;
  if (this->_internal_limit() != 0) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteInt32ToArray(
        3, this->_internal_limit(), target);
  }

  // int32 offset = 4;
  if (this->_internal_offset() != 0) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteInt32ToArray(
        4, this->_internal_offset(), target);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.MetricPointPaging)
  return target;
}

::size_t MetricPointPaging::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.MetricPointPaging)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // .keyapis.telemetry_control.v1.MetricPointPaging.OrderByType order_by_type = 1;
  if (this->_internal_order_by_type() != 0) {
    total_size += 1 +
                  ::_pbi::WireFormatLite::EnumSize(this->_internal_order_by_type());
  }

  // .keyapis.telemetry_control.v1.MetricPointPaging.DirectionType direction_type = 2;
  if (this->_internal_direction_type() != 0) {
    total_size += 1 +
                  ::_pbi::WireFormatLite::EnumSize(this->_internal_direction_type());
  }

  // int32 limit = 3;
  if (this->_internal_limit() != 0) {
    total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(
        this->_internal_limit());
  }

  // int32 offset = 4;
  if (this->_internal_offset() != 0) {
    total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(
        this->_internal_offset());
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void MetricPointPaging::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const MetricPointPaging*>(
      &from));
}

void MetricPointPaging::MergeFrom(const MetricPointPaging& from) {
  MetricPointPaging* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.MetricPointPaging)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if (from._internal_order_by_type() != 0) {
    _this->_internal_set_order_by_type(from._internal_order_by_type());
  }
  if (from._internal_direction_type() != 0) {
    _this->_internal_set_direction_type(from._internal_direction_type());
  }
  if (from._internal_limit() != 0) {
    _this->_internal_set_limit(from._internal_limit());
  }
  if (from._internal_offset() != 0) {
    _this->_internal_set_offset(from._internal_offset());
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void MetricPointPaging::CopyFrom(const MetricPointPaging& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.MetricPointPaging)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void MetricPointPaging::InternalSwap(MetricPointPaging* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::PROTOBUF_NAMESPACE_ID::internal::memswap<
      PROTOBUF_FIELD_OFFSET(MetricPointPaging, _impl_.offset_)
      + sizeof(MetricPointPaging::_impl_.offset_)
      - PROTOBUF_FIELD_OFFSET(MetricPointPaging, _impl_.order_by_type_)>(
          reinterpret_cast<char*>(&_impl_.order_by_type_),
          reinterpret_cast<char*>(&other->_impl_.order_by_type_));
}

std::string MetricPointPaging::GetTypeName() const {
  return "keyapis.telemetry_control.v1.MetricPointPaging";
}

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

class MetricPointFilter_ValidationError::_Internal {
 public:
};

MetricPointFilter_ValidationError::MetricPointFilter_ValidationError(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
}
MetricPointFilter_ValidationError::MetricPointFilter_ValidationError(const MetricPointFilter_ValidationError& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  MetricPointFilter_ValidationError* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.path_) {}

    , decltype(_impl_.message_) {}

    , /*decltype(_impl_._cached_size_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  _impl_.path_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.path_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (!from._internal_path().empty()) {
    _this->_impl_.path_.Set(from._internal_path(), _this->GetArenaForAllocation());
  }
  _impl_.message_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.message_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (!from._internal_message().empty()) {
    _this->_impl_.message_.Set(from._internal_message(), _this->GetArenaForAllocation());
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
}

inline void MetricPointFilter_ValidationError::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.path_) {}

    , decltype(_impl_.message_) {}

    , /*decltype(_impl_._cached_size_)*/{}
  };
  _impl_.path_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.path_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  _impl_.message_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.message_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
}

MetricPointFilter_ValidationError::~MetricPointFilter_ValidationError() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void MetricPointFilter_ValidationError::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  _impl_.path_.Destroy();
  _impl_.message_.Destroy();
}

void MetricPointFilter_ValidationError::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void MetricPointFilter_ValidationError::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _impl_.path_.ClearToEmpty();
  _impl_.message_.ClearToEmpty();
  _internal_metadata_.Clear<std::string>();
}

const char* MetricPointFilter_ValidationError::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // string path = 1 [(.google.api.field_behavior) = REQUIRED];
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          auto str = _internal_mutable_path();
          ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(ptr);
          CHK_(::_pbi::VerifyUTF8(str, nullptr));
        } else {
          goto handle_unusual;
        }
        continue;
      // string message = 2 [(.google.api.field_behavior) = REQUIRED];
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          auto str = _internal_mutable_message();
          ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(ptr);
          CHK_(::_pbi::VerifyUTF8(str, nullptr));
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* MetricPointFilter_ValidationError::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // string path = 1 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_path().empty()) {
    const std::string& _s = this->_internal_path();
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        _s.data(), static_cast<int>(_s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.MetricPointFilter.ValidationError.path");
    target = stream->WriteStringMaybeAliased(1, _s, target);
  }

  // string message = 2 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_message().empty()) {
    const std::string& _s = this->_internal_message();
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        _s.data(), static_cast<int>(_s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.MetricPointFilter.ValidationError.message");
    target = stream->WriteStringMaybeAliased(2, _s, target);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
  return target;
}

::size_t MetricPointFilter_ValidationError::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // string path = 1 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_path().empty()) {
    total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
                                    this->_internal_path());
  }

  // string message = 2 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_message().empty()) {
    total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
                                    this->_internal_message());
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void MetricPointFilter_ValidationError::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const MetricPointFilter_ValidationError*>(
      &from));
}

void MetricPointFilter_ValidationError::MergeFrom(const MetricPointFilter_ValidationError& from) {
  MetricPointFilter_ValidationError* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_path().empty()) {
    _this->_internal_set_path(from._internal_path());
  }
  if (!from._internal_message().empty()) {
    _this->_internal_set_message(from._internal_message());
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void MetricPointFilter_ValidationError::CopyFrom(const MetricPointFilter_ValidationError& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.MetricPointFilter.ValidationError)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void MetricPointFilter_ValidationError::InternalSwap(MetricPointFilter_ValidationError* other) {
  using std::swap;
  auto* lhs_arena = GetArenaForAllocation();
  auto* rhs_arena = other->GetArenaForAllocation();
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.path_, lhs_arena,
                                       &other->_impl_.path_, rhs_arena);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.message_, lhs_arena,
                                       &other->_impl_.message_, rhs_arena);
}

std::string MetricPointFilter_ValidationError::GetTypeName() const {
  return "keyapis.telemetry_control.v1.MetricPointFilter.ValidationError";
}

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

class MetricPointFilter::_Internal {
 public:
};

MetricPointFilter::MetricPointFilter(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.MetricPointFilter)
}
MetricPointFilter::MetricPointFilter(const MetricPointFilter& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  MetricPointFilter* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.device_metric_point_metric_types_) { from._internal_device_metric_point_metric_types() }
    , /*decltype(_impl_._device_metric_point_metric_types_cached_byte_size_)*/ { 0 }

    , decltype(_impl_.device_metric_point_status_types_) { from._internal_device_metric_point_status_types() }
    , /*decltype(_impl_._device_metric_point_status_types_cached_byte_size_)*/ { 0 }

    , decltype(_impl_.room_numbers_){from._impl_.room_numbers_}
    , decltype(_impl_.room_labels_){from._impl_.room_labels_}
    , decltype(_impl_.building_ids_) { from._impl_.building_ids_ }
    ,/* _impl_._building_ids_cached_byte_size_ = */ { 0 }

    , decltype(_impl_.fias_ids_){from._impl_.fias_ids_}
    , decltype(_impl_.device_ids_) { from._impl_.device_ids_ }
    ,/* _impl_._device_ids_cached_byte_size_ = */ { 0 }

    , decltype(_impl_.device_serial_numbers_){from._impl_.device_serial_numbers_}
    , decltype(_impl_.orpons_) { from._impl_.orpons_ }
    ,/* _impl_._orpons_cached_byte_size_ = */ { 0 }

    , /*decltype(_impl_._cached_size_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.MetricPointFilter)
}

inline void MetricPointFilter::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.device_metric_point_metric_types_) { arena }
    , /*decltype(_impl_._device_metric_point_metric_types_cached_byte_size_)*/ { 0 }

    , decltype(_impl_.device_metric_point_status_types_) { arena }
    , /*decltype(_impl_._device_metric_point_status_types_cached_byte_size_)*/ { 0 }

    , decltype(_impl_.room_numbers_){arena}
    , decltype(_impl_.room_labels_){arena}
    , decltype(_impl_.building_ids_) { arena }
    ,/* _impl_._building_ids_cached_byte_size_ = */ { 0 }

    , decltype(_impl_.fias_ids_){arena}
    , decltype(_impl_.device_ids_) { arena }
    ,/* _impl_._device_ids_cached_byte_size_ = */ { 0 }

    , decltype(_impl_.device_serial_numbers_){arena}
    , decltype(_impl_.orpons_) { arena }
    ,/* _impl_._orpons_cached_byte_size_ = */ { 0 }

    , /*decltype(_impl_._cached_size_)*/{}
  };
}

MetricPointFilter::~MetricPointFilter() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.MetricPointFilter)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void MetricPointFilter::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  _internal_mutable_device_metric_point_metric_types()->~RepeatedField();
  _internal_mutable_device_metric_point_status_types()->~RepeatedField();
  _internal_mutable_room_numbers()->~RepeatedPtrField();
  _internal_mutable_room_labels()->~RepeatedPtrField();
  _impl_.building_ids_.~RepeatedField();
  _internal_mutable_fias_ids()->~RepeatedPtrField();
  _impl_.device_ids_.~RepeatedField();
  _internal_mutable_device_serial_numbers()->~RepeatedPtrField();
  _impl_.orpons_.~RepeatedField();
}

void MetricPointFilter::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void MetricPointFilter::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.MetricPointFilter)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _internal_mutable_device_metric_point_metric_types()->Clear();
  _internal_mutable_device_metric_point_status_types()->Clear();
  _internal_mutable_room_numbers()->Clear();
  _internal_mutable_room_labels()->Clear();
  _internal_mutable_building_ids()->Clear();
  _internal_mutable_fias_ids()->Clear();
  _internal_mutable_device_ids()->Clear();
  _internal_mutable_device_serial_numbers()->Clear();
  _internal_mutable_orpons()->Clear();
  _internal_metadata_.Clear<std::string>();
}

const char* MetricPointFilter::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // repeated .keyapis.telemetry_control.v1.Device.MetricPoint.MetricType device_metric_point_metric_types = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedEnumParser(_internal_mutable_device_metric_point_metric_types(), ptr, ctx);
          CHK_(ptr);
        } else if (static_cast<::uint8_t>(tag) == 8) {
          ::int32_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
          CHK_(ptr);
          _internal_add_device_metric_point_metric_types(static_cast<::keyapis::telemetry_control::v1::Device_MetricPoint_MetricType>(val));
        } else {
          goto handle_unusual;
        }
        continue;
      // repeated .keyapis.telemetry_control.v1.Device.MetricPoint.StatusType device_metric_point_status_types = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedEnumParser(_internal_mutable_device_metric_point_status_types(), ptr, ctx);
          CHK_(ptr);
        } else if (static_cast<::uint8_t>(tag) == 16) {
          ::int32_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
          CHK_(ptr);
          _internal_add_device_metric_point_status_types(static_cast<::keyapis::telemetry_control::v1::Device_MetricPoint_StatusType>(val));
        } else {
          goto handle_unusual;
        }
        continue;
      // repeated string room_numbers = 3;
      case 3:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 26)) {
          ptr -= 1;
          do {
            ptr += 1;
            auto str = _internal_add_room_numbers();
            ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
            CHK_(ptr);
            CHK_(::_pbi::VerifyUTF8(str, nullptr));
            if (!ctx->DataAvailable(ptr)) break;
          } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<26>(ptr));
        } else {
          goto handle_unusual;
        }
        continue;
      // repeated string room_labels = 4;
      case 4:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 34)) {
          ptr -= 1;
          do {
            ptr += 1;
            auto str = _internal_add_room_labels();
            ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
            CHK_(ptr);
            CHK_(::_pbi::VerifyUTF8(str, nullptr));
            if (!ctx->DataAvailable(ptr)) break;
          } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<34>(ptr));
        } else {
          goto handle_unusual;
        }
        continue;
      // repeated int32 building_ids = 5;
      case 5:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 42)) {
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedInt32Parser(_internal_mutable_building_ids(), ptr, ctx);
          CHK_(ptr);
        } else if (static_cast<::uint8_t>(tag) == 40) {
          _internal_add_building_ids(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr));
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // repeated string fias_ids = 6;
      case 6:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 50)) {
          ptr -= 1;
          do {
            ptr += 1;
            auto str = _internal_add_fias_ids();
            ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
            CHK_(ptr);
            CHK_(::_pbi::VerifyUTF8(str, nullptr));
            if (!ctx->DataAvailable(ptr)) break;
          } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<50>(ptr));
        } else {
          goto handle_unusual;
        }
        continue;
      // repeated int32 device_ids = 7;
      case 7:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 58)) {
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedInt32Parser(_internal_mutable_device_ids(), ptr, ctx);
          CHK_(ptr);
        } else if (static_cast<::uint8_t>(tag) == 56) {
          _internal_add_device_ids(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr));
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // repeated string device_serial_numbers = 8;
      case 8:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 66)) {
          ptr -= 1;
          do {
            ptr += 1;
            auto str = _internal_add_device_serial_numbers();
            ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
            CHK_(ptr);
            CHK_(::_pbi::VerifyUTF8(str, nullptr));
            if (!ctx->DataAvailable(ptr)) break;
          } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<66>(ptr));
        } else {
          goto handle_unusual;
        }
        continue;
      // repeated int64 orpons = 9;
      case 9:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 74)) {
          ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedInt64Parser(_internal_mutable_orpons(), ptr, ctx);
          CHK_(ptr);
        } else if (static_cast<::uint8_t>(tag) == 72) {
          _internal_add_orpons(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr));
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* MetricPointFilter::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.MetricPointFilter)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // repeated .keyapis.telemetry_control.v1.Device.MetricPoint.MetricType device_metric_point_metric_types = 1;
  {
    int byte_size = _impl_._device_metric_point_metric_types_cached_byte_size_.Get();
    if (byte_size > 0) {
      target = stream->WriteEnumPacked(1, _internal_device_metric_point_metric_types(),
                                       byte_size, target);
    }
  }

  // repeated .keyapis.telemetry_control.v1.Device.MetricPoint.StatusType device_metric_point_status_types = 2;
  {
    int byte_size = _impl_._device_metric_point_status_types_cached_byte_size_.Get();
    if (byte_size > 0) {
      target = stream->WriteEnumPacked(2, _internal_device_metric_point_status_types(),
                                       byte_size, target);
    }
  }

  // repeated string room_numbers = 3;
  for (int i = 0, n = this->_internal_room_numbers_size(); i < n; ++i) {
    const auto& s = this->_internal_room_numbers(i);
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        s.data(), static_cast<int>(s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.MetricPointFilter.room_numbers");
    target = stream->WriteString(3, s, target);
  }

  // repeated string room_labels = 4;
  for (int i = 0, n = this->_internal_room_labels_size(); i < n; ++i) {
    const auto& s = this->_internal_room_labels(i);
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        s.data(), static_cast<int>(s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.MetricPointFilter.room_labels");
    target = stream->WriteString(4, s, target);
  }

  // repeated int32 building_ids = 5;
  {
    int byte_size = _impl_._building_ids_cached_byte_size_.Get();
    if (byte_size > 0) {
      target = stream->WriteInt32Packed(5, _internal_building_ids(),
                                                 byte_size, target);
    }
  }

  // repeated string fias_ids = 6;
  for (int i = 0, n = this->_internal_fias_ids_size(); i < n; ++i) {
    const auto& s = this->_internal_fias_ids(i);
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        s.data(), static_cast<int>(s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.MetricPointFilter.fias_ids");
    target = stream->WriteString(6, s, target);
  }

  // repeated int32 device_ids = 7;
  {
    int byte_size = _impl_._device_ids_cached_byte_size_.Get();
    if (byte_size > 0) {
      target = stream->WriteInt32Packed(7, _internal_device_ids(),
                                                 byte_size, target);
    }
  }

  // repeated string device_serial_numbers = 8;
  for (int i = 0, n = this->_internal_device_serial_numbers_size(); i < n; ++i) {
    const auto& s = this->_internal_device_serial_numbers(i);
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        s.data(), static_cast<int>(s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.MetricPointFilter.device_serial_numbers");
    target = stream->WriteString(8, s, target);
  }

  // repeated int64 orpons = 9;
  {
    int byte_size = _impl_._orpons_cached_byte_size_.Get();
    if (byte_size > 0) {
      target = stream->WriteInt64Packed(9, _internal_orpons(),
                                                 byte_size, target);
    }
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.MetricPointFilter)
  return target;
}

::size_t MetricPointFilter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.MetricPointFilter)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // repeated .keyapis.telemetry_control.v1.Device.MetricPoint.MetricType device_metric_point_metric_types = 1;
  {
    std::size_t data_size = 0;
    auto count = static_cast<std::size_t>(this->_internal_device_metric_point_metric_types_size());

    for (std::size_t i = 0; i < count; ++i) {
      data_size += ::_pbi::WireFormatLite::EnumSize(
          this->_internal_device_metric_point_metric_types(static_cast<int>(i)));
    }
    total_size += data_size;
    if (data_size > 0) {
      total_size += 1;
      total_size += ::_pbi::WireFormatLite::Int32Size(
          static_cast<int32_t>(data_size));
    }
    _impl_._device_metric_point_metric_types_cached_byte_size_.Set(::_pbi::ToCachedSize(data_size));
  }

  // repeated .keyapis.telemetry_control.v1.Device.MetricPoint.StatusType device_metric_point_status_types = 2;
  {
    std::size_t data_size = 0;
    auto count = static_cast<std::size_t>(this->_internal_device_metric_point_status_types_size());

    for (std::size_t i = 0; i < count; ++i) {
      data_size += ::_pbi::WireFormatLite::EnumSize(
          this->_internal_device_metric_point_status_types(static_cast<int>(i)));
    }
    total_size += data_size;
    if (data_size > 0) {
      total_size += 1;
      total_size += ::_pbi::WireFormatLite::Int32Size(
          static_cast<int32_t>(data_size));
    }
    _impl_._device_metric_point_status_types_cached_byte_size_.Set(::_pbi::ToCachedSize(data_size));
  }

  // repeated string room_numbers = 3;
  total_size += 1 * ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(_internal_room_numbers().size());
  for (int i = 0, n = _internal_room_numbers().size(); i < n; ++i) {
    total_size += ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        _internal_room_numbers().Get(i));
  }

  // repeated string room_labels = 4;
  total_size += 1 * ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(_internal_room_labels().size());
  for (int i = 0, n = _internal_room_labels().size(); i < n; ++i) {
    total_size += ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        _internal_room_labels().Get(i));
  }

  // repeated int32 building_ids = 5;
  {
    std::size_t data_size = ::_pbi::WireFormatLite::Int32Size(
        this->_internal_building_ids())
    ;
    _impl_._building_ids_cached_byte_size_.Set(::_pbi::ToCachedSize(data_size));
    std::size_t tag_size = data_size == 0
        ? 0
        : 1 + ::_pbi::WireFormatLite::Int32Size(
                            static_cast<int32_t>(data_size))
    ;
    total_size += tag_size + data_size;
  }

  // repeated string fias_ids = 6;
  total_size += 1 * ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(_internal_fias_ids().size());
  for (int i = 0, n = _internal_fias_ids().size(); i < n; ++i) {
    total_size += ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        _internal_fias_ids().Get(i));
  }

  // repeated int32 device_ids = 7;
  {
    std::size_t data_size = ::_pbi::WireFormatLite::Int32Size(
        this->_internal_device_ids())
    ;
    _impl_._device_ids_cached_byte_size_.Set(::_pbi::ToCachedSize(data_size));
    std::size_t tag_size = data_size == 0
        ? 0
        : 1 + ::_pbi::WireFormatLite::Int32Size(
                            static_cast<int32_t>(data_size))
    ;
    total_size += tag_size + data_size;
  }

  // repeated string device_serial_numbers = 8;
  total_size += 1 * ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(_internal_device_serial_numbers().size());
  for (int i = 0, n = _internal_device_serial_numbers().size(); i < n; ++i) {
    total_size += ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
        _internal_device_serial_numbers().Get(i));
  }

  // repeated int64 orpons = 9;
  {
    std::size_t data_size = ::_pbi::WireFormatLite::Int64Size(
        this->_internal_orpons())
    ;
    _impl_._orpons_cached_byte_size_.Set(::_pbi::ToCachedSize(data_size));
    std::size_t tag_size = data_size == 0
        ? 0
        : 1 + ::_pbi::WireFormatLite::Int32Size(
                            static_cast<int32_t>(data_size))
    ;
    total_size += tag_size + data_size;
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void MetricPointFilter::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const MetricPointFilter*>(
      &from));
}

void MetricPointFilter::MergeFrom(const MetricPointFilter& from) {
  MetricPointFilter* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.MetricPointFilter)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  _this->_internal_mutable_device_metric_point_metric_types()->MergeFrom(from._internal_device_metric_point_metric_types());
  _this->_internal_mutable_device_metric_point_status_types()->MergeFrom(from._internal_device_metric_point_status_types());
  _this->_internal_mutable_room_numbers()->MergeFrom(from._internal_room_numbers());
  _this->_internal_mutable_room_labels()->MergeFrom(from._internal_room_labels());
  _this->_impl_.building_ids_.MergeFrom(from._impl_.building_ids_);
  _this->_internal_mutable_fias_ids()->MergeFrom(from._internal_fias_ids());
  _this->_impl_.device_ids_.MergeFrom(from._impl_.device_ids_);
  _this->_internal_mutable_device_serial_numbers()->MergeFrom(from._internal_device_serial_numbers());
  _this->_impl_.orpons_.MergeFrom(from._impl_.orpons_);
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void MetricPointFilter::CopyFrom(const MetricPointFilter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.MetricPointFilter)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void MetricPointFilter::InternalSwap(MetricPointFilter* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  _internal_mutable_device_metric_point_metric_types()->InternalSwap(
      other->_internal_mutable_device_metric_point_metric_types());
  _internal_mutable_device_metric_point_status_types()->InternalSwap(
      other->_internal_mutable_device_metric_point_status_types());
  _internal_mutable_room_numbers()->InternalSwap(
      other->_internal_mutable_room_numbers());
  _internal_mutable_room_labels()->InternalSwap(
      other->_internal_mutable_room_labels());
  _impl_.building_ids_.InternalSwap(&other->_impl_.building_ids_);
  _internal_mutable_fias_ids()->InternalSwap(
      other->_internal_mutable_fias_ids());
  _impl_.device_ids_.InternalSwap(&other->_impl_.device_ids_);
  _internal_mutable_device_serial_numbers()->InternalSwap(
      other->_internal_mutable_device_serial_numbers());
  _impl_.orpons_.InternalSwap(&other->_impl_.orpons_);
}

std::string MetricPointFilter::GetTypeName() const {
  return "keyapis.telemetry_control.v1.MetricPointFilter";
}

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

class GetMetricPointListResponse_Error::_Internal {
 public:
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError& metric_point_filter_validation(const GetMetricPointListResponse_Error* msg);
  static const ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError& metric_point_paging_validation(const GetMetricPointListResponse_Error* msg);
};

const ::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError&
GetMetricPointListResponse_Error::_Internal::metric_point_filter_validation(const GetMetricPointListResponse_Error* msg) {
  return *msg->_impl_.reason_.metric_point_filter_validation_;
}
const ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError&
GetMetricPointListResponse_Error::_Internal::metric_point_paging_validation(const GetMetricPointListResponse_Error* msg) {
  return *msg->_impl_.reason_.metric_point_paging_validation_;
}
void GetMetricPointListResponse_Error::set_allocated_metric_point_filter_validation(::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError* metric_point_filter_validation) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_reason();
  if (metric_point_filter_validation) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(metric_point_filter_validation);
    if (message_arena != submessage_arena) {
      metric_point_filter_validation = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, metric_point_filter_validation, submessage_arena);
    }
    set_has_metric_point_filter_validation();
    _impl_.reason_.metric_point_filter_validation_ = metric_point_filter_validation;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error.metric_point_filter_validation)
}
void GetMetricPointListResponse_Error::set_allocated_metric_point_paging_validation(::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError* metric_point_paging_validation) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_reason();
  if (metric_point_paging_validation) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(metric_point_paging_validation);
    if (message_arena != submessage_arena) {
      metric_point_paging_validation = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, metric_point_paging_validation, submessage_arena);
    }
    set_has_metric_point_paging_validation();
    _impl_.reason_.metric_point_paging_validation_ = metric_point_paging_validation;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error.metric_point_paging_validation)
}
GetMetricPointListResponse_Error::GetMetricPointListResponse_Error(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
}
GetMetricPointListResponse_Error::GetMetricPointListResponse_Error(const GetMetricPointListResponse_Error& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  GetMetricPointListResponse_Error* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.reason_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  clear_has_reason();
  switch (from.reason_case()) {
    case kMetricPointFilterValidation: {
      _this->_internal_mutable_metric_point_filter_validation()->::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError::MergeFrom(
          from._internal_metric_point_filter_validation());
      break;
    }
    case kMetricPointPagingValidation: {
      _this->_internal_mutable_metric_point_paging_validation()->::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError::MergeFrom(
          from._internal_metric_point_paging_validation());
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
}

inline void GetMetricPointListResponse_Error::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.reason_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_reason();
}

GetMetricPointListResponse_Error::~GetMetricPointListResponse_Error() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void GetMetricPointListResponse_Error::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (has_reason()) {
    clear_reason();
  }
}

void GetMetricPointListResponse_Error::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void GetMetricPointListResponse_Error::clear_reason() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
  switch (reason_case()) {
    case kMetricPointFilterValidation: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.reason_.metric_point_filter_validation_;
      }
      break;
    }
    case kMetricPointPagingValidation: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.reason_.metric_point_paging_validation_;
      }
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = REASON_NOT_SET;
}


void GetMetricPointListResponse_Error::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  clear_reason();
  _internal_metadata_.Clear<std::string>();
}

const char* GetMetricPointListResponse_Error::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.MetricPointFilter.ValidationError metric_point_filter_validation = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_metric_point_filter_validation(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // .keyapis.telemetry_control.v1.MetricPointPaging.ValidationError metric_point_paging_validation = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          ptr = ctx->ParseMessage(_internal_mutable_metric_point_paging_validation(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* GetMetricPointListResponse_Error::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (reason_case()) {
    case kMetricPointFilterValidation: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(1, _Internal::metric_point_filter_validation(this),
          _Internal::metric_point_filter_validation(this).GetCachedSize(), target, stream);
      break;
    }
    case kMetricPointPagingValidation: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(2, _Internal::metric_point_paging_validation(this),
          _Internal::metric_point_paging_validation(this).GetCachedSize(), target, stream);
      break;
    }
    default: ;
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
  return target;
}

::size_t GetMetricPointListResponse_Error::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  switch (reason_case()) {
    // .keyapis.telemetry_control.v1.MetricPointFilter.ValidationError metric_point_filter_validation = 1;
    case kMetricPointFilterValidation: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.reason_.metric_point_filter_validation_);
      break;
    }
    // .keyapis.telemetry_control.v1.MetricPointPaging.ValidationError metric_point_paging_validation = 2;
    case kMetricPointPagingValidation: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.reason_.metric_point_paging_validation_);
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void GetMetricPointListResponse_Error::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const GetMetricPointListResponse_Error*>(
      &from));
}

void GetMetricPointListResponse_Error::MergeFrom(const GetMetricPointListResponse_Error& from) {
  GetMetricPointListResponse_Error* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (from.reason_case()) {
    case kMetricPointFilterValidation: {
      _this->_internal_mutable_metric_point_filter_validation()->::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError::MergeFrom(
          from._internal_metric_point_filter_validation());
      break;
    }
    case kMetricPointPagingValidation: {
      _this->_internal_mutable_metric_point_paging_validation()->::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError::MergeFrom(
          from._internal_metric_point_paging_validation());
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void GetMetricPointListResponse_Error::CopyFrom(const GetMetricPointListResponse_Error& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.GetMetricPointListResponse.Error)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void GetMetricPointListResponse_Error::InternalSwap(GetMetricPointListResponse_Error* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_.reason_, other->_impl_.reason_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string GetMetricPointListResponse_Error::GetTypeName() const {
  return "keyapis.telemetry_control.v1.GetMetricPointListResponse.Error";
}

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

class GetMetricPointListResponse::_Internal {
 public:
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::GetMetricPointListResponse, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::Device_MetricPoint& data(const GetMetricPointListResponse* msg);
  static const ::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error& error(const GetMetricPointListResponse* msg);
};

const ::keyapis::telemetry_control::v1::Device_MetricPoint&
GetMetricPointListResponse::_Internal::data(const GetMetricPointListResponse* msg) {
  return *msg->_impl_.type_.data_;
}
const ::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error&
GetMetricPointListResponse::_Internal::error(const GetMetricPointListResponse* msg) {
  return *msg->_impl_.type_.error_;
}
void GetMetricPointListResponse::set_allocated_data(::keyapis::telemetry_control::v1::Device_MetricPoint* data) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_type();
  if (data) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
        ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(
                reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(data));
    if (message_arena != submessage_arena) {
      data = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, data, submessage_arena);
    }
    set_has_data();
    _impl_.type_.data_ = data;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.GetMetricPointListResponse.data)
}
void GetMetricPointListResponse::clear_data() {
  if (type_case() == kData) {
    if (GetArenaForAllocation() == nullptr) {
      delete _impl_.type_.data_;
    }
    clear_has_type();
  }
}
void GetMetricPointListResponse::set_allocated_error(::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error* error) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_type();
  if (error) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(error);
    if (message_arena != submessage_arena) {
      error = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, error, submessage_arena);
    }
    set_has_error();
    _impl_.type_.error_ = error;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.GetMetricPointListResponse.error)
}
GetMetricPointListResponse::GetMetricPointListResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.GetMetricPointListResponse)
}
GetMetricPointListResponse::GetMetricPointListResponse(const GetMetricPointListResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  GetMetricPointListResponse* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.type_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  clear_has_type();
  switch (from.type_case()) {
    case kData: {
      _this->_internal_mutable_data()->::keyapis::telemetry_control::v1::Device_MetricPoint::MergeFrom(
          from._internal_data());
      break;
    }
    case kError: {
      _this->_internal_mutable_error()->::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error::MergeFrom(
          from._internal_error());
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.GetMetricPointListResponse)
}

inline void GetMetricPointListResponse::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.type_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_type();
}

GetMetricPointListResponse::~GetMetricPointListResponse() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.GetMetricPointListResponse)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void GetMetricPointListResponse::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (has_type()) {
    clear_type();
  }
}

void GetMetricPointListResponse::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void GetMetricPointListResponse::clear_type() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.GetMetricPointListResponse)
  switch (type_case()) {
    case kData: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.type_.data_;
      }
      break;
    }
    case kError: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.type_.error_;
      }
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = TYPE_NOT_SET;
}


void GetMetricPointListResponse::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.GetMetricPointListResponse)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  clear_type();
  _internal_metadata_.Clear<std::string>();
}

const char* GetMetricPointListResponse::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_data(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // .keyapis.telemetry_control.v1.GetMetricPointListResponse.Error error = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          ptr = ctx->ParseMessage(_internal_mutable_error(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* GetMetricPointListResponse::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.GetMetricPointListResponse)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (type_case()) {
    case kData: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(1, _Internal::data(this),
          _Internal::data(this).GetCachedSize(), target, stream);
      break;
    }
    case kError: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(2, _Internal::error(this),
          _Internal::error(this).GetCachedSize(), target, stream);
      break;
    }
    default: ;
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.GetMetricPointListResponse)
  return target;
}

::size_t GetMetricPointListResponse::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.GetMetricPointListResponse)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  switch (type_case()) {
    // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1;
    case kData: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.type_.data_);
      break;
    }
    // .keyapis.telemetry_control.v1.GetMetricPointListResponse.Error error = 2;
    case kError: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.type_.error_);
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void GetMetricPointListResponse::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const GetMetricPointListResponse*>(
      &from));
}

void GetMetricPointListResponse::MergeFrom(const GetMetricPointListResponse& from) {
  GetMetricPointListResponse* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.GetMetricPointListResponse)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (from.type_case()) {
    case kData: {
      _this->_internal_mutable_data()->::keyapis::telemetry_control::v1::Device_MetricPoint::MergeFrom(
          from._internal_data());
      break;
    }
    case kError: {
      _this->_internal_mutable_error()->::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error::MergeFrom(
          from._internal_error());
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void GetMetricPointListResponse::CopyFrom(const GetMetricPointListResponse& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.GetMetricPointListResponse)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void GetMetricPointListResponse::InternalSwap(GetMetricPointListResponse* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_.type_, other->_impl_.type_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string GetMetricPointListResponse::GetTypeName() const {
  return "keyapis.telemetry_control.v1.GetMetricPointListResponse";
}

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

class GetMetricPointCountRequest::_Internal {
 public:
  using HasBits = decltype(std::declval<GetMetricPointCountRequest>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
    8 * PROTOBUF_FIELD_OFFSET(GetMetricPointCountRequest, _impl_._has_bits_);
  static const ::keyapis::telemetry_control::v1::MetricPointFilter& filter(const GetMetricPointCountRequest* msg);
  static void set_has_filter(HasBits* has_bits) {
    (*has_bits)[0] |= 1u;
  }
};

const ::keyapis::telemetry_control::v1::MetricPointFilter&
GetMetricPointCountRequest::_Internal::filter(const GetMetricPointCountRequest* msg) {
  return *msg->_impl_.filter_;
}
GetMetricPointCountRequest::GetMetricPointCountRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
}
GetMetricPointCountRequest::GetMetricPointCountRequest(const GetMetricPointCountRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  GetMetricPointCountRequest* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_._has_bits_){from._impl_._has_bits_}
    , /*decltype(_impl_._cached_size_)*/{}
    , decltype(_impl_.filter_){nullptr}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  if ((from._impl_._has_bits_[0] & 0x00000001u) != 0) {
    _this->_impl_.filter_ = new ::keyapis::telemetry_control::v1::MetricPointFilter(*from._impl_.filter_);
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
}

inline void GetMetricPointCountRequest::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_._has_bits_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , decltype(_impl_.filter_){nullptr}
  };
}

GetMetricPointCountRequest::~GetMetricPointCountRequest() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void GetMetricPointCountRequest::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (this != internal_default_instance()) delete _impl_.filter_;
}

void GetMetricPointCountRequest::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void GetMetricPointCountRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  cached_has_bits = _impl_._has_bits_[0];
  if (cached_has_bits & 0x00000001u) {
    ABSL_DCHECK(_impl_.filter_ != nullptr);
    _impl_.filter_->Clear();
  }
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<std::string>();
}

const char* GetMetricPointCountRequest::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  _Internal::HasBits has_bits{};
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.MetricPointFilter filter = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_filter(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  _impl_._has_bits_.Or(has_bits);
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* GetMetricPointCountRequest::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _impl_._has_bits_[0];
  // .keyapis.telemetry_control.v1.MetricPointFilter filter = 1;
  if (cached_has_bits & 0x00000001u) {
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(1, _Internal::filter(this),
        _Internal::filter(this).GetCachedSize(), target, stream);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
  return target;
}

::size_t GetMetricPointCountRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // .keyapis.telemetry_control.v1.MetricPointFilter filter = 1;
  cached_has_bits = _impl_._has_bits_[0];
  if (cached_has_bits & 0x00000001u) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
        *_impl_.filter_);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void GetMetricPointCountRequest::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const GetMetricPointCountRequest*>(
      &from));
}

void GetMetricPointCountRequest::MergeFrom(const GetMetricPointCountRequest& from) {
  GetMetricPointCountRequest* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if ((from._impl_._has_bits_[0] & 0x00000001u) != 0) {
    _this->_internal_mutable_filter()->::keyapis::telemetry_control::v1::MetricPointFilter::MergeFrom(
        from._internal_filter());
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void GetMetricPointCountRequest::CopyFrom(const GetMetricPointCountRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.GetMetricPointCountRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void GetMetricPointCountRequest::InternalSwap(GetMetricPointCountRequest* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  swap(_impl_.filter_, other->_impl_.filter_);
}

std::string GetMetricPointCountRequest::GetTypeName() const {
  return "keyapis.telemetry_control.v1.GetMetricPointCountRequest";
}

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

class GetMetricPointCountResponse_Error::_Internal {
 public:
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError& metric_point_filter_validation(const GetMetricPointCountResponse_Error* msg);
};

const ::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError&
GetMetricPointCountResponse_Error::_Internal::metric_point_filter_validation(const GetMetricPointCountResponse_Error* msg) {
  return *msg->_impl_.reason_.metric_point_filter_validation_;
}
void GetMetricPointCountResponse_Error::set_allocated_metric_point_filter_validation(::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError* metric_point_filter_validation) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_reason();
  if (metric_point_filter_validation) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(metric_point_filter_validation);
    if (message_arena != submessage_arena) {
      metric_point_filter_validation = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, metric_point_filter_validation, submessage_arena);
    }
    set_has_metric_point_filter_validation();
    _impl_.reason_.metric_point_filter_validation_ = metric_point_filter_validation;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error.metric_point_filter_validation)
}
GetMetricPointCountResponse_Error::GetMetricPointCountResponse_Error(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
}
GetMetricPointCountResponse_Error::GetMetricPointCountResponse_Error(const GetMetricPointCountResponse_Error& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  GetMetricPointCountResponse_Error* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.reason_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  clear_has_reason();
  switch (from.reason_case()) {
    case kMetricPointFilterValidation: {
      _this->_internal_mutable_metric_point_filter_validation()->::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError::MergeFrom(
          from._internal_metric_point_filter_validation());
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
}

inline void GetMetricPointCountResponse_Error::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.reason_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_reason();
}

GetMetricPointCountResponse_Error::~GetMetricPointCountResponse_Error() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void GetMetricPointCountResponse_Error::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (has_reason()) {
    clear_reason();
  }
}

void GetMetricPointCountResponse_Error::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void GetMetricPointCountResponse_Error::clear_reason() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
  switch (reason_case()) {
    case kMetricPointFilterValidation: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.reason_.metric_point_filter_validation_;
      }
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = REASON_NOT_SET;
}


void GetMetricPointCountResponse_Error::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  clear_reason();
  _internal_metadata_.Clear<std::string>();
}

const char* GetMetricPointCountResponse_Error::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.MetricPointFilter.ValidationError metric_point_filter_validation = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_metric_point_filter_validation(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* GetMetricPointCountResponse_Error::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // .keyapis.telemetry_control.v1.MetricPointFilter.ValidationError metric_point_filter_validation = 1;
  if (reason_case() == kMetricPointFilterValidation) {
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(1, _Internal::metric_point_filter_validation(this),
        _Internal::metric_point_filter_validation(this).GetCachedSize(), target, stream);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
  return target;
}

::size_t GetMetricPointCountResponse_Error::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  switch (reason_case()) {
    // .keyapis.telemetry_control.v1.MetricPointFilter.ValidationError metric_point_filter_validation = 1;
    case kMetricPointFilterValidation: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.reason_.metric_point_filter_validation_);
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void GetMetricPointCountResponse_Error::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const GetMetricPointCountResponse_Error*>(
      &from));
}

void GetMetricPointCountResponse_Error::MergeFrom(const GetMetricPointCountResponse_Error& from) {
  GetMetricPointCountResponse_Error* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (from.reason_case()) {
    case kMetricPointFilterValidation: {
      _this->_internal_mutable_metric_point_filter_validation()->::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError::MergeFrom(
          from._internal_metric_point_filter_validation());
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void GetMetricPointCountResponse_Error::CopyFrom(const GetMetricPointCountResponse_Error& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void GetMetricPointCountResponse_Error::InternalSwap(GetMetricPointCountResponse_Error* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_.reason_, other->_impl_.reason_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string GetMetricPointCountResponse_Error::GetTypeName() const {
  return "keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error";
}

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

class GetMetricPointCountResponse::_Internal {
 public:
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::GetMetricPointCountResponse, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error& error(const GetMetricPointCountResponse* msg);
};

const ::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error&
GetMetricPointCountResponse::_Internal::error(const GetMetricPointCountResponse* msg) {
  return *msg->_impl_.type_.error_;
}
void GetMetricPointCountResponse::set_allocated_error(::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error* error) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_type();
  if (error) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(error);
    if (message_arena != submessage_arena) {
      error = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, error, submessage_arena);
    }
    set_has_error();
    _impl_.type_.error_ = error;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.GetMetricPointCountResponse.error)
}
GetMetricPointCountResponse::GetMetricPointCountResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
}
GetMetricPointCountResponse::GetMetricPointCountResponse(const GetMetricPointCountResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  GetMetricPointCountResponse* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.type_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  clear_has_type();
  switch (from.type_case()) {
    case kData: {
      _this->_internal_set_data(from._internal_data());
      break;
    }
    case kError: {
      _this->_internal_mutable_error()->::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error::MergeFrom(
          from._internal_error());
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
}

inline void GetMetricPointCountResponse::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.type_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_type();
}

GetMetricPointCountResponse::~GetMetricPointCountResponse() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void GetMetricPointCountResponse::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (has_type()) {
    clear_type();
  }
}

void GetMetricPointCountResponse::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void GetMetricPointCountResponse::clear_type() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
  switch (type_case()) {
    case kData: {
      // No need to clear
      break;
    }
    case kError: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.type_.error_;
      }
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = TYPE_NOT_SET;
}


void GetMetricPointCountResponse::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  clear_type();
  _internal_metadata_.Clear<std::string>();
}

const char* GetMetricPointCountResponse::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // int32 data = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
          _internal_set_data(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr));
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // .keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error error = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          ptr = ctx->ParseMessage(_internal_mutable_error(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* GetMetricPointCountResponse::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (type_case()) {
    case kData: {
      target = stream->EnsureSpace(target);
      target = ::_pbi::WireFormatLite::WriteInt32ToArray(
          1, this->_internal_data(), target);
      break;
    }
    case kError: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(2, _Internal::error(this),
          _Internal::error(this).GetCachedSize(), target, stream);
      break;
    }
    default: ;
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
  return target;
}

::size_t GetMetricPointCountResponse::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  switch (type_case()) {
    // int32 data = 1;
    case kData: {
      total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(
          this->_internal_data());
      break;
    }
    // .keyapis.telemetry_control.v1.GetMetricPointCountResponse.Error error = 2;
    case kError: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.type_.error_);
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void GetMetricPointCountResponse::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const GetMetricPointCountResponse*>(
      &from));
}

void GetMetricPointCountResponse::MergeFrom(const GetMetricPointCountResponse& from) {
  GetMetricPointCountResponse* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (from.type_case()) {
    case kData: {
      _this->_internal_set_data(from._internal_data());
      break;
    }
    case kError: {
      _this->_internal_mutable_error()->::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error::MergeFrom(
          from._internal_error());
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void GetMetricPointCountResponse::CopyFrom(const GetMetricPointCountResponse& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.GetMetricPointCountResponse)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void GetMetricPointCountResponse::InternalSwap(GetMetricPointCountResponse* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_.type_, other->_impl_.type_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string GetMetricPointCountResponse::GetTypeName() const {
  return "keyapis.telemetry_control.v1.GetMetricPointCountResponse";
}

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

class PostMetricPointRequest::_Internal {
 public:
  using HasBits = decltype(std::declval<PostMetricPointRequest>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
    8 * PROTOBUF_FIELD_OFFSET(PostMetricPointRequest, _impl_._has_bits_);
  static const ::keyapis::telemetry_control::v1::Device_MetricPoint& data(const PostMetricPointRequest* msg);
  static void set_has_data(HasBits* has_bits) {
    (*has_bits)[0] |= 1u;
  }
};

const ::keyapis::telemetry_control::v1::Device_MetricPoint&
PostMetricPointRequest::_Internal::data(const PostMetricPointRequest* msg) {
  return *msg->_impl_.data_;
}
void PostMetricPointRequest::clear_data() {
  if (_impl_.data_ != nullptr) _impl_.data_->Clear();
  _impl_._has_bits_[0] &= ~0x00000001u;
}
PostMetricPointRequest::PostMetricPointRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.PostMetricPointRequest)
}
PostMetricPointRequest::PostMetricPointRequest(const PostMetricPointRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  PostMetricPointRequest* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_._has_bits_){from._impl_._has_bits_}
    , /*decltype(_impl_._cached_size_)*/{}
    , decltype(_impl_.data_){nullptr}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  if ((from._impl_._has_bits_[0] & 0x00000001u) != 0) {
    _this->_impl_.data_ = new ::keyapis::telemetry_control::v1::Device_MetricPoint(*from._impl_.data_);
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.PostMetricPointRequest)
}

inline void PostMetricPointRequest::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_._has_bits_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , decltype(_impl_.data_){nullptr}
  };
}

PostMetricPointRequest::~PostMetricPointRequest() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.PostMetricPointRequest)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void PostMetricPointRequest::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (this != internal_default_instance()) delete _impl_.data_;
}

void PostMetricPointRequest::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void PostMetricPointRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.PostMetricPointRequest)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  cached_has_bits = _impl_._has_bits_[0];
  if (cached_has_bits & 0x00000001u) {
    ABSL_DCHECK(_impl_.data_ != nullptr);
    _impl_.data_->Clear();
  }
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<std::string>();
}

const char* PostMetricPointRequest::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  _Internal::HasBits has_bits{};
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1 [(.google.api.field_behavior) = REQUIRED];
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_data(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  _impl_._has_bits_.Or(has_bits);
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* PostMetricPointRequest::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.PostMetricPointRequest)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _impl_._has_bits_[0];
  // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1 [(.google.api.field_behavior) = REQUIRED];
  if (cached_has_bits & 0x00000001u) {
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(1, _Internal::data(this),
        _Internal::data(this).GetCachedSize(), target, stream);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.PostMetricPointRequest)
  return target;
}

::size_t PostMetricPointRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.PostMetricPointRequest)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1 [(.google.api.field_behavior) = REQUIRED];
  cached_has_bits = _impl_._has_bits_[0];
  if (cached_has_bits & 0x00000001u) {
    total_size += 1 +
      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
        *_impl_.data_);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void PostMetricPointRequest::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const PostMetricPointRequest*>(
      &from));
}

void PostMetricPointRequest::MergeFrom(const PostMetricPointRequest& from) {
  PostMetricPointRequest* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.PostMetricPointRequest)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if ((from._impl_._has_bits_[0] & 0x00000001u) != 0) {
    _this->_internal_mutable_data()->::keyapis::telemetry_control::v1::Device_MetricPoint::MergeFrom(
        from._internal_data());
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void PostMetricPointRequest::CopyFrom(const PostMetricPointRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.PostMetricPointRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void PostMetricPointRequest::InternalSwap(PostMetricPointRequest* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  swap(_impl_.data_, other->_impl_.data_);
}

std::string PostMetricPointRequest::GetTypeName() const {
  return "keyapis.telemetry_control.v1.PostMetricPointRequest";
}

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

class PostMetricPointResponse_Error::_Internal {
 public:
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::PostMetricPointResponse_Error, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::ValidationError& validation(const PostMetricPointResponse_Error* msg);
};

const ::keyapis::telemetry_control::v1::ValidationError&
PostMetricPointResponse_Error::_Internal::validation(const PostMetricPointResponse_Error* msg) {
  return *msg->_impl_.reason_.validation_;
}
void PostMetricPointResponse_Error::set_allocated_validation(::keyapis::telemetry_control::v1::ValidationError* validation) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_reason();
  if (validation) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(validation);
    if (message_arena != submessage_arena) {
      validation = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, validation, submessage_arena);
    }
    set_has_validation();
    _impl_.reason_.validation_ = validation;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.PostMetricPointResponse.Error.validation)
}
PostMetricPointResponse_Error::PostMetricPointResponse_Error(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
}
PostMetricPointResponse_Error::PostMetricPointResponse_Error(const PostMetricPointResponse_Error& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  PostMetricPointResponse_Error* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.reason_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  clear_has_reason();
  switch (from.reason_case()) {
    case kValidation: {
      _this->_internal_mutable_validation()->::keyapis::telemetry_control::v1::ValidationError::MergeFrom(
          from._internal_validation());
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
}

inline void PostMetricPointResponse_Error::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.reason_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_reason();
}

PostMetricPointResponse_Error::~PostMetricPointResponse_Error() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void PostMetricPointResponse_Error::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (has_reason()) {
    clear_reason();
  }
}

void PostMetricPointResponse_Error::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void PostMetricPointResponse_Error::clear_reason() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
  switch (reason_case()) {
    case kValidation: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.reason_.validation_;
      }
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = REASON_NOT_SET;
}


void PostMetricPointResponse_Error::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  clear_reason();
  _internal_metadata_.Clear<std::string>();
}

const char* PostMetricPointResponse_Error::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.ValidationError validation = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_validation(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* PostMetricPointResponse_Error::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // .keyapis.telemetry_control.v1.ValidationError validation = 1;
  if (reason_case() == kValidation) {
    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
      InternalWriteMessage(1, _Internal::validation(this),
        _Internal::validation(this).GetCachedSize(), target, stream);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
  return target;
}

::size_t PostMetricPointResponse_Error::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  switch (reason_case()) {
    // .keyapis.telemetry_control.v1.ValidationError validation = 1;
    case kValidation: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.reason_.validation_);
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void PostMetricPointResponse_Error::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const PostMetricPointResponse_Error*>(
      &from));
}

void PostMetricPointResponse_Error::MergeFrom(const PostMetricPointResponse_Error& from) {
  PostMetricPointResponse_Error* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (from.reason_case()) {
    case kValidation: {
      _this->_internal_mutable_validation()->::keyapis::telemetry_control::v1::ValidationError::MergeFrom(
          from._internal_validation());
      break;
    }
    case REASON_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void PostMetricPointResponse_Error::CopyFrom(const PostMetricPointResponse_Error& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.PostMetricPointResponse.Error)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void PostMetricPointResponse_Error::InternalSwap(PostMetricPointResponse_Error* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_.reason_, other->_impl_.reason_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string PostMetricPointResponse_Error::GetTypeName() const {
  return "keyapis.telemetry_control.v1.PostMetricPointResponse.Error";
}

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

class PostMetricPointResponse::_Internal {
 public:
  static constexpr ::int32_t kOneofCaseOffset =
    PROTOBUF_FIELD_OFFSET(::keyapis::telemetry_control::v1::PostMetricPointResponse, _impl_._oneof_case_);
  static const ::keyapis::telemetry_control::v1::Device_MetricPoint& data(const PostMetricPointResponse* msg);
  static const ::keyapis::telemetry_control::v1::PostMetricPointResponse_Error& error(const PostMetricPointResponse* msg);
};

const ::keyapis::telemetry_control::v1::Device_MetricPoint&
PostMetricPointResponse::_Internal::data(const PostMetricPointResponse* msg) {
  return *msg->_impl_.type_.data_;
}
const ::keyapis::telemetry_control::v1::PostMetricPointResponse_Error&
PostMetricPointResponse::_Internal::error(const PostMetricPointResponse* msg) {
  return *msg->_impl_.type_.error_;
}
void PostMetricPointResponse::set_allocated_data(::keyapis::telemetry_control::v1::Device_MetricPoint* data) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_type();
  if (data) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
        ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(
                reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(data));
    if (message_arena != submessage_arena) {
      data = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, data, submessage_arena);
    }
    set_has_data();
    _impl_.type_.data_ = data;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.PostMetricPointResponse.data)
}
void PostMetricPointResponse::clear_data() {
  if (type_case() == kData) {
    if (GetArenaForAllocation() == nullptr) {
      delete _impl_.type_.data_;
    }
    clear_has_type();
  }
}
void PostMetricPointResponse::set_allocated_error(::keyapis::telemetry_control::v1::PostMetricPointResponse_Error* error) {
  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
  clear_type();
  if (error) {
    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
      ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(error);
    if (message_arena != submessage_arena) {
      error = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
          message_arena, error, submessage_arena);
    }
    set_has_error();
    _impl_.type_.error_ = error;
  }
  // @@protoc_insertion_point(field_set_allocated:keyapis.telemetry_control.v1.PostMetricPointResponse.error)
}
PostMetricPointResponse::PostMetricPointResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.PostMetricPointResponse)
}
PostMetricPointResponse::PostMetricPointResponse(const PostMetricPointResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  PostMetricPointResponse* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.type_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  clear_has_type();
  switch (from.type_case()) {
    case kData: {
      _this->_internal_mutable_data()->::keyapis::telemetry_control::v1::Device_MetricPoint::MergeFrom(
          from._internal_data());
      break;
    }
    case kError: {
      _this->_internal_mutable_error()->::keyapis::telemetry_control::v1::PostMetricPointResponse_Error::MergeFrom(
          from._internal_error());
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.PostMetricPointResponse)
}

inline void PostMetricPointResponse::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.type_){}
    , /*decltype(_impl_._cached_size_)*/{}
    , /*decltype(_impl_._oneof_case_)*/{}
  };
  clear_has_type();
}

PostMetricPointResponse::~PostMetricPointResponse() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.PostMetricPointResponse)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void PostMetricPointResponse::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  if (has_type()) {
    clear_type();
  }
}

void PostMetricPointResponse::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void PostMetricPointResponse::clear_type() {
// @@protoc_insertion_point(one_of_clear_start:keyapis.telemetry_control.v1.PostMetricPointResponse)
  switch (type_case()) {
    case kData: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.type_.data_;
      }
      break;
    }
    case kError: {
      if (GetArenaForAllocation() == nullptr) {
        delete _impl_.type_.error_;
      }
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = TYPE_NOT_SET;
}


void PostMetricPointResponse::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.PostMetricPointResponse)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  clear_type();
  _internal_metadata_.Clear<std::string>();
}

const char* PostMetricPointResponse::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1;
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          ptr = ctx->ParseMessage(_internal_mutable_data(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      // .keyapis.telemetry_control.v1.PostMetricPointResponse.Error error = 2;
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          ptr = ctx->ParseMessage(_internal_mutable_error(), ptr);
          CHK_(ptr);
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* PostMetricPointResponse::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.PostMetricPointResponse)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (type_case()) {
    case kData: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(1, _Internal::data(this),
          _Internal::data(this).GetCachedSize(), target, stream);
      break;
    }
    case kError: {
      target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
        InternalWriteMessage(2, _Internal::error(this),
          _Internal::error(this).GetCachedSize(), target, stream);
      break;
    }
    default: ;
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.PostMetricPointResponse)
  return target;
}

::size_t PostMetricPointResponse::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.PostMetricPointResponse)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  switch (type_case()) {
    // .keyapis.telemetry_control.v1.Device.MetricPoint data = 1;
    case kData: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.type_.data_);
      break;
    }
    // .keyapis.telemetry_control.v1.PostMetricPointResponse.Error error = 2;
    case kError: {
      total_size += 1 +
        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
          *_impl_.type_.error_);
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void PostMetricPointResponse::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const PostMetricPointResponse*>(
      &from));
}

void PostMetricPointResponse::MergeFrom(const PostMetricPointResponse& from) {
  PostMetricPointResponse* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.PostMetricPointResponse)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  switch (from.type_case()) {
    case kData: {
      _this->_internal_mutable_data()->::keyapis::telemetry_control::v1::Device_MetricPoint::MergeFrom(
          from._internal_data());
      break;
    }
    case kError: {
      _this->_internal_mutable_error()->::keyapis::telemetry_control::v1::PostMetricPointResponse_Error::MergeFrom(
          from._internal_error());
      break;
    }
    case TYPE_NOT_SET: {
      break;
    }
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void PostMetricPointResponse::CopyFrom(const PostMetricPointResponse& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.PostMetricPointResponse)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void PostMetricPointResponse::InternalSwap(PostMetricPointResponse* other) {
  using std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_.type_, other->_impl_.type_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

std::string PostMetricPointResponse::GetTypeName() const {
  return "keyapis.telemetry_control.v1.PostMetricPointResponse";
}

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

class DeleteMetricPointRequest::_Internal {
 public:
};

DeleteMetricPointRequest::DeleteMetricPointRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
}
DeleteMetricPointRequest::DeleteMetricPointRequest(const DeleteMetricPointRequest& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  DeleteMetricPointRequest* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.id_) {}

    , /*decltype(_impl_._cached_size_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  _impl_.id_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.id_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (!from._internal_id().empty()) {
    _this->_impl_.id_.Set(from._internal_id(), _this->GetArenaForAllocation());
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
}

inline void DeleteMetricPointRequest::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.id_) {}

    , /*decltype(_impl_._cached_size_)*/{}
  };
  _impl_.id_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.id_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
}

DeleteMetricPointRequest::~DeleteMetricPointRequest() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void DeleteMetricPointRequest::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  _impl_.id_.Destroy();
}

void DeleteMetricPointRequest::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void DeleteMetricPointRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _impl_.id_.ClearToEmpty();
  _internal_metadata_.Clear<std::string>();
}

const char* DeleteMetricPointRequest::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // string id = 1 [(.google.api.field_behavior) = REQUIRED];
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          auto str = _internal_mutable_id();
          ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(ptr);
          CHK_(::_pbi::VerifyUTF8(str, nullptr));
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* DeleteMetricPointRequest::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // string id = 1 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_id().empty()) {
    const std::string& _s = this->_internal_id();
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        _s.data(), static_cast<int>(_s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.DeleteMetricPointRequest.id");
    target = stream->WriteStringMaybeAliased(1, _s, target);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
  return target;
}

::size_t DeleteMetricPointRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // string id = 1 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_id().empty()) {
    total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
                                    this->_internal_id());
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void DeleteMetricPointRequest::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const DeleteMetricPointRequest*>(
      &from));
}

void DeleteMetricPointRequest::MergeFrom(const DeleteMetricPointRequest& from) {
  DeleteMetricPointRequest* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_id().empty()) {
    _this->_internal_set_id(from._internal_id());
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void DeleteMetricPointRequest::CopyFrom(const DeleteMetricPointRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.DeleteMetricPointRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void DeleteMetricPointRequest::InternalSwap(DeleteMetricPointRequest* other) {
  using std::swap;
  auto* lhs_arena = GetArenaForAllocation();
  auto* rhs_arena = other->GetArenaForAllocation();
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.id_, lhs_arena,
                                       &other->_impl_.id_, rhs_arena);
}

std::string DeleteMetricPointRequest::GetTypeName() const {
  return "keyapis.telemetry_control.v1.DeleteMetricPointRequest";
}

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

class DeleteMetricPointResponse::_Internal {
 public:
};

DeleteMetricPointResponse::DeleteMetricPointResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
}
DeleteMetricPointResponse::DeleteMetricPointResponse(const DeleteMetricPointResponse& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(), _impl_(from._impl_) {
  _internal_metadata_.MergeFrom<std::string>(
      from._internal_metadata_);
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
}

inline void DeleteMetricPointResponse::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      /*decltype(_impl_._cached_size_)*/{}
  };
}

DeleteMetricPointResponse::~DeleteMetricPointResponse() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void DeleteMetricPointResponse::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
}

void DeleteMetricPointResponse::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void DeleteMetricPointResponse::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _internal_metadata_.Clear<std::string>();
}

const char* DeleteMetricPointResponse::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* DeleteMetricPointResponse::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
  return target;
}

::size_t DeleteMetricPointResponse::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
  ::size_t total_size = 0;

  ::uint32_t 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())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void DeleteMetricPointResponse::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const DeleteMetricPointResponse*>(
      &from));
}

void DeleteMetricPointResponse::MergeFrom(const DeleteMetricPointResponse& from) {
  DeleteMetricPointResponse* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void DeleteMetricPointResponse::CopyFrom(const DeleteMetricPointResponse& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.DeleteMetricPointResponse)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

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

std::string DeleteMetricPointResponse::GetTypeName() const {
  return "keyapis.telemetry_control.v1.DeleteMetricPointResponse";
}

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

class ValidationError::_Internal {
 public:
};

ValidationError::ValidationError(::PROTOBUF_NAMESPACE_ID::Arena* arena)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena) {
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:keyapis.telemetry_control.v1.ValidationError)
}
ValidationError::ValidationError(const ValidationError& from)
  : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
  ValidationError* const _this = this; (void)_this;
  new (&_impl_) Impl_{
      decltype(_impl_.path_) {}

    , decltype(_impl_.message_) {}

    , /*decltype(_impl_._cached_size_)*/{}};

  _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
  _impl_.path_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.path_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (!from._internal_path().empty()) {
    _this->_impl_.path_.Set(from._internal_path(), _this->GetArenaForAllocation());
  }
  _impl_.message_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.message_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  if (!from._internal_message().empty()) {
    _this->_impl_.message_.Set(from._internal_message(), _this->GetArenaForAllocation());
  }
  // @@protoc_insertion_point(copy_constructor:keyapis.telemetry_control.v1.ValidationError)
}

inline void ValidationError::SharedCtor(::_pb::Arena* arena) {
  (void)arena;
  new (&_impl_) Impl_{
      decltype(_impl_.path_) {}

    , decltype(_impl_.message_) {}

    , /*decltype(_impl_._cached_size_)*/{}
  };
  _impl_.path_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.path_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
  _impl_.message_.InitDefault();
  #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
        _impl_.message_.Set("", GetArenaForAllocation());
  #endif  // PROTOBUF_FORCE_COPY_DEFAULT_STRING
}

ValidationError::~ValidationError() {
  // @@protoc_insertion_point(destructor:keyapis.telemetry_control.v1.ValidationError)
  if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
  (void)arena;
    return;
  }
  SharedDtor();
}

inline void ValidationError::SharedDtor() {
  ABSL_DCHECK(GetArenaForAllocation() == nullptr);
  _impl_.path_.Destroy();
  _impl_.message_.Destroy();
}

void ValidationError::SetCachedSize(int size) const {
  _impl_._cached_size_.Set(size);
}

void ValidationError::Clear() {
// @@protoc_insertion_point(message_clear_start:keyapis.telemetry_control.v1.ValidationError)
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _impl_.path_.ClearToEmpty();
  _impl_.message_.ClearToEmpty();
  _internal_metadata_.Clear<std::string>();
}

const char* ValidationError::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
  while (!ctx->Done(&ptr)) {
    ::uint32_t tag;
    ptr = ::_pbi::ReadTag(ptr, &tag);
    switch (tag >> 3) {
      // string path = 1 [(.google.api.field_behavior) = REQUIRED];
      case 1:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
          auto str = _internal_mutable_path();
          ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(ptr);
          CHK_(::_pbi::VerifyUTF8(str, nullptr));
        } else {
          goto handle_unusual;
        }
        continue;
      // string message = 2 [(.google.api.field_behavior) = REQUIRED];
      case 2:
        if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
          auto str = _internal_mutable_message();
          ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
          CHK_(ptr);
          CHK_(::_pbi::VerifyUTF8(str, nullptr));
        } else {
          goto handle_unusual;
        }
        continue;
      default:
        goto handle_unusual;
    }  // switch
  handle_unusual:
    if ((tag == 0) || ((tag & 7) == 4)) {
      CHK_(ptr);
      ctx->SetLastTag(tag);
      goto message_done;
    }
    ptr = UnknownFieldParse(
        tag,
        _internal_metadata_.mutable_unknown_fields<std::string>(),
        ptr, ctx);
    CHK_(ptr != nullptr);
  }  // while
message_done:
  return ptr;
failure:
  ptr = nullptr;
  goto message_done;
#undef CHK_
}

::uint8_t* ValidationError::_InternalSerialize(
    ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
  // @@protoc_insertion_point(serialize_to_array_start:keyapis.telemetry_control.v1.ValidationError)
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  // string path = 1 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_path().empty()) {
    const std::string& _s = this->_internal_path();
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        _s.data(), static_cast<int>(_s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.ValidationError.path");
    target = stream->WriteStringMaybeAliased(1, _s, target);
  }

  // string message = 2 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_message().empty()) {
    const std::string& _s = this->_internal_message();
    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
        _s.data(), static_cast<int>(_s.length()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, "keyapis.telemetry_control.v1.ValidationError.message");
    target = stream->WriteStringMaybeAliased(2, _s, target);
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
        static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:keyapis.telemetry_control.v1.ValidationError)
  return target;
}

::size_t ValidationError::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:keyapis.telemetry_control.v1.ValidationError)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  // string path = 1 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_path().empty()) {
    total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
                                    this->_internal_path());
  }

  // string message = 2 [(.google.api.field_behavior) = REQUIRED];
  if (!this->_internal_message().empty()) {
    total_size += 1 + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
                                    this->_internal_message());
  }

  if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
    total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
  }
  int cached_size = ::_pbi::ToCachedSize(total_size);
  SetCachedSize(cached_size);
  return total_size;
}

void ValidationError::CheckTypeAndMergeFrom(
    const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
  MergeFrom(*::_pbi::DownCast<const ValidationError*>(
      &from));
}

void ValidationError::MergeFrom(const ValidationError& from) {
  ValidationError* const _this = this;
  // @@protoc_insertion_point(class_specific_merge_from_start:keyapis.telemetry_control.v1.ValidationError)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  if (!from._internal_path().empty()) {
    _this->_internal_set_path(from._internal_path());
  }
  if (!from._internal_message().empty()) {
    _this->_internal_set_message(from._internal_message());
  }
  _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
}

void ValidationError::CopyFrom(const ValidationError& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:keyapis.telemetry_control.v1.ValidationError)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void ValidationError::InternalSwap(ValidationError* other) {
  using std::swap;
  auto* lhs_arena = GetArenaForAllocation();
  auto* rhs_arena = other->GetArenaForAllocation();
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.path_, lhs_arena,
                                       &other->_impl_.path_, rhs_arena);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.message_, lhs_arena,
                                       &other->_impl_.message_, rhs_arena);
}

std::string ValidationError::GetTypeName() const {
  return "keyapis.telemetry_control.v1.ValidationError";
}

// @@protoc_insertion_point(namespace_scope)
}  // namespace v1
}  // namespace telemetry_control
}  // namespace keyapis
PROTOBUF_NAMESPACE_OPEN
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::GetMetricPointRequest*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::GetMetricPointRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::GetMetricPointRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::GetMetricPointResponse*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::GetMetricPointResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::GetMetricPointResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::GetMetricPointListRequest*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::GetMetricPointListRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::GetMetricPointListRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_LimitInvalid*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_LimitInvalid >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_LimitInvalid >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_OffsetInvalid*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_OffsetInvalid >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError_OffsetInvalid >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::MetricPointPaging_ValidationError >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::MetricPointPaging*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::MetricPointPaging >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::MetricPointPaging >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::MetricPointFilter_ValidationError >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::MetricPointFilter*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::MetricPointFilter >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::MetricPointFilter >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::GetMetricPointListResponse_Error >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::GetMetricPointListResponse*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::GetMetricPointListResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::GetMetricPointListResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::GetMetricPointCountRequest*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::GetMetricPointCountRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::GetMetricPointCountRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::GetMetricPointCountResponse_Error >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::GetMetricPointCountResponse*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::GetMetricPointCountResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::GetMetricPointCountResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::PostMetricPointRequest*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::PostMetricPointRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::PostMetricPointRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::PostMetricPointResponse_Error*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::PostMetricPointResponse_Error >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::PostMetricPointResponse_Error >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::PostMetricPointResponse*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::PostMetricPointResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::PostMetricPointResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::DeleteMetricPointRequest*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::DeleteMetricPointRequest >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::DeleteMetricPointRequest >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::DeleteMetricPointResponse*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::DeleteMetricPointResponse >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::DeleteMetricPointResponse >(arena);
}
template<> PROTOBUF_NOINLINE ::keyapis::telemetry_control::v1::ValidationError*
Arena::CreateMaybeMessage< ::keyapis::telemetry_control::v1::ValidationError >(Arena* arena) {
  return Arena::CreateMessageInternal< ::keyapis::telemetry_control::v1::ValidationError >(arena);
}
PROTOBUF_NAMESPACE_CLOSE
// @@protoc_insertion_point(global_scope)
#include "google/protobuf/port_undef.inc"
