| // This file is auto-generated by generate_proto_header.py, do not edit |
| |
| // clang-format off |
| |
| #include "resultstore.pb.h" |
| |
| #include "output_stream.h" |
| #include "proto.h" |
| |
| namespace rs { |
| namespace google { |
| namespace api { |
| void Http::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : rules_) { |
| if (has_rules_) { |
| WriteLengthDelimited(output__, 1, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_fully_decode_reserved_expansion_) { |
| WriteVarint32(output__, 2, fully_decode_reserved_expansion_); |
| } |
| } |
| |
| size_t Http::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : rules_) { |
| if (has_rules_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_fully_decode_reserved_expansion_) { |
| size += VarintSizeBool(fully_decode_reserved_expansion_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Http::Clear() { |
| if (has_rules_) { |
| rules_.clear(); |
| has_rules_ = false; |
| } |
| fully_decode_reserved_expansion_ = false; |
| } |
| |
| void Http::add_rules(const ::rs::google::api::HttpRule& value) { |
| has_rules_ = true; |
| rules_.push_back(value); |
| } |
| void Http::set_fully_decode_reserved_expansion(const bool& value) { |
| has_fully_decode_reserved_expansion_ = true; |
| fully_decode_reserved_expansion_ = value; |
| } |
| |
| void CustomHttpPattern::SerializeToOstream(OutputStream* output__) const { |
| if (has_kind_) { |
| WriteString(output__, 1, kind_); |
| } |
| if (has_path_) { |
| WriteString(output__, 2, path_); |
| } |
| } |
| |
| size_t CustomHttpPattern::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_kind_) { |
| size += StringSize(kind_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_path_) { |
| size += StringSize(path_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void CustomHttpPattern::Clear() { |
| kind_.clear(); |
| path_.clear(); |
| } |
| |
| void CustomHttpPattern::set_kind(const std::string& value) { |
| has_kind_ = true; |
| kind_ = value; |
| } |
| |
| void CustomHttpPattern::set_path(const std::string& value) { |
| has_path_ = true; |
| path_ = value; |
| } |
| |
| void HttpRule::SerializeToOstream(OutputStream* output__) const { |
| if (has_selector_) { |
| WriteString(output__, 1, selector_); |
| } |
| if (has_get_) { |
| WriteString(output__, 2, get_); |
| } |
| if (has_put_) { |
| WriteString(output__, 3, put_); |
| } |
| if (has_post_) { |
| WriteString(output__, 4, post_); |
| } |
| if (has_delete_) { |
| WriteString(output__, 5, delete_); |
| } |
| if (has_patch_) { |
| WriteString(output__, 6, patch_); |
| } |
| if (has_custom_) { |
| WriteLengthDelimited(output__, 8, |
| custom_.ByteSizeLong()); |
| custom_.SerializeToOstream(output__); |
| } |
| if (has_body_) { |
| WriteString(output__, 7, body_); |
| } |
| if (has_response_body_) { |
| WriteString(output__, 12, response_body_); |
| } |
| for (const auto& elem : additional_bindings_) { |
| if (has_additional_bindings_) { |
| WriteLengthDelimited(output__, 11, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t HttpRule::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_selector_) { |
| size += StringSize(selector_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_get_) { |
| size += StringSize(get_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_put_) { |
| size += StringSize(put_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_post_) { |
| size += StringSize(post_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_delete_) { |
| size += StringSize(delete_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_patch_) { |
| size += StringSize(patch_) + VarintSize32(6 << kTagTypeBits); |
| } |
| if (has_custom_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(custom_.ByteSizeLong()); |
| size += custom_.ByteSizeLong(); |
| } |
| if (has_body_) { |
| size += StringSize(body_) + VarintSize32(7 << kTagTypeBits); |
| } |
| if (has_response_body_) { |
| size += StringSize(response_body_) + VarintSize32(12 << kTagTypeBits); |
| } |
| for (const auto& elem : additional_bindings_) { |
| if (has_additional_bindings_) { |
| size += VarintSize32(11 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void HttpRule::Clear() { |
| selector_.clear(); |
| get_.clear(); |
| put_.clear(); |
| post_.clear(); |
| delete_.clear(); |
| patch_.clear(); |
| if (has_custom_) { |
| custom_.Clear(); |
| has_custom_ = false; |
| } |
| body_.clear(); |
| response_body_.clear(); |
| if (has_additional_bindings_) { |
| additional_bindings_.clear(); |
| has_additional_bindings_ = false; |
| } |
| } |
| |
| void HttpRule::set_selector(const std::string& value) { |
| has_selector_ = true; |
| selector_ = value; |
| } |
| |
| void HttpRule::set_get(const std::string& value) { |
| has_get_ = true; |
| get_ = value; |
| } |
| |
| void HttpRule::set_put(const std::string& value) { |
| has_put_ = true; |
| put_ = value; |
| } |
| |
| void HttpRule::set_post(const std::string& value) { |
| has_post_ = true; |
| post_ = value; |
| } |
| |
| void HttpRule::set_delete(const std::string& value) { |
| has_delete_ = true; |
| delete_ = value; |
| } |
| |
| void HttpRule::set_patch(const std::string& value) { |
| has_patch_ = true; |
| patch_ = value; |
| } |
| |
| void HttpRule::set_body(const std::string& value) { |
| has_body_ = true; |
| body_ = value; |
| } |
| |
| void HttpRule::set_response_body(const std::string& value) { |
| has_response_body_ = true; |
| response_body_ = value; |
| } |
| |
| void HttpRule::add_additional_bindings(const ::rs::google::api::HttpRule& value) { |
| has_additional_bindings_ = true; |
| additional_bindings_.push_back(value); |
| } |
| } // namespace api |
| } // namespace google |
| namespace google { |
| namespace protobuf { |
| void FileDescriptorSet::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : file_) { |
| if (has_file_) { |
| WriteLengthDelimited(output__, 1, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t FileDescriptorSet::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : file_) { |
| if (has_file_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void FileDescriptorSet::Clear() { |
| if (has_file_) { |
| file_.clear(); |
| has_file_ = false; |
| } |
| } |
| |
| void FileDescriptorSet::add_file(const ::rs::google::protobuf::FileDescriptorProto& value) { |
| has_file_ = true; |
| file_.push_back(value); |
| } |
| void FeatureSet::SerializeToOstream(OutputStream* output__) const { |
| if (has_field_presence_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(field_presence_)); |
| } |
| if (has_enum_type_) { |
| WriteVarint32SignExtended(output__, 2, static_cast<int32_t>(enum_type_)); |
| } |
| if (has_repeated_field_encoding_) { |
| WriteVarint32SignExtended(output__, 3, static_cast<int32_t>(repeated_field_encoding_)); |
| } |
| if (has_utf8_validation_) { |
| WriteVarint32SignExtended(output__, 4, static_cast<int32_t>(utf8_validation_)); |
| } |
| if (has_message_encoding_) { |
| WriteVarint32SignExtended(output__, 5, static_cast<int32_t>(message_encoding_)); |
| } |
| if (has_json_format_) { |
| WriteVarint32SignExtended(output__, 6, static_cast<int32_t>(json_format_)); |
| } |
| } |
| |
| size_t FeatureSet::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_field_presence_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(field_presence_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_enum_type_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(enum_type_)) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_repeated_field_encoding_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(repeated_field_encoding_)) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_utf8_validation_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(utf8_validation_)) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_message_encoding_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(message_encoding_)) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_json_format_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(json_format_)) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FeatureSet::Clear() { |
| field_presence_ = static_cast< ::rs::google::protobuf::FeatureSet::FieldPresence >(0); |
| enum_type_ = static_cast< ::rs::google::protobuf::FeatureSet::EnumType >(0); |
| repeated_field_encoding_ = static_cast< ::rs::google::protobuf::FeatureSet::RepeatedFieldEncoding >(0); |
| utf8_validation_ = static_cast< ::rs::google::protobuf::FeatureSet::Utf8Validation >(0); |
| message_encoding_ = static_cast< ::rs::google::protobuf::FeatureSet::MessageEncoding >(0); |
| json_format_ = static_cast< ::rs::google::protobuf::FeatureSet::JsonFormat >(0); |
| } |
| |
| void FeatureSet::set_field_presence(const ::rs::google::protobuf::FeatureSet::FieldPresence& value) { |
| has_field_presence_ = true; |
| field_presence_ = value; |
| } |
| |
| void FeatureSet::set_enum_type(const ::rs::google::protobuf::FeatureSet::EnumType& value) { |
| has_enum_type_ = true; |
| enum_type_ = value; |
| } |
| |
| void FeatureSet::set_repeated_field_encoding(const ::rs::google::protobuf::FeatureSet::RepeatedFieldEncoding& value) { |
| has_repeated_field_encoding_ = true; |
| repeated_field_encoding_ = value; |
| } |
| |
| void FeatureSet::set_utf8_validation(const ::rs::google::protobuf::FeatureSet::Utf8Validation& value) { |
| has_utf8_validation_ = true; |
| utf8_validation_ = value; |
| } |
| |
| void FeatureSet::set_message_encoding(const ::rs::google::protobuf::FeatureSet::MessageEncoding& value) { |
| has_message_encoding_ = true; |
| message_encoding_ = value; |
| } |
| |
| void FeatureSet::set_json_format(const ::rs::google::protobuf::FeatureSet::JsonFormat& value) { |
| has_json_format_ = true; |
| json_format_ = value; |
| } |
| |
| void FileOptions::SerializeToOstream(OutputStream* output__) const { |
| if (has_java_package_) { |
| WriteString(output__, 1, java_package_); |
| } |
| if (has_java_outer_classname_) { |
| WriteString(output__, 8, java_outer_classname_); |
| } |
| if (has_java_multiple_files_) { |
| WriteVarint32(output__, 10, java_multiple_files_); |
| } |
| if (has_java_generate_equals_and_hash_) { |
| WriteVarint32(output__, 20, java_generate_equals_and_hash_); |
| } |
| if (has_java_string_check_utf8_) { |
| WriteVarint32(output__, 27, java_string_check_utf8_); |
| } |
| if (has_optimize_for_) { |
| WriteVarint32SignExtended(output__, 9, static_cast<int32_t>(optimize_for_)); |
| } |
| if (has_go_package_) { |
| WriteString(output__, 11, go_package_); |
| } |
| if (has_cc_generic_services_) { |
| WriteVarint32(output__, 16, cc_generic_services_); |
| } |
| if (has_java_generic_services_) { |
| WriteVarint32(output__, 17, java_generic_services_); |
| } |
| if (has_py_generic_services_) { |
| WriteVarint32(output__, 18, py_generic_services_); |
| } |
| if (has_deprecated_) { |
| WriteVarint32(output__, 23, deprecated_); |
| } |
| if (has_cc_enable_arenas_) { |
| WriteVarint32(output__, 31, cc_enable_arenas_); |
| } |
| if (has_objc_class_prefix_) { |
| WriteString(output__, 36, objc_class_prefix_); |
| } |
| if (has_csharp_namespace_) { |
| WriteString(output__, 37, csharp_namespace_); |
| } |
| if (has_swift_prefix_) { |
| WriteString(output__, 39, swift_prefix_); |
| } |
| if (has_php_class_prefix_) { |
| WriteString(output__, 40, php_class_prefix_); |
| } |
| if (has_php_namespace_) { |
| WriteString(output__, 41, php_namespace_); |
| } |
| if (has_php_metadata_namespace_) { |
| WriteString(output__, 44, php_metadata_namespace_); |
| } |
| if (has_ruby_package_) { |
| WriteString(output__, 45, ruby_package_); |
| } |
| if (has_features_) { |
| WriteLengthDelimited(output__, 50, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t FileOptions::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_java_package_) { |
| size += StringSize(java_package_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_java_outer_classname_) { |
| size += StringSize(java_outer_classname_) + VarintSize32(8 << kTagTypeBits); |
| } |
| if (has_java_multiple_files_) { |
| size += VarintSizeBool(java_multiple_files_) + VarintSize32(10 << kTagTypeBits); |
| } |
| if (has_java_generate_equals_and_hash_) { |
| size += VarintSizeBool(java_generate_equals_and_hash_) + VarintSize32(20 << kTagTypeBits); |
| } |
| if (has_java_string_check_utf8_) { |
| size += VarintSizeBool(java_string_check_utf8_) + VarintSize32(27 << kTagTypeBits); |
| } |
| if (has_optimize_for_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(optimize_for_)) + VarintSize32(9 << kTagTypeBits); |
| } |
| if (has_go_package_) { |
| size += StringSize(go_package_) + VarintSize32(11 << kTagTypeBits); |
| } |
| if (has_cc_generic_services_) { |
| size += VarintSizeBool(cc_generic_services_) + VarintSize32(16 << kTagTypeBits); |
| } |
| if (has_java_generic_services_) { |
| size += VarintSizeBool(java_generic_services_) + VarintSize32(17 << kTagTypeBits); |
| } |
| if (has_py_generic_services_) { |
| size += VarintSizeBool(py_generic_services_) + VarintSize32(18 << kTagTypeBits); |
| } |
| if (has_deprecated_) { |
| size += VarintSizeBool(deprecated_) + VarintSize32(23 << kTagTypeBits); |
| } |
| if (has_cc_enable_arenas_) { |
| size += VarintSizeBool(cc_enable_arenas_) + VarintSize32(31 << kTagTypeBits); |
| } |
| if (has_objc_class_prefix_) { |
| size += StringSize(objc_class_prefix_) + VarintSize32(36 << kTagTypeBits); |
| } |
| if (has_csharp_namespace_) { |
| size += StringSize(csharp_namespace_) + VarintSize32(37 << kTagTypeBits); |
| } |
| if (has_swift_prefix_) { |
| size += StringSize(swift_prefix_) + VarintSize32(39 << kTagTypeBits); |
| } |
| if (has_php_class_prefix_) { |
| size += StringSize(php_class_prefix_) + VarintSize32(40 << kTagTypeBits); |
| } |
| if (has_php_namespace_) { |
| size += StringSize(php_namespace_) + VarintSize32(41 << kTagTypeBits); |
| } |
| if (has_php_metadata_namespace_) { |
| size += StringSize(php_metadata_namespace_) + VarintSize32(44 << kTagTypeBits); |
| } |
| if (has_ruby_package_) { |
| size += StringSize(ruby_package_) + VarintSize32(45 << kTagTypeBits); |
| } |
| if (has_features_) { |
| size += VarintSize32(50 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void FileOptions::Clear() { |
| java_package_.clear(); |
| java_outer_classname_.clear(); |
| java_multiple_files_ = false; |
| java_generate_equals_and_hash_ = false; |
| java_string_check_utf8_ = false; |
| optimize_for_ = static_cast< ::rs::google::protobuf::FileOptions::OptimizeMode >(0); |
| go_package_.clear(); |
| cc_generic_services_ = false; |
| java_generic_services_ = false; |
| py_generic_services_ = false; |
| deprecated_ = false; |
| cc_enable_arenas_ = false; |
| objc_class_prefix_.clear(); |
| csharp_namespace_.clear(); |
| swift_prefix_.clear(); |
| php_class_prefix_.clear(); |
| php_namespace_.clear(); |
| php_metadata_namespace_.clear(); |
| ruby_package_.clear(); |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| } |
| |
| void FileOptions::set_java_package(const std::string& value) { |
| has_java_package_ = true; |
| java_package_ = value; |
| } |
| |
| void FileOptions::set_java_outer_classname(const std::string& value) { |
| has_java_outer_classname_ = true; |
| java_outer_classname_ = value; |
| } |
| |
| void FileOptions::set_java_multiple_files(const bool& value) { |
| has_java_multiple_files_ = true; |
| java_multiple_files_ = value; |
| } |
| |
| void FileOptions::set_java_generate_equals_and_hash(const bool& value) { |
| has_java_generate_equals_and_hash_ = true; |
| java_generate_equals_and_hash_ = value; |
| } |
| |
| void FileOptions::set_java_string_check_utf8(const bool& value) { |
| has_java_string_check_utf8_ = true; |
| java_string_check_utf8_ = value; |
| } |
| |
| void FileOptions::set_optimize_for(const ::rs::google::protobuf::FileOptions::OptimizeMode& value) { |
| has_optimize_for_ = true; |
| optimize_for_ = value; |
| } |
| |
| void FileOptions::set_go_package(const std::string& value) { |
| has_go_package_ = true; |
| go_package_ = value; |
| } |
| |
| void FileOptions::set_cc_generic_services(const bool& value) { |
| has_cc_generic_services_ = true; |
| cc_generic_services_ = value; |
| } |
| |
| void FileOptions::set_java_generic_services(const bool& value) { |
| has_java_generic_services_ = true; |
| java_generic_services_ = value; |
| } |
| |
| void FileOptions::set_py_generic_services(const bool& value) { |
| has_py_generic_services_ = true; |
| py_generic_services_ = value; |
| } |
| |
| void FileOptions::set_deprecated(const bool& value) { |
| has_deprecated_ = true; |
| deprecated_ = value; |
| } |
| |
| void FileOptions::set_cc_enable_arenas(const bool& value) { |
| has_cc_enable_arenas_ = true; |
| cc_enable_arenas_ = value; |
| } |
| |
| void FileOptions::set_objc_class_prefix(const std::string& value) { |
| has_objc_class_prefix_ = true; |
| objc_class_prefix_ = value; |
| } |
| |
| void FileOptions::set_csharp_namespace(const std::string& value) { |
| has_csharp_namespace_ = true; |
| csharp_namespace_ = value; |
| } |
| |
| void FileOptions::set_swift_prefix(const std::string& value) { |
| has_swift_prefix_ = true; |
| swift_prefix_ = value; |
| } |
| |
| void FileOptions::set_php_class_prefix(const std::string& value) { |
| has_php_class_prefix_ = true; |
| php_class_prefix_ = value; |
| } |
| |
| void FileOptions::set_php_namespace(const std::string& value) { |
| has_php_namespace_ = true; |
| php_namespace_ = value; |
| } |
| |
| void FileOptions::set_php_metadata_namespace(const std::string& value) { |
| has_php_metadata_namespace_ = true; |
| php_metadata_namespace_ = value; |
| } |
| |
| void FileOptions::set_ruby_package(const std::string& value) { |
| has_ruby_package_ = true; |
| ruby_package_ = value; |
| } |
| |
| void FileOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void SourceCodeInfo::Location::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : path_) { |
| WriteVarint32SignExtended(output__, 1, elem); |
| } |
| for (const auto& elem : span_) { |
| WriteVarint32SignExtended(output__, 2, elem); |
| } |
| if (has_leading_comments_) { |
| WriteString(output__, 3, leading_comments_); |
| } |
| if (has_trailing_comments_) { |
| WriteString(output__, 4, trailing_comments_); |
| } |
| for (const auto& elem : leading_detached_comments_) { |
| WriteString(output__, 6, elem); |
| } |
| } |
| |
| size_t SourceCodeInfo::Location::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : path_) { |
| size += VarintSize32SignExtended(elem) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : span_) { |
| size += VarintSize32SignExtended(elem) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_leading_comments_) { |
| size += StringSize(leading_comments_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_trailing_comments_) { |
| size += StringSize(trailing_comments_) + VarintSize32(4 << kTagTypeBits); |
| } |
| for (const auto& elem : leading_detached_comments_) { |
| size += StringSize(elem) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void SourceCodeInfo::Location::Clear() { |
| path_.clear(); |
| span_.clear(); |
| leading_comments_.clear(); |
| trailing_comments_.clear(); |
| leading_detached_comments_.clear(); |
| } |
| |
| void SourceCodeInfo::Location::add_path(const int32_t& value) { |
| has_path_ = true; |
| path_.push_back(value); |
| } |
| void SourceCodeInfo::Location::set_path(const std::vector< int32_t >& value) { |
| has_path_ = true; |
| path_ = value; |
| } |
| |
| void SourceCodeInfo::Location::add_span(const int32_t& value) { |
| has_span_ = true; |
| span_.push_back(value); |
| } |
| void SourceCodeInfo::Location::set_span(const std::vector< int32_t >& value) { |
| has_span_ = true; |
| span_ = value; |
| } |
| |
| void SourceCodeInfo::Location::set_leading_comments(const std::string& value) { |
| has_leading_comments_ = true; |
| leading_comments_ = value; |
| } |
| |
| void SourceCodeInfo::Location::set_trailing_comments(const std::string& value) { |
| has_trailing_comments_ = true; |
| trailing_comments_ = value; |
| } |
| |
| void SourceCodeInfo::Location::add_leading_detached_comments(const std::string& value) { |
| has_leading_detached_comments_ = true; |
| leading_detached_comments_.push_back(value); |
| } |
| void SourceCodeInfo::Location::set_leading_detached_comments(const std::vector< std::string >& value) { |
| has_leading_detached_comments_ = true; |
| leading_detached_comments_ = value; |
| } |
| |
| void SourceCodeInfo::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : location_) { |
| if (has_location_) { |
| WriteLengthDelimited(output__, 1, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t SourceCodeInfo::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : location_) { |
| if (has_location_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void SourceCodeInfo::Clear() { |
| if (has_location_) { |
| location_.clear(); |
| has_location_ = false; |
| } |
| } |
| |
| void SourceCodeInfo::add_location(const ::rs::google::protobuf::SourceCodeInfo::Location& value) { |
| has_location_ = true; |
| location_.push_back(value); |
| } |
| void FileDescriptorProto::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_package_) { |
| WriteString(output__, 2, package_); |
| } |
| for (const auto& elem : dependency_) { |
| WriteString(output__, 3, elem); |
| } |
| for (const auto& elem : public_dependency_) { |
| WriteVarint32SignExtended(output__, 10, elem); |
| } |
| for (const auto& elem : weak_dependency_) { |
| WriteVarint32SignExtended(output__, 11, elem); |
| } |
| for (const auto& elem : message_type_) { |
| if (has_message_type_) { |
| WriteLengthDelimited(output__, 4, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : enum_type_) { |
| if (has_enum_type_) { |
| WriteLengthDelimited(output__, 5, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : service_) { |
| if (has_service_) { |
| WriteLengthDelimited(output__, 6, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : extension_) { |
| if (has_extension_) { |
| WriteLengthDelimited(output__, 7, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 8, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| if (has_source_code_info_) { |
| WriteLengthDelimited(output__, 9, |
| source_code_info_.ByteSizeLong()); |
| source_code_info_.SerializeToOstream(output__); |
| } |
| if (has_syntax_) { |
| WriteString(output__, 12, syntax_); |
| } |
| if (has_edition_) { |
| WriteVarint32SignExtended(output__, 14, static_cast<int32_t>(edition_)); |
| } |
| } |
| |
| size_t FileDescriptorProto::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_package_) { |
| size += StringSize(package_) + VarintSize32(2 << kTagTypeBits); |
| } |
| for (const auto& elem : dependency_) { |
| size += StringSize(elem) + VarintSize32(3 << kTagTypeBits); |
| } |
| for (const auto& elem : public_dependency_) { |
| size += VarintSize32SignExtended(elem) + VarintSize32(10 << kTagTypeBits); |
| } |
| for (const auto& elem : weak_dependency_) { |
| size += VarintSize32SignExtended(elem) + VarintSize32(11 << kTagTypeBits); |
| } |
| for (const auto& elem : message_type_) { |
| if (has_message_type_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : enum_type_) { |
| if (has_enum_type_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : service_) { |
| if (has_service_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : extension_) { |
| if (has_extension_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_options_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| if (has_source_code_info_) { |
| size += VarintSize32(9 << kTagTypeBits) + |
| VarintSize32(source_code_info_.ByteSizeLong()); |
| size += source_code_info_.ByteSizeLong(); |
| } |
| if (has_syntax_) { |
| size += StringSize(syntax_) + VarintSize32(12 << kTagTypeBits); |
| } |
| if (has_edition_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(edition_)) + VarintSize32(14 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FileDescriptorProto::Clear() { |
| name_.clear(); |
| package_.clear(); |
| dependency_.clear(); |
| public_dependency_.clear(); |
| weak_dependency_.clear(); |
| if (has_message_type_) { |
| message_type_.clear(); |
| has_message_type_ = false; |
| } |
| if (has_enum_type_) { |
| enum_type_.clear(); |
| has_enum_type_ = false; |
| } |
| if (has_service_) { |
| service_.clear(); |
| has_service_ = false; |
| } |
| if (has_extension_) { |
| extension_.clear(); |
| has_extension_ = false; |
| } |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| if (has_source_code_info_) { |
| source_code_info_.Clear(); |
| has_source_code_info_ = false; |
| } |
| syntax_.clear(); |
| edition_ = static_cast< ::rs::google::protobuf::Edition >(0); |
| } |
| |
| void FileDescriptorProto::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void FileDescriptorProto::set_package(const std::string& value) { |
| has_package_ = true; |
| package_ = value; |
| } |
| |
| void FileDescriptorProto::add_dependency(const std::string& value) { |
| has_dependency_ = true; |
| dependency_.push_back(value); |
| } |
| void FileDescriptorProto::set_dependency(const std::vector< std::string >& value) { |
| has_dependency_ = true; |
| dependency_ = value; |
| } |
| |
| void FileDescriptorProto::add_public_dependency(const int32_t& value) { |
| has_public_dependency_ = true; |
| public_dependency_.push_back(value); |
| } |
| void FileDescriptorProto::set_public_dependency(const std::vector< int32_t >& value) { |
| has_public_dependency_ = true; |
| public_dependency_ = value; |
| } |
| |
| void FileDescriptorProto::add_weak_dependency(const int32_t& value) { |
| has_weak_dependency_ = true; |
| weak_dependency_.push_back(value); |
| } |
| void FileDescriptorProto::set_weak_dependency(const std::vector< int32_t >& value) { |
| has_weak_dependency_ = true; |
| weak_dependency_ = value; |
| } |
| |
| void FileDescriptorProto::add_message_type(const ::rs::google::protobuf::DescriptorProto& value) { |
| has_message_type_ = true; |
| message_type_.push_back(value); |
| } |
| void FileDescriptorProto::add_enum_type(const ::rs::google::protobuf::EnumDescriptorProto& value) { |
| has_enum_type_ = true; |
| enum_type_.push_back(value); |
| } |
| void FileDescriptorProto::add_service(const ::rs::google::protobuf::ServiceDescriptorProto& value) { |
| has_service_ = true; |
| service_.push_back(value); |
| } |
| void FileDescriptorProto::add_extension(const ::rs::google::protobuf::FieldDescriptorProto& value) { |
| has_extension_ = true; |
| extension_.push_back(value); |
| } |
| void FileDescriptorProto::set_syntax(const std::string& value) { |
| has_syntax_ = true; |
| syntax_ = value; |
| } |
| |
| void FileDescriptorProto::set_edition(const ::rs::google::protobuf::Edition& value) { |
| has_edition_ = true; |
| edition_ = value; |
| } |
| |
| void ExtensionRangeOptions::Declaration::SerializeToOstream(OutputStream* output__) const { |
| if (has_number_) { |
| WriteVarint32SignExtended(output__, 1, number_); |
| } |
| if (has_full_name_) { |
| WriteString(output__, 2, full_name_); |
| } |
| if (has_type_) { |
| WriteString(output__, 3, type_); |
| } |
| if (has_reserved_) { |
| WriteVarint32(output__, 5, reserved_); |
| } |
| if (has_repeated_) { |
| WriteVarint32(output__, 6, repeated_); |
| } |
| } |
| |
| size_t ExtensionRangeOptions::Declaration::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_number_) { |
| size += VarintSize32SignExtended(number_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_full_name_) { |
| size += StringSize(full_name_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_type_) { |
| size += StringSize(type_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_reserved_) { |
| size += VarintSizeBool(reserved_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_repeated_) { |
| size += VarintSizeBool(repeated_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void ExtensionRangeOptions::Declaration::Clear() { |
| number_ = static_cast< int32_t >(0); |
| full_name_.clear(); |
| type_.clear(); |
| reserved_ = false; |
| repeated_ = false; |
| } |
| |
| void ExtensionRangeOptions::Declaration::set_number(const int32_t& value) { |
| has_number_ = true; |
| number_ = value; |
| } |
| |
| void ExtensionRangeOptions::Declaration::set_full_name(const std::string& value) { |
| has_full_name_ = true; |
| full_name_ = value; |
| } |
| |
| void ExtensionRangeOptions::Declaration::set_type(const std::string& value) { |
| has_type_ = true; |
| type_ = value; |
| } |
| |
| void ExtensionRangeOptions::Declaration::set_reserved(const bool& value) { |
| has_reserved_ = true; |
| reserved_ = value; |
| } |
| |
| void ExtensionRangeOptions::Declaration::set_repeated(const bool& value) { |
| has_repeated_ = true; |
| repeated_ = value; |
| } |
| |
| void ExtensionRangeOptions::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : declaration_) { |
| if (has_declaration_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_features_) { |
| WriteLengthDelimited(output__, 50, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| if (has_verification_) { |
| WriteVarint32SignExtended(output__, 3, static_cast<int32_t>(verification_)); |
| } |
| } |
| |
| size_t ExtensionRangeOptions::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : declaration_) { |
| if (has_declaration_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_features_) { |
| size += VarintSize32(50 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| if (has_verification_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(verification_)) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void ExtensionRangeOptions::Clear() { |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| if (has_declaration_) { |
| declaration_.clear(); |
| has_declaration_ = false; |
| } |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| verification_ = static_cast< ::rs::google::protobuf::ExtensionRangeOptions::VerificationState >(0); |
| } |
| |
| void ExtensionRangeOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void ExtensionRangeOptions::add_declaration(const ::rs::google::protobuf::ExtensionRangeOptions::Declaration& value) { |
| has_declaration_ = true; |
| declaration_.push_back(value); |
| } |
| void ExtensionRangeOptions::set_verification(const ::rs::google::protobuf::ExtensionRangeOptions::VerificationState& value) { |
| has_verification_ = true; |
| verification_ = value; |
| } |
| |
| void MessageOptions::SerializeToOstream(OutputStream* output__) const { |
| if (has_message_set_wire_format_) { |
| WriteVarint32(output__, 1, message_set_wire_format_); |
| } |
| if (has_no_standard_descriptor_accessor_) { |
| WriteVarint32(output__, 2, no_standard_descriptor_accessor_); |
| } |
| if (has_deprecated_) { |
| WriteVarint32(output__, 3, deprecated_); |
| } |
| if (has_map_entry_) { |
| WriteVarint32(output__, 7, map_entry_); |
| } |
| if (has_deprecated_legacy_json_field_conflicts_) { |
| WriteVarint32(output__, 11, deprecated_legacy_json_field_conflicts_); |
| } |
| if (has_features_) { |
| WriteLengthDelimited(output__, 12, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t MessageOptions::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_message_set_wire_format_) { |
| size += VarintSizeBool(message_set_wire_format_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_no_standard_descriptor_accessor_) { |
| size += VarintSizeBool(no_standard_descriptor_accessor_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_deprecated_) { |
| size += VarintSizeBool(deprecated_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_map_entry_) { |
| size += VarintSizeBool(map_entry_) + VarintSize32(7 << kTagTypeBits); |
| } |
| if (has_deprecated_legacy_json_field_conflicts_) { |
| size += VarintSizeBool(deprecated_legacy_json_field_conflicts_) + VarintSize32(11 << kTagTypeBits); |
| } |
| if (has_features_) { |
| size += VarintSize32(12 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void MessageOptions::Clear() { |
| message_set_wire_format_ = false; |
| no_standard_descriptor_accessor_ = false; |
| deprecated_ = false; |
| map_entry_ = false; |
| deprecated_legacy_json_field_conflicts_ = false; |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| } |
| |
| void MessageOptions::set_message_set_wire_format(const bool& value) { |
| has_message_set_wire_format_ = true; |
| message_set_wire_format_ = value; |
| } |
| |
| void MessageOptions::set_no_standard_descriptor_accessor(const bool& value) { |
| has_no_standard_descriptor_accessor_ = true; |
| no_standard_descriptor_accessor_ = value; |
| } |
| |
| void MessageOptions::set_deprecated(const bool& value) { |
| has_deprecated_ = true; |
| deprecated_ = value; |
| } |
| |
| void MessageOptions::set_map_entry(const bool& value) { |
| has_map_entry_ = true; |
| map_entry_ = value; |
| } |
| |
| void MessageOptions::set_deprecated_legacy_json_field_conflicts(const bool& value) { |
| has_deprecated_legacy_json_field_conflicts_ = true; |
| deprecated_legacy_json_field_conflicts_ = value; |
| } |
| |
| void MessageOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void DescriptorProto::ExtensionRange::SerializeToOstream(OutputStream* output__) const { |
| if (has_start_) { |
| WriteVarint32SignExtended(output__, 1, start_); |
| } |
| if (has_end_) { |
| WriteVarint32SignExtended(output__, 2, end_); |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 3, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t DescriptorProto::ExtensionRange::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_start_) { |
| size += VarintSize32SignExtended(start_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_end_) { |
| size += VarintSize32SignExtended(end_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_options_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void DescriptorProto::ExtensionRange::Clear() { |
| start_ = static_cast< int32_t >(0); |
| end_ = static_cast< int32_t >(0); |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| } |
| |
| void DescriptorProto::ExtensionRange::set_start(const int32_t& value) { |
| has_start_ = true; |
| start_ = value; |
| } |
| |
| void DescriptorProto::ExtensionRange::set_end(const int32_t& value) { |
| has_end_ = true; |
| end_ = value; |
| } |
| |
| void DescriptorProto::ReservedRange::SerializeToOstream(OutputStream* output__) const { |
| if (has_start_) { |
| WriteVarint32SignExtended(output__, 1, start_); |
| } |
| if (has_end_) { |
| WriteVarint32SignExtended(output__, 2, end_); |
| } |
| } |
| |
| size_t DescriptorProto::ReservedRange::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_start_) { |
| size += VarintSize32SignExtended(start_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_end_) { |
| size += VarintSize32SignExtended(end_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void DescriptorProto::ReservedRange::Clear() { |
| start_ = static_cast< int32_t >(0); |
| end_ = static_cast< int32_t >(0); |
| } |
| |
| void DescriptorProto::ReservedRange::set_start(const int32_t& value) { |
| has_start_ = true; |
| start_ = value; |
| } |
| |
| void DescriptorProto::ReservedRange::set_end(const int32_t& value) { |
| has_end_ = true; |
| end_ = value; |
| } |
| |
| void DescriptorProto::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| for (const auto& elem : field_) { |
| if (has_field_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : extension_) { |
| if (has_extension_) { |
| WriteLengthDelimited(output__, 6, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : nested_type_) { |
| if (has_nested_type_) { |
| WriteLengthDelimited(output__, 3, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : enum_type_) { |
| if (has_enum_type_) { |
| WriteLengthDelimited(output__, 4, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : extension_range_) { |
| if (has_extension_range_) { |
| WriteLengthDelimited(output__, 5, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : oneof_decl_) { |
| if (has_oneof_decl_) { |
| WriteLengthDelimited(output__, 8, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 7, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : reserved_range_) { |
| if (has_reserved_range_) { |
| WriteLengthDelimited(output__, 9, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : reserved_name_) { |
| WriteString(output__, 10, elem); |
| } |
| } |
| |
| size_t DescriptorProto::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : field_) { |
| if (has_field_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : extension_) { |
| if (has_extension_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : nested_type_) { |
| if (has_nested_type_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : enum_type_) { |
| if (has_enum_type_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : extension_range_) { |
| if (has_extension_range_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : oneof_decl_) { |
| if (has_oneof_decl_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_options_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| for (const auto& elem : reserved_range_) { |
| if (has_reserved_range_) { |
| size += VarintSize32(9 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : reserved_name_) { |
| size += StringSize(elem) + VarintSize32(10 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void DescriptorProto::Clear() { |
| name_.clear(); |
| if (has_field_) { |
| field_.clear(); |
| has_field_ = false; |
| } |
| if (has_extension_) { |
| extension_.clear(); |
| has_extension_ = false; |
| } |
| if (has_nested_type_) { |
| nested_type_.clear(); |
| has_nested_type_ = false; |
| } |
| if (has_enum_type_) { |
| enum_type_.clear(); |
| has_enum_type_ = false; |
| } |
| if (has_extension_range_) { |
| extension_range_.clear(); |
| has_extension_range_ = false; |
| } |
| if (has_oneof_decl_) { |
| oneof_decl_.clear(); |
| has_oneof_decl_ = false; |
| } |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| if (has_reserved_range_) { |
| reserved_range_.clear(); |
| has_reserved_range_ = false; |
| } |
| reserved_name_.clear(); |
| } |
| |
| void DescriptorProto::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void DescriptorProto::add_field(const ::rs::google::protobuf::FieldDescriptorProto& value) { |
| has_field_ = true; |
| field_.push_back(value); |
| } |
| void DescriptorProto::add_extension(const ::rs::google::protobuf::FieldDescriptorProto& value) { |
| has_extension_ = true; |
| extension_.push_back(value); |
| } |
| void DescriptorProto::add_nested_type(const ::rs::google::protobuf::DescriptorProto& value) { |
| has_nested_type_ = true; |
| nested_type_.push_back(value); |
| } |
| void DescriptorProto::add_enum_type(const ::rs::google::protobuf::EnumDescriptorProto& value) { |
| has_enum_type_ = true; |
| enum_type_.push_back(value); |
| } |
| void DescriptorProto::add_extension_range(const ::rs::google::protobuf::DescriptorProto::ExtensionRange& value) { |
| has_extension_range_ = true; |
| extension_range_.push_back(value); |
| } |
| void DescriptorProto::add_oneof_decl(const ::rs::google::protobuf::OneofDescriptorProto& value) { |
| has_oneof_decl_ = true; |
| oneof_decl_.push_back(value); |
| } |
| void DescriptorProto::add_reserved_range(const ::rs::google::protobuf::DescriptorProto::ReservedRange& value) { |
| has_reserved_range_ = true; |
| reserved_range_.push_back(value); |
| } |
| void DescriptorProto::add_reserved_name(const std::string& value) { |
| has_reserved_name_ = true; |
| reserved_name_.push_back(value); |
| } |
| void DescriptorProto::set_reserved_name(const std::vector< std::string >& value) { |
| has_reserved_name_ = true; |
| reserved_name_ = value; |
| } |
| |
| void FieldOptions::EditionDefault::SerializeToOstream(OutputStream* output__) const { |
| if (has_edition_) { |
| WriteVarint32SignExtended(output__, 3, static_cast<int32_t>(edition_)); |
| } |
| if (has_value_) { |
| WriteString(output__, 2, value_); |
| } |
| } |
| |
| size_t FieldOptions::EditionDefault::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_edition_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(edition_)) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_value_) { |
| size += StringSize(value_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FieldOptions::EditionDefault::Clear() { |
| edition_ = static_cast< ::rs::google::protobuf::Edition >(0); |
| value_.clear(); |
| } |
| |
| void FieldOptions::EditionDefault::set_edition(const ::rs::google::protobuf::Edition& value) { |
| has_edition_ = true; |
| edition_ = value; |
| } |
| |
| void FieldOptions::EditionDefault::set_value(const std::string& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void FieldOptions::FeatureSupport::SerializeToOstream(OutputStream* output__) const { |
| if (has_edition_introduced_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(edition_introduced_)); |
| } |
| if (has_edition_deprecated_) { |
| WriteVarint32SignExtended(output__, 2, static_cast<int32_t>(edition_deprecated_)); |
| } |
| if (has_deprecation_warning_) { |
| WriteString(output__, 3, deprecation_warning_); |
| } |
| if (has_edition_removed_) { |
| WriteVarint32SignExtended(output__, 4, static_cast<int32_t>(edition_removed_)); |
| } |
| } |
| |
| size_t FieldOptions::FeatureSupport::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_edition_introduced_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(edition_introduced_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_edition_deprecated_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(edition_deprecated_)) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_deprecation_warning_) { |
| size += StringSize(deprecation_warning_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_edition_removed_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(edition_removed_)) + VarintSize32(4 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FieldOptions::FeatureSupport::Clear() { |
| edition_introduced_ = static_cast< ::rs::google::protobuf::Edition >(0); |
| edition_deprecated_ = static_cast< ::rs::google::protobuf::Edition >(0); |
| deprecation_warning_.clear(); |
| edition_removed_ = static_cast< ::rs::google::protobuf::Edition >(0); |
| } |
| |
| void FieldOptions::FeatureSupport::set_edition_introduced(const ::rs::google::protobuf::Edition& value) { |
| has_edition_introduced_ = true; |
| edition_introduced_ = value; |
| } |
| |
| void FieldOptions::FeatureSupport::set_edition_deprecated(const ::rs::google::protobuf::Edition& value) { |
| has_edition_deprecated_ = true; |
| edition_deprecated_ = value; |
| } |
| |
| void FieldOptions::FeatureSupport::set_deprecation_warning(const std::string& value) { |
| has_deprecation_warning_ = true; |
| deprecation_warning_ = value; |
| } |
| |
| void FieldOptions::FeatureSupport::set_edition_removed(const ::rs::google::protobuf::Edition& value) { |
| has_edition_removed_ = true; |
| edition_removed_ = value; |
| } |
| |
| void FieldOptions::SerializeToOstream(OutputStream* output__) const { |
| if (has_ctype_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(ctype_)); |
| } |
| if (has_packed_) { |
| WriteVarint32(output__, 2, packed_); |
| } |
| if (has_jstype_) { |
| WriteVarint32SignExtended(output__, 6, static_cast<int32_t>(jstype_)); |
| } |
| if (has_lazy_) { |
| WriteVarint32(output__, 5, lazy_); |
| } |
| if (has_unverified_lazy_) { |
| WriteVarint32(output__, 15, unverified_lazy_); |
| } |
| if (has_deprecated_) { |
| WriteVarint32(output__, 3, deprecated_); |
| } |
| if (has_weak_) { |
| WriteVarint32(output__, 10, weak_); |
| } |
| if (has_debug_redact_) { |
| WriteVarint32(output__, 16, debug_redact_); |
| } |
| if (has_retention_) { |
| WriteVarint32SignExtended(output__, 17, static_cast<int32_t>(retention_)); |
| } |
| for (const auto& elem : targets_) { |
| WriteVarint32SignExtended(output__, 19, static_cast<int32_t>(elem)); |
| } |
| for (const auto& elem : edition_defaults_) { |
| if (has_edition_defaults_) { |
| WriteLengthDelimited(output__, 20, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_features_) { |
| WriteLengthDelimited(output__, 21, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| if (has_feature_support_) { |
| WriteLengthDelimited(output__, 22, |
| feature_support_.ByteSizeLong()); |
| feature_support_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t FieldOptions::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_ctype_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(ctype_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_packed_) { |
| size += VarintSizeBool(packed_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_jstype_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(jstype_)) + VarintSize32(6 << kTagTypeBits); |
| } |
| if (has_lazy_) { |
| size += VarintSizeBool(lazy_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_unverified_lazy_) { |
| size += VarintSizeBool(unverified_lazy_) + VarintSize32(15 << kTagTypeBits); |
| } |
| if (has_deprecated_) { |
| size += VarintSizeBool(deprecated_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_weak_) { |
| size += VarintSizeBool(weak_) + VarintSize32(10 << kTagTypeBits); |
| } |
| if (has_debug_redact_) { |
| size += VarintSizeBool(debug_redact_) + VarintSize32(16 << kTagTypeBits); |
| } |
| if (has_retention_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(retention_)) + VarintSize32(17 << kTagTypeBits); |
| } |
| for (const auto& elem : targets_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(elem)) + VarintSize32(19 << kTagTypeBits); |
| } |
| for (const auto& elem : edition_defaults_) { |
| if (has_edition_defaults_) { |
| size += VarintSize32(20 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_features_) { |
| size += VarintSize32(21 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| if (has_feature_support_) { |
| size += VarintSize32(22 << kTagTypeBits) + |
| VarintSize32(feature_support_.ByteSizeLong()); |
| size += feature_support_.ByteSizeLong(); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void FieldOptions::Clear() { |
| ctype_ = static_cast< ::rs::google::protobuf::FieldOptions::CType >(0); |
| packed_ = false; |
| jstype_ = static_cast< ::rs::google::protobuf::FieldOptions::JSType >(0); |
| lazy_ = false; |
| unverified_lazy_ = false; |
| deprecated_ = false; |
| weak_ = false; |
| debug_redact_ = false; |
| retention_ = static_cast< ::rs::google::protobuf::FieldOptions::OptionRetention >(0); |
| targets_.clear(); |
| if (has_edition_defaults_) { |
| edition_defaults_.clear(); |
| has_edition_defaults_ = false; |
| } |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| if (has_feature_support_) { |
| feature_support_.Clear(); |
| has_feature_support_ = false; |
| } |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| } |
| |
| void FieldOptions::set_ctype(const ::rs::google::protobuf::FieldOptions::CType& value) { |
| has_ctype_ = true; |
| ctype_ = value; |
| } |
| |
| void FieldOptions::set_packed(const bool& value) { |
| has_packed_ = true; |
| packed_ = value; |
| } |
| |
| void FieldOptions::set_jstype(const ::rs::google::protobuf::FieldOptions::JSType& value) { |
| has_jstype_ = true; |
| jstype_ = value; |
| } |
| |
| void FieldOptions::set_lazy(const bool& value) { |
| has_lazy_ = true; |
| lazy_ = value; |
| } |
| |
| void FieldOptions::set_unverified_lazy(const bool& value) { |
| has_unverified_lazy_ = true; |
| unverified_lazy_ = value; |
| } |
| |
| void FieldOptions::set_deprecated(const bool& value) { |
| has_deprecated_ = true; |
| deprecated_ = value; |
| } |
| |
| void FieldOptions::set_weak(const bool& value) { |
| has_weak_ = true; |
| weak_ = value; |
| } |
| |
| void FieldOptions::set_debug_redact(const bool& value) { |
| has_debug_redact_ = true; |
| debug_redact_ = value; |
| } |
| |
| void FieldOptions::set_retention(const ::rs::google::protobuf::FieldOptions::OptionRetention& value) { |
| has_retention_ = true; |
| retention_ = value; |
| } |
| |
| void FieldOptions::add_targets(const ::rs::google::protobuf::FieldOptions::OptionTargetType& value) { |
| has_targets_ = true; |
| targets_.push_back(value); |
| } |
| void FieldOptions::set_targets(const std::vector< ::rs::google::protobuf::FieldOptions::OptionTargetType >& value) { |
| has_targets_ = true; |
| targets_ = value; |
| } |
| |
| void FieldOptions::add_edition_defaults(const ::rs::google::protobuf::FieldOptions::EditionDefault& value) { |
| has_edition_defaults_ = true; |
| edition_defaults_.push_back(value); |
| } |
| void FieldOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void FieldDescriptorProto::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_number_) { |
| WriteVarint32SignExtended(output__, 3, number_); |
| } |
| if (has_label_) { |
| WriteVarint32SignExtended(output__, 4, static_cast<int32_t>(label_)); |
| } |
| if (has_type_) { |
| WriteVarint32SignExtended(output__, 5, static_cast<int32_t>(type_)); |
| } |
| if (has_type_name_) { |
| WriteString(output__, 6, type_name_); |
| } |
| if (has_extendee_) { |
| WriteString(output__, 2, extendee_); |
| } |
| if (has_default_value_) { |
| WriteString(output__, 7, default_value_); |
| } |
| if (has_oneof_index_) { |
| WriteVarint32SignExtended(output__, 9, oneof_index_); |
| } |
| if (has_json_name_) { |
| WriteString(output__, 10, json_name_); |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 8, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| if (has_proto3_optional_) { |
| WriteVarint32(output__, 17, proto3_optional_); |
| } |
| } |
| |
| size_t FieldDescriptorProto::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_number_) { |
| size += VarintSize32SignExtended(number_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_label_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(label_)) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_type_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(type_)) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_type_name_) { |
| size += StringSize(type_name_) + VarintSize32(6 << kTagTypeBits); |
| } |
| if (has_extendee_) { |
| size += StringSize(extendee_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_default_value_) { |
| size += StringSize(default_value_) + VarintSize32(7 << kTagTypeBits); |
| } |
| if (has_oneof_index_) { |
| size += VarintSize32SignExtended(oneof_index_) + VarintSize32(9 << kTagTypeBits); |
| } |
| if (has_json_name_) { |
| size += StringSize(json_name_) + VarintSize32(10 << kTagTypeBits); |
| } |
| if (has_options_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| if (has_proto3_optional_) { |
| size += VarintSizeBool(proto3_optional_) + VarintSize32(17 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FieldDescriptorProto::Clear() { |
| name_.clear(); |
| number_ = static_cast< int32_t >(0); |
| label_ = static_cast< ::rs::google::protobuf::FieldDescriptorProto::Label >(0); |
| type_ = static_cast< ::rs::google::protobuf::FieldDescriptorProto::Type >(0); |
| type_name_.clear(); |
| extendee_.clear(); |
| default_value_.clear(); |
| oneof_index_ = static_cast< int32_t >(0); |
| json_name_.clear(); |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| proto3_optional_ = false; |
| } |
| |
| void FieldDescriptorProto::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void FieldDescriptorProto::set_number(const int32_t& value) { |
| has_number_ = true; |
| number_ = value; |
| } |
| |
| void FieldDescriptorProto::set_label(const ::rs::google::protobuf::FieldDescriptorProto::Label& value) { |
| has_label_ = true; |
| label_ = value; |
| } |
| |
| void FieldDescriptorProto::set_type(const ::rs::google::protobuf::FieldDescriptorProto::Type& value) { |
| has_type_ = true; |
| type_ = value; |
| } |
| |
| void FieldDescriptorProto::set_type_name(const std::string& value) { |
| has_type_name_ = true; |
| type_name_ = value; |
| } |
| |
| void FieldDescriptorProto::set_extendee(const std::string& value) { |
| has_extendee_ = true; |
| extendee_ = value; |
| } |
| |
| void FieldDescriptorProto::set_default_value(const std::string& value) { |
| has_default_value_ = true; |
| default_value_ = value; |
| } |
| |
| void FieldDescriptorProto::set_oneof_index(const int32_t& value) { |
| has_oneof_index_ = true; |
| oneof_index_ = value; |
| } |
| |
| void FieldDescriptorProto::set_json_name(const std::string& value) { |
| has_json_name_ = true; |
| json_name_ = value; |
| } |
| |
| void FieldDescriptorProto::set_proto3_optional(const bool& value) { |
| has_proto3_optional_ = true; |
| proto3_optional_ = value; |
| } |
| |
| void OneofOptions::SerializeToOstream(OutputStream* output__) const { |
| if (has_features_) { |
| WriteLengthDelimited(output__, 1, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t OneofOptions::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_features_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void OneofOptions::Clear() { |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| } |
| |
| void OneofOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void OneofDescriptorProto::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 2, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t OneofDescriptorProto::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_options_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void OneofDescriptorProto::Clear() { |
| name_.clear(); |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| } |
| |
| void OneofDescriptorProto::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void EnumOptions::SerializeToOstream(OutputStream* output__) const { |
| if (has_allow_alias_) { |
| WriteVarint32(output__, 2, allow_alias_); |
| } |
| if (has_deprecated_) { |
| WriteVarint32(output__, 3, deprecated_); |
| } |
| if (has_deprecated_legacy_json_field_conflicts_) { |
| WriteVarint32(output__, 6, deprecated_legacy_json_field_conflicts_); |
| } |
| if (has_features_) { |
| WriteLengthDelimited(output__, 7, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t EnumOptions::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_allow_alias_) { |
| size += VarintSizeBool(allow_alias_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_deprecated_) { |
| size += VarintSizeBool(deprecated_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_deprecated_legacy_json_field_conflicts_) { |
| size += VarintSizeBool(deprecated_legacy_json_field_conflicts_) + VarintSize32(6 << kTagTypeBits); |
| } |
| if (has_features_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void EnumOptions::Clear() { |
| allow_alias_ = false; |
| deprecated_ = false; |
| deprecated_legacy_json_field_conflicts_ = false; |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| } |
| |
| void EnumOptions::set_allow_alias(const bool& value) { |
| has_allow_alias_ = true; |
| allow_alias_ = value; |
| } |
| |
| void EnumOptions::set_deprecated(const bool& value) { |
| has_deprecated_ = true; |
| deprecated_ = value; |
| } |
| |
| void EnumOptions::set_deprecated_legacy_json_field_conflicts(const bool& value) { |
| has_deprecated_legacy_json_field_conflicts_ = true; |
| deprecated_legacy_json_field_conflicts_ = value; |
| } |
| |
| void EnumOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void EnumDescriptorProto::EnumReservedRange::SerializeToOstream(OutputStream* output__) const { |
| if (has_start_) { |
| WriteVarint32SignExtended(output__, 1, start_); |
| } |
| if (has_end_) { |
| WriteVarint32SignExtended(output__, 2, end_); |
| } |
| } |
| |
| size_t EnumDescriptorProto::EnumReservedRange::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_start_) { |
| size += VarintSize32SignExtended(start_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_end_) { |
| size += VarintSize32SignExtended(end_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void EnumDescriptorProto::EnumReservedRange::Clear() { |
| start_ = static_cast< int32_t >(0); |
| end_ = static_cast< int32_t >(0); |
| } |
| |
| void EnumDescriptorProto::EnumReservedRange::set_start(const int32_t& value) { |
| has_start_ = true; |
| start_ = value; |
| } |
| |
| void EnumDescriptorProto::EnumReservedRange::set_end(const int32_t& value) { |
| has_end_ = true; |
| end_ = value; |
| } |
| |
| void EnumDescriptorProto::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| for (const auto& elem : value_) { |
| if (has_value_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 3, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : reserved_range_) { |
| if (has_reserved_range_) { |
| WriteLengthDelimited(output__, 4, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : reserved_name_) { |
| WriteString(output__, 5, elem); |
| } |
| } |
| |
| size_t EnumDescriptorProto::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : value_) { |
| if (has_value_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_options_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| for (const auto& elem : reserved_range_) { |
| if (has_reserved_range_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : reserved_name_) { |
| size += StringSize(elem) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void EnumDescriptorProto::Clear() { |
| name_.clear(); |
| if (has_value_) { |
| value_.clear(); |
| has_value_ = false; |
| } |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| if (has_reserved_range_) { |
| reserved_range_.clear(); |
| has_reserved_range_ = false; |
| } |
| reserved_name_.clear(); |
| } |
| |
| void EnumDescriptorProto::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void EnumDescriptorProto::add_value(const ::rs::google::protobuf::EnumValueDescriptorProto& value) { |
| has_value_ = true; |
| value_.push_back(value); |
| } |
| void EnumDescriptorProto::add_reserved_range(const ::rs::google::protobuf::EnumDescriptorProto::EnumReservedRange& value) { |
| has_reserved_range_ = true; |
| reserved_range_.push_back(value); |
| } |
| void EnumDescriptorProto::add_reserved_name(const std::string& value) { |
| has_reserved_name_ = true; |
| reserved_name_.push_back(value); |
| } |
| void EnumDescriptorProto::set_reserved_name(const std::vector< std::string >& value) { |
| has_reserved_name_ = true; |
| reserved_name_ = value; |
| } |
| |
| void EnumValueOptions::SerializeToOstream(OutputStream* output__) const { |
| if (has_deprecated_) { |
| WriteVarint32(output__, 1, deprecated_); |
| } |
| if (has_features_) { |
| WriteLengthDelimited(output__, 2, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| if (has_debug_redact_) { |
| WriteVarint32(output__, 3, debug_redact_); |
| } |
| if (has_feature_support_) { |
| WriteLengthDelimited(output__, 4, |
| feature_support_.ByteSizeLong()); |
| feature_support_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t EnumValueOptions::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_deprecated_) { |
| size += VarintSizeBool(deprecated_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_features_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| if (has_debug_redact_) { |
| size += VarintSizeBool(debug_redact_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_feature_support_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(feature_support_.ByteSizeLong()); |
| size += feature_support_.ByteSizeLong(); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void EnumValueOptions::Clear() { |
| deprecated_ = false; |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| debug_redact_ = false; |
| if (has_feature_support_) { |
| feature_support_.Clear(); |
| has_feature_support_ = false; |
| } |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| } |
| |
| void EnumValueOptions::set_deprecated(const bool& value) { |
| has_deprecated_ = true; |
| deprecated_ = value; |
| } |
| |
| void EnumValueOptions::set_debug_redact(const bool& value) { |
| has_debug_redact_ = true; |
| debug_redact_ = value; |
| } |
| |
| void EnumValueOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void EnumValueDescriptorProto::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_number_) { |
| WriteVarint32SignExtended(output__, 2, number_); |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 3, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t EnumValueDescriptorProto::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_number_) { |
| size += VarintSize32SignExtended(number_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_options_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void EnumValueDescriptorProto::Clear() { |
| name_.clear(); |
| number_ = static_cast< int32_t >(0); |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| } |
| |
| void EnumValueDescriptorProto::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void EnumValueDescriptorProto::set_number(const int32_t& value) { |
| has_number_ = true; |
| number_ = value; |
| } |
| |
| void ServiceOptions::SerializeToOstream(OutputStream* output__) const { |
| if (has_features_) { |
| WriteLengthDelimited(output__, 34, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| if (has_deprecated_) { |
| WriteVarint32(output__, 33, deprecated_); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t ServiceOptions::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_features_) { |
| size += VarintSize32(34 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| if (has_deprecated_) { |
| size += VarintSizeBool(deprecated_) + VarintSize32(33 << kTagTypeBits); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void ServiceOptions::Clear() { |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| deprecated_ = false; |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| } |
| |
| void ServiceOptions::set_deprecated(const bool& value) { |
| has_deprecated_ = true; |
| deprecated_ = value; |
| } |
| |
| void ServiceOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void ServiceDescriptorProto::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| for (const auto& elem : method_) { |
| if (has_method_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 3, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t ServiceDescriptorProto::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : method_) { |
| if (has_method_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_options_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void ServiceDescriptorProto::Clear() { |
| name_.clear(); |
| if (has_method_) { |
| method_.clear(); |
| has_method_ = false; |
| } |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| } |
| |
| void ServiceDescriptorProto::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void ServiceDescriptorProto::add_method(const ::rs::google::protobuf::MethodDescriptorProto& value) { |
| has_method_ = true; |
| method_.push_back(value); |
| } |
| void MethodOptions::SerializeToOstream(OutputStream* output__) const { |
| if (has_deprecated_) { |
| WriteVarint32(output__, 33, deprecated_); |
| } |
| if (has_idempotency_level_) { |
| WriteVarint32SignExtended(output__, 34, static_cast<int32_t>(idempotency_level_)); |
| } |
| if (has_features_) { |
| WriteLengthDelimited(output__, 35, |
| features_.ByteSizeLong()); |
| features_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| WriteLengthDelimited(output__, 999, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t MethodOptions::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_deprecated_) { |
| size += VarintSizeBool(deprecated_) + VarintSize32(33 << kTagTypeBits); |
| } |
| if (has_idempotency_level_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(idempotency_level_)) + VarintSize32(34 << kTagTypeBits); |
| } |
| if (has_features_) { |
| size += VarintSize32(35 << kTagTypeBits) + |
| VarintSize32(features_.ByteSizeLong()); |
| size += features_.ByteSizeLong(); |
| } |
| for (const auto& elem : uninterpreted_option_) { |
| if (has_uninterpreted_option_) { |
| size += VarintSize32(999 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void MethodOptions::Clear() { |
| deprecated_ = false; |
| idempotency_level_ = static_cast< ::rs::google::protobuf::MethodOptions::IdempotencyLevel >(0); |
| if (has_features_) { |
| features_.Clear(); |
| has_features_ = false; |
| } |
| if (has_uninterpreted_option_) { |
| uninterpreted_option_.clear(); |
| has_uninterpreted_option_ = false; |
| } |
| } |
| |
| void MethodOptions::set_deprecated(const bool& value) { |
| has_deprecated_ = true; |
| deprecated_ = value; |
| } |
| |
| void MethodOptions::set_idempotency_level(const ::rs::google::protobuf::MethodOptions::IdempotencyLevel& value) { |
| has_idempotency_level_ = true; |
| idempotency_level_ = value; |
| } |
| |
| void MethodOptions::add_uninterpreted_option(const ::rs::google::protobuf::UninterpretedOption& value) { |
| has_uninterpreted_option_ = true; |
| uninterpreted_option_.push_back(value); |
| } |
| void MethodDescriptorProto::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_input_type_) { |
| WriteString(output__, 2, input_type_); |
| } |
| if (has_output_type_) { |
| WriteString(output__, 3, output_type_); |
| } |
| if (has_options_) { |
| WriteLengthDelimited(output__, 4, |
| options_.ByteSizeLong()); |
| options_.SerializeToOstream(output__); |
| } |
| if (has_client_streaming_) { |
| WriteVarint32(output__, 5, client_streaming_); |
| } |
| if (has_server_streaming_) { |
| WriteVarint32(output__, 6, server_streaming_); |
| } |
| } |
| |
| size_t MethodDescriptorProto::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_input_type_) { |
| size += StringSize(input_type_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_output_type_) { |
| size += StringSize(output_type_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_options_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(options_.ByteSizeLong()); |
| size += options_.ByteSizeLong(); |
| } |
| if (has_client_streaming_) { |
| size += VarintSizeBool(client_streaming_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_server_streaming_) { |
| size += VarintSizeBool(server_streaming_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void MethodDescriptorProto::Clear() { |
| name_.clear(); |
| input_type_.clear(); |
| output_type_.clear(); |
| if (has_options_) { |
| options_.Clear(); |
| has_options_ = false; |
| } |
| client_streaming_ = false; |
| server_streaming_ = false; |
| } |
| |
| void MethodDescriptorProto::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void MethodDescriptorProto::set_input_type(const std::string& value) { |
| has_input_type_ = true; |
| input_type_ = value; |
| } |
| |
| void MethodDescriptorProto::set_output_type(const std::string& value) { |
| has_output_type_ = true; |
| output_type_ = value; |
| } |
| |
| void MethodDescriptorProto::set_client_streaming(const bool& value) { |
| has_client_streaming_ = true; |
| client_streaming_ = value; |
| } |
| |
| void MethodDescriptorProto::set_server_streaming(const bool& value) { |
| has_server_streaming_ = true; |
| server_streaming_ = value; |
| } |
| |
| void UninterpretedOption::NamePart::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_part_) { |
| WriteString(output__, 1, name_part_); |
| } |
| if (has_is_extension_) { |
| WriteVarint32(output__, 2, is_extension_); |
| } |
| } |
| |
| size_t UninterpretedOption::NamePart::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_part_) { |
| size += StringSize(name_part_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_is_extension_) { |
| size += VarintSizeBool(is_extension_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UninterpretedOption::NamePart::Clear() { |
| name_part_.clear(); |
| is_extension_ = false; |
| } |
| |
| void UninterpretedOption::NamePart::set_name_part(const std::string& value) { |
| has_name_part_ = true; |
| name_part_ = value; |
| } |
| |
| void UninterpretedOption::NamePart::set_is_extension(const bool& value) { |
| has_is_extension_ = true; |
| is_extension_ = value; |
| } |
| |
| void UninterpretedOption::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : name_) { |
| if (has_name_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_identifier_value_) { |
| WriteString(output__, 3, identifier_value_); |
| } |
| if (has_positive_int_value_) { |
| WriteVarint64(output__, 4, positive_int_value_); |
| } |
| if (has_negative_int_value_) { |
| WriteVarint64(output__, 5, negative_int_value_); |
| } |
| if (has_double_value_) { |
| WriteFixed64(output__, 6, static_cast<uint64_t>(double_value_)); |
| } |
| if (has_string_value_) { |
| WriteString(output__, 7, string_value_); |
| } |
| if (has_aggregate_value_) { |
| WriteString(output__, 8, aggregate_value_); |
| } |
| } |
| |
| size_t UninterpretedOption::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : name_) { |
| if (has_name_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_identifier_value_) { |
| size += StringSize(identifier_value_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_positive_int_value_) { |
| size += VarintSize64(positive_int_value_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_negative_int_value_) { |
| size += VarintSize64(negative_int_value_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_double_value_) { |
| size += FixedSize64(static_cast<uint64_t>(double_value_)) + VarintSize32(6 << kTagTypeBits); |
| } |
| if (has_string_value_) { |
| size += StringSize(string_value_) + VarintSize32(7 << kTagTypeBits); |
| } |
| if (has_aggregate_value_) { |
| size += StringSize(aggregate_value_) + VarintSize32(8 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UninterpretedOption::Clear() { |
| if (has_name_) { |
| name_.clear(); |
| has_name_ = false; |
| } |
| identifier_value_.clear(); |
| positive_int_value_ = static_cast< uint64_t >(0); |
| negative_int_value_ = static_cast< int64_t >(0); |
| double_value_ = static_cast< double >(0); |
| string_value_.clear(); |
| aggregate_value_.clear(); |
| } |
| |
| void UninterpretedOption::add_name(const ::rs::google::protobuf::UninterpretedOption::NamePart& value) { |
| has_name_ = true; |
| name_.push_back(value); |
| } |
| void UninterpretedOption::set_identifier_value(const std::string& value) { |
| has_identifier_value_ = true; |
| identifier_value_ = value; |
| } |
| |
| void UninterpretedOption::set_positive_int_value(const uint64_t& value) { |
| has_positive_int_value_ = true; |
| positive_int_value_ = value; |
| } |
| |
| void UninterpretedOption::set_negative_int_value(const int64_t& value) { |
| has_negative_int_value_ = true; |
| negative_int_value_ = value; |
| } |
| |
| void UninterpretedOption::set_double_value(const double& value) { |
| has_double_value_ = true; |
| double_value_ = value; |
| } |
| |
| void UninterpretedOption::set_string_value(const std::string& value) { |
| has_string_value_ = true; |
| string_value_ = value; |
| } |
| |
| void UninterpretedOption::set_aggregate_value(const std::string& value) { |
| has_aggregate_value_ = true; |
| aggregate_value_ = value; |
| } |
| |
| void FeatureSetDefaults::FeatureSetEditionDefault::SerializeToOstream(OutputStream* output__) const { |
| if (has_edition_) { |
| WriteVarint32SignExtended(output__, 3, static_cast<int32_t>(edition_)); |
| } |
| if (has_overridable_features_) { |
| WriteLengthDelimited(output__, 4, |
| overridable_features_.ByteSizeLong()); |
| overridable_features_.SerializeToOstream(output__); |
| } |
| if (has_fixed_features_) { |
| WriteLengthDelimited(output__, 5, |
| fixed_features_.ByteSizeLong()); |
| fixed_features_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t FeatureSetDefaults::FeatureSetEditionDefault::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_edition_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(edition_)) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_overridable_features_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(overridable_features_.ByteSizeLong()); |
| size += overridable_features_.ByteSizeLong(); |
| } |
| if (has_fixed_features_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(fixed_features_.ByteSizeLong()); |
| size += fixed_features_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void FeatureSetDefaults::FeatureSetEditionDefault::Clear() { |
| edition_ = static_cast< ::rs::google::protobuf::Edition >(0); |
| if (has_overridable_features_) { |
| overridable_features_.Clear(); |
| has_overridable_features_ = false; |
| } |
| if (has_fixed_features_) { |
| fixed_features_.Clear(); |
| has_fixed_features_ = false; |
| } |
| } |
| |
| void FeatureSetDefaults::FeatureSetEditionDefault::set_edition(const ::rs::google::protobuf::Edition& value) { |
| has_edition_ = true; |
| edition_ = value; |
| } |
| |
| void FeatureSetDefaults::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : defaults_) { |
| if (has_defaults_) { |
| WriteLengthDelimited(output__, 1, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_minimum_edition_) { |
| WriteVarint32SignExtended(output__, 4, static_cast<int32_t>(minimum_edition_)); |
| } |
| if (has_maximum_edition_) { |
| WriteVarint32SignExtended(output__, 5, static_cast<int32_t>(maximum_edition_)); |
| } |
| } |
| |
| size_t FeatureSetDefaults::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : defaults_) { |
| if (has_defaults_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_minimum_edition_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(minimum_edition_)) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_maximum_edition_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(maximum_edition_)) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FeatureSetDefaults::Clear() { |
| if (has_defaults_) { |
| defaults_.clear(); |
| has_defaults_ = false; |
| } |
| minimum_edition_ = static_cast< ::rs::google::protobuf::Edition >(0); |
| maximum_edition_ = static_cast< ::rs::google::protobuf::Edition >(0); |
| } |
| |
| void FeatureSetDefaults::add_defaults(const ::rs::google::protobuf::FeatureSetDefaults::FeatureSetEditionDefault& value) { |
| has_defaults_ = true; |
| defaults_.push_back(value); |
| } |
| void FeatureSetDefaults::set_minimum_edition(const ::rs::google::protobuf::Edition& value) { |
| has_minimum_edition_ = true; |
| minimum_edition_ = value; |
| } |
| |
| void FeatureSetDefaults::set_maximum_edition(const ::rs::google::protobuf::Edition& value) { |
| has_maximum_edition_ = true; |
| maximum_edition_ = value; |
| } |
| |
| void GeneratedCodeInfo::Annotation::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : path_) { |
| WriteVarint32SignExtended(output__, 1, elem); |
| } |
| if (has_source_file_) { |
| WriteString(output__, 2, source_file_); |
| } |
| if (has_begin_) { |
| WriteVarint32SignExtended(output__, 3, begin_); |
| } |
| if (has_end_) { |
| WriteVarint32SignExtended(output__, 4, end_); |
| } |
| if (has_semantic_) { |
| WriteVarint32SignExtended(output__, 5, static_cast<int32_t>(semantic_)); |
| } |
| } |
| |
| size_t GeneratedCodeInfo::Annotation::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : path_) { |
| size += VarintSize32SignExtended(elem) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_source_file_) { |
| size += StringSize(source_file_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_begin_) { |
| size += VarintSize32SignExtended(begin_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_end_) { |
| size += VarintSize32SignExtended(end_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_semantic_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(semantic_)) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void GeneratedCodeInfo::Annotation::Clear() { |
| path_.clear(); |
| source_file_.clear(); |
| begin_ = static_cast< int32_t >(0); |
| end_ = static_cast< int32_t >(0); |
| semantic_ = static_cast< ::rs::google::protobuf::GeneratedCodeInfo::Annotation::Semantic >(0); |
| } |
| |
| void GeneratedCodeInfo::Annotation::add_path(const int32_t& value) { |
| has_path_ = true; |
| path_.push_back(value); |
| } |
| void GeneratedCodeInfo::Annotation::set_path(const std::vector< int32_t >& value) { |
| has_path_ = true; |
| path_ = value; |
| } |
| |
| void GeneratedCodeInfo::Annotation::set_source_file(const std::string& value) { |
| has_source_file_ = true; |
| source_file_ = value; |
| } |
| |
| void GeneratedCodeInfo::Annotation::set_begin(const int32_t& value) { |
| has_begin_ = true; |
| begin_ = value; |
| } |
| |
| void GeneratedCodeInfo::Annotation::set_end(const int32_t& value) { |
| has_end_ = true; |
| end_ = value; |
| } |
| |
| void GeneratedCodeInfo::Annotation::set_semantic(const ::rs::google::protobuf::GeneratedCodeInfo::Annotation::Semantic& value) { |
| has_semantic_ = true; |
| semantic_ = value; |
| } |
| |
| void GeneratedCodeInfo::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : annotation_) { |
| if (has_annotation_) { |
| WriteLengthDelimited(output__, 1, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t GeneratedCodeInfo::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : annotation_) { |
| if (has_annotation_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void GeneratedCodeInfo::Clear() { |
| if (has_annotation_) { |
| annotation_.clear(); |
| has_annotation_ = false; |
| } |
| } |
| |
| void GeneratedCodeInfo::add_annotation(const ::rs::google::protobuf::GeneratedCodeInfo::Annotation& value) { |
| has_annotation_ = true; |
| annotation_.push_back(value); |
| } |
| } // namespace protobuf |
| } // namespace google |
| namespace google { |
| namespace api { |
| } // namespace api |
| } // namespace google |
| namespace google { |
| namespace api { |
| } // namespace api |
| } // namespace google |
| namespace google { |
| namespace protobuf { |
| void Duration::SerializeToOstream(OutputStream* output__) const { |
| if (has_seconds_) { |
| WriteVarint64(output__, 1, seconds_); |
| } |
| if (has_nanos_) { |
| WriteVarint32SignExtended(output__, 2, nanos_); |
| } |
| } |
| |
| size_t Duration::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_seconds_) { |
| size += VarintSize64(seconds_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_nanos_) { |
| size += VarintSize32SignExtended(nanos_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Duration::Clear() { |
| seconds_ = static_cast< int64_t >(0); |
| nanos_ = static_cast< int32_t >(0); |
| } |
| |
| void Duration::set_seconds(const int64_t& value) { |
| has_seconds_ = true; |
| seconds_ = value; |
| } |
| |
| void Duration::set_nanos(const int32_t& value) { |
| has_nanos_ = true; |
| nanos_ = value; |
| } |
| |
| } // namespace protobuf |
| } // namespace google |
| namespace google { |
| namespace api { |
| void SelectiveGapicGeneration::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : methods_) { |
| WriteString(output__, 1, elem); |
| } |
| if (has_generate_omitted_as_internal_) { |
| WriteVarint32(output__, 2, generate_omitted_as_internal_); |
| } |
| } |
| |
| size_t SelectiveGapicGeneration::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : methods_) { |
| size += StringSize(elem) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_generate_omitted_as_internal_) { |
| size += VarintSizeBool(generate_omitted_as_internal_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void SelectiveGapicGeneration::Clear() { |
| methods_.clear(); |
| generate_omitted_as_internal_ = false; |
| } |
| |
| void SelectiveGapicGeneration::add_methods(const std::string& value) { |
| has_methods_ = true; |
| methods_.push_back(value); |
| } |
| void SelectiveGapicGeneration::set_methods(const std::vector< std::string >& value) { |
| has_methods_ = true; |
| methods_ = value; |
| } |
| |
| void SelectiveGapicGeneration::set_generate_omitted_as_internal(const bool& value) { |
| has_generate_omitted_as_internal_ = true; |
| generate_omitted_as_internal_ = value; |
| } |
| |
| void CommonLanguageSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_reference_docs_uri_) { |
| WriteString(output__, 1, reference_docs_uri_); |
| } |
| for (const auto& elem : destinations_) { |
| WriteVarint32SignExtended(output__, 2, static_cast<int32_t>(elem)); |
| } |
| if (has_selective_gapic_generation_) { |
| WriteLengthDelimited(output__, 3, |
| selective_gapic_generation_.ByteSizeLong()); |
| selective_gapic_generation_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t CommonLanguageSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_reference_docs_uri_) { |
| size += StringSize(reference_docs_uri_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : destinations_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(elem)) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_selective_gapic_generation_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(selective_gapic_generation_.ByteSizeLong()); |
| size += selective_gapic_generation_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void CommonLanguageSettings::Clear() { |
| reference_docs_uri_.clear(); |
| destinations_.clear(); |
| if (has_selective_gapic_generation_) { |
| selective_gapic_generation_.Clear(); |
| has_selective_gapic_generation_ = false; |
| } |
| } |
| |
| void CommonLanguageSettings::set_reference_docs_uri(const std::string& value) { |
| has_reference_docs_uri_ = true; |
| reference_docs_uri_ = value; |
| } |
| |
| void CommonLanguageSettings::add_destinations(const ::rs::google::api::ClientLibraryDestination& value) { |
| has_destinations_ = true; |
| destinations_.push_back(value); |
| } |
| void CommonLanguageSettings::set_destinations(const std::vector< ::rs::google::api::ClientLibraryDestination >& value) { |
| has_destinations_ = true; |
| destinations_ = value; |
| } |
| |
| void CppSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_common_) { |
| WriteLengthDelimited(output__, 1, |
| common_.ByteSizeLong()); |
| common_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t CppSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_common_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(common_.ByteSizeLong()); |
| size += common_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void CppSettings::Clear() { |
| if (has_common_) { |
| common_.Clear(); |
| has_common_ = false; |
| } |
| } |
| |
| void DotnetSettings::RenamedServicesEntry::SerializeToOstream(OutputStream* output__) const { |
| if (has_key_) { |
| WriteString(output__, 1, key_); |
| } |
| if (has_value_) { |
| WriteString(output__, 2, value_); |
| } |
| } |
| |
| size_t DotnetSettings::RenamedServicesEntry::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_key_) { |
| size += StringSize(key_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_value_) { |
| size += StringSize(value_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void DotnetSettings::RenamedServicesEntry::Clear() { |
| key_.clear(); |
| value_.clear(); |
| } |
| |
| void DotnetSettings::RenamedServicesEntry::set_key(const std::string& value) { |
| has_key_ = true; |
| key_ = value; |
| } |
| |
| void DotnetSettings::RenamedServicesEntry::set_value(const std::string& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void DotnetSettings::RenamedResourcesEntry::SerializeToOstream(OutputStream* output__) const { |
| if (has_key_) { |
| WriteString(output__, 1, key_); |
| } |
| if (has_value_) { |
| WriteString(output__, 2, value_); |
| } |
| } |
| |
| size_t DotnetSettings::RenamedResourcesEntry::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_key_) { |
| size += StringSize(key_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_value_) { |
| size += StringSize(value_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void DotnetSettings::RenamedResourcesEntry::Clear() { |
| key_.clear(); |
| value_.clear(); |
| } |
| |
| void DotnetSettings::RenamedResourcesEntry::set_key(const std::string& value) { |
| has_key_ = true; |
| key_ = value; |
| } |
| |
| void DotnetSettings::RenamedResourcesEntry::set_value(const std::string& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void DotnetSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_common_) { |
| WriteLengthDelimited(output__, 1, |
| common_.ByteSizeLong()); |
| common_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : renamed_services_) { |
| if (has_renamed_services_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : renamed_resources_) { |
| if (has_renamed_resources_) { |
| WriteLengthDelimited(output__, 3, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : ignored_resources_) { |
| WriteString(output__, 4, elem); |
| } |
| for (const auto& elem : forced_namespace_aliases_) { |
| WriteString(output__, 5, elem); |
| } |
| for (const auto& elem : handwritten_signatures_) { |
| WriteString(output__, 6, elem); |
| } |
| } |
| |
| size_t DotnetSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_common_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(common_.ByteSizeLong()); |
| size += common_.ByteSizeLong(); |
| } |
| for (const auto& elem : renamed_services_) { |
| if (has_renamed_services_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : renamed_resources_) { |
| if (has_renamed_resources_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : ignored_resources_) { |
| size += StringSize(elem) + VarintSize32(4 << kTagTypeBits); |
| } |
| for (const auto& elem : forced_namespace_aliases_) { |
| size += StringSize(elem) + VarintSize32(5 << kTagTypeBits); |
| } |
| for (const auto& elem : handwritten_signatures_) { |
| size += StringSize(elem) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void DotnetSettings::Clear() { |
| if (has_common_) { |
| common_.Clear(); |
| has_common_ = false; |
| } |
| if (has_renamed_services_) { |
| renamed_services_.clear(); |
| has_renamed_services_ = false; |
| } |
| if (has_renamed_resources_) { |
| renamed_resources_.clear(); |
| has_renamed_resources_ = false; |
| } |
| ignored_resources_.clear(); |
| forced_namespace_aliases_.clear(); |
| handwritten_signatures_.clear(); |
| } |
| |
| void DotnetSettings::add_renamed_services(const ::rs::google::api::DotnetSettings::RenamedServicesEntry& value) { |
| has_renamed_services_ = true; |
| renamed_services_.push_back(value); |
| } |
| void DotnetSettings::add_renamed_resources(const ::rs::google::api::DotnetSettings::RenamedResourcesEntry& value) { |
| has_renamed_resources_ = true; |
| renamed_resources_.push_back(value); |
| } |
| void DotnetSettings::add_ignored_resources(const std::string& value) { |
| has_ignored_resources_ = true; |
| ignored_resources_.push_back(value); |
| } |
| void DotnetSettings::set_ignored_resources(const std::vector< std::string >& value) { |
| has_ignored_resources_ = true; |
| ignored_resources_ = value; |
| } |
| |
| void DotnetSettings::add_forced_namespace_aliases(const std::string& value) { |
| has_forced_namespace_aliases_ = true; |
| forced_namespace_aliases_.push_back(value); |
| } |
| void DotnetSettings::set_forced_namespace_aliases(const std::vector< std::string >& value) { |
| has_forced_namespace_aliases_ = true; |
| forced_namespace_aliases_ = value; |
| } |
| |
| void DotnetSettings::add_handwritten_signatures(const std::string& value) { |
| has_handwritten_signatures_ = true; |
| handwritten_signatures_.push_back(value); |
| } |
| void DotnetSettings::set_handwritten_signatures(const std::vector< std::string >& value) { |
| has_handwritten_signatures_ = true; |
| handwritten_signatures_ = value; |
| } |
| |
| void GoSettings::RenamedServicesEntry::SerializeToOstream(OutputStream* output__) const { |
| if (has_key_) { |
| WriteString(output__, 1, key_); |
| } |
| if (has_value_) { |
| WriteString(output__, 2, value_); |
| } |
| } |
| |
| size_t GoSettings::RenamedServicesEntry::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_key_) { |
| size += StringSize(key_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_value_) { |
| size += StringSize(value_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void GoSettings::RenamedServicesEntry::Clear() { |
| key_.clear(); |
| value_.clear(); |
| } |
| |
| void GoSettings::RenamedServicesEntry::set_key(const std::string& value) { |
| has_key_ = true; |
| key_ = value; |
| } |
| |
| void GoSettings::RenamedServicesEntry::set_value(const std::string& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void GoSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_common_) { |
| WriteLengthDelimited(output__, 1, |
| common_.ByteSizeLong()); |
| common_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : renamed_services_) { |
| if (has_renamed_services_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t GoSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_common_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(common_.ByteSizeLong()); |
| size += common_.ByteSizeLong(); |
| } |
| for (const auto& elem : renamed_services_) { |
| if (has_renamed_services_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void GoSettings::Clear() { |
| if (has_common_) { |
| common_.Clear(); |
| has_common_ = false; |
| } |
| if (has_renamed_services_) { |
| renamed_services_.clear(); |
| has_renamed_services_ = false; |
| } |
| } |
| |
| void GoSettings::add_renamed_services(const ::rs::google::api::GoSettings::RenamedServicesEntry& value) { |
| has_renamed_services_ = true; |
| renamed_services_.push_back(value); |
| } |
| void JavaSettings::ServiceClassNamesEntry::SerializeToOstream(OutputStream* output__) const { |
| if (has_key_) { |
| WriteString(output__, 1, key_); |
| } |
| if (has_value_) { |
| WriteString(output__, 2, value_); |
| } |
| } |
| |
| size_t JavaSettings::ServiceClassNamesEntry::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_key_) { |
| size += StringSize(key_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_value_) { |
| size += StringSize(value_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void JavaSettings::ServiceClassNamesEntry::Clear() { |
| key_.clear(); |
| value_.clear(); |
| } |
| |
| void JavaSettings::ServiceClassNamesEntry::set_key(const std::string& value) { |
| has_key_ = true; |
| key_ = value; |
| } |
| |
| void JavaSettings::ServiceClassNamesEntry::set_value(const std::string& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void JavaSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_library_package_) { |
| WriteString(output__, 1, library_package_); |
| } |
| for (const auto& elem : service_class_names_) { |
| if (has_service_class_names_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_common_) { |
| WriteLengthDelimited(output__, 3, |
| common_.ByteSizeLong()); |
| common_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t JavaSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_library_package_) { |
| size += StringSize(library_package_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : service_class_names_) { |
| if (has_service_class_names_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_common_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(common_.ByteSizeLong()); |
| size += common_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void JavaSettings::Clear() { |
| library_package_.clear(); |
| if (has_service_class_names_) { |
| service_class_names_.clear(); |
| has_service_class_names_ = false; |
| } |
| if (has_common_) { |
| common_.Clear(); |
| has_common_ = false; |
| } |
| } |
| |
| void JavaSettings::set_library_package(const std::string& value) { |
| has_library_package_ = true; |
| library_package_ = value; |
| } |
| |
| void JavaSettings::add_service_class_names(const ::rs::google::api::JavaSettings::ServiceClassNamesEntry& value) { |
| has_service_class_names_ = true; |
| service_class_names_.push_back(value); |
| } |
| void NodeSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_common_) { |
| WriteLengthDelimited(output__, 1, |
| common_.ByteSizeLong()); |
| common_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t NodeSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_common_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(common_.ByteSizeLong()); |
| size += common_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void NodeSettings::Clear() { |
| if (has_common_) { |
| common_.Clear(); |
| has_common_ = false; |
| } |
| } |
| |
| void PhpSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_common_) { |
| WriteLengthDelimited(output__, 1, |
| common_.ByteSizeLong()); |
| common_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t PhpSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_common_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(common_.ByteSizeLong()); |
| size += common_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void PhpSettings::Clear() { |
| if (has_common_) { |
| common_.Clear(); |
| has_common_ = false; |
| } |
| } |
| |
| void PythonSettings::ExperimentalFeatures::SerializeToOstream(OutputStream* output__) const { |
| if (has_rest_async_io_enabled_) { |
| WriteVarint32(output__, 1, rest_async_io_enabled_); |
| } |
| if (has_protobuf_pythonic_types_enabled_) { |
| WriteVarint32(output__, 2, protobuf_pythonic_types_enabled_); |
| } |
| if (has_unversioned_package_disabled_) { |
| WriteVarint32(output__, 3, unversioned_package_disabled_); |
| } |
| } |
| |
| size_t PythonSettings::ExperimentalFeatures::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_rest_async_io_enabled_) { |
| size += VarintSizeBool(rest_async_io_enabled_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_protobuf_pythonic_types_enabled_) { |
| size += VarintSizeBool(protobuf_pythonic_types_enabled_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_unversioned_package_disabled_) { |
| size += VarintSizeBool(unversioned_package_disabled_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void PythonSettings::ExperimentalFeatures::Clear() { |
| rest_async_io_enabled_ = false; |
| protobuf_pythonic_types_enabled_ = false; |
| unversioned_package_disabled_ = false; |
| } |
| |
| void PythonSettings::ExperimentalFeatures::set_rest_async_io_enabled(const bool& value) { |
| has_rest_async_io_enabled_ = true; |
| rest_async_io_enabled_ = value; |
| } |
| |
| void PythonSettings::ExperimentalFeatures::set_protobuf_pythonic_types_enabled(const bool& value) { |
| has_protobuf_pythonic_types_enabled_ = true; |
| protobuf_pythonic_types_enabled_ = value; |
| } |
| |
| void PythonSettings::ExperimentalFeatures::set_unversioned_package_disabled(const bool& value) { |
| has_unversioned_package_disabled_ = true; |
| unversioned_package_disabled_ = value; |
| } |
| |
| void PythonSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_common_) { |
| WriteLengthDelimited(output__, 1, |
| common_.ByteSizeLong()); |
| common_.SerializeToOstream(output__); |
| } |
| if (has_experimental_features_) { |
| WriteLengthDelimited(output__, 2, |
| experimental_features_.ByteSizeLong()); |
| experimental_features_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t PythonSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_common_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(common_.ByteSizeLong()); |
| size += common_.ByteSizeLong(); |
| } |
| if (has_experimental_features_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(experimental_features_.ByteSizeLong()); |
| size += experimental_features_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void PythonSettings::Clear() { |
| if (has_common_) { |
| common_.Clear(); |
| has_common_ = false; |
| } |
| if (has_experimental_features_) { |
| experimental_features_.Clear(); |
| has_experimental_features_ = false; |
| } |
| } |
| |
| void RubySettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_common_) { |
| WriteLengthDelimited(output__, 1, |
| common_.ByteSizeLong()); |
| common_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t RubySettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_common_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(common_.ByteSizeLong()); |
| size += common_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void RubySettings::Clear() { |
| if (has_common_) { |
| common_.Clear(); |
| has_common_ = false; |
| } |
| } |
| |
| void ClientLibrarySettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_version_) { |
| WriteString(output__, 1, version_); |
| } |
| if (has_launch_stage_) { |
| WriteVarint32SignExtended(output__, 2, static_cast<int32_t>(launch_stage_)); |
| } |
| if (has_rest_numeric_enums_) { |
| WriteVarint32(output__, 3, rest_numeric_enums_); |
| } |
| if (has_java_settings_) { |
| WriteLengthDelimited(output__, 21, |
| java_settings_.ByteSizeLong()); |
| java_settings_.SerializeToOstream(output__); |
| } |
| if (has_cpp_settings_) { |
| WriteLengthDelimited(output__, 22, |
| cpp_settings_.ByteSizeLong()); |
| cpp_settings_.SerializeToOstream(output__); |
| } |
| if (has_php_settings_) { |
| WriteLengthDelimited(output__, 23, |
| php_settings_.ByteSizeLong()); |
| php_settings_.SerializeToOstream(output__); |
| } |
| if (has_python_settings_) { |
| WriteLengthDelimited(output__, 24, |
| python_settings_.ByteSizeLong()); |
| python_settings_.SerializeToOstream(output__); |
| } |
| if (has_node_settings_) { |
| WriteLengthDelimited(output__, 25, |
| node_settings_.ByteSizeLong()); |
| node_settings_.SerializeToOstream(output__); |
| } |
| if (has_dotnet_settings_) { |
| WriteLengthDelimited(output__, 26, |
| dotnet_settings_.ByteSizeLong()); |
| dotnet_settings_.SerializeToOstream(output__); |
| } |
| if (has_ruby_settings_) { |
| WriteLengthDelimited(output__, 27, |
| ruby_settings_.ByteSizeLong()); |
| ruby_settings_.SerializeToOstream(output__); |
| } |
| if (has_go_settings_) { |
| WriteLengthDelimited(output__, 28, |
| go_settings_.ByteSizeLong()); |
| go_settings_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t ClientLibrarySettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_version_) { |
| size += StringSize(version_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_launch_stage_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(launch_stage_)) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_rest_numeric_enums_) { |
| size += VarintSizeBool(rest_numeric_enums_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_java_settings_) { |
| size += VarintSize32(21 << kTagTypeBits) + |
| VarintSize32(java_settings_.ByteSizeLong()); |
| size += java_settings_.ByteSizeLong(); |
| } |
| if (has_cpp_settings_) { |
| size += VarintSize32(22 << kTagTypeBits) + |
| VarintSize32(cpp_settings_.ByteSizeLong()); |
| size += cpp_settings_.ByteSizeLong(); |
| } |
| if (has_php_settings_) { |
| size += VarintSize32(23 << kTagTypeBits) + |
| VarintSize32(php_settings_.ByteSizeLong()); |
| size += php_settings_.ByteSizeLong(); |
| } |
| if (has_python_settings_) { |
| size += VarintSize32(24 << kTagTypeBits) + |
| VarintSize32(python_settings_.ByteSizeLong()); |
| size += python_settings_.ByteSizeLong(); |
| } |
| if (has_node_settings_) { |
| size += VarintSize32(25 << kTagTypeBits) + |
| VarintSize32(node_settings_.ByteSizeLong()); |
| size += node_settings_.ByteSizeLong(); |
| } |
| if (has_dotnet_settings_) { |
| size += VarintSize32(26 << kTagTypeBits) + |
| VarintSize32(dotnet_settings_.ByteSizeLong()); |
| size += dotnet_settings_.ByteSizeLong(); |
| } |
| if (has_ruby_settings_) { |
| size += VarintSize32(27 << kTagTypeBits) + |
| VarintSize32(ruby_settings_.ByteSizeLong()); |
| size += ruby_settings_.ByteSizeLong(); |
| } |
| if (has_go_settings_) { |
| size += VarintSize32(28 << kTagTypeBits) + |
| VarintSize32(go_settings_.ByteSizeLong()); |
| size += go_settings_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void ClientLibrarySettings::Clear() { |
| version_.clear(); |
| launch_stage_ = static_cast< ::rs::google::api::LaunchStage >(0); |
| rest_numeric_enums_ = false; |
| if (has_java_settings_) { |
| java_settings_.Clear(); |
| has_java_settings_ = false; |
| } |
| if (has_cpp_settings_) { |
| cpp_settings_.Clear(); |
| has_cpp_settings_ = false; |
| } |
| if (has_php_settings_) { |
| php_settings_.Clear(); |
| has_php_settings_ = false; |
| } |
| if (has_python_settings_) { |
| python_settings_.Clear(); |
| has_python_settings_ = false; |
| } |
| if (has_node_settings_) { |
| node_settings_.Clear(); |
| has_node_settings_ = false; |
| } |
| if (has_dotnet_settings_) { |
| dotnet_settings_.Clear(); |
| has_dotnet_settings_ = false; |
| } |
| if (has_ruby_settings_) { |
| ruby_settings_.Clear(); |
| has_ruby_settings_ = false; |
| } |
| if (has_go_settings_) { |
| go_settings_.Clear(); |
| has_go_settings_ = false; |
| } |
| } |
| |
| void ClientLibrarySettings::set_version(const std::string& value) { |
| has_version_ = true; |
| version_ = value; |
| } |
| |
| void ClientLibrarySettings::set_launch_stage(const ::rs::google::api::LaunchStage& value) { |
| has_launch_stage_ = true; |
| launch_stage_ = value; |
| } |
| |
| void ClientLibrarySettings::set_rest_numeric_enums(const bool& value) { |
| has_rest_numeric_enums_ = true; |
| rest_numeric_enums_ = value; |
| } |
| |
| void Publishing::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : method_settings_) { |
| if (has_method_settings_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_new_issue_uri_) { |
| WriteString(output__, 101, new_issue_uri_); |
| } |
| if (has_documentation_uri_) { |
| WriteString(output__, 102, documentation_uri_); |
| } |
| if (has_api_short_name_) { |
| WriteString(output__, 103, api_short_name_); |
| } |
| if (has_github_label_) { |
| WriteString(output__, 104, github_label_); |
| } |
| for (const auto& elem : codeowner_github_teams_) { |
| WriteString(output__, 105, elem); |
| } |
| if (has_doc_tag_prefix_) { |
| WriteString(output__, 106, doc_tag_prefix_); |
| } |
| if (has_organization_) { |
| WriteVarint32SignExtended(output__, 107, static_cast<int32_t>(organization_)); |
| } |
| for (const auto& elem : library_settings_) { |
| if (has_library_settings_) { |
| WriteLengthDelimited(output__, 109, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_proto_reference_documentation_uri_) { |
| WriteString(output__, 110, proto_reference_documentation_uri_); |
| } |
| if (has_rest_reference_documentation_uri_) { |
| WriteString(output__, 111, rest_reference_documentation_uri_); |
| } |
| } |
| |
| size_t Publishing::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : method_settings_) { |
| if (has_method_settings_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_new_issue_uri_) { |
| size += StringSize(new_issue_uri_) + VarintSize32(101 << kTagTypeBits); |
| } |
| if (has_documentation_uri_) { |
| size += StringSize(documentation_uri_) + VarintSize32(102 << kTagTypeBits); |
| } |
| if (has_api_short_name_) { |
| size += StringSize(api_short_name_) + VarintSize32(103 << kTagTypeBits); |
| } |
| if (has_github_label_) { |
| size += StringSize(github_label_) + VarintSize32(104 << kTagTypeBits); |
| } |
| for (const auto& elem : codeowner_github_teams_) { |
| size += StringSize(elem) + VarintSize32(105 << kTagTypeBits); |
| } |
| if (has_doc_tag_prefix_) { |
| size += StringSize(doc_tag_prefix_) + VarintSize32(106 << kTagTypeBits); |
| } |
| if (has_organization_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(organization_)) + VarintSize32(107 << kTagTypeBits); |
| } |
| for (const auto& elem : library_settings_) { |
| if (has_library_settings_) { |
| size += VarintSize32(109 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_proto_reference_documentation_uri_) { |
| size += StringSize(proto_reference_documentation_uri_) + VarintSize32(110 << kTagTypeBits); |
| } |
| if (has_rest_reference_documentation_uri_) { |
| size += StringSize(rest_reference_documentation_uri_) + VarintSize32(111 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Publishing::Clear() { |
| if (has_method_settings_) { |
| method_settings_.clear(); |
| has_method_settings_ = false; |
| } |
| new_issue_uri_.clear(); |
| documentation_uri_.clear(); |
| api_short_name_.clear(); |
| github_label_.clear(); |
| codeowner_github_teams_.clear(); |
| doc_tag_prefix_.clear(); |
| organization_ = static_cast< ::rs::google::api::ClientLibraryOrganization >(0); |
| if (has_library_settings_) { |
| library_settings_.clear(); |
| has_library_settings_ = false; |
| } |
| proto_reference_documentation_uri_.clear(); |
| rest_reference_documentation_uri_.clear(); |
| } |
| |
| void Publishing::add_method_settings(const ::rs::google::api::MethodSettings& value) { |
| has_method_settings_ = true; |
| method_settings_.push_back(value); |
| } |
| void Publishing::set_new_issue_uri(const std::string& value) { |
| has_new_issue_uri_ = true; |
| new_issue_uri_ = value; |
| } |
| |
| void Publishing::set_documentation_uri(const std::string& value) { |
| has_documentation_uri_ = true; |
| documentation_uri_ = value; |
| } |
| |
| void Publishing::set_api_short_name(const std::string& value) { |
| has_api_short_name_ = true; |
| api_short_name_ = value; |
| } |
| |
| void Publishing::set_github_label(const std::string& value) { |
| has_github_label_ = true; |
| github_label_ = value; |
| } |
| |
| void Publishing::add_codeowner_github_teams(const std::string& value) { |
| has_codeowner_github_teams_ = true; |
| codeowner_github_teams_.push_back(value); |
| } |
| void Publishing::set_codeowner_github_teams(const std::vector< std::string >& value) { |
| has_codeowner_github_teams_ = true; |
| codeowner_github_teams_ = value; |
| } |
| |
| void Publishing::set_doc_tag_prefix(const std::string& value) { |
| has_doc_tag_prefix_ = true; |
| doc_tag_prefix_ = value; |
| } |
| |
| void Publishing::set_organization(const ::rs::google::api::ClientLibraryOrganization& value) { |
| has_organization_ = true; |
| organization_ = value; |
| } |
| |
| void Publishing::add_library_settings(const ::rs::google::api::ClientLibrarySettings& value) { |
| has_library_settings_ = true; |
| library_settings_.push_back(value); |
| } |
| void Publishing::set_proto_reference_documentation_uri(const std::string& value) { |
| has_proto_reference_documentation_uri_ = true; |
| proto_reference_documentation_uri_ = value; |
| } |
| |
| void Publishing::set_rest_reference_documentation_uri(const std::string& value) { |
| has_rest_reference_documentation_uri_ = true; |
| rest_reference_documentation_uri_ = value; |
| } |
| |
| void MethodSettings::LongRunning::SerializeToOstream(OutputStream* output__) const { |
| if (has_initial_poll_delay_) { |
| WriteLengthDelimited(output__, 1, |
| initial_poll_delay_.ByteSizeLong()); |
| initial_poll_delay_.SerializeToOstream(output__); |
| } |
| if (has_poll_delay_multiplier_) { |
| WriteFixed32(output__, 2, static_cast<uint32_t>(poll_delay_multiplier_)); |
| } |
| if (has_max_poll_delay_) { |
| WriteLengthDelimited(output__, 3, |
| max_poll_delay_.ByteSizeLong()); |
| max_poll_delay_.SerializeToOstream(output__); |
| } |
| if (has_total_poll_timeout_) { |
| WriteLengthDelimited(output__, 4, |
| total_poll_timeout_.ByteSizeLong()); |
| total_poll_timeout_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t MethodSettings::LongRunning::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_initial_poll_delay_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(initial_poll_delay_.ByteSizeLong()); |
| size += initial_poll_delay_.ByteSizeLong(); |
| } |
| if (has_poll_delay_multiplier_) { |
| size += FixedSize32(static_cast<uint32_t>(poll_delay_multiplier_)) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_max_poll_delay_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(max_poll_delay_.ByteSizeLong()); |
| size += max_poll_delay_.ByteSizeLong(); |
| } |
| if (has_total_poll_timeout_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(total_poll_timeout_.ByteSizeLong()); |
| size += total_poll_timeout_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void MethodSettings::LongRunning::Clear() { |
| if (has_initial_poll_delay_) { |
| initial_poll_delay_.Clear(); |
| has_initial_poll_delay_ = false; |
| } |
| poll_delay_multiplier_ = static_cast< float >(0); |
| if (has_max_poll_delay_) { |
| max_poll_delay_.Clear(); |
| has_max_poll_delay_ = false; |
| } |
| if (has_total_poll_timeout_) { |
| total_poll_timeout_.Clear(); |
| has_total_poll_timeout_ = false; |
| } |
| } |
| |
| void MethodSettings::LongRunning::set_poll_delay_multiplier(const float& value) { |
| has_poll_delay_multiplier_ = true; |
| poll_delay_multiplier_ = value; |
| } |
| |
| void MethodSettings::SerializeToOstream(OutputStream* output__) const { |
| if (has_selector_) { |
| WriteString(output__, 1, selector_); |
| } |
| if (has_long_running_) { |
| WriteLengthDelimited(output__, 2, |
| long_running_.ByteSizeLong()); |
| long_running_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : auto_populated_fields_) { |
| WriteString(output__, 3, elem); |
| } |
| } |
| |
| size_t MethodSettings::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_selector_) { |
| size += StringSize(selector_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_long_running_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(long_running_.ByteSizeLong()); |
| size += long_running_.ByteSizeLong(); |
| } |
| for (const auto& elem : auto_populated_fields_) { |
| size += StringSize(elem) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void MethodSettings::Clear() { |
| selector_.clear(); |
| if (has_long_running_) { |
| long_running_.Clear(); |
| has_long_running_ = false; |
| } |
| auto_populated_fields_.clear(); |
| } |
| |
| void MethodSettings::set_selector(const std::string& value) { |
| has_selector_ = true; |
| selector_ = value; |
| } |
| |
| void MethodSettings::add_auto_populated_fields(const std::string& value) { |
| has_auto_populated_fields_ = true; |
| auto_populated_fields_.push_back(value); |
| } |
| void MethodSettings::set_auto_populated_fields(const std::vector< std::string >& value) { |
| has_auto_populated_fields_ = true; |
| auto_populated_fields_ = value; |
| } |
| |
| } // namespace api |
| } // namespace google |
| namespace google { |
| namespace api { |
| } // namespace api |
| } // namespace google |
| namespace google { |
| namespace api { |
| void ResourceDescriptor::SerializeToOstream(OutputStream* output__) const { |
| if (has_type_) { |
| WriteString(output__, 1, type_); |
| } |
| for (const auto& elem : pattern_) { |
| WriteString(output__, 2, elem); |
| } |
| if (has_name_field_) { |
| WriteString(output__, 3, name_field_); |
| } |
| if (has_history_) { |
| WriteVarint32SignExtended(output__, 4, static_cast<int32_t>(history_)); |
| } |
| if (has_plural_) { |
| WriteString(output__, 5, plural_); |
| } |
| if (has_singular_) { |
| WriteString(output__, 6, singular_); |
| } |
| for (const auto& elem : style_) { |
| WriteVarint32SignExtended(output__, 10, static_cast<int32_t>(elem)); |
| } |
| } |
| |
| size_t ResourceDescriptor::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_type_) { |
| size += StringSize(type_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : pattern_) { |
| size += StringSize(elem) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_name_field_) { |
| size += StringSize(name_field_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_history_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(history_)) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_plural_) { |
| size += StringSize(plural_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_singular_) { |
| size += StringSize(singular_) + VarintSize32(6 << kTagTypeBits); |
| } |
| for (const auto& elem : style_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(elem)) + VarintSize32(10 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void ResourceDescriptor::Clear() { |
| type_.clear(); |
| pattern_.clear(); |
| name_field_.clear(); |
| history_ = static_cast< ::rs::google::api::ResourceDescriptor::History >(0); |
| plural_.clear(); |
| singular_.clear(); |
| style_.clear(); |
| } |
| |
| void ResourceDescriptor::set_type(const std::string& value) { |
| has_type_ = true; |
| type_ = value; |
| } |
| |
| void ResourceDescriptor::add_pattern(const std::string& value) { |
| has_pattern_ = true; |
| pattern_.push_back(value); |
| } |
| void ResourceDescriptor::set_pattern(const std::vector< std::string >& value) { |
| has_pattern_ = true; |
| pattern_ = value; |
| } |
| |
| void ResourceDescriptor::set_name_field(const std::string& value) { |
| has_name_field_ = true; |
| name_field_ = value; |
| } |
| |
| void ResourceDescriptor::set_history(const ::rs::google::api::ResourceDescriptor::History& value) { |
| has_history_ = true; |
| history_ = value; |
| } |
| |
| void ResourceDescriptor::set_plural(const std::string& value) { |
| has_plural_ = true; |
| plural_ = value; |
| } |
| |
| void ResourceDescriptor::set_singular(const std::string& value) { |
| has_singular_ = true; |
| singular_ = value; |
| } |
| |
| void ResourceDescriptor::add_style(const ::rs::google::api::ResourceDescriptor::Style& value) { |
| has_style_ = true; |
| style_.push_back(value); |
| } |
| void ResourceDescriptor::set_style(const std::vector< ::rs::google::api::ResourceDescriptor::Style >& value) { |
| has_style_ = true; |
| style_ = value; |
| } |
| |
| void ResourceReference::SerializeToOstream(OutputStream* output__) const { |
| if (has_type_) { |
| WriteString(output__, 1, type_); |
| } |
| if (has_child_type_) { |
| WriteString(output__, 2, child_type_); |
| } |
| } |
| |
| size_t ResourceReference::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_type_) { |
| size += StringSize(type_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_child_type_) { |
| size += StringSize(child_type_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void ResourceReference::Clear() { |
| type_.clear(); |
| child_type_.clear(); |
| } |
| |
| void ResourceReference::set_type(const std::string& value) { |
| has_type_ = true; |
| type_ = value; |
| } |
| |
| void ResourceReference::set_child_type(const std::string& value) { |
| has_child_type_ = true; |
| child_type_ = value; |
| } |
| |
| } // namespace api |
| } // namespace google |
| namespace google { |
| namespace protobuf { |
| void Timestamp::SerializeToOstream(OutputStream* output__) const { |
| if (has_seconds_) { |
| WriteVarint64(output__, 1, seconds_); |
| } |
| if (has_nanos_) { |
| WriteVarint32SignExtended(output__, 2, nanos_); |
| } |
| } |
| |
| size_t Timestamp::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_seconds_) { |
| size += VarintSize64(seconds_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_nanos_) { |
| size += VarintSize32SignExtended(nanos_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Timestamp::Clear() { |
| seconds_ = static_cast< int64_t >(0); |
| nanos_ = static_cast< int32_t >(0); |
| } |
| |
| void Timestamp::set_seconds(const int64_t& value) { |
| has_seconds_ = true; |
| seconds_ = value; |
| } |
| |
| void Timestamp::set_nanos(const int32_t& value) { |
| has_nanos_ = true; |
| nanos_ = value; |
| } |
| |
| } // namespace protobuf |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void StatusAttributes::SerializeToOstream(OutputStream* output__) const { |
| if (has_status_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(status_)); |
| } |
| if (has_description_) { |
| WriteString(output__, 2, description_); |
| } |
| } |
| |
| size_t StatusAttributes::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_status_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(status_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_description_) { |
| size += StringSize(description_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void StatusAttributes::Clear() { |
| status_ = static_cast< ::rs::google::devtools::resultstore::v2::Status >(0); |
| description_.clear(); |
| } |
| |
| void StatusAttributes::set_status(const ::rs::google::devtools::resultstore::v2::Status& value) { |
| has_status_ = true; |
| status_ = value; |
| } |
| |
| void StatusAttributes::set_description(const std::string& value) { |
| has_description_ = true; |
| description_ = value; |
| } |
| |
| void Property::SerializeToOstream(OutputStream* output__) const { |
| if (has_key_) { |
| WriteString(output__, 1, key_); |
| } |
| if (has_value_) { |
| WriteString(output__, 2, value_); |
| } |
| } |
| |
| size_t Property::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_key_) { |
| size += StringSize(key_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_value_) { |
| size += StringSize(value_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Property::Clear() { |
| key_.clear(); |
| value_.clear(); |
| } |
| |
| void Property::set_key(const std::string& value) { |
| has_key_ = true; |
| key_ = value; |
| } |
| |
| void Property::set_value(const std::string& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void Timing::SerializeToOstream(OutputStream* output__) const { |
| if (has_start_time_) { |
| WriteLengthDelimited(output__, 1, |
| start_time_.ByteSizeLong()); |
| start_time_.SerializeToOstream(output__); |
| } |
| if (has_duration_) { |
| WriteLengthDelimited(output__, 2, |
| duration_.ByteSizeLong()); |
| duration_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t Timing::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_start_time_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(start_time_.ByteSizeLong()); |
| size += start_time_.ByteSizeLong(); |
| } |
| if (has_duration_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(duration_.ByteSizeLong()); |
| size += duration_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void Timing::Clear() { |
| if (has_start_time_) { |
| start_time_.Clear(); |
| has_start_time_ = false; |
| } |
| if (has_duration_) { |
| duration_.Clear(); |
| has_duration_ = false; |
| } |
| } |
| |
| void Dependency::Id::SerializeToOstream(OutputStream* output__) const { |
| if (has_target_id_) { |
| WriteString(output__, 2, target_id_); |
| } |
| if (has_configuration_id_) { |
| WriteString(output__, 3, configuration_id_); |
| } |
| if (has_action_id_) { |
| WriteString(output__, 4, action_id_); |
| } |
| } |
| |
| size_t Dependency::Id::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_target_id_) { |
| size += StringSize(target_id_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_configuration_id_) { |
| size += StringSize(configuration_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_action_id_) { |
| size += StringSize(action_id_) + VarintSize32(4 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Dependency::Id::Clear() { |
| target_id_.clear(); |
| configuration_id_.clear(); |
| action_id_.clear(); |
| } |
| |
| void Dependency::Id::set_target_id(const std::string& value) { |
| has_target_id_ = true; |
| target_id_ = value; |
| } |
| |
| void Dependency::Id::set_configuration_id(const std::string& value) { |
| has_configuration_id_ = true; |
| configuration_id_ = value; |
| } |
| |
| void Dependency::Id::set_action_id(const std::string& value) { |
| has_action_id_ = true; |
| action_id_ = value; |
| } |
| |
| void Dependency::SerializeToOstream(OutputStream* output__) const { |
| if (has_target_) { |
| WriteString(output__, 1, target_); |
| } |
| if (has_configured_target_) { |
| WriteString(output__, 2, configured_target_); |
| } |
| if (has_action_) { |
| WriteString(output__, 3, action_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 5, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| if (has_label_) { |
| WriteString(output__, 4, label_); |
| } |
| } |
| |
| size_t Dependency::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_target_) { |
| size += StringSize(target_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_configured_target_) { |
| size += StringSize(configured_target_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_action_) { |
| size += StringSize(action_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| if (has_label_) { |
| size += StringSize(label_) + VarintSize32(4 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Dependency::Clear() { |
| target_.clear(); |
| configured_target_.clear(); |
| action_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| label_.clear(); |
| } |
| |
| void Dependency::set_target(const std::string& value) { |
| has_target_ = true; |
| target_ = value; |
| } |
| |
| void Dependency::set_configured_target(const std::string& value) { |
| has_configured_target_ = true; |
| configured_target_ = value; |
| } |
| |
| void Dependency::set_action(const std::string& value) { |
| has_action_ = true; |
| action_ = value; |
| } |
| |
| void Dependency::set_label(const std::string& value) { |
| has_label_ = true; |
| label_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void LineCoverage::SerializeToOstream(OutputStream* output__) const { |
| if (has_instrumented_lines_) { |
| WriteString(output__, 1, instrumented_lines_); |
| } |
| if (has_executed_lines_) { |
| WriteString(output__, 2, executed_lines_); |
| } |
| } |
| |
| size_t LineCoverage::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_instrumented_lines_) { |
| size += StringSize(instrumented_lines_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_executed_lines_) { |
| size += StringSize(executed_lines_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void LineCoverage::Clear() { |
| instrumented_lines_.clear(); |
| executed_lines_.clear(); |
| } |
| |
| void LineCoverage::set_instrumented_lines(const std::string& value) { |
| has_instrumented_lines_ = true; |
| instrumented_lines_ = value; |
| } |
| |
| void LineCoverage::set_executed_lines(const std::string& value) { |
| has_executed_lines_ = true; |
| executed_lines_ = value; |
| } |
| |
| void BranchCoverage::SerializeToOstream(OutputStream* output__) const { |
| if (has_branch_present_) { |
| WriteString(output__, 1, branch_present_); |
| } |
| for (const auto& elem : branches_in_line_) { |
| WriteVarint32SignExtended(output__, 2, elem); |
| } |
| if (has_executed_) { |
| WriteString(output__, 3, executed_); |
| } |
| if (has_taken_) { |
| WriteString(output__, 4, taken_); |
| } |
| } |
| |
| size_t BranchCoverage::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_branch_present_) { |
| size += StringSize(branch_present_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : branches_in_line_) { |
| size += VarintSize32SignExtended(elem) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_executed_) { |
| size += StringSize(executed_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_taken_) { |
| size += StringSize(taken_) + VarintSize32(4 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void BranchCoverage::Clear() { |
| branch_present_.clear(); |
| branches_in_line_.clear(); |
| executed_.clear(); |
| taken_.clear(); |
| } |
| |
| void BranchCoverage::set_branch_present(const std::string& value) { |
| has_branch_present_ = true; |
| branch_present_ = value; |
| } |
| |
| void BranchCoverage::add_branches_in_line(const int32_t& value) { |
| has_branches_in_line_ = true; |
| branches_in_line_.push_back(value); |
| } |
| void BranchCoverage::set_branches_in_line(const std::vector< int32_t >& value) { |
| has_branches_in_line_ = true; |
| branches_in_line_ = value; |
| } |
| |
| void BranchCoverage::set_executed(const std::string& value) { |
| has_executed_ = true; |
| executed_ = value; |
| } |
| |
| void BranchCoverage::set_taken(const std::string& value) { |
| has_taken_ = true; |
| taken_ = value; |
| } |
| |
| void FileCoverage::SerializeToOstream(OutputStream* output__) const { |
| if (has_path_) { |
| WriteString(output__, 1, path_); |
| } |
| if (has_line_coverage_) { |
| WriteLengthDelimited(output__, 2, |
| line_coverage_.ByteSizeLong()); |
| line_coverage_.SerializeToOstream(output__); |
| } |
| if (has_branch_coverage_) { |
| WriteLengthDelimited(output__, 3, |
| branch_coverage_.ByteSizeLong()); |
| branch_coverage_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t FileCoverage::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_path_) { |
| size += StringSize(path_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_line_coverage_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(line_coverage_.ByteSizeLong()); |
| size += line_coverage_.ByteSizeLong(); |
| } |
| if (has_branch_coverage_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(branch_coverage_.ByteSizeLong()); |
| size += branch_coverage_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void FileCoverage::Clear() { |
| path_.clear(); |
| if (has_line_coverage_) { |
| line_coverage_.Clear(); |
| has_line_coverage_ = false; |
| } |
| if (has_branch_coverage_) { |
| branch_coverage_.Clear(); |
| has_branch_coverage_ = false; |
| } |
| } |
| |
| void FileCoverage::set_path(const std::string& value) { |
| has_path_ = true; |
| path_ = value; |
| } |
| |
| void ActionCoverage::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : file_coverages_) { |
| if (has_file_coverages_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t ActionCoverage::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : file_coverages_) { |
| if (has_file_coverages_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void ActionCoverage::Clear() { |
| if (has_file_coverages_) { |
| file_coverages_.clear(); |
| has_file_coverages_ = false; |
| } |
| } |
| |
| void ActionCoverage::add_file_coverages(const ::rs::google::devtools::resultstore::v2::FileCoverage& value) { |
| has_file_coverages_ = true; |
| file_coverages_.push_back(value); |
| } |
| void AggregateCoverage::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : file_coverages_) { |
| if (has_file_coverages_) { |
| WriteLengthDelimited(output__, 1, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t AggregateCoverage::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : file_coverages_) { |
| if (has_file_coverages_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void AggregateCoverage::Clear() { |
| if (has_file_coverages_) { |
| file_coverages_.clear(); |
| has_file_coverages_ = false; |
| } |
| } |
| |
| void AggregateCoverage::add_file_coverages(const ::rs::google::devtools::resultstore::v2::FileCoverage& value) { |
| has_file_coverages_ = true; |
| file_coverages_.push_back(value); |
| } |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace protobuf { |
| void DoubleValue::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteFixed64(output__, 1, static_cast<uint64_t>(value_)); |
| } |
| } |
| |
| size_t DoubleValue::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += FixedSize64(static_cast<uint64_t>(value_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void DoubleValue::Clear() { |
| value_ = static_cast< double >(0); |
| } |
| |
| void DoubleValue::set_value(const double& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void FloatValue::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteFixed32(output__, 1, static_cast<uint32_t>(value_)); |
| } |
| } |
| |
| size_t FloatValue::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += FixedSize32(static_cast<uint32_t>(value_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FloatValue::Clear() { |
| value_ = static_cast< float >(0); |
| } |
| |
| void FloatValue::set_value(const float& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void Int64Value::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteVarint64(output__, 1, value_); |
| } |
| } |
| |
| size_t Int64Value::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += VarintSize64(value_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Int64Value::Clear() { |
| value_ = static_cast< int64_t >(0); |
| } |
| |
| void Int64Value::set_value(const int64_t& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void UInt64Value::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteVarint64(output__, 1, value_); |
| } |
| } |
| |
| size_t UInt64Value::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += VarintSize64(value_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UInt64Value::Clear() { |
| value_ = static_cast< uint64_t >(0); |
| } |
| |
| void UInt64Value::set_value(const uint64_t& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void Int32Value::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteVarint32SignExtended(output__, 1, value_); |
| } |
| } |
| |
| size_t Int32Value::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += VarintSize32SignExtended(value_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Int32Value::Clear() { |
| value_ = static_cast< int32_t >(0); |
| } |
| |
| void Int32Value::set_value(const int32_t& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void UInt32Value::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteVarint32(output__, 1, value_); |
| } |
| } |
| |
| size_t UInt32Value::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += VarintSize32(value_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UInt32Value::Clear() { |
| value_ = static_cast< uint32_t >(0); |
| } |
| |
| void UInt32Value::set_value(const uint32_t& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void BoolValue::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteVarint32(output__, 1, value_); |
| } |
| } |
| |
| size_t BoolValue::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += VarintSizeBool(value_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void BoolValue::Clear() { |
| value_ = false; |
| } |
| |
| void BoolValue::set_value(const bool& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void StringValue::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteString(output__, 1, value_); |
| } |
| } |
| |
| size_t StringValue::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += StringSize(value_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void StringValue::Clear() { |
| value_.clear(); |
| } |
| |
| void StringValue::set_value(const std::string& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| void BytesValue::SerializeToOstream(OutputStream* output__) const { |
| if (has_value_) { |
| WriteString(output__, 1, value_); |
| } |
| } |
| |
| size_t BytesValue::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_value_) { |
| size += StringSize(value_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void BytesValue::Clear() { |
| value_.clear(); |
| } |
| |
| void BytesValue::set_value(const std::string& value) { |
| has_value_ = true; |
| value_ = value; |
| } |
| |
| } // namespace protobuf |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void ArchiveEntry::SerializeToOstream(OutputStream* output__) const { |
| if (has_path_) { |
| WriteString(output__, 1, path_); |
| } |
| if (has_length_) { |
| WriteLengthDelimited(output__, 2, |
| length_.ByteSizeLong()); |
| length_.SerializeToOstream(output__); |
| } |
| if (has_content_type_) { |
| WriteString(output__, 3, content_type_); |
| } |
| } |
| |
| size_t ArchiveEntry::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_path_) { |
| size += StringSize(path_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_length_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(length_.ByteSizeLong()); |
| size += length_.ByteSizeLong(); |
| } |
| if (has_content_type_) { |
| size += StringSize(content_type_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void ArchiveEntry::Clear() { |
| path_.clear(); |
| if (has_length_) { |
| length_.Clear(); |
| has_length_ = false; |
| } |
| content_type_.clear(); |
| } |
| |
| void ArchiveEntry::set_path(const std::string& value) { |
| has_path_ = true; |
| path_ = value; |
| } |
| |
| void ArchiveEntry::set_content_type(const std::string& value) { |
| has_content_type_ = true; |
| content_type_ = value; |
| } |
| |
| void File::SerializeToOstream(OutputStream* output__) const { |
| if (has_uid_) { |
| WriteString(output__, 1, uid_); |
| } |
| if (has_uri_) { |
| WriteString(output__, 2, uri_); |
| } |
| if (has_length_) { |
| WriteLengthDelimited(output__, 3, |
| length_.ByteSizeLong()); |
| length_.SerializeToOstream(output__); |
| } |
| if (has_content_type_) { |
| WriteString(output__, 4, content_type_); |
| } |
| if (has_archive_entry_) { |
| WriteLengthDelimited(output__, 5, |
| archive_entry_.ByteSizeLong()); |
| archive_entry_.SerializeToOstream(output__); |
| } |
| if (has_content_viewer_) { |
| WriteString(output__, 6, content_viewer_); |
| } |
| if (has_hidden_) { |
| WriteVarint32(output__, 7, hidden_); |
| } |
| if (has_description_) { |
| WriteString(output__, 8, description_); |
| } |
| if (has_digest_) { |
| WriteString(output__, 9, digest_); |
| } |
| if (has_hash_type_) { |
| WriteVarint32SignExtended(output__, 10, static_cast<int32_t>(hash_type_)); |
| } |
| } |
| |
| size_t File::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_uid_) { |
| size += StringSize(uid_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_uri_) { |
| size += StringSize(uri_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_length_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(length_.ByteSizeLong()); |
| size += length_.ByteSizeLong(); |
| } |
| if (has_content_type_) { |
| size += StringSize(content_type_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_archive_entry_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(archive_entry_.ByteSizeLong()); |
| size += archive_entry_.ByteSizeLong(); |
| } |
| if (has_content_viewer_) { |
| size += StringSize(content_viewer_) + VarintSize32(6 << kTagTypeBits); |
| } |
| if (has_hidden_) { |
| size += VarintSizeBool(hidden_) + VarintSize32(7 << kTagTypeBits); |
| } |
| if (has_description_) { |
| size += StringSize(description_) + VarintSize32(8 << kTagTypeBits); |
| } |
| if (has_digest_) { |
| size += StringSize(digest_) + VarintSize32(9 << kTagTypeBits); |
| } |
| if (has_hash_type_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(hash_type_)) + VarintSize32(10 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void File::Clear() { |
| uid_.clear(); |
| uri_.clear(); |
| if (has_length_) { |
| length_.Clear(); |
| has_length_ = false; |
| } |
| content_type_.clear(); |
| if (has_archive_entry_) { |
| archive_entry_.Clear(); |
| has_archive_entry_ = false; |
| } |
| content_viewer_.clear(); |
| hidden_ = false; |
| description_.clear(); |
| digest_.clear(); |
| hash_type_ = static_cast< ::rs::google::devtools::resultstore::v2::File::HashType >(0); |
| } |
| |
| void File::set_uid(const std::string& value) { |
| has_uid_ = true; |
| uid_ = value; |
| } |
| |
| void File::set_uri(const std::string& value) { |
| has_uri_ = true; |
| uri_ = value; |
| } |
| |
| void File::set_content_type(const std::string& value) { |
| has_content_type_ = true; |
| content_type_ = value; |
| } |
| |
| void File::set_content_viewer(const std::string& value) { |
| has_content_viewer_ = true; |
| content_viewer_ = value; |
| } |
| |
| void File::set_hidden(const bool& value) { |
| has_hidden_ = true; |
| hidden_ = value; |
| } |
| |
| void File::set_description(const std::string& value) { |
| has_description_ = true; |
| description_ = value; |
| } |
| |
| void File::set_digest(const std::string& value) { |
| has_digest_ = true; |
| digest_ = value; |
| } |
| |
| void File::set_hash_type(const ::rs::google::devtools::resultstore::v2::File::HashType& value) { |
| has_hash_type_ = true; |
| hash_type_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void FileProcessingErrors::SerializeToOstream(OutputStream* output__) const { |
| if (has_file_uid_) { |
| WriteString(output__, 1, file_uid_); |
| } |
| for (const auto& elem : file_processing_errors_) { |
| if (has_file_processing_errors_) { |
| WriteLengthDelimited(output__, 3, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t FileProcessingErrors::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_file_uid_) { |
| size += StringSize(file_uid_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : file_processing_errors_) { |
| if (has_file_processing_errors_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void FileProcessingErrors::Clear() { |
| file_uid_.clear(); |
| if (has_file_processing_errors_) { |
| file_processing_errors_.clear(); |
| has_file_processing_errors_ = false; |
| } |
| } |
| |
| void FileProcessingErrors::set_file_uid(const std::string& value) { |
| has_file_uid_ = true; |
| file_uid_ = value; |
| } |
| |
| void FileProcessingErrors::add_file_processing_errors(const ::rs::google::devtools::resultstore::v2::FileProcessingError& value) { |
| has_file_processing_errors_ = true; |
| file_processing_errors_.push_back(value); |
| } |
| void FileProcessingError::SerializeToOstream(OutputStream* output__) const { |
| if (has_type_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(type_)); |
| } |
| if (has_message_) { |
| WriteString(output__, 2, message_); |
| } |
| } |
| |
| size_t FileProcessingError::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_type_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(type_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_message_) { |
| size += StringSize(message_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FileProcessingError::Clear() { |
| type_ = static_cast< ::rs::google::devtools::resultstore::v2::FileProcessingErrorType >(0); |
| message_.clear(); |
| } |
| |
| void FileProcessingError::set_type(const ::rs::google::devtools::resultstore::v2::FileProcessingErrorType& value) { |
| has_type_ = true; |
| type_ = value; |
| } |
| |
| void FileProcessingError::set_message(const std::string& value) { |
| has_message_ = true; |
| message_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void TestSuite::SerializeToOstream(OutputStream* output__) const { |
| if (has_suite_name_) { |
| WriteString(output__, 1, suite_name_); |
| } |
| for (const auto& elem : tests_) { |
| if (has_tests_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : failures_) { |
| if (has_failures_) { |
| WriteLengthDelimited(output__, 3, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : errors_) { |
| if (has_errors_) { |
| WriteLengthDelimited(output__, 4, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_timing_) { |
| WriteLengthDelimited(output__, 6, |
| timing_.ByteSizeLong()); |
| timing_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| WriteLengthDelimited(output__, 7, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| WriteLengthDelimited(output__, 8, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t TestSuite::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_suite_name_) { |
| size += StringSize(suite_name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : tests_) { |
| if (has_tests_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : failures_) { |
| if (has_failures_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : errors_) { |
| if (has_errors_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_timing_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(timing_.ByteSizeLong()); |
| size += timing_.ByteSizeLong(); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void TestSuite::Clear() { |
| suite_name_.clear(); |
| if (has_tests_) { |
| tests_.clear(); |
| has_tests_ = false; |
| } |
| if (has_failures_) { |
| failures_.clear(); |
| has_failures_ = false; |
| } |
| if (has_errors_) { |
| errors_.clear(); |
| has_errors_ = false; |
| } |
| if (has_timing_) { |
| timing_.Clear(); |
| has_timing_ = false; |
| } |
| if (has_properties_) { |
| properties_.clear(); |
| has_properties_ = false; |
| } |
| if (has_files_) { |
| files_.clear(); |
| has_files_ = false; |
| } |
| } |
| |
| void TestSuite::set_suite_name(const std::string& value) { |
| has_suite_name_ = true; |
| suite_name_ = value; |
| } |
| |
| void TestSuite::add_tests(const ::rs::google::devtools::resultstore::v2::Test& value) { |
| has_tests_ = true; |
| tests_.push_back(value); |
| } |
| void TestSuite::add_failures(const ::rs::google::devtools::resultstore::v2::TestFailure& value) { |
| has_failures_ = true; |
| failures_.push_back(value); |
| } |
| void TestSuite::add_errors(const ::rs::google::devtools::resultstore::v2::TestError& value) { |
| has_errors_ = true; |
| errors_.push_back(value); |
| } |
| void TestSuite::add_properties(const ::rs::google::devtools::resultstore::v2::Property& value) { |
| has_properties_ = true; |
| properties_.push_back(value); |
| } |
| void TestSuite::add_files(const ::rs::google::devtools::resultstore::v2::File& value) { |
| has_files_ = true; |
| files_.push_back(value); |
| } |
| void TestCase::SerializeToOstream(OutputStream* output__) const { |
| if (has_case_name_) { |
| WriteString(output__, 1, case_name_); |
| } |
| if (has_class_name_) { |
| WriteString(output__, 2, class_name_); |
| } |
| if (has_result_) { |
| WriteVarint32SignExtended(output__, 3, static_cast<int32_t>(result_)); |
| } |
| for (const auto& elem : failures_) { |
| if (has_failures_) { |
| WriteLengthDelimited(output__, 4, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : errors_) { |
| if (has_errors_) { |
| WriteLengthDelimited(output__, 5, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_timing_) { |
| WriteLengthDelimited(output__, 7, |
| timing_.ByteSizeLong()); |
| timing_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| WriteLengthDelimited(output__, 8, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| WriteLengthDelimited(output__, 9, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_retry_number_) { |
| WriteVarint32SignExtended(output__, 10, retry_number_); |
| } |
| if (has_repeat_number_) { |
| WriteVarint32SignExtended(output__, 11, repeat_number_); |
| } |
| } |
| |
| size_t TestCase::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_case_name_) { |
| size += StringSize(case_name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_class_name_) { |
| size += StringSize(class_name_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_result_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(result_)) + VarintSize32(3 << kTagTypeBits); |
| } |
| for (const auto& elem : failures_) { |
| if (has_failures_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : errors_) { |
| if (has_errors_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_timing_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(timing_.ByteSizeLong()); |
| size += timing_.ByteSizeLong(); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| size += VarintSize32(9 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_retry_number_) { |
| size += VarintSize32SignExtended(retry_number_) + VarintSize32(10 << kTagTypeBits); |
| } |
| if (has_repeat_number_) { |
| size += VarintSize32SignExtended(repeat_number_) + VarintSize32(11 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TestCase::Clear() { |
| case_name_.clear(); |
| class_name_.clear(); |
| result_ = static_cast< ::rs::google::devtools::resultstore::v2::TestCase::Result >(0); |
| if (has_failures_) { |
| failures_.clear(); |
| has_failures_ = false; |
| } |
| if (has_errors_) { |
| errors_.clear(); |
| has_errors_ = false; |
| } |
| if (has_timing_) { |
| timing_.Clear(); |
| has_timing_ = false; |
| } |
| if (has_properties_) { |
| properties_.clear(); |
| has_properties_ = false; |
| } |
| if (has_files_) { |
| files_.clear(); |
| has_files_ = false; |
| } |
| retry_number_ = static_cast< int32_t >(0); |
| repeat_number_ = static_cast< int32_t >(0); |
| } |
| |
| void TestCase::set_case_name(const std::string& value) { |
| has_case_name_ = true; |
| case_name_ = value; |
| } |
| |
| void TestCase::set_class_name(const std::string& value) { |
| has_class_name_ = true; |
| class_name_ = value; |
| } |
| |
| void TestCase::set_result(const ::rs::google::devtools::resultstore::v2::TestCase::Result& value) { |
| has_result_ = true; |
| result_ = value; |
| } |
| |
| void TestCase::add_failures(const ::rs::google::devtools::resultstore::v2::TestFailure& value) { |
| has_failures_ = true; |
| failures_.push_back(value); |
| } |
| void TestCase::add_errors(const ::rs::google::devtools::resultstore::v2::TestError& value) { |
| has_errors_ = true; |
| errors_.push_back(value); |
| } |
| void TestCase::add_properties(const ::rs::google::devtools::resultstore::v2::Property& value) { |
| has_properties_ = true; |
| properties_.push_back(value); |
| } |
| void TestCase::add_files(const ::rs::google::devtools::resultstore::v2::File& value) { |
| has_files_ = true; |
| files_.push_back(value); |
| } |
| void TestCase::set_retry_number(const int32_t& value) { |
| has_retry_number_ = true; |
| retry_number_ = value; |
| } |
| |
| void TestCase::set_repeat_number(const int32_t& value) { |
| has_repeat_number_ = true; |
| repeat_number_ = value; |
| } |
| |
| void Test::SerializeToOstream(OutputStream* output__) const { |
| if (has_test_case_) { |
| WriteLengthDelimited(output__, 1, |
| test_case_.ByteSizeLong()); |
| test_case_.SerializeToOstream(output__); |
| } |
| if (has_test_suite_) { |
| WriteLengthDelimited(output__, 2, |
| test_suite_.ByteSizeLong()); |
| test_suite_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t Test::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_test_case_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(test_case_.ByteSizeLong()); |
| size += test_case_.ByteSizeLong(); |
| } |
| if (has_test_suite_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(test_suite_.ByteSizeLong()); |
| size += test_suite_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void Test::Clear() { |
| if (has_test_case_) { |
| test_case_.Clear(); |
| has_test_case_ = false; |
| } |
| if (has_test_suite_) { |
| test_suite_.Clear(); |
| has_test_suite_ = false; |
| } |
| } |
| |
| void TestFailure::SerializeToOstream(OutputStream* output__) const { |
| if (has_failure_message_) { |
| WriteString(output__, 1, failure_message_); |
| } |
| if (has_exception_type_) { |
| WriteString(output__, 2, exception_type_); |
| } |
| if (has_stack_trace_) { |
| WriteString(output__, 3, stack_trace_); |
| } |
| for (const auto& elem : expected_) { |
| WriteString(output__, 4, elem); |
| } |
| for (const auto& elem : actual_) { |
| WriteString(output__, 5, elem); |
| } |
| } |
| |
| size_t TestFailure::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_failure_message_) { |
| size += StringSize(failure_message_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_exception_type_) { |
| size += StringSize(exception_type_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_stack_trace_) { |
| size += StringSize(stack_trace_) + VarintSize32(3 << kTagTypeBits); |
| } |
| for (const auto& elem : expected_) { |
| size += StringSize(elem) + VarintSize32(4 << kTagTypeBits); |
| } |
| for (const auto& elem : actual_) { |
| size += StringSize(elem) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TestFailure::Clear() { |
| failure_message_.clear(); |
| exception_type_.clear(); |
| stack_trace_.clear(); |
| expected_.clear(); |
| actual_.clear(); |
| } |
| |
| void TestFailure::set_failure_message(const std::string& value) { |
| has_failure_message_ = true; |
| failure_message_ = value; |
| } |
| |
| void TestFailure::set_exception_type(const std::string& value) { |
| has_exception_type_ = true; |
| exception_type_ = value; |
| } |
| |
| void TestFailure::set_stack_trace(const std::string& value) { |
| has_stack_trace_ = true; |
| stack_trace_ = value; |
| } |
| |
| void TestFailure::add_expected(const std::string& value) { |
| has_expected_ = true; |
| expected_.push_back(value); |
| } |
| void TestFailure::set_expected(const std::vector< std::string >& value) { |
| has_expected_ = true; |
| expected_ = value; |
| } |
| |
| void TestFailure::add_actual(const std::string& value) { |
| has_actual_ = true; |
| actual_.push_back(value); |
| } |
| void TestFailure::set_actual(const std::vector< std::string >& value) { |
| has_actual_ = true; |
| actual_ = value; |
| } |
| |
| void TestError::SerializeToOstream(OutputStream* output__) const { |
| if (has_error_message_) { |
| WriteString(output__, 1, error_message_); |
| } |
| if (has_exception_type_) { |
| WriteString(output__, 2, exception_type_); |
| } |
| if (has_stack_trace_) { |
| WriteString(output__, 3, stack_trace_); |
| } |
| } |
| |
| size_t TestError::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_error_message_) { |
| size += StringSize(error_message_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_exception_type_) { |
| size += StringSize(exception_type_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_stack_trace_) { |
| size += StringSize(stack_trace_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TestError::Clear() { |
| error_message_.clear(); |
| exception_type_.clear(); |
| stack_trace_.clear(); |
| } |
| |
| void TestError::set_error_message(const std::string& value) { |
| has_error_message_ = true; |
| error_message_ = value; |
| } |
| |
| void TestError::set_exception_type(const std::string& value) { |
| has_exception_type_ = true; |
| exception_type_ = value; |
| } |
| |
| void TestError::set_stack_trace(const std::string& value) { |
| has_stack_trace_ = true; |
| stack_trace_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void InputFileInfo::SerializeToOstream(OutputStream* output__) const { |
| if (has_count_) { |
| WriteVarint64(output__, 1, count_); |
| } |
| if (has_distinct_count_) { |
| WriteVarint64(output__, 2, distinct_count_); |
| } |
| if (has_count_limit_) { |
| WriteVarint64(output__, 3, count_limit_); |
| } |
| if (has_distinct_bytes_) { |
| WriteVarint64(output__, 4, distinct_bytes_); |
| } |
| if (has_distinct_byte_limit_) { |
| WriteVarint64(output__, 5, distinct_byte_limit_); |
| } |
| } |
| |
| size_t InputFileInfo::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_count_) { |
| size += VarintSize64(count_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_distinct_count_) { |
| size += VarintSize64(distinct_count_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_count_limit_) { |
| size += VarintSize64(count_limit_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_distinct_bytes_) { |
| size += VarintSize64(distinct_bytes_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_distinct_byte_limit_) { |
| size += VarintSize64(distinct_byte_limit_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void InputFileInfo::Clear() { |
| count_ = static_cast< int64_t >(0); |
| distinct_count_ = static_cast< int64_t >(0); |
| count_limit_ = static_cast< int64_t >(0); |
| distinct_bytes_ = static_cast< int64_t >(0); |
| distinct_byte_limit_ = static_cast< int64_t >(0); |
| } |
| |
| void InputFileInfo::set_count(const int64_t& value) { |
| has_count_ = true; |
| count_ = value; |
| } |
| |
| void InputFileInfo::set_distinct_count(const int64_t& value) { |
| has_distinct_count_ = true; |
| distinct_count_ = value; |
| } |
| |
| void InputFileInfo::set_count_limit(const int64_t& value) { |
| has_count_limit_ = true; |
| count_limit_ = value; |
| } |
| |
| void InputFileInfo::set_distinct_bytes(const int64_t& value) { |
| has_distinct_bytes_ = true; |
| distinct_bytes_ = value; |
| } |
| |
| void InputFileInfo::set_distinct_byte_limit(const int64_t& value) { |
| has_distinct_byte_limit_ = true; |
| distinct_byte_limit_ = value; |
| } |
| |
| void ActionAttributes::SerializeToOstream(OutputStream* output__) const { |
| if (has_execution_strategy_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(execution_strategy_)); |
| } |
| if (has_exit_code_) { |
| WriteVarint32SignExtended(output__, 2, exit_code_); |
| } |
| if (has_hostname_) { |
| WriteString(output__, 3, hostname_); |
| } |
| if (has_input_file_info_) { |
| WriteLengthDelimited(output__, 4, |
| input_file_info_.ByteSizeLong()); |
| input_file_info_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t ActionAttributes::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_execution_strategy_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(execution_strategy_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_exit_code_) { |
| size += VarintSize32SignExtended(exit_code_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_hostname_) { |
| size += StringSize(hostname_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_input_file_info_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(input_file_info_.ByteSizeLong()); |
| size += input_file_info_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void ActionAttributes::Clear() { |
| execution_strategy_ = static_cast< ::rs::google::devtools::resultstore::v2::ExecutionStrategy >(0); |
| exit_code_ = static_cast< int32_t >(0); |
| hostname_.clear(); |
| if (has_input_file_info_) { |
| input_file_info_.Clear(); |
| has_input_file_info_ = false; |
| } |
| } |
| |
| void ActionAttributes::set_execution_strategy(const ::rs::google::devtools::resultstore::v2::ExecutionStrategy& value) { |
| has_execution_strategy_ = true; |
| execution_strategy_ = value; |
| } |
| |
| void ActionAttributes::set_exit_code(const int32_t& value) { |
| has_exit_code_ = true; |
| exit_code_ = value; |
| } |
| |
| void ActionAttributes::set_hostname(const std::string& value) { |
| has_hostname_ = true; |
| hostname_ = value; |
| } |
| |
| void BuildAction::SerializeToOstream(OutputStream* output__) const { |
| if (has_type_) { |
| WriteString(output__, 1, type_); |
| } |
| if (has_primary_input_path_) { |
| WriteString(output__, 2, primary_input_path_); |
| } |
| if (has_primary_output_path_) { |
| WriteString(output__, 3, primary_output_path_); |
| } |
| } |
| |
| size_t BuildAction::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_type_) { |
| size += StringSize(type_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_primary_input_path_) { |
| size += StringSize(primary_input_path_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_primary_output_path_) { |
| size += StringSize(primary_output_path_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void BuildAction::Clear() { |
| type_.clear(); |
| primary_input_path_.clear(); |
| primary_output_path_.clear(); |
| } |
| |
| void BuildAction::set_type(const std::string& value) { |
| has_type_ = true; |
| type_ = value; |
| } |
| |
| void BuildAction::set_primary_input_path(const std::string& value) { |
| has_primary_input_path_ = true; |
| primary_input_path_ = value; |
| } |
| |
| void BuildAction::set_primary_output_path(const std::string& value) { |
| has_primary_output_path_ = true; |
| primary_output_path_ = value; |
| } |
| |
| void LocalTestTiming::SerializeToOstream(OutputStream* output__) const { |
| if (has_test_process_duration_) { |
| WriteLengthDelimited(output__, 1, |
| test_process_duration_.ByteSizeLong()); |
| test_process_duration_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t LocalTestTiming::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_test_process_duration_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(test_process_duration_.ByteSizeLong()); |
| size += test_process_duration_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void LocalTestTiming::Clear() { |
| if (has_test_process_duration_) { |
| test_process_duration_.Clear(); |
| has_test_process_duration_ = false; |
| } |
| } |
| |
| void RemoteTestTiming::SerializeToOstream(OutputStream* output__) const { |
| if (has_local_analysis_duration_) { |
| WriteLengthDelimited(output__, 1, |
| local_analysis_duration_.ByteSizeLong()); |
| local_analysis_duration_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : attempts_) { |
| if (has_attempts_) { |
| WriteLengthDelimited(output__, 2, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t RemoteTestTiming::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_local_analysis_duration_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(local_analysis_duration_.ByteSizeLong()); |
| size += local_analysis_duration_.ByteSizeLong(); |
| } |
| for (const auto& elem : attempts_) { |
| if (has_attempts_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void RemoteTestTiming::Clear() { |
| if (has_local_analysis_duration_) { |
| local_analysis_duration_.Clear(); |
| has_local_analysis_duration_ = false; |
| } |
| if (has_attempts_) { |
| attempts_.clear(); |
| has_attempts_ = false; |
| } |
| } |
| |
| void RemoteTestTiming::add_attempts(const ::rs::google::devtools::resultstore::v2::RemoteTestAttemptTiming& value) { |
| has_attempts_ = true; |
| attempts_.push_back(value); |
| } |
| void TestTiming::SerializeToOstream(OutputStream* output__) const { |
| if (has_local_) { |
| WriteLengthDelimited(output__, 1, |
| local_.ByteSizeLong()); |
| local_.SerializeToOstream(output__); |
| } |
| if (has_remote_) { |
| WriteLengthDelimited(output__, 2, |
| remote_.ByteSizeLong()); |
| remote_.SerializeToOstream(output__); |
| } |
| if (has_system_time_duration_) { |
| WriteLengthDelimited(output__, 3, |
| system_time_duration_.ByteSizeLong()); |
| system_time_duration_.SerializeToOstream(output__); |
| } |
| if (has_user_time_duration_) { |
| WriteLengthDelimited(output__, 4, |
| user_time_duration_.ByteSizeLong()); |
| user_time_duration_.SerializeToOstream(output__); |
| } |
| if (has_test_caching_) { |
| WriteVarint32SignExtended(output__, 5, static_cast<int32_t>(test_caching_)); |
| } |
| } |
| |
| size_t TestTiming::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_local_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(local_.ByteSizeLong()); |
| size += local_.ByteSizeLong(); |
| } |
| if (has_remote_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(remote_.ByteSizeLong()); |
| size += remote_.ByteSizeLong(); |
| } |
| if (has_system_time_duration_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(system_time_duration_.ByteSizeLong()); |
| size += system_time_duration_.ByteSizeLong(); |
| } |
| if (has_user_time_duration_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(user_time_duration_.ByteSizeLong()); |
| size += user_time_duration_.ByteSizeLong(); |
| } |
| if (has_test_caching_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(test_caching_)) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TestTiming::Clear() { |
| if (has_local_) { |
| local_.Clear(); |
| has_local_ = false; |
| } |
| if (has_remote_) { |
| remote_.Clear(); |
| has_remote_ = false; |
| } |
| if (has_system_time_duration_) { |
| system_time_duration_.Clear(); |
| has_system_time_duration_ = false; |
| } |
| if (has_user_time_duration_) { |
| user_time_duration_.Clear(); |
| has_user_time_duration_ = false; |
| } |
| test_caching_ = static_cast< ::rs::google::devtools::resultstore::v2::TestCaching >(0); |
| } |
| |
| void TestTiming::set_test_caching(const ::rs::google::devtools::resultstore::v2::TestCaching& value) { |
| has_test_caching_ = true; |
| test_caching_ = value; |
| } |
| |
| void TestAction::SerializeToOstream(OutputStream* output__) const { |
| if (has_test_timing_) { |
| WriteLengthDelimited(output__, 1, |
| test_timing_.ByteSizeLong()); |
| test_timing_.SerializeToOstream(output__); |
| } |
| if (has_shard_number_) { |
| WriteVarint32SignExtended(output__, 2, shard_number_); |
| } |
| if (has_run_number_) { |
| WriteVarint32SignExtended(output__, 3, run_number_); |
| } |
| if (has_attempt_number_) { |
| WriteVarint32SignExtended(output__, 4, attempt_number_); |
| } |
| if (has_test_suite_) { |
| WriteLengthDelimited(output__, 5, |
| test_suite_.ByteSizeLong()); |
| test_suite_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : warnings_) { |
| if (has_warnings_) { |
| WriteLengthDelimited(output__, 8, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_estimated_memory_bytes_) { |
| WriteVarint64(output__, 10, estimated_memory_bytes_); |
| } |
| } |
| |
| size_t TestAction::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_test_timing_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(test_timing_.ByteSizeLong()); |
| size += test_timing_.ByteSizeLong(); |
| } |
| if (has_shard_number_) { |
| size += VarintSize32SignExtended(shard_number_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_run_number_) { |
| size += VarintSize32SignExtended(run_number_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_attempt_number_) { |
| size += VarintSize32SignExtended(attempt_number_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_test_suite_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(test_suite_.ByteSizeLong()); |
| size += test_suite_.ByteSizeLong(); |
| } |
| for (const auto& elem : warnings_) { |
| if (has_warnings_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_estimated_memory_bytes_) { |
| size += VarintSize64(estimated_memory_bytes_) + VarintSize32(10 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TestAction::Clear() { |
| if (has_test_timing_) { |
| test_timing_.Clear(); |
| has_test_timing_ = false; |
| } |
| shard_number_ = static_cast< int32_t >(0); |
| run_number_ = static_cast< int32_t >(0); |
| attempt_number_ = static_cast< int32_t >(0); |
| if (has_test_suite_) { |
| test_suite_.Clear(); |
| has_test_suite_ = false; |
| } |
| if (has_warnings_) { |
| warnings_.clear(); |
| has_warnings_ = false; |
| } |
| estimated_memory_bytes_ = static_cast< int64_t >(0); |
| } |
| |
| void TestAction::set_shard_number(const int32_t& value) { |
| has_shard_number_ = true; |
| shard_number_ = value; |
| } |
| |
| void TestAction::set_run_number(const int32_t& value) { |
| has_run_number_ = true; |
| run_number_ = value; |
| } |
| |
| void TestAction::set_attempt_number(const int32_t& value) { |
| has_attempt_number_ = true; |
| attempt_number_ = value; |
| } |
| |
| void TestAction::add_warnings(const ::rs::google::devtools::resultstore::v2::TestWarning& value) { |
| has_warnings_ = true; |
| warnings_.push_back(value); |
| } |
| void TestAction::set_estimated_memory_bytes(const int64_t& value) { |
| has_estimated_memory_bytes_ = true; |
| estimated_memory_bytes_ = value; |
| } |
| |
| void Action::Id::SerializeToOstream(OutputStream* output__) const { |
| if (has_invocation_id_) { |
| WriteString(output__, 1, invocation_id_); |
| } |
| if (has_target_id_) { |
| WriteString(output__, 2, target_id_); |
| } |
| if (has_configuration_id_) { |
| WriteString(output__, 3, configuration_id_); |
| } |
| if (has_action_id_) { |
| WriteString(output__, 4, action_id_); |
| } |
| } |
| |
| size_t Action::Id::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_invocation_id_) { |
| size += StringSize(invocation_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_target_id_) { |
| size += StringSize(target_id_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_configuration_id_) { |
| size += StringSize(configuration_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_action_id_) { |
| size += StringSize(action_id_) + VarintSize32(4 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Action::Id::Clear() { |
| invocation_id_.clear(); |
| target_id_.clear(); |
| configuration_id_.clear(); |
| action_id_.clear(); |
| } |
| |
| void Action::Id::set_invocation_id(const std::string& value) { |
| has_invocation_id_ = true; |
| invocation_id_ = value; |
| } |
| |
| void Action::Id::set_target_id(const std::string& value) { |
| has_target_id_ = true; |
| target_id_ = value; |
| } |
| |
| void Action::Id::set_configuration_id(const std::string& value) { |
| has_configuration_id_ = true; |
| configuration_id_ = value; |
| } |
| |
| void Action::Id::set_action_id(const std::string& value) { |
| has_action_id_ = true; |
| action_id_ = value; |
| } |
| |
| void Action::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| if (has_status_attributes_) { |
| WriteLengthDelimited(output__, 3, |
| status_attributes_.ByteSizeLong()); |
| status_attributes_.SerializeToOstream(output__); |
| } |
| if (has_timing_) { |
| WriteLengthDelimited(output__, 4, |
| timing_.ByteSizeLong()); |
| timing_.SerializeToOstream(output__); |
| } |
| if (has_build_action_) { |
| WriteLengthDelimited(output__, 9, |
| build_action_.ByteSizeLong()); |
| build_action_.SerializeToOstream(output__); |
| } |
| if (has_test_action_) { |
| WriteLengthDelimited(output__, 10, |
| test_action_.ByteSizeLong()); |
| test_action_.SerializeToOstream(output__); |
| } |
| if (has_action_attributes_) { |
| WriteLengthDelimited(output__, 5, |
| action_attributes_.ByteSizeLong()); |
| action_attributes_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : action_dependencies_) { |
| if (has_action_dependencies_) { |
| WriteLengthDelimited(output__, 14, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| WriteLengthDelimited(output__, 7, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| WriteLengthDelimited(output__, 8, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : file_sets_) { |
| WriteString(output__, 15, elem); |
| } |
| if (has_coverage_) { |
| WriteLengthDelimited(output__, 11, |
| coverage_.ByteSizeLong()); |
| coverage_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : file_processing_errors_) { |
| if (has_file_processing_errors_) { |
| WriteLengthDelimited(output__, 13, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t Action::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| if (has_status_attributes_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(status_attributes_.ByteSizeLong()); |
| size += status_attributes_.ByteSizeLong(); |
| } |
| if (has_timing_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(timing_.ByteSizeLong()); |
| size += timing_.ByteSizeLong(); |
| } |
| if (has_build_action_) { |
| size += VarintSize32(9 << kTagTypeBits) + |
| VarintSize32(build_action_.ByteSizeLong()); |
| size += build_action_.ByteSizeLong(); |
| } |
| if (has_test_action_) { |
| size += VarintSize32(10 << kTagTypeBits) + |
| VarintSize32(test_action_.ByteSizeLong()); |
| size += test_action_.ByteSizeLong(); |
| } |
| if (has_action_attributes_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(action_attributes_.ByteSizeLong()); |
| size += action_attributes_.ByteSizeLong(); |
| } |
| for (const auto& elem : action_dependencies_) { |
| if (has_action_dependencies_) { |
| size += VarintSize32(14 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : file_sets_) { |
| size += StringSize(elem) + VarintSize32(15 << kTagTypeBits); |
| } |
| if (has_coverage_) { |
| size += VarintSize32(11 << kTagTypeBits) + |
| VarintSize32(coverage_.ByteSizeLong()); |
| size += coverage_.ByteSizeLong(); |
| } |
| for (const auto& elem : file_processing_errors_) { |
| if (has_file_processing_errors_) { |
| size += VarintSize32(13 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void Action::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| if (has_status_attributes_) { |
| status_attributes_.Clear(); |
| has_status_attributes_ = false; |
| } |
| if (has_timing_) { |
| timing_.Clear(); |
| has_timing_ = false; |
| } |
| if (has_build_action_) { |
| build_action_.Clear(); |
| has_build_action_ = false; |
| } |
| if (has_test_action_) { |
| test_action_.Clear(); |
| has_test_action_ = false; |
| } |
| if (has_action_attributes_) { |
| action_attributes_.Clear(); |
| has_action_attributes_ = false; |
| } |
| if (has_action_dependencies_) { |
| action_dependencies_.clear(); |
| has_action_dependencies_ = false; |
| } |
| if (has_properties_) { |
| properties_.clear(); |
| has_properties_ = false; |
| } |
| if (has_files_) { |
| files_.clear(); |
| has_files_ = false; |
| } |
| file_sets_.clear(); |
| if (has_coverage_) { |
| coverage_.Clear(); |
| has_coverage_ = false; |
| } |
| if (has_file_processing_errors_) { |
| file_processing_errors_.clear(); |
| has_file_processing_errors_ = false; |
| } |
| } |
| |
| void Action::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void Action::add_action_dependencies(const ::rs::google::devtools::resultstore::v2::Dependency& value) { |
| has_action_dependencies_ = true; |
| action_dependencies_.push_back(value); |
| } |
| void Action::add_properties(const ::rs::google::devtools::resultstore::v2::Property& value) { |
| has_properties_ = true; |
| properties_.push_back(value); |
| } |
| void Action::add_files(const ::rs::google::devtools::resultstore::v2::File& value) { |
| has_files_ = true; |
| files_.push_back(value); |
| } |
| void Action::add_file_sets(const std::string& value) { |
| has_file_sets_ = true; |
| file_sets_.push_back(value); |
| } |
| void Action::set_file_sets(const std::vector< std::string >& value) { |
| has_file_sets_ = true; |
| file_sets_ = value; |
| } |
| |
| void Action::add_file_processing_errors(const ::rs::google::devtools::resultstore::v2::FileProcessingErrors& value) { |
| has_file_processing_errors_ = true; |
| file_processing_errors_.push_back(value); |
| } |
| void RemoteTestAttemptTiming::SerializeToOstream(OutputStream* output__) const { |
| if (has_queue_duration_) { |
| WriteLengthDelimited(output__, 1, |
| queue_duration_.ByteSizeLong()); |
| queue_duration_.SerializeToOstream(output__); |
| } |
| if (has_upload_duration_) { |
| WriteLengthDelimited(output__, 2, |
| upload_duration_.ByteSizeLong()); |
| upload_duration_.SerializeToOstream(output__); |
| } |
| if (has_machine_setup_duration_) { |
| WriteLengthDelimited(output__, 3, |
| machine_setup_duration_.ByteSizeLong()); |
| machine_setup_duration_.SerializeToOstream(output__); |
| } |
| if (has_test_process_duration_) { |
| WriteLengthDelimited(output__, 4, |
| test_process_duration_.ByteSizeLong()); |
| test_process_duration_.SerializeToOstream(output__); |
| } |
| if (has_download_duration_) { |
| WriteLengthDelimited(output__, 5, |
| download_duration_.ByteSizeLong()); |
| download_duration_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t RemoteTestAttemptTiming::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_queue_duration_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(queue_duration_.ByteSizeLong()); |
| size += queue_duration_.ByteSizeLong(); |
| } |
| if (has_upload_duration_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(upload_duration_.ByteSizeLong()); |
| size += upload_duration_.ByteSizeLong(); |
| } |
| if (has_machine_setup_duration_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(machine_setup_duration_.ByteSizeLong()); |
| size += machine_setup_duration_.ByteSizeLong(); |
| } |
| if (has_test_process_duration_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(test_process_duration_.ByteSizeLong()); |
| size += test_process_duration_.ByteSizeLong(); |
| } |
| if (has_download_duration_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(download_duration_.ByteSizeLong()); |
| size += download_duration_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void RemoteTestAttemptTiming::Clear() { |
| if (has_queue_duration_) { |
| queue_duration_.Clear(); |
| has_queue_duration_ = false; |
| } |
| if (has_upload_duration_) { |
| upload_duration_.Clear(); |
| has_upload_duration_ = false; |
| } |
| if (has_machine_setup_duration_) { |
| machine_setup_duration_.Clear(); |
| has_machine_setup_duration_ = false; |
| } |
| if (has_test_process_duration_) { |
| test_process_duration_.Clear(); |
| has_test_process_duration_ = false; |
| } |
| if (has_download_duration_) { |
| download_duration_.Clear(); |
| has_download_duration_ = false; |
| } |
| } |
| |
| void TestWarning::SerializeToOstream(OutputStream* output__) const { |
| if (has_warning_message_) { |
| WriteString(output__, 1, warning_message_); |
| } |
| } |
| |
| size_t TestWarning::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_warning_message_) { |
| size += StringSize(warning_message_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TestWarning::Clear() { |
| warning_message_.clear(); |
| } |
| |
| void TestWarning::set_warning_message(const std::string& value) { |
| has_warning_message_ = true; |
| warning_message_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void ConfigurationAttributes::SerializeToOstream(OutputStream* output__) const { |
| if (has_cpu_) { |
| WriteString(output__, 1, cpu_); |
| } |
| } |
| |
| size_t ConfigurationAttributes::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_cpu_) { |
| size += StringSize(cpu_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void ConfigurationAttributes::Clear() { |
| cpu_.clear(); |
| } |
| |
| void ConfigurationAttributes::set_cpu(const std::string& value) { |
| has_cpu_ = true; |
| cpu_ = value; |
| } |
| |
| void Configuration::Id::SerializeToOstream(OutputStream* output__) const { |
| if (has_invocation_id_) { |
| WriteString(output__, 1, invocation_id_); |
| } |
| if (has_configuration_id_) { |
| WriteString(output__, 2, configuration_id_); |
| } |
| } |
| |
| size_t Configuration::Id::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_invocation_id_) { |
| size += StringSize(invocation_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_configuration_id_) { |
| size += StringSize(configuration_id_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Configuration::Id::Clear() { |
| invocation_id_.clear(); |
| configuration_id_.clear(); |
| } |
| |
| void Configuration::Id::set_invocation_id(const std::string& value) { |
| has_invocation_id_ = true; |
| invocation_id_ = value; |
| } |
| |
| void Configuration::Id::set_configuration_id(const std::string& value) { |
| has_configuration_id_ = true; |
| configuration_id_ = value; |
| } |
| |
| void Configuration::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| if (has_status_attributes_) { |
| WriteLengthDelimited(output__, 3, |
| status_attributes_.ByteSizeLong()); |
| status_attributes_.SerializeToOstream(output__); |
| } |
| if (has_configuration_attributes_) { |
| WriteLengthDelimited(output__, 5, |
| configuration_attributes_.ByteSizeLong()); |
| configuration_attributes_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| WriteLengthDelimited(output__, 6, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_display_name_) { |
| WriteString(output__, 8, display_name_); |
| } |
| } |
| |
| size_t Configuration::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| if (has_status_attributes_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(status_attributes_.ByteSizeLong()); |
| size += status_attributes_.ByteSizeLong(); |
| } |
| if (has_configuration_attributes_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(configuration_attributes_.ByteSizeLong()); |
| size += configuration_attributes_.ByteSizeLong(); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_display_name_) { |
| size += StringSize(display_name_) + VarintSize32(8 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Configuration::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| if (has_status_attributes_) { |
| status_attributes_.Clear(); |
| has_status_attributes_ = false; |
| } |
| if (has_configuration_attributes_) { |
| configuration_attributes_.Clear(); |
| has_configuration_attributes_ = false; |
| } |
| if (has_properties_) { |
| properties_.clear(); |
| has_properties_ = false; |
| } |
| display_name_.clear(); |
| } |
| |
| void Configuration::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void Configuration::add_properties(const ::rs::google::devtools::resultstore::v2::Property& value) { |
| has_properties_ = true; |
| properties_.push_back(value); |
| } |
| void Configuration::set_display_name(const std::string& value) { |
| has_display_name_ = true; |
| display_name_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void ConfiguredTestAttributes::SerializeToOstream(OutputStream* output__) const { |
| if (has_total_run_count_) { |
| WriteVarint32SignExtended(output__, 2, total_run_count_); |
| } |
| if (has_total_shard_count_) { |
| WriteVarint32SignExtended(output__, 3, total_shard_count_); |
| } |
| if (has_timeout_duration_) { |
| WriteLengthDelimited(output__, 5, |
| timeout_duration_.ByteSizeLong()); |
| timeout_duration_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t ConfiguredTestAttributes::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_total_run_count_) { |
| size += VarintSize32SignExtended(total_run_count_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_total_shard_count_) { |
| size += VarintSize32SignExtended(total_shard_count_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_timeout_duration_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(timeout_duration_.ByteSizeLong()); |
| size += timeout_duration_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void ConfiguredTestAttributes::Clear() { |
| total_run_count_ = static_cast< int32_t >(0); |
| total_shard_count_ = static_cast< int32_t >(0); |
| if (has_timeout_duration_) { |
| timeout_duration_.Clear(); |
| has_timeout_duration_ = false; |
| } |
| } |
| |
| void ConfiguredTestAttributes::set_total_run_count(const int32_t& value) { |
| has_total_run_count_ = true; |
| total_run_count_ = value; |
| } |
| |
| void ConfiguredTestAttributes::set_total_shard_count(const int32_t& value) { |
| has_total_shard_count_ = true; |
| total_shard_count_ = value; |
| } |
| |
| void ConfiguredTarget::Id::SerializeToOstream(OutputStream* output__) const { |
| if (has_invocation_id_) { |
| WriteString(output__, 1, invocation_id_); |
| } |
| if (has_target_id_) { |
| WriteString(output__, 2, target_id_); |
| } |
| if (has_configuration_id_) { |
| WriteString(output__, 3, configuration_id_); |
| } |
| } |
| |
| size_t ConfiguredTarget::Id::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_invocation_id_) { |
| size += StringSize(invocation_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_target_id_) { |
| size += StringSize(target_id_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_configuration_id_) { |
| size += StringSize(configuration_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void ConfiguredTarget::Id::Clear() { |
| invocation_id_.clear(); |
| target_id_.clear(); |
| configuration_id_.clear(); |
| } |
| |
| void ConfiguredTarget::Id::set_invocation_id(const std::string& value) { |
| has_invocation_id_ = true; |
| invocation_id_ = value; |
| } |
| |
| void ConfiguredTarget::Id::set_target_id(const std::string& value) { |
| has_target_id_ = true; |
| target_id_ = value; |
| } |
| |
| void ConfiguredTarget::Id::set_configuration_id(const std::string& value) { |
| has_configuration_id_ = true; |
| configuration_id_ = value; |
| } |
| |
| void ConfiguredTarget::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| if (has_status_attributes_) { |
| WriteLengthDelimited(output__, 3, |
| status_attributes_.ByteSizeLong()); |
| status_attributes_.SerializeToOstream(output__); |
| } |
| if (has_timing_) { |
| WriteLengthDelimited(output__, 4, |
| timing_.ByteSizeLong()); |
| timing_.SerializeToOstream(output__); |
| } |
| if (has_test_attributes_) { |
| WriteLengthDelimited(output__, 6, |
| test_attributes_.ByteSizeLong()); |
| test_attributes_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| WriteLengthDelimited(output__, 7, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| WriteLengthDelimited(output__, 8, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t ConfiguredTarget::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| if (has_status_attributes_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(status_attributes_.ByteSizeLong()); |
| size += status_attributes_.ByteSizeLong(); |
| } |
| if (has_timing_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(timing_.ByteSizeLong()); |
| size += timing_.ByteSizeLong(); |
| } |
| if (has_test_attributes_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(test_attributes_.ByteSizeLong()); |
| size += test_attributes_.ByteSizeLong(); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void ConfiguredTarget::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| if (has_status_attributes_) { |
| status_attributes_.Clear(); |
| has_status_attributes_ = false; |
| } |
| if (has_timing_) { |
| timing_.Clear(); |
| has_timing_ = false; |
| } |
| if (has_test_attributes_) { |
| test_attributes_.Clear(); |
| has_test_attributes_ = false; |
| } |
| if (has_properties_) { |
| properties_.clear(); |
| has_properties_ = false; |
| } |
| if (has_files_) { |
| files_.clear(); |
| has_files_ = false; |
| } |
| } |
| |
| void ConfiguredTarget::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void ConfiguredTarget::add_properties(const ::rs::google::devtools::resultstore::v2::Property& value) { |
| has_properties_ = true; |
| properties_.push_back(value); |
| } |
| void ConfiguredTarget::add_files(const ::rs::google::devtools::resultstore::v2::File& value) { |
| has_files_ = true; |
| files_.push_back(value); |
| } |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void FileSet::Id::SerializeToOstream(OutputStream* output__) const { |
| if (has_invocation_id_) { |
| WriteString(output__, 1, invocation_id_); |
| } |
| if (has_file_set_id_) { |
| WriteString(output__, 2, file_set_id_); |
| } |
| } |
| |
| size_t FileSet::Id::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_invocation_id_) { |
| size += StringSize(invocation_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_file_set_id_) { |
| size += StringSize(file_set_id_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FileSet::Id::Clear() { |
| invocation_id_.clear(); |
| file_set_id_.clear(); |
| } |
| |
| void FileSet::Id::set_invocation_id(const std::string& value) { |
| has_invocation_id_ = true; |
| invocation_id_ = value; |
| } |
| |
| void FileSet::Id::set_file_set_id(const std::string& value) { |
| has_file_set_id_ = true; |
| file_set_id_ = value; |
| } |
| |
| void FileSet::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : file_sets_) { |
| WriteString(output__, 3, elem); |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| WriteLengthDelimited(output__, 4, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t FileSet::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| for (const auto& elem : file_sets_) { |
| size += StringSize(elem) + VarintSize32(3 << kTagTypeBits); |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void FileSet::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| file_sets_.clear(); |
| if (has_files_) { |
| files_.clear(); |
| has_files_ = false; |
| } |
| } |
| |
| void FileSet::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void FileSet::add_file_sets(const std::string& value) { |
| has_file_sets_ = true; |
| file_sets_.push_back(value); |
| } |
| void FileSet::set_file_sets(const std::vector< std::string >& value) { |
| has_file_sets_ = true; |
| file_sets_ = value; |
| } |
| |
| void FileSet::add_files(const ::rs::google::devtools::resultstore::v2::File& value) { |
| has_files_ = true; |
| files_.push_back(value); |
| } |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void LineCoverageSummary::SerializeToOstream(OutputStream* output__) const { |
| if (has_instrumented_line_count_) { |
| WriteVarint32SignExtended(output__, 1, instrumented_line_count_); |
| } |
| if (has_executed_line_count_) { |
| WriteVarint32SignExtended(output__, 2, executed_line_count_); |
| } |
| } |
| |
| size_t LineCoverageSummary::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_instrumented_line_count_) { |
| size += VarintSize32SignExtended(instrumented_line_count_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_executed_line_count_) { |
| size += VarintSize32SignExtended(executed_line_count_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void LineCoverageSummary::Clear() { |
| instrumented_line_count_ = static_cast< int32_t >(0); |
| executed_line_count_ = static_cast< int32_t >(0); |
| } |
| |
| void LineCoverageSummary::set_instrumented_line_count(const int32_t& value) { |
| has_instrumented_line_count_ = true; |
| instrumented_line_count_ = value; |
| } |
| |
| void LineCoverageSummary::set_executed_line_count(const int32_t& value) { |
| has_executed_line_count_ = true; |
| executed_line_count_ = value; |
| } |
| |
| void BranchCoverageSummary::SerializeToOstream(OutputStream* output__) const { |
| if (has_total_branch_count_) { |
| WriteVarint32SignExtended(output__, 1, total_branch_count_); |
| } |
| if (has_executed_branch_count_) { |
| WriteVarint32SignExtended(output__, 2, executed_branch_count_); |
| } |
| if (has_taken_branch_count_) { |
| WriteVarint32SignExtended(output__, 3, taken_branch_count_); |
| } |
| } |
| |
| size_t BranchCoverageSummary::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_total_branch_count_) { |
| size += VarintSize32SignExtended(total_branch_count_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_executed_branch_count_) { |
| size += VarintSize32SignExtended(executed_branch_count_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_taken_branch_count_) { |
| size += VarintSize32SignExtended(taken_branch_count_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void BranchCoverageSummary::Clear() { |
| total_branch_count_ = static_cast< int32_t >(0); |
| executed_branch_count_ = static_cast< int32_t >(0); |
| taken_branch_count_ = static_cast< int32_t >(0); |
| } |
| |
| void BranchCoverageSummary::set_total_branch_count(const int32_t& value) { |
| has_total_branch_count_ = true; |
| total_branch_count_ = value; |
| } |
| |
| void BranchCoverageSummary::set_executed_branch_count(const int32_t& value) { |
| has_executed_branch_count_ = true; |
| executed_branch_count_ = value; |
| } |
| |
| void BranchCoverageSummary::set_taken_branch_count(const int32_t& value) { |
| has_taken_branch_count_ = true; |
| taken_branch_count_ = value; |
| } |
| |
| void LanguageCoverageSummary::SerializeToOstream(OutputStream* output__) const { |
| if (has_language_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(language_)); |
| } |
| if (has_line_summary_) { |
| WriteLengthDelimited(output__, 2, |
| line_summary_.ByteSizeLong()); |
| line_summary_.SerializeToOstream(output__); |
| } |
| if (has_branch_summary_) { |
| WriteLengthDelimited(output__, 3, |
| branch_summary_.ByteSizeLong()); |
| branch_summary_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t LanguageCoverageSummary::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_language_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(language_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_line_summary_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(line_summary_.ByteSizeLong()); |
| size += line_summary_.ByteSizeLong(); |
| } |
| if (has_branch_summary_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(branch_summary_.ByteSizeLong()); |
| size += branch_summary_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void LanguageCoverageSummary::Clear() { |
| language_ = static_cast< ::rs::google::devtools::resultstore::v2::Language >(0); |
| if (has_line_summary_) { |
| line_summary_.Clear(); |
| has_line_summary_ = false; |
| } |
| if (has_branch_summary_) { |
| branch_summary_.Clear(); |
| has_branch_summary_ = false; |
| } |
| } |
| |
| void LanguageCoverageSummary::set_language(const ::rs::google::devtools::resultstore::v2::Language& value) { |
| has_language_ = true; |
| language_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void InvocationAttributes::SerializeToOstream(OutputStream* output__) const { |
| if (has_project_id_) { |
| WriteString(output__, 1, project_id_); |
| } |
| for (const auto& elem : users_) { |
| WriteString(output__, 2, elem); |
| } |
| for (const auto& elem : labels_) { |
| WriteString(output__, 3, elem); |
| } |
| if (has_description_) { |
| WriteString(output__, 4, description_); |
| } |
| for (const auto& elem : invocation_contexts_) { |
| if (has_invocation_contexts_) { |
| WriteLengthDelimited(output__, 6, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_exit_code_) { |
| WriteVarint32SignExtended(output__, 7, exit_code_); |
| } |
| } |
| |
| size_t InvocationAttributes::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_project_id_) { |
| size += StringSize(project_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| for (const auto& elem : users_) { |
| size += StringSize(elem) + VarintSize32(2 << kTagTypeBits); |
| } |
| for (const auto& elem : labels_) { |
| size += StringSize(elem) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_description_) { |
| size += StringSize(description_) + VarintSize32(4 << kTagTypeBits); |
| } |
| for (const auto& elem : invocation_contexts_) { |
| if (has_invocation_contexts_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_exit_code_) { |
| size += VarintSize32SignExtended(exit_code_) + VarintSize32(7 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void InvocationAttributes::Clear() { |
| project_id_.clear(); |
| users_.clear(); |
| labels_.clear(); |
| description_.clear(); |
| if (has_invocation_contexts_) { |
| invocation_contexts_.clear(); |
| has_invocation_contexts_ = false; |
| } |
| exit_code_ = static_cast< int32_t >(0); |
| } |
| |
| void InvocationAttributes::set_project_id(const std::string& value) { |
| has_project_id_ = true; |
| project_id_ = value; |
| } |
| |
| void InvocationAttributes::add_users(const std::string& value) { |
| has_users_ = true; |
| users_.push_back(value); |
| } |
| void InvocationAttributes::set_users(const std::vector< std::string >& value) { |
| has_users_ = true; |
| users_ = value; |
| } |
| |
| void InvocationAttributes::add_labels(const std::string& value) { |
| has_labels_ = true; |
| labels_.push_back(value); |
| } |
| void InvocationAttributes::set_labels(const std::vector< std::string >& value) { |
| has_labels_ = true; |
| labels_ = value; |
| } |
| |
| void InvocationAttributes::set_description(const std::string& value) { |
| has_description_ = true; |
| description_ = value; |
| } |
| |
| void InvocationAttributes::add_invocation_contexts(const ::rs::google::devtools::resultstore::v2::InvocationContext& value) { |
| has_invocation_contexts_ = true; |
| invocation_contexts_.push_back(value); |
| } |
| void InvocationAttributes::set_exit_code(const int32_t& value) { |
| has_exit_code_ = true; |
| exit_code_ = value; |
| } |
| |
| void WorkspaceContext::SerializeToOstream(OutputStream* output__) const { |
| } |
| |
| size_t WorkspaceContext::ByteSizeLong() const { |
| size_t size = 0; |
| return size; |
| } |
| |
| void WorkspaceContext::Clear() { |
| } |
| |
| void WorkspaceInfo::SerializeToOstream(OutputStream* output__) const { |
| if (has_workspace_context_) { |
| WriteLengthDelimited(output__, 1, |
| workspace_context_.ByteSizeLong()); |
| workspace_context_.SerializeToOstream(output__); |
| } |
| if (has_hostname_) { |
| WriteString(output__, 3, hostname_); |
| } |
| if (has_working_directory_) { |
| WriteString(output__, 4, working_directory_); |
| } |
| if (has_tool_tag_) { |
| WriteString(output__, 5, tool_tag_); |
| } |
| for (const auto& elem : command_lines_) { |
| if (has_command_lines_) { |
| WriteLengthDelimited(output__, 7, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t WorkspaceInfo::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_workspace_context_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(workspace_context_.ByteSizeLong()); |
| size += workspace_context_.ByteSizeLong(); |
| } |
| if (has_hostname_) { |
| size += StringSize(hostname_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_working_directory_) { |
| size += StringSize(working_directory_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_tool_tag_) { |
| size += StringSize(tool_tag_) + VarintSize32(5 << kTagTypeBits); |
| } |
| for (const auto& elem : command_lines_) { |
| if (has_command_lines_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void WorkspaceInfo::Clear() { |
| if (has_workspace_context_) { |
| workspace_context_.Clear(); |
| has_workspace_context_ = false; |
| } |
| hostname_.clear(); |
| working_directory_.clear(); |
| tool_tag_.clear(); |
| if (has_command_lines_) { |
| command_lines_.clear(); |
| has_command_lines_ = false; |
| } |
| } |
| |
| void WorkspaceInfo::set_hostname(const std::string& value) { |
| has_hostname_ = true; |
| hostname_ = value; |
| } |
| |
| void WorkspaceInfo::set_working_directory(const std::string& value) { |
| has_working_directory_ = true; |
| working_directory_ = value; |
| } |
| |
| void WorkspaceInfo::set_tool_tag(const std::string& value) { |
| has_tool_tag_ = true; |
| tool_tag_ = value; |
| } |
| |
| void WorkspaceInfo::add_command_lines(const ::rs::google::devtools::resultstore::v2::CommandLine& value) { |
| has_command_lines_ = true; |
| command_lines_.push_back(value); |
| } |
| void Invocation::Id::SerializeToOstream(OutputStream* output__) const { |
| if (has_invocation_id_) { |
| WriteString(output__, 1, invocation_id_); |
| } |
| } |
| |
| size_t Invocation::Id::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_invocation_id_) { |
| size += StringSize(invocation_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Invocation::Id::Clear() { |
| invocation_id_.clear(); |
| } |
| |
| void Invocation::Id::set_invocation_id(const std::string& value) { |
| has_invocation_id_ = true; |
| invocation_id_ = value; |
| } |
| |
| void Invocation::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| if (has_status_attributes_) { |
| WriteLengthDelimited(output__, 3, |
| status_attributes_.ByteSizeLong()); |
| status_attributes_.SerializeToOstream(output__); |
| } |
| if (has_timing_) { |
| WriteLengthDelimited(output__, 4, |
| timing_.ByteSizeLong()); |
| timing_.SerializeToOstream(output__); |
| } |
| if (has_invocation_attributes_) { |
| WriteLengthDelimited(output__, 5, |
| invocation_attributes_.ByteSizeLong()); |
| invocation_attributes_.SerializeToOstream(output__); |
| } |
| if (has_workspace_info_) { |
| WriteLengthDelimited(output__, 6, |
| workspace_info_.ByteSizeLong()); |
| workspace_info_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| WriteLengthDelimited(output__, 7, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| WriteLengthDelimited(output__, 8, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : coverage_summaries_) { |
| if (has_coverage_summaries_) { |
| WriteLengthDelimited(output__, 9, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_aggregate_coverage_) { |
| WriteLengthDelimited(output__, 10, |
| aggregate_coverage_.ByteSizeLong()); |
| aggregate_coverage_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : file_processing_errors_) { |
| if (has_file_processing_errors_) { |
| WriteLengthDelimited(output__, 11, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t Invocation::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| if (has_status_attributes_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(status_attributes_.ByteSizeLong()); |
| size += status_attributes_.ByteSizeLong(); |
| } |
| if (has_timing_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(timing_.ByteSizeLong()); |
| size += timing_.ByteSizeLong(); |
| } |
| if (has_invocation_attributes_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(invocation_attributes_.ByteSizeLong()); |
| size += invocation_attributes_.ByteSizeLong(); |
| } |
| if (has_workspace_info_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(workspace_info_.ByteSizeLong()); |
| size += workspace_info_.ByteSizeLong(); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : coverage_summaries_) { |
| if (has_coverage_summaries_) { |
| size += VarintSize32(9 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_aggregate_coverage_) { |
| size += VarintSize32(10 << kTagTypeBits) + |
| VarintSize32(aggregate_coverage_.ByteSizeLong()); |
| size += aggregate_coverage_.ByteSizeLong(); |
| } |
| for (const auto& elem : file_processing_errors_) { |
| if (has_file_processing_errors_) { |
| size += VarintSize32(11 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void Invocation::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| if (has_status_attributes_) { |
| status_attributes_.Clear(); |
| has_status_attributes_ = false; |
| } |
| if (has_timing_) { |
| timing_.Clear(); |
| has_timing_ = false; |
| } |
| if (has_invocation_attributes_) { |
| invocation_attributes_.Clear(); |
| has_invocation_attributes_ = false; |
| } |
| if (has_workspace_info_) { |
| workspace_info_.Clear(); |
| has_workspace_info_ = false; |
| } |
| if (has_properties_) { |
| properties_.clear(); |
| has_properties_ = false; |
| } |
| if (has_files_) { |
| files_.clear(); |
| has_files_ = false; |
| } |
| if (has_coverage_summaries_) { |
| coverage_summaries_.clear(); |
| has_coverage_summaries_ = false; |
| } |
| if (has_aggregate_coverage_) { |
| aggregate_coverage_.Clear(); |
| has_aggregate_coverage_ = false; |
| } |
| if (has_file_processing_errors_) { |
| file_processing_errors_.clear(); |
| has_file_processing_errors_ = false; |
| } |
| } |
| |
| void Invocation::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void Invocation::add_properties(const ::rs::google::devtools::resultstore::v2::Property& value) { |
| has_properties_ = true; |
| properties_.push_back(value); |
| } |
| void Invocation::add_files(const ::rs::google::devtools::resultstore::v2::File& value) { |
| has_files_ = true; |
| files_.push_back(value); |
| } |
| void Invocation::add_coverage_summaries(const ::rs::google::devtools::resultstore::v2::LanguageCoverageSummary& value) { |
| has_coverage_summaries_ = true; |
| coverage_summaries_.push_back(value); |
| } |
| void Invocation::add_file_processing_errors(const ::rs::google::devtools::resultstore::v2::FileProcessingErrors& value) { |
| has_file_processing_errors_ = true; |
| file_processing_errors_.push_back(value); |
| } |
| void CommandLine::SerializeToOstream(OutputStream* output__) const { |
| if (has_label_) { |
| WriteString(output__, 1, label_); |
| } |
| if (has_tool_) { |
| WriteString(output__, 2, tool_); |
| } |
| for (const auto& elem : args_) { |
| WriteString(output__, 3, elem); |
| } |
| if (has_command_) { |
| WriteString(output__, 4, command_); |
| } |
| } |
| |
| size_t CommandLine::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_label_) { |
| size += StringSize(label_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_tool_) { |
| size += StringSize(tool_) + VarintSize32(2 << kTagTypeBits); |
| } |
| for (const auto& elem : args_) { |
| size += StringSize(elem) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_command_) { |
| size += StringSize(command_) + VarintSize32(4 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void CommandLine::Clear() { |
| label_.clear(); |
| tool_.clear(); |
| args_.clear(); |
| command_.clear(); |
| } |
| |
| void CommandLine::set_label(const std::string& value) { |
| has_label_ = true; |
| label_ = value; |
| } |
| |
| void CommandLine::set_tool(const std::string& value) { |
| has_tool_ = true; |
| tool_ = value; |
| } |
| |
| void CommandLine::add_args(const std::string& value) { |
| has_args_ = true; |
| args_.push_back(value); |
| } |
| void CommandLine::set_args(const std::vector< std::string >& value) { |
| has_args_ = true; |
| args_ = value; |
| } |
| |
| void CommandLine::set_command(const std::string& value) { |
| has_command_ = true; |
| command_ = value; |
| } |
| |
| void InvocationContext::SerializeToOstream(OutputStream* output__) const { |
| if (has_display_name_) { |
| WriteString(output__, 1, display_name_); |
| } |
| if (has_url_) { |
| WriteString(output__, 2, url_); |
| } |
| } |
| |
| size_t InvocationContext::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_display_name_) { |
| size += StringSize(display_name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_url_) { |
| size += StringSize(url_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void InvocationContext::Clear() { |
| display_name_.clear(); |
| url_.clear(); |
| } |
| |
| void InvocationContext::set_display_name(const std::string& value) { |
| has_display_name_ = true; |
| display_name_ = value; |
| } |
| |
| void InvocationContext::set_url(const std::string& value) { |
| has_url_ = true; |
| url_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void TargetAttributes::SerializeToOstream(OutputStream* output__) const { |
| if (has_type_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(type_)); |
| } |
| if (has_language_) { |
| WriteVarint32SignExtended(output__, 2, static_cast<int32_t>(language_)); |
| } |
| for (const auto& elem : tags_) { |
| WriteString(output__, 3, elem); |
| } |
| } |
| |
| size_t TargetAttributes::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_type_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(type_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_language_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(language_)) + VarintSize32(2 << kTagTypeBits); |
| } |
| for (const auto& elem : tags_) { |
| size += StringSize(elem) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TargetAttributes::Clear() { |
| type_ = static_cast< ::rs::google::devtools::resultstore::v2::TargetType >(0); |
| language_ = static_cast< ::rs::google::devtools::resultstore::v2::Language >(0); |
| tags_.clear(); |
| } |
| |
| void TargetAttributes::set_type(const ::rs::google::devtools::resultstore::v2::TargetType& value) { |
| has_type_ = true; |
| type_ = value; |
| } |
| |
| void TargetAttributes::set_language(const ::rs::google::devtools::resultstore::v2::Language& value) { |
| has_language_ = true; |
| language_ = value; |
| } |
| |
| void TargetAttributes::add_tags(const std::string& value) { |
| has_tags_ = true; |
| tags_.push_back(value); |
| } |
| void TargetAttributes::set_tags(const std::vector< std::string >& value) { |
| has_tags_ = true; |
| tags_ = value; |
| } |
| |
| void TestAttributes::SerializeToOstream(OutputStream* output__) const { |
| if (has_size_) { |
| WriteVarint32SignExtended(output__, 1, static_cast<int32_t>(size_)); |
| } |
| } |
| |
| size_t TestAttributes::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_size_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(size_)) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TestAttributes::Clear() { |
| size_ = static_cast< ::rs::google::devtools::resultstore::v2::TestSize >(0); |
| } |
| |
| void TestAttributes::set_size(const ::rs::google::devtools::resultstore::v2::TestSize& value) { |
| has_size_ = true; |
| size_ = value; |
| } |
| |
| void Target::Id::SerializeToOstream(OutputStream* output__) const { |
| if (has_invocation_id_) { |
| WriteString(output__, 1, invocation_id_); |
| } |
| if (has_target_id_) { |
| WriteString(output__, 2, target_id_); |
| } |
| } |
| |
| size_t Target::Id::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_invocation_id_) { |
| size += StringSize(invocation_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_target_id_) { |
| size += StringSize(target_id_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Target::Id::Clear() { |
| invocation_id_.clear(); |
| target_id_.clear(); |
| } |
| |
| void Target::Id::set_invocation_id(const std::string& value) { |
| has_invocation_id_ = true; |
| invocation_id_ = value; |
| } |
| |
| void Target::Id::set_target_id(const std::string& value) { |
| has_target_id_ = true; |
| target_id_ = value; |
| } |
| |
| void Target::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| if (has_status_attributes_) { |
| WriteLengthDelimited(output__, 3, |
| status_attributes_.ByteSizeLong()); |
| status_attributes_.SerializeToOstream(output__); |
| } |
| if (has_timing_) { |
| WriteLengthDelimited(output__, 4, |
| timing_.ByteSizeLong()); |
| timing_.SerializeToOstream(output__); |
| } |
| if (has_target_attributes_) { |
| WriteLengthDelimited(output__, 5, |
| target_attributes_.ByteSizeLong()); |
| target_attributes_.SerializeToOstream(output__); |
| } |
| if (has_test_attributes_) { |
| WriteLengthDelimited(output__, 6, |
| test_attributes_.ByteSizeLong()); |
| test_attributes_.SerializeToOstream(output__); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| WriteLengthDelimited(output__, 7, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| WriteLengthDelimited(output__, 8, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| if (has_visible_) { |
| WriteVarint32(output__, 10, visible_); |
| } |
| } |
| |
| size_t Target::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| if (has_status_attributes_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(status_attributes_.ByteSizeLong()); |
| size += status_attributes_.ByteSizeLong(); |
| } |
| if (has_timing_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(timing_.ByteSizeLong()); |
| size += timing_.ByteSizeLong(); |
| } |
| if (has_target_attributes_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(target_attributes_.ByteSizeLong()); |
| size += target_attributes_.ByteSizeLong(); |
| } |
| if (has_test_attributes_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(test_attributes_.ByteSizeLong()); |
| size += test_attributes_.ByteSizeLong(); |
| } |
| for (const auto& elem : properties_) { |
| if (has_properties_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| for (const auto& elem : files_) { |
| if (has_files_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| if (has_visible_) { |
| size += VarintSizeBool(visible_) + VarintSize32(10 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void Target::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| if (has_status_attributes_) { |
| status_attributes_.Clear(); |
| has_status_attributes_ = false; |
| } |
| if (has_timing_) { |
| timing_.Clear(); |
| has_timing_ = false; |
| } |
| if (has_target_attributes_) { |
| target_attributes_.Clear(); |
| has_target_attributes_ = false; |
| } |
| if (has_test_attributes_) { |
| test_attributes_.Clear(); |
| has_test_attributes_ = false; |
| } |
| if (has_properties_) { |
| properties_.clear(); |
| has_properties_ = false; |
| } |
| if (has_files_) { |
| files_.clear(); |
| has_files_ = false; |
| } |
| visible_ = false; |
| } |
| |
| void Target::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void Target::add_properties(const ::rs::google::devtools::resultstore::v2::Property& value) { |
| has_properties_ = true; |
| properties_.push_back(value); |
| } |
| void Target::add_files(const ::rs::google::devtools::resultstore::v2::File& value) { |
| has_files_ = true; |
| files_.push_back(value); |
| } |
| void Target::set_visible(const bool& value) { |
| has_visible_ = true; |
| visible_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void UploadMetadata::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_resume_token_) { |
| WriteString(output__, 2, resume_token_); |
| } |
| if (has_uploader_state_) { |
| WriteString(output__, 3, uploader_state_); |
| } |
| } |
| |
| size_t UploadMetadata::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_resume_token_) { |
| size += StringSize(resume_token_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_uploader_state_) { |
| size += StringSize(uploader_state_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UploadMetadata::Clear() { |
| name_.clear(); |
| resume_token_.clear(); |
| uploader_state_.clear(); |
| } |
| |
| void UploadMetadata::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void UploadMetadata::set_resume_token(const std::string& value) { |
| has_resume_token_ = true; |
| resume_token_ = value; |
| } |
| |
| void UploadMetadata::set_uploader_state(const std::string& value) { |
| has_uploader_state_ = true; |
| uploader_state_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| namespace google { |
| namespace protobuf { |
| void Empty::SerializeToOstream(OutputStream* output__) const { |
| } |
| |
| size_t Empty::ByteSizeLong() const { |
| size_t size = 0; |
| return size; |
| } |
| |
| void Empty::Clear() { |
| } |
| |
| } // namespace protobuf |
| } // namespace google |
| namespace google { |
| namespace protobuf { |
| void FieldMask::SerializeToOstream(OutputStream* output__) const { |
| for (const auto& elem : paths_) { |
| WriteString(output__, 1, elem); |
| } |
| } |
| |
| size_t FieldMask::ByteSizeLong() const { |
| size_t size = 0; |
| for (const auto& elem : paths_) { |
| size += StringSize(elem) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FieldMask::Clear() { |
| paths_.clear(); |
| } |
| |
| void FieldMask::add_paths(const std::string& value) { |
| has_paths_ = true; |
| paths_.push_back(value); |
| } |
| void FieldMask::set_paths(const std::vector< std::string >& value) { |
| has_paths_ = true; |
| paths_ = value; |
| } |
| |
| } // namespace protobuf |
| } // namespace google |
| namespace google { |
| namespace devtools { |
| namespace resultstore { |
| namespace v2 { |
| void CreateInvocationRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_invocation_id_) { |
| WriteString(output__, 2, invocation_id_); |
| } |
| if (has_invocation_) { |
| WriteLengthDelimited(output__, 3, |
| invocation_.ByteSizeLong()); |
| invocation_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 4, authorization_token_); |
| } |
| if (has_auto_finalize_time_) { |
| WriteLengthDelimited(output__, 6, |
| auto_finalize_time_.ByteSizeLong()); |
| auto_finalize_time_.SerializeToOstream(output__); |
| } |
| if (has_initial_resume_token_) { |
| WriteString(output__, 7, initial_resume_token_); |
| } |
| if (has_uploader_state_) { |
| WriteString(output__, 8, uploader_state_); |
| } |
| } |
| |
| size_t CreateInvocationRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_invocation_id_) { |
| size += StringSize(invocation_id_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_invocation_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(invocation_.ByteSizeLong()); |
| size += invocation_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_auto_finalize_time_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(auto_finalize_time_.ByteSizeLong()); |
| size += auto_finalize_time_.ByteSizeLong(); |
| } |
| if (has_initial_resume_token_) { |
| size += StringSize(initial_resume_token_) + VarintSize32(7 << kTagTypeBits); |
| } |
| if (has_uploader_state_) { |
| size += StringSize(uploader_state_) + VarintSize32(8 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void CreateInvocationRequest::Clear() { |
| request_id_.clear(); |
| invocation_id_.clear(); |
| if (has_invocation_) { |
| invocation_.Clear(); |
| has_invocation_ = false; |
| } |
| authorization_token_.clear(); |
| if (has_auto_finalize_time_) { |
| auto_finalize_time_.Clear(); |
| has_auto_finalize_time_ = false; |
| } |
| initial_resume_token_.clear(); |
| uploader_state_.clear(); |
| } |
| |
| void CreateInvocationRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void CreateInvocationRequest::set_invocation_id(const std::string& value) { |
| has_invocation_id_ = true; |
| invocation_id_ = value; |
| } |
| |
| void CreateInvocationRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void CreateInvocationRequest::set_initial_resume_token(const std::string& value) { |
| has_initial_resume_token_ = true; |
| initial_resume_token_ = value; |
| } |
| |
| void CreateInvocationRequest::set_uploader_state(const std::string& value) { |
| has_uploader_state_ = true; |
| uploader_state_ = value; |
| } |
| |
| void UpdateInvocationRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_invocation_) { |
| WriteLengthDelimited(output__, 3, |
| invocation_.ByteSizeLong()); |
| invocation_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| } |
| |
| size_t UpdateInvocationRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_invocation_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(invocation_.ByteSizeLong()); |
| size += invocation_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UpdateInvocationRequest::Clear() { |
| if (has_invocation_) { |
| invocation_.Clear(); |
| has_invocation_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| } |
| |
| void UpdateInvocationRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void MergeInvocationRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_invocation_) { |
| WriteLengthDelimited(output__, 3, |
| invocation_.ByteSizeLong()); |
| invocation_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| } |
| |
| size_t MergeInvocationRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_invocation_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(invocation_.ByteSizeLong()); |
| size += invocation_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void MergeInvocationRequest::Clear() { |
| request_id_.clear(); |
| if (has_invocation_) { |
| invocation_.Clear(); |
| has_invocation_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| } |
| |
| void MergeInvocationRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void MergeInvocationRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void TouchInvocationRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 2, authorization_token_); |
| } |
| } |
| |
| size_t TouchInvocationRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void TouchInvocationRequest::Clear() { |
| name_.clear(); |
| authorization_token_.clear(); |
| } |
| |
| void TouchInvocationRequest::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void TouchInvocationRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void TouchInvocationResponse::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t TouchInvocationResponse::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void TouchInvocationResponse::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| } |
| |
| void TouchInvocationResponse::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void DeleteInvocationRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| } |
| |
| size_t DeleteInvocationRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void DeleteInvocationRequest::Clear() { |
| name_.clear(); |
| } |
| |
| void DeleteInvocationRequest::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void FinalizeInvocationRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 3, authorization_token_); |
| } |
| } |
| |
| size_t FinalizeInvocationRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FinalizeInvocationRequest::Clear() { |
| name_.clear(); |
| authorization_token_.clear(); |
| } |
| |
| void FinalizeInvocationRequest::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void FinalizeInvocationRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void FinalizeInvocationResponse::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t FinalizeInvocationResponse::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void FinalizeInvocationResponse::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| } |
| |
| void FinalizeInvocationResponse::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void CreateTargetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_parent_) { |
| WriteString(output__, 2, parent_); |
| } |
| if (has_target_id_) { |
| WriteString(output__, 3, target_id_); |
| } |
| if (has_target_) { |
| WriteLengthDelimited(output__, 4, |
| target_.ByteSizeLong()); |
| target_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| } |
| |
| size_t CreateTargetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_parent_) { |
| size += StringSize(parent_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_target_id_) { |
| size += StringSize(target_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_target_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(target_.ByteSizeLong()); |
| size += target_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void CreateTargetRequest::Clear() { |
| request_id_.clear(); |
| parent_.clear(); |
| target_id_.clear(); |
| if (has_target_) { |
| target_.Clear(); |
| has_target_ = false; |
| } |
| authorization_token_.clear(); |
| } |
| |
| void CreateTargetRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void CreateTargetRequest::set_parent(const std::string& value) { |
| has_parent_ = true; |
| parent_ = value; |
| } |
| |
| void CreateTargetRequest::set_target_id(const std::string& value) { |
| has_target_id_ = true; |
| target_id_ = value; |
| } |
| |
| void CreateTargetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateTargetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_target_) { |
| WriteLengthDelimited(output__, 3, |
| target_.ByteSizeLong()); |
| target_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 6, create_if_not_found_); |
| } |
| } |
| |
| size_t UpdateTargetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_target_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(target_.ByteSizeLong()); |
| size += target_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UpdateTargetRequest::Clear() { |
| if (has_target_) { |
| target_.Clear(); |
| has_target_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void UpdateTargetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateTargetRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void MergeTargetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_target_) { |
| WriteLengthDelimited(output__, 3, |
| target_.ByteSizeLong()); |
| target_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 6, create_if_not_found_); |
| } |
| } |
| |
| size_t MergeTargetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_target_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(target_.ByteSizeLong()); |
| size += target_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void MergeTargetRequest::Clear() { |
| request_id_.clear(); |
| if (has_target_) { |
| target_.Clear(); |
| has_target_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void MergeTargetRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void MergeTargetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void MergeTargetRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void FinalizeTargetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 3, authorization_token_); |
| } |
| } |
| |
| size_t FinalizeTargetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FinalizeTargetRequest::Clear() { |
| name_.clear(); |
| authorization_token_.clear(); |
| } |
| |
| void FinalizeTargetRequest::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void FinalizeTargetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void FinalizeTargetResponse::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t FinalizeTargetResponse::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void FinalizeTargetResponse::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| } |
| |
| void FinalizeTargetResponse::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void CreateConfiguredTargetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_parent_) { |
| WriteString(output__, 2, parent_); |
| } |
| if (has_config_id_) { |
| WriteString(output__, 3, config_id_); |
| } |
| if (has_configured_target_) { |
| WriteLengthDelimited(output__, 4, |
| configured_target_.ByteSizeLong()); |
| configured_target_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| } |
| |
| size_t CreateConfiguredTargetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_parent_) { |
| size += StringSize(parent_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_config_id_) { |
| size += StringSize(config_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_configured_target_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(configured_target_.ByteSizeLong()); |
| size += configured_target_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void CreateConfiguredTargetRequest::Clear() { |
| request_id_.clear(); |
| parent_.clear(); |
| config_id_.clear(); |
| if (has_configured_target_) { |
| configured_target_.Clear(); |
| has_configured_target_ = false; |
| } |
| authorization_token_.clear(); |
| } |
| |
| void CreateConfiguredTargetRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void CreateConfiguredTargetRequest::set_parent(const std::string& value) { |
| has_parent_ = true; |
| parent_ = value; |
| } |
| |
| void CreateConfiguredTargetRequest::set_config_id(const std::string& value) { |
| has_config_id_ = true; |
| config_id_ = value; |
| } |
| |
| void CreateConfiguredTargetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateConfiguredTargetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_configured_target_) { |
| WriteLengthDelimited(output__, 3, |
| configured_target_.ByteSizeLong()); |
| configured_target_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 6, create_if_not_found_); |
| } |
| } |
| |
| size_t UpdateConfiguredTargetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_configured_target_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(configured_target_.ByteSizeLong()); |
| size += configured_target_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UpdateConfiguredTargetRequest::Clear() { |
| if (has_configured_target_) { |
| configured_target_.Clear(); |
| has_configured_target_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void UpdateConfiguredTargetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateConfiguredTargetRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void MergeConfiguredTargetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_configured_target_) { |
| WriteLengthDelimited(output__, 3, |
| configured_target_.ByteSizeLong()); |
| configured_target_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 6, create_if_not_found_); |
| } |
| } |
| |
| size_t MergeConfiguredTargetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_configured_target_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(configured_target_.ByteSizeLong()); |
| size += configured_target_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void MergeConfiguredTargetRequest::Clear() { |
| request_id_.clear(); |
| if (has_configured_target_) { |
| configured_target_.Clear(); |
| has_configured_target_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void MergeConfiguredTargetRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void MergeConfiguredTargetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void MergeConfiguredTargetRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void FinalizeConfiguredTargetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 3, authorization_token_); |
| } |
| } |
| |
| size_t FinalizeConfiguredTargetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(3 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void FinalizeConfiguredTargetRequest::Clear() { |
| name_.clear(); |
| authorization_token_.clear(); |
| } |
| |
| void FinalizeConfiguredTargetRequest::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void FinalizeConfiguredTargetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void FinalizeConfiguredTargetResponse::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_id_) { |
| WriteLengthDelimited(output__, 2, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t FinalizeConfiguredTargetResponse::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_id_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void FinalizeConfiguredTargetResponse::Clear() { |
| name_.clear(); |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| } |
| |
| void FinalizeConfiguredTargetResponse::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void CreateActionRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_parent_) { |
| WriteString(output__, 2, parent_); |
| } |
| if (has_action_id_) { |
| WriteString(output__, 3, action_id_); |
| } |
| if (has_action_) { |
| WriteLengthDelimited(output__, 4, |
| action_.ByteSizeLong()); |
| action_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| } |
| |
| size_t CreateActionRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_parent_) { |
| size += StringSize(parent_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_action_id_) { |
| size += StringSize(action_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_action_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(action_.ByteSizeLong()); |
| size += action_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void CreateActionRequest::Clear() { |
| request_id_.clear(); |
| parent_.clear(); |
| action_id_.clear(); |
| if (has_action_) { |
| action_.Clear(); |
| has_action_ = false; |
| } |
| authorization_token_.clear(); |
| } |
| |
| void CreateActionRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void CreateActionRequest::set_parent(const std::string& value) { |
| has_parent_ = true; |
| parent_ = value; |
| } |
| |
| void CreateActionRequest::set_action_id(const std::string& value) { |
| has_action_id_ = true; |
| action_id_ = value; |
| } |
| |
| void CreateActionRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateActionRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_action_) { |
| WriteLengthDelimited(output__, 3, |
| action_.ByteSizeLong()); |
| action_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 6, create_if_not_found_); |
| } |
| } |
| |
| size_t UpdateActionRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_action_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(action_.ByteSizeLong()); |
| size += action_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UpdateActionRequest::Clear() { |
| if (has_action_) { |
| action_.Clear(); |
| has_action_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void UpdateActionRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateActionRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void MergeActionRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_action_) { |
| WriteLengthDelimited(output__, 3, |
| action_.ByteSizeLong()); |
| action_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 6, create_if_not_found_); |
| } |
| } |
| |
| size_t MergeActionRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_action_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(action_.ByteSizeLong()); |
| size += action_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void MergeActionRequest::Clear() { |
| request_id_.clear(); |
| if (has_action_) { |
| action_.Clear(); |
| has_action_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void MergeActionRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void MergeActionRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void MergeActionRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void CreateConfigurationRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_parent_) { |
| WriteString(output__, 2, parent_); |
| } |
| if (has_config_id_) { |
| WriteString(output__, 3, config_id_); |
| } |
| if (has_configuration_) { |
| WriteLengthDelimited(output__, 4, |
| configuration_.ByteSizeLong()); |
| configuration_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| } |
| |
| size_t CreateConfigurationRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_parent_) { |
| size += StringSize(parent_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_config_id_) { |
| size += StringSize(config_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_configuration_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(configuration_.ByteSizeLong()); |
| size += configuration_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void CreateConfigurationRequest::Clear() { |
| request_id_.clear(); |
| parent_.clear(); |
| config_id_.clear(); |
| if (has_configuration_) { |
| configuration_.Clear(); |
| has_configuration_ = false; |
| } |
| authorization_token_.clear(); |
| } |
| |
| void CreateConfigurationRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void CreateConfigurationRequest::set_parent(const std::string& value) { |
| has_parent_ = true; |
| parent_ = value; |
| } |
| |
| void CreateConfigurationRequest::set_config_id(const std::string& value) { |
| has_config_id_ = true; |
| config_id_ = value; |
| } |
| |
| void CreateConfigurationRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateConfigurationRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_configuration_) { |
| WriteLengthDelimited(output__, 3, |
| configuration_.ByteSizeLong()); |
| configuration_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 4, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 6, create_if_not_found_); |
| } |
| } |
| |
| size_t UpdateConfigurationRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_configuration_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(configuration_.ByteSizeLong()); |
| size += configuration_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(6 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UpdateConfigurationRequest::Clear() { |
| if (has_configuration_) { |
| configuration_.Clear(); |
| has_configuration_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void UpdateConfigurationRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateConfigurationRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void CreateFileSetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_parent_) { |
| WriteString(output__, 2, parent_); |
| } |
| if (has_file_set_id_) { |
| WriteString(output__, 3, file_set_id_); |
| } |
| if (has_file_set_) { |
| WriteLengthDelimited(output__, 4, |
| file_set_.ByteSizeLong()); |
| file_set_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 5, authorization_token_); |
| } |
| } |
| |
| size_t CreateFileSetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_parent_) { |
| size += StringSize(parent_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_file_set_id_) { |
| size += StringSize(file_set_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_file_set_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(file_set_.ByteSizeLong()); |
| size += file_set_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void CreateFileSetRequest::Clear() { |
| request_id_.clear(); |
| parent_.clear(); |
| file_set_id_.clear(); |
| if (has_file_set_) { |
| file_set_.Clear(); |
| has_file_set_ = false; |
| } |
| authorization_token_.clear(); |
| } |
| |
| void CreateFileSetRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void CreateFileSetRequest::set_parent(const std::string& value) { |
| has_parent_ = true; |
| parent_ = value; |
| } |
| |
| void CreateFileSetRequest::set_file_set_id(const std::string& value) { |
| has_file_set_id_ = true; |
| file_set_id_ = value; |
| } |
| |
| void CreateFileSetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateFileSetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_file_set_) { |
| WriteLengthDelimited(output__, 1, |
| file_set_.ByteSizeLong()); |
| file_set_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 2, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 3, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 4, create_if_not_found_); |
| } |
| } |
| |
| size_t UpdateFileSetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_file_set_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(file_set_.ByteSizeLong()); |
| size += file_set_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(4 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UpdateFileSetRequest::Clear() { |
| if (has_file_set_) { |
| file_set_.Clear(); |
| has_file_set_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void UpdateFileSetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UpdateFileSetRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void MergeFileSetRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_request_id_) { |
| WriteString(output__, 1, request_id_); |
| } |
| if (has_file_set_) { |
| WriteLengthDelimited(output__, 2, |
| file_set_.ByteSizeLong()); |
| file_set_.SerializeToOstream(output__); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 3, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 4, authorization_token_); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 5, create_if_not_found_); |
| } |
| } |
| |
| size_t MergeFileSetRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_request_id_) { |
| size += StringSize(request_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_file_set_) { |
| size += VarintSize32(2 << kTagTypeBits) + |
| VarintSize32(file_set_.ByteSizeLong()); |
| size += file_set_.ByteSizeLong(); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(5 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void MergeFileSetRequest::Clear() { |
| request_id_.clear(); |
| if (has_file_set_) { |
| file_set_.Clear(); |
| has_file_set_ = false; |
| } |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| authorization_token_.clear(); |
| create_if_not_found_ = false; |
| } |
| |
| void MergeFileSetRequest::set_request_id(const std::string& value) { |
| has_request_id_ = true; |
| request_id_ = value; |
| } |
| |
| void MergeFileSetRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void MergeFileSetRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void UploadBatchRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_parent_) { |
| WriteString(output__, 1, parent_); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 2, authorization_token_); |
| } |
| if (has_next_resume_token_) { |
| WriteString(output__, 3, next_resume_token_); |
| } |
| if (has_resume_token_) { |
| WriteString(output__, 4, resume_token_); |
| } |
| if (has_uploader_state_) { |
| WriteString(output__, 6, uploader_state_); |
| } |
| for (const auto& elem : upload_requests_) { |
| if (has_upload_requests_) { |
| WriteLengthDelimited(output__, 5, |
| elem.ByteSizeLong()); |
| elem.SerializeToOstream(output__); |
| } |
| } |
| } |
| |
| size_t UploadBatchRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_parent_) { |
| size += StringSize(parent_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_next_resume_token_) { |
| size += StringSize(next_resume_token_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_resume_token_) { |
| size += StringSize(resume_token_) + VarintSize32(4 << kTagTypeBits); |
| } |
| if (has_uploader_state_) { |
| size += StringSize(uploader_state_) + VarintSize32(6 << kTagTypeBits); |
| } |
| for (const auto& elem : upload_requests_) { |
| if (has_upload_requests_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(elem.ByteSizeLong()); |
| size += elem.ByteSizeLong(); |
| } |
| } |
| return size; |
| } |
| |
| void UploadBatchRequest::Clear() { |
| parent_.clear(); |
| authorization_token_.clear(); |
| next_resume_token_.clear(); |
| resume_token_.clear(); |
| uploader_state_.clear(); |
| if (has_upload_requests_) { |
| upload_requests_.clear(); |
| has_upload_requests_ = false; |
| } |
| } |
| |
| void UploadBatchRequest::set_parent(const std::string& value) { |
| has_parent_ = true; |
| parent_ = value; |
| } |
| |
| void UploadBatchRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| void UploadBatchRequest::set_next_resume_token(const std::string& value) { |
| has_next_resume_token_ = true; |
| next_resume_token_ = value; |
| } |
| |
| void UploadBatchRequest::set_resume_token(const std::string& value) { |
| has_resume_token_ = true; |
| resume_token_ = value; |
| } |
| |
| void UploadBatchRequest::set_uploader_state(const std::string& value) { |
| has_uploader_state_ = true; |
| uploader_state_ = value; |
| } |
| |
| void UploadBatchRequest::add_upload_requests(const ::rs::google::devtools::resultstore::v2::UploadRequest& value) { |
| has_upload_requests_ = true; |
| upload_requests_.push_back(value); |
| } |
| void UploadBatchResponse::SerializeToOstream(OutputStream* output__) const { |
| } |
| |
| size_t UploadBatchResponse::ByteSizeLong() const { |
| size_t size = 0; |
| return size; |
| } |
| |
| void UploadBatchResponse::Clear() { |
| } |
| |
| void UploadRequest::Id::SerializeToOstream(OutputStream* output__) const { |
| if (has_target_id_) { |
| WriteString(output__, 1, target_id_); |
| } |
| if (has_configuration_id_) { |
| WriteString(output__, 2, configuration_id_); |
| } |
| if (has_action_id_) { |
| WriteString(output__, 3, action_id_); |
| } |
| if (has_file_set_id_) { |
| WriteString(output__, 4, file_set_id_); |
| } |
| } |
| |
| size_t UploadRequest::Id::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_target_id_) { |
| size += StringSize(target_id_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_configuration_id_) { |
| size += StringSize(configuration_id_) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_action_id_) { |
| size += StringSize(action_id_) + VarintSize32(3 << kTagTypeBits); |
| } |
| if (has_file_set_id_) { |
| size += StringSize(file_set_id_) + VarintSize32(4 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void UploadRequest::Id::Clear() { |
| target_id_.clear(); |
| configuration_id_.clear(); |
| action_id_.clear(); |
| file_set_id_.clear(); |
| } |
| |
| void UploadRequest::Id::set_target_id(const std::string& value) { |
| has_target_id_ = true; |
| target_id_ = value; |
| } |
| |
| void UploadRequest::Id::set_configuration_id(const std::string& value) { |
| has_configuration_id_ = true; |
| configuration_id_ = value; |
| } |
| |
| void UploadRequest::Id::set_action_id(const std::string& value) { |
| has_action_id_ = true; |
| action_id_ = value; |
| } |
| |
| void UploadRequest::Id::set_file_set_id(const std::string& value) { |
| has_file_set_id_ = true; |
| file_set_id_ = value; |
| } |
| |
| void UploadRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_id_) { |
| WriteLengthDelimited(output__, 1, |
| id_.ByteSizeLong()); |
| id_.SerializeToOstream(output__); |
| } |
| if (has_upload_operation_) { |
| WriteVarint32SignExtended(output__, 2, static_cast<int32_t>(upload_operation_)); |
| } |
| if (has_update_mask_) { |
| WriteLengthDelimited(output__, 3, |
| update_mask_.ByteSizeLong()); |
| update_mask_.SerializeToOstream(output__); |
| } |
| if (has_create_if_not_found_) { |
| WriteVarint32(output__, 10, create_if_not_found_); |
| } |
| if (has_invocation_) { |
| WriteLengthDelimited(output__, 4, |
| invocation_.ByteSizeLong()); |
| invocation_.SerializeToOstream(output__); |
| } |
| if (has_target_) { |
| WriteLengthDelimited(output__, 5, |
| target_.ByteSizeLong()); |
| target_.SerializeToOstream(output__); |
| } |
| if (has_configuration_) { |
| WriteLengthDelimited(output__, 6, |
| configuration_.ByteSizeLong()); |
| configuration_.SerializeToOstream(output__); |
| } |
| if (has_configured_target_) { |
| WriteLengthDelimited(output__, 7, |
| configured_target_.ByteSizeLong()); |
| configured_target_.SerializeToOstream(output__); |
| } |
| if (has_action_) { |
| WriteLengthDelimited(output__, 8, |
| action_.ByteSizeLong()); |
| action_.SerializeToOstream(output__); |
| } |
| if (has_file_set_) { |
| WriteLengthDelimited(output__, 9, |
| file_set_.ByteSizeLong()); |
| file_set_.SerializeToOstream(output__); |
| } |
| } |
| |
| size_t UploadRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_id_) { |
| size += VarintSize32(1 << kTagTypeBits) + |
| VarintSize32(id_.ByteSizeLong()); |
| size += id_.ByteSizeLong(); |
| } |
| if (has_upload_operation_) { |
| size += VarintSize32SignExtended(static_cast<int32_t>(upload_operation_)) + VarintSize32(2 << kTagTypeBits); |
| } |
| if (has_update_mask_) { |
| size += VarintSize32(3 << kTagTypeBits) + |
| VarintSize32(update_mask_.ByteSizeLong()); |
| size += update_mask_.ByteSizeLong(); |
| } |
| if (has_create_if_not_found_) { |
| size += VarintSizeBool(create_if_not_found_) + VarintSize32(10 << kTagTypeBits); |
| } |
| if (has_invocation_) { |
| size += VarintSize32(4 << kTagTypeBits) + |
| VarintSize32(invocation_.ByteSizeLong()); |
| size += invocation_.ByteSizeLong(); |
| } |
| if (has_target_) { |
| size += VarintSize32(5 << kTagTypeBits) + |
| VarintSize32(target_.ByteSizeLong()); |
| size += target_.ByteSizeLong(); |
| } |
| if (has_configuration_) { |
| size += VarintSize32(6 << kTagTypeBits) + |
| VarintSize32(configuration_.ByteSizeLong()); |
| size += configuration_.ByteSizeLong(); |
| } |
| if (has_configured_target_) { |
| size += VarintSize32(7 << kTagTypeBits) + |
| VarintSize32(configured_target_.ByteSizeLong()); |
| size += configured_target_.ByteSizeLong(); |
| } |
| if (has_action_) { |
| size += VarintSize32(8 << kTagTypeBits) + |
| VarintSize32(action_.ByteSizeLong()); |
| size += action_.ByteSizeLong(); |
| } |
| if (has_file_set_) { |
| size += VarintSize32(9 << kTagTypeBits) + |
| VarintSize32(file_set_.ByteSizeLong()); |
| size += file_set_.ByteSizeLong(); |
| } |
| return size; |
| } |
| |
| void UploadRequest::Clear() { |
| if (has_id_) { |
| id_.Clear(); |
| has_id_ = false; |
| } |
| upload_operation_ = static_cast< ::rs::google::devtools::resultstore::v2::UploadRequest::UploadOperation >(0); |
| if (has_update_mask_) { |
| update_mask_.Clear(); |
| has_update_mask_ = false; |
| } |
| create_if_not_found_ = false; |
| if (has_invocation_) { |
| invocation_.Clear(); |
| has_invocation_ = false; |
| } |
| if (has_target_) { |
| target_.Clear(); |
| has_target_ = false; |
| } |
| if (has_configuration_) { |
| configuration_.Clear(); |
| has_configuration_ = false; |
| } |
| if (has_configured_target_) { |
| configured_target_.Clear(); |
| has_configured_target_ = false; |
| } |
| if (has_action_) { |
| action_.Clear(); |
| has_action_ = false; |
| } |
| if (has_file_set_) { |
| file_set_.Clear(); |
| has_file_set_ = false; |
| } |
| } |
| |
| void UploadRequest::set_upload_operation(const ::rs::google::devtools::resultstore::v2::UploadRequest::UploadOperation& value) { |
| has_upload_operation_ = true; |
| upload_operation_ = value; |
| } |
| |
| void UploadRequest::set_create_if_not_found(const bool& value) { |
| has_create_if_not_found_ = true; |
| create_if_not_found_ = value; |
| } |
| |
| void GetInvocationUploadMetadataRequest::SerializeToOstream(OutputStream* output__) const { |
| if (has_name_) { |
| WriteString(output__, 1, name_); |
| } |
| if (has_authorization_token_) { |
| WriteString(output__, 2, authorization_token_); |
| } |
| } |
| |
| size_t GetInvocationUploadMetadataRequest::ByteSizeLong() const { |
| size_t size = 0; |
| if (has_name_) { |
| size += StringSize(name_) + VarintSize32(1 << kTagTypeBits); |
| } |
| if (has_authorization_token_) { |
| size += StringSize(authorization_token_) + VarintSize32(2 << kTagTypeBits); |
| } |
| return size; |
| } |
| |
| void GetInvocationUploadMetadataRequest::Clear() { |
| name_.clear(); |
| authorization_token_.clear(); |
| } |
| |
| void GetInvocationUploadMetadataRequest::set_name(const std::string& value) { |
| has_name_ = true; |
| name_ = value; |
| } |
| |
| void GetInvocationUploadMetadataRequest::set_authorization_token(const std::string& value) { |
| has_authorization_token_ = true; |
| authorization_token_ = value; |
| } |
| |
| } // namespace v2 |
| } // namespace resultstore |
| } // namespace devtools |
| } // namespace google |
| } // namespace rs |