diff options
author | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
---|---|---|
committer | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
commit | 5f8de423f190bbb79a62f804151bc24824fa32d8 (patch) | |
tree | 10027f336435511475e392454359edea8e25895d /toolkit/components/url-classifier/protobuf/safebrowsing.pb.cc | |
parent | 49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff) | |
download | UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip |
Add m-esr52 at 52.6.0
Diffstat (limited to 'toolkit/components/url-classifier/protobuf/safebrowsing.pb.cc')
-rw-r--r-- | toolkit/components/url-classifier/protobuf/safebrowsing.pb.cc | 7166 |
1 files changed, 7166 insertions, 0 deletions
diff --git a/toolkit/components/url-classifier/protobuf/safebrowsing.pb.cc b/toolkit/components/url-classifier/protobuf/safebrowsing.pb.cc new file mode 100644 index 000000000..d3e49251b --- /dev/null +++ b/toolkit/components/url-classifier/protobuf/safebrowsing.pb.cc @@ -0,0 +1,7166 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: safebrowsing.proto + +#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION +#include "safebrowsing.pb.h" + +#include <algorithm> + +#include <google/protobuf/stubs/common.h> +#include <google/protobuf/stubs/once.h> +#include <google/protobuf/io/coded_stream.h> +#include <google/protobuf/wire_format_lite_inl.h> +#include <google/protobuf/io/zero_copy_stream_impl_lite.h> +// @@protoc_insertion_point(includes) + +namespace mozilla { +namespace safebrowsing { + +void protobuf_ShutdownFile_safebrowsing_2eproto() { + delete ThreatInfo::default_instance_; + delete ThreatMatch::default_instance_; + delete FindThreatMatchesRequest::default_instance_; + delete FindThreatMatchesResponse::default_instance_; + delete FetchThreatListUpdatesRequest::default_instance_; + delete FetchThreatListUpdatesRequest_ListUpdateRequest::default_instance_; + delete FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::default_instance_; + delete FetchThreatListUpdatesResponse::default_instance_; + delete FetchThreatListUpdatesResponse_ListUpdateResponse::default_instance_; + delete FindFullHashesRequest::default_instance_; + delete FindFullHashesResponse::default_instance_; + delete ThreatHit::default_instance_; + delete ThreatHit_ThreatSource::default_instance_; + delete ClientInfo::default_instance_; + delete Checksum::default_instance_; + delete ThreatEntry::default_instance_; + delete ThreatEntrySet::default_instance_; + delete RawIndices::default_instance_; + delete RawHashes::default_instance_; + delete RiceDeltaEncoding::default_instance_; + delete ThreatEntryMetadata::default_instance_; + delete ThreatEntryMetadata_MetadataEntry::default_instance_; + delete ThreatListDescriptor::default_instance_; + delete ListThreatListsResponse::default_instance_; + delete Duration::default_instance_; +} + +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER +void protobuf_AddDesc_safebrowsing_2eproto_impl() { + GOOGLE_PROTOBUF_VERIFY_VERSION; + +#else +void protobuf_AddDesc_safebrowsing_2eproto() { + static bool already_here = false; + if (already_here) return; + already_here = true; + GOOGLE_PROTOBUF_VERIFY_VERSION; + +#endif + ThreatInfo::default_instance_ = new ThreatInfo(); + ThreatMatch::default_instance_ = new ThreatMatch(); + FindThreatMatchesRequest::default_instance_ = new FindThreatMatchesRequest(); + FindThreatMatchesResponse::default_instance_ = new FindThreatMatchesResponse(); + FetchThreatListUpdatesRequest::default_instance_ = new FetchThreatListUpdatesRequest(); + FetchThreatListUpdatesRequest_ListUpdateRequest::default_instance_ = new FetchThreatListUpdatesRequest_ListUpdateRequest(); + FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::default_instance_ = new FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints(); + FetchThreatListUpdatesResponse::default_instance_ = new FetchThreatListUpdatesResponse(); + FetchThreatListUpdatesResponse_ListUpdateResponse::default_instance_ = new FetchThreatListUpdatesResponse_ListUpdateResponse(); + FindFullHashesRequest::default_instance_ = new FindFullHashesRequest(); + FindFullHashesResponse::default_instance_ = new FindFullHashesResponse(); + ThreatHit::default_instance_ = new ThreatHit(); + ThreatHit_ThreatSource::default_instance_ = new ThreatHit_ThreatSource(); + ClientInfo::default_instance_ = new ClientInfo(); + Checksum::default_instance_ = new Checksum(); + ThreatEntry::default_instance_ = new ThreatEntry(); + ThreatEntrySet::default_instance_ = new ThreatEntrySet(); + RawIndices::default_instance_ = new RawIndices(); + RawHashes::default_instance_ = new RawHashes(); + RiceDeltaEncoding::default_instance_ = new RiceDeltaEncoding(); + ThreatEntryMetadata::default_instance_ = new ThreatEntryMetadata(); + ThreatEntryMetadata_MetadataEntry::default_instance_ = new ThreatEntryMetadata_MetadataEntry(); + ThreatListDescriptor::default_instance_ = new ThreatListDescriptor(); + ListThreatListsResponse::default_instance_ = new ListThreatListsResponse(); + Duration::default_instance_ = new Duration(); + ThreatInfo::default_instance_->InitAsDefaultInstance(); + ThreatMatch::default_instance_->InitAsDefaultInstance(); + FindThreatMatchesRequest::default_instance_->InitAsDefaultInstance(); + FindThreatMatchesResponse::default_instance_->InitAsDefaultInstance(); + FetchThreatListUpdatesRequest::default_instance_->InitAsDefaultInstance(); + FetchThreatListUpdatesRequest_ListUpdateRequest::default_instance_->InitAsDefaultInstance(); + FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::default_instance_->InitAsDefaultInstance(); + FetchThreatListUpdatesResponse::default_instance_->InitAsDefaultInstance(); + FetchThreatListUpdatesResponse_ListUpdateResponse::default_instance_->InitAsDefaultInstance(); + FindFullHashesRequest::default_instance_->InitAsDefaultInstance(); + FindFullHashesResponse::default_instance_->InitAsDefaultInstance(); + ThreatHit::default_instance_->InitAsDefaultInstance(); + ThreatHit_ThreatSource::default_instance_->InitAsDefaultInstance(); + ClientInfo::default_instance_->InitAsDefaultInstance(); + Checksum::default_instance_->InitAsDefaultInstance(); + ThreatEntry::default_instance_->InitAsDefaultInstance(); + ThreatEntrySet::default_instance_->InitAsDefaultInstance(); + RawIndices::default_instance_->InitAsDefaultInstance(); + RawHashes::default_instance_->InitAsDefaultInstance(); + RiceDeltaEncoding::default_instance_->InitAsDefaultInstance(); + ThreatEntryMetadata::default_instance_->InitAsDefaultInstance(); + ThreatEntryMetadata_MetadataEntry::default_instance_->InitAsDefaultInstance(); + ThreatListDescriptor::default_instance_->InitAsDefaultInstance(); + ListThreatListsResponse::default_instance_->InitAsDefaultInstance(); + Duration::default_instance_->InitAsDefaultInstance(); + ::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_safebrowsing_2eproto); +} + +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER +GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AddDesc_safebrowsing_2eproto_once_); +void protobuf_AddDesc_safebrowsing_2eproto() { + ::google::protobuf::GoogleOnceInit(&protobuf_AddDesc_safebrowsing_2eproto_once_, + &protobuf_AddDesc_safebrowsing_2eproto_impl); +} +#else +// Force AddDescriptors() to be called at static initialization time. +struct StaticDescriptorInitializer_safebrowsing_2eproto { + StaticDescriptorInitializer_safebrowsing_2eproto() { + protobuf_AddDesc_safebrowsing_2eproto(); + } +} static_descriptor_initializer_safebrowsing_2eproto_; +#endif +bool ThreatType_IsValid(int value) { + switch(value) { + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + return true; + default: + return false; + } +} + +bool PlatformType_IsValid(int value) { + switch(value) { + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 7: + case 8: + return true; + default: + return false; + } +} + +bool CompressionType_IsValid(int value) { + switch(value) { + case 0: + case 1: + case 2: + return true; + default: + return false; + } +} + +bool ThreatEntryType_IsValid(int value) { + switch(value) { + case 0: + case 1: + case 2: + case 3: + return true; + default: + return false; + } +} + + +// =================================================================== + +#ifndef _MSC_VER +const int ThreatInfo::kThreatTypesFieldNumber; +const int ThreatInfo::kPlatformTypesFieldNumber; +const int ThreatInfo::kThreatEntryTypesFieldNumber; +const int ThreatInfo::kThreatEntriesFieldNumber; +#endif // !_MSC_VER + +ThreatInfo::ThreatInfo() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatInfo) +} + +void ThreatInfo::InitAsDefaultInstance() { +} + +ThreatInfo::ThreatInfo(const ThreatInfo& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatInfo) +} + +void ThreatInfo::SharedCtor() { + _cached_size_ = 0; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatInfo::~ThreatInfo() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatInfo) + SharedDtor(); +} + +void ThreatInfo::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void ThreatInfo::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatInfo& ThreatInfo::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatInfo* ThreatInfo::default_instance_ = NULL; + +ThreatInfo* ThreatInfo::New() const { + return new ThreatInfo; +} + +void ThreatInfo::Clear() { + threat_types_.Clear(); + platform_types_.Clear(); + threat_entry_types_.Clear(); + threat_entries_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatInfo::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatInfo) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // repeated .mozilla.safebrowsing.ThreatType threat_types = 1; + case 1: { + if (tag == 8) { + parse_threat_types: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatType_IsValid(value)) { + add_threat_types(static_cast< ::mozilla::safebrowsing::ThreatType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else if (tag == 10) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPackedEnumNoInline( + input, + &::mozilla::safebrowsing::ThreatType_IsValid, + this->mutable_threat_types()))); + } else { + goto handle_unusual; + } + if (input->ExpectTag(8)) goto parse_threat_types; + if (input->ExpectTag(16)) goto parse_platform_types; + break; + } + + // repeated .mozilla.safebrowsing.PlatformType platform_types = 2; + case 2: { + if (tag == 16) { + parse_platform_types: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::PlatformType_IsValid(value)) { + add_platform_types(static_cast< ::mozilla::safebrowsing::PlatformType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else if (tag == 18) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPackedEnumNoInline( + input, + &::mozilla::safebrowsing::PlatformType_IsValid, + this->mutable_platform_types()))); + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_platform_types; + if (input->ExpectTag(26)) goto parse_threat_entries; + break; + } + + // repeated .mozilla.safebrowsing.ThreatEntry threat_entries = 3; + case 3: { + if (tag == 26) { + parse_threat_entries: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_threat_entries())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_threat_entries; + if (input->ExpectTag(32)) goto parse_threat_entry_types; + break; + } + + // repeated .mozilla.safebrowsing.ThreatEntryType threat_entry_types = 4; + case 4: { + if (tag == 32) { + parse_threat_entry_types: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatEntryType_IsValid(value)) { + add_threat_entry_types(static_cast< ::mozilla::safebrowsing::ThreatEntryType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else if (tag == 34) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPackedEnumNoInline( + input, + &::mozilla::safebrowsing::ThreatEntryType_IsValid, + this->mutable_threat_entry_types()))); + } else { + goto handle_unusual; + } + if (input->ExpectTag(32)) goto parse_threat_entry_types; + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatInfo) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatInfo) + return false; +#undef DO_ +} + +void ThreatInfo::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatInfo) + // repeated .mozilla.safebrowsing.ThreatType threat_types = 1; + for (int i = 0; i < this->threat_types_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 1, this->threat_types(i), output); + } + + // repeated .mozilla.safebrowsing.PlatformType platform_types = 2; + for (int i = 0; i < this->platform_types_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 2, this->platform_types(i), output); + } + + // repeated .mozilla.safebrowsing.ThreatEntry threat_entries = 3; + for (int i = 0; i < this->threat_entries_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 3, this->threat_entries(i), output); + } + + // repeated .mozilla.safebrowsing.ThreatEntryType threat_entry_types = 4; + for (int i = 0; i < this->threat_entry_types_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 4, this->threat_entry_types(i), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatInfo) +} + +int ThreatInfo::ByteSize() const { + int total_size = 0; + + // repeated .mozilla.safebrowsing.ThreatType threat_types = 1; + { + int data_size = 0; + for (int i = 0; i < this->threat_types_size(); i++) { + data_size += ::google::protobuf::internal::WireFormatLite::EnumSize( + this->threat_types(i)); + } + total_size += 1 * this->threat_types_size() + data_size; + } + + // repeated .mozilla.safebrowsing.PlatformType platform_types = 2; + { + int data_size = 0; + for (int i = 0; i < this->platform_types_size(); i++) { + data_size += ::google::protobuf::internal::WireFormatLite::EnumSize( + this->platform_types(i)); + } + total_size += 1 * this->platform_types_size() + data_size; + } + + // repeated .mozilla.safebrowsing.ThreatEntryType threat_entry_types = 4; + { + int data_size = 0; + for (int i = 0; i < this->threat_entry_types_size(); i++) { + data_size += ::google::protobuf::internal::WireFormatLite::EnumSize( + this->threat_entry_types(i)); + } + total_size += 1 * this->threat_entry_types_size() + data_size; + } + + // repeated .mozilla.safebrowsing.ThreatEntry threat_entries = 3; + total_size += 1 * this->threat_entries_size(); + for (int i = 0; i < this->threat_entries_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->threat_entries(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatInfo::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatInfo*>(&from)); +} + +void ThreatInfo::MergeFrom(const ThreatInfo& from) { + GOOGLE_CHECK_NE(&from, this); + threat_types_.MergeFrom(from.threat_types_); + platform_types_.MergeFrom(from.platform_types_); + threat_entry_types_.MergeFrom(from.threat_entry_types_); + threat_entries_.MergeFrom(from.threat_entries_); + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatInfo::CopyFrom(const ThreatInfo& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatInfo::IsInitialized() const { + + return true; +} + +void ThreatInfo::Swap(ThreatInfo* other) { + if (other != this) { + threat_types_.Swap(&other->threat_types_); + platform_types_.Swap(&other->platform_types_); + threat_entry_types_.Swap(&other->threat_entry_types_); + threat_entries_.Swap(&other->threat_entries_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatInfo::GetTypeName() const { + return "mozilla.safebrowsing.ThreatInfo"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int ThreatMatch::kThreatTypeFieldNumber; +const int ThreatMatch::kPlatformTypeFieldNumber; +const int ThreatMatch::kThreatEntryTypeFieldNumber; +const int ThreatMatch::kThreatFieldNumber; +const int ThreatMatch::kThreatEntryMetadataFieldNumber; +const int ThreatMatch::kCacheDurationFieldNumber; +#endif // !_MSC_VER + +ThreatMatch::ThreatMatch() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatMatch) +} + +void ThreatMatch::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + threat_ = const_cast< ::mozilla::safebrowsing::ThreatEntry*>( + ::mozilla::safebrowsing::ThreatEntry::internal_default_instance()); +#else + threat_ = const_cast< ::mozilla::safebrowsing::ThreatEntry*>(&::mozilla::safebrowsing::ThreatEntry::default_instance()); +#endif +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + threat_entry_metadata_ = const_cast< ::mozilla::safebrowsing::ThreatEntryMetadata*>( + ::mozilla::safebrowsing::ThreatEntryMetadata::internal_default_instance()); +#else + threat_entry_metadata_ = const_cast< ::mozilla::safebrowsing::ThreatEntryMetadata*>(&::mozilla::safebrowsing::ThreatEntryMetadata::default_instance()); +#endif +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + cache_duration_ = const_cast< ::mozilla::safebrowsing::Duration*>( + ::mozilla::safebrowsing::Duration::internal_default_instance()); +#else + cache_duration_ = const_cast< ::mozilla::safebrowsing::Duration*>(&::mozilla::safebrowsing::Duration::default_instance()); +#endif +} + +ThreatMatch::ThreatMatch(const ThreatMatch& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatMatch) +} + +void ThreatMatch::SharedCtor() { + _cached_size_ = 0; + threat_type_ = 0; + platform_type_ = 0; + threat_entry_type_ = 0; + threat_ = NULL; + threat_entry_metadata_ = NULL; + cache_duration_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatMatch::~ThreatMatch() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatMatch) + SharedDtor(); +} + +void ThreatMatch::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete threat_; + delete threat_entry_metadata_; + delete cache_duration_; + } +} + +void ThreatMatch::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatMatch& ThreatMatch::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatMatch* ThreatMatch::default_instance_ = NULL; + +ThreatMatch* ThreatMatch::New() const { + return new ThreatMatch; +} + +void ThreatMatch::Clear() { +#define OFFSET_OF_FIELD_(f) (reinterpret_cast<char*>( \ + &reinterpret_cast<ThreatMatch*>(16)->f) - \ + reinterpret_cast<char*>(16)) + +#define ZR_(first, last) do { \ + size_t f = OFFSET_OF_FIELD_(first); \ + size_t n = OFFSET_OF_FIELD_(last) - f + sizeof(last); \ + ::memset(&first, 0, n); \ + } while (0) + + if (_has_bits_[0 / 32] & 63) { + ZR_(threat_type_, platform_type_); + threat_entry_type_ = 0; + if (has_threat()) { + if (threat_ != NULL) threat_->::mozilla::safebrowsing::ThreatEntry::Clear(); + } + if (has_threat_entry_metadata()) { + if (threat_entry_metadata_ != NULL) threat_entry_metadata_->::mozilla::safebrowsing::ThreatEntryMetadata::Clear(); + } + if (has_cache_duration()) { + if (cache_duration_ != NULL) cache_duration_->::mozilla::safebrowsing::Duration::Clear(); + } + } + +#undef OFFSET_OF_FIELD_ +#undef ZR_ + + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatMatch::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatMatch) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + case 1: { + if (tag == 8) { + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatType_IsValid(value)) { + set_threat_type(static_cast< ::mozilla::safebrowsing::ThreatType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_platform_type; + break; + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + case 2: { + if (tag == 16) { + parse_platform_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::PlatformType_IsValid(value)) { + set_platform_type(static_cast< ::mozilla::safebrowsing::PlatformType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_threat; + break; + } + + // optional .mozilla.safebrowsing.ThreatEntry threat = 3; + case 3: { + if (tag == 26) { + parse_threat: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_threat())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(34)) goto parse_threat_entry_metadata; + break; + } + + // optional .mozilla.safebrowsing.ThreatEntryMetadata threat_entry_metadata = 4; + case 4: { + if (tag == 34) { + parse_threat_entry_metadata: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_threat_entry_metadata())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(42)) goto parse_cache_duration; + break; + } + + // optional .mozilla.safebrowsing.Duration cache_duration = 5; + case 5: { + if (tag == 42) { + parse_cache_duration: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_cache_duration())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(48)) goto parse_threat_entry_type; + break; + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 6; + case 6: { + if (tag == 48) { + parse_threat_entry_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatEntryType_IsValid(value)) { + set_threat_entry_type(static_cast< ::mozilla::safebrowsing::ThreatEntryType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatMatch) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatMatch) + return false; +#undef DO_ +} + +void ThreatMatch::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatMatch) + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 1, this->threat_type(), output); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + if (has_platform_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 2, this->platform_type(), output); + } + + // optional .mozilla.safebrowsing.ThreatEntry threat = 3; + if (has_threat()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 3, this->threat(), output); + } + + // optional .mozilla.safebrowsing.ThreatEntryMetadata threat_entry_metadata = 4; + if (has_threat_entry_metadata()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 4, this->threat_entry_metadata(), output); + } + + // optional .mozilla.safebrowsing.Duration cache_duration = 5; + if (has_cache_duration()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 5, this->cache_duration(), output); + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 6; + if (has_threat_entry_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 6, this->threat_entry_type(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatMatch) +} + +int ThreatMatch::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_type()); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + if (has_platform_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->platform_type()); + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 6; + if (has_threat_entry_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_entry_type()); + } + + // optional .mozilla.safebrowsing.ThreatEntry threat = 3; + if (has_threat()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->threat()); + } + + // optional .mozilla.safebrowsing.ThreatEntryMetadata threat_entry_metadata = 4; + if (has_threat_entry_metadata()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->threat_entry_metadata()); + } + + // optional .mozilla.safebrowsing.Duration cache_duration = 5; + if (has_cache_duration()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->cache_duration()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatMatch::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatMatch*>(&from)); +} + +void ThreatMatch::MergeFrom(const ThreatMatch& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_threat_type()) { + set_threat_type(from.threat_type()); + } + if (from.has_platform_type()) { + set_platform_type(from.platform_type()); + } + if (from.has_threat_entry_type()) { + set_threat_entry_type(from.threat_entry_type()); + } + if (from.has_threat()) { + mutable_threat()->::mozilla::safebrowsing::ThreatEntry::MergeFrom(from.threat()); + } + if (from.has_threat_entry_metadata()) { + mutable_threat_entry_metadata()->::mozilla::safebrowsing::ThreatEntryMetadata::MergeFrom(from.threat_entry_metadata()); + } + if (from.has_cache_duration()) { + mutable_cache_duration()->::mozilla::safebrowsing::Duration::MergeFrom(from.cache_duration()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatMatch::CopyFrom(const ThreatMatch& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatMatch::IsInitialized() const { + + return true; +} + +void ThreatMatch::Swap(ThreatMatch* other) { + if (other != this) { + std::swap(threat_type_, other->threat_type_); + std::swap(platform_type_, other->platform_type_); + std::swap(threat_entry_type_, other->threat_entry_type_); + std::swap(threat_, other->threat_); + std::swap(threat_entry_metadata_, other->threat_entry_metadata_); + std::swap(cache_duration_, other->cache_duration_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatMatch::GetTypeName() const { + return "mozilla.safebrowsing.ThreatMatch"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int FindThreatMatchesRequest::kClientFieldNumber; +const int FindThreatMatchesRequest::kThreatInfoFieldNumber; +#endif // !_MSC_VER + +FindThreatMatchesRequest::FindThreatMatchesRequest() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FindThreatMatchesRequest) +} + +void FindThreatMatchesRequest::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + client_ = const_cast< ::mozilla::safebrowsing::ClientInfo*>( + ::mozilla::safebrowsing::ClientInfo::internal_default_instance()); +#else + client_ = const_cast< ::mozilla::safebrowsing::ClientInfo*>(&::mozilla::safebrowsing::ClientInfo::default_instance()); +#endif +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + threat_info_ = const_cast< ::mozilla::safebrowsing::ThreatInfo*>( + ::mozilla::safebrowsing::ThreatInfo::internal_default_instance()); +#else + threat_info_ = const_cast< ::mozilla::safebrowsing::ThreatInfo*>(&::mozilla::safebrowsing::ThreatInfo::default_instance()); +#endif +} + +FindThreatMatchesRequest::FindThreatMatchesRequest(const FindThreatMatchesRequest& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FindThreatMatchesRequest) +} + +void FindThreatMatchesRequest::SharedCtor() { + _cached_size_ = 0; + client_ = NULL; + threat_info_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FindThreatMatchesRequest::~FindThreatMatchesRequest() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FindThreatMatchesRequest) + SharedDtor(); +} + +void FindThreatMatchesRequest::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete client_; + delete threat_info_; + } +} + +void FindThreatMatchesRequest::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FindThreatMatchesRequest& FindThreatMatchesRequest::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FindThreatMatchesRequest* FindThreatMatchesRequest::default_instance_ = NULL; + +FindThreatMatchesRequest* FindThreatMatchesRequest::New() const { + return new FindThreatMatchesRequest; +} + +void FindThreatMatchesRequest::Clear() { + if (_has_bits_[0 / 32] & 3) { + if (has_client()) { + if (client_ != NULL) client_->::mozilla::safebrowsing::ClientInfo::Clear(); + } + if (has_threat_info()) { + if (threat_info_ != NULL) threat_info_->::mozilla::safebrowsing::ThreatInfo::Clear(); + } + } + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FindThreatMatchesRequest::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FindThreatMatchesRequest) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.ClientInfo client = 1; + case 1: { + if (tag == 10) { + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_client())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(18)) goto parse_threat_info; + break; + } + + // optional .mozilla.safebrowsing.ThreatInfo threat_info = 2; + case 2: { + if (tag == 18) { + parse_threat_info: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_threat_info())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FindThreatMatchesRequest) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FindThreatMatchesRequest) + return false; +#undef DO_ +} + +void FindThreatMatchesRequest::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FindThreatMatchesRequest) + // optional .mozilla.safebrowsing.ClientInfo client = 1; + if (has_client()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 1, this->client(), output); + } + + // optional .mozilla.safebrowsing.ThreatInfo threat_info = 2; + if (has_threat_info()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 2, this->threat_info(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FindThreatMatchesRequest) +} + +int FindThreatMatchesRequest::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.ClientInfo client = 1; + if (has_client()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->client()); + } + + // optional .mozilla.safebrowsing.ThreatInfo threat_info = 2; + if (has_threat_info()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->threat_info()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FindThreatMatchesRequest::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FindThreatMatchesRequest*>(&from)); +} + +void FindThreatMatchesRequest::MergeFrom(const FindThreatMatchesRequest& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_client()) { + mutable_client()->::mozilla::safebrowsing::ClientInfo::MergeFrom(from.client()); + } + if (from.has_threat_info()) { + mutable_threat_info()->::mozilla::safebrowsing::ThreatInfo::MergeFrom(from.threat_info()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FindThreatMatchesRequest::CopyFrom(const FindThreatMatchesRequest& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FindThreatMatchesRequest::IsInitialized() const { + + return true; +} + +void FindThreatMatchesRequest::Swap(FindThreatMatchesRequest* other) { + if (other != this) { + std::swap(client_, other->client_); + std::swap(threat_info_, other->threat_info_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FindThreatMatchesRequest::GetTypeName() const { + return "mozilla.safebrowsing.FindThreatMatchesRequest"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int FindThreatMatchesResponse::kMatchesFieldNumber; +#endif // !_MSC_VER + +FindThreatMatchesResponse::FindThreatMatchesResponse() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FindThreatMatchesResponse) +} + +void FindThreatMatchesResponse::InitAsDefaultInstance() { +} + +FindThreatMatchesResponse::FindThreatMatchesResponse(const FindThreatMatchesResponse& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FindThreatMatchesResponse) +} + +void FindThreatMatchesResponse::SharedCtor() { + _cached_size_ = 0; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FindThreatMatchesResponse::~FindThreatMatchesResponse() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FindThreatMatchesResponse) + SharedDtor(); +} + +void FindThreatMatchesResponse::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void FindThreatMatchesResponse::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FindThreatMatchesResponse& FindThreatMatchesResponse::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FindThreatMatchesResponse* FindThreatMatchesResponse::default_instance_ = NULL; + +FindThreatMatchesResponse* FindThreatMatchesResponse::New() const { + return new FindThreatMatchesResponse; +} + +void FindThreatMatchesResponse::Clear() { + matches_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FindThreatMatchesResponse::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FindThreatMatchesResponse) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // repeated .mozilla.safebrowsing.ThreatMatch matches = 1; + case 1: { + if (tag == 10) { + parse_matches: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_matches())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(10)) goto parse_matches; + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FindThreatMatchesResponse) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FindThreatMatchesResponse) + return false; +#undef DO_ +} + +void FindThreatMatchesResponse::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FindThreatMatchesResponse) + // repeated .mozilla.safebrowsing.ThreatMatch matches = 1; + for (int i = 0; i < this->matches_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 1, this->matches(i), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FindThreatMatchesResponse) +} + +int FindThreatMatchesResponse::ByteSize() const { + int total_size = 0; + + // repeated .mozilla.safebrowsing.ThreatMatch matches = 1; + total_size += 1 * this->matches_size(); + for (int i = 0; i < this->matches_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->matches(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FindThreatMatchesResponse::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FindThreatMatchesResponse*>(&from)); +} + +void FindThreatMatchesResponse::MergeFrom(const FindThreatMatchesResponse& from) { + GOOGLE_CHECK_NE(&from, this); + matches_.MergeFrom(from.matches_); + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FindThreatMatchesResponse::CopyFrom(const FindThreatMatchesResponse& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FindThreatMatchesResponse::IsInitialized() const { + + return true; +} + +void FindThreatMatchesResponse::Swap(FindThreatMatchesResponse* other) { + if (other != this) { + matches_.Swap(&other->matches_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FindThreatMatchesResponse::GetTypeName() const { + return "mozilla.safebrowsing.FindThreatMatchesResponse"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::kMaxUpdateEntriesFieldNumber; +const int FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::kMaxDatabaseEntriesFieldNumber; +const int FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::kRegionFieldNumber; +const int FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::kSupportedCompressionsFieldNumber; +#endif // !_MSC_VER + +FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints) +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::InitAsDefaultInstance() { +} + +FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints(const FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints) +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + max_update_entries_ = 0; + max_database_entries_ = 0; + region_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::~FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints) + SharedDtor(); +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::SharedDtor() { + if (region_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete region_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints& FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints* FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::default_instance_ = NULL; + +FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints* FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::New() const { + return new FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints; +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::Clear() { +#define OFFSET_OF_FIELD_(f) (reinterpret_cast<char*>( \ + &reinterpret_cast<FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints*>(16)->f) - \ + reinterpret_cast<char*>(16)) + +#define ZR_(first, last) do { \ + size_t f = OFFSET_OF_FIELD_(first); \ + size_t n = OFFSET_OF_FIELD_(last) - f + sizeof(last); \ + ::memset(&first, 0, n); \ + } while (0) + + if (_has_bits_[0 / 32] & 7) { + ZR_(max_update_entries_, max_database_entries_); + if (has_region()) { + if (region_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + region_->clear(); + } + } + } + +#undef OFFSET_OF_FIELD_ +#undef ZR_ + + supported_compressions_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional int32 max_update_entries = 1; + case 1: { + if (tag == 8) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( + input, &max_update_entries_))); + set_has_max_update_entries(); + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_max_database_entries; + break; + } + + // optional int32 max_database_entries = 2; + case 2: { + if (tag == 16) { + parse_max_database_entries: + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( + input, &max_database_entries_))); + set_has_max_database_entries(); + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_region; + break; + } + + // optional string region = 3; + case 3: { + if (tag == 26) { + parse_region: + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_region())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(32)) goto parse_supported_compressions; + break; + } + + // repeated .mozilla.safebrowsing.CompressionType supported_compressions = 4; + case 4: { + if (tag == 32) { + parse_supported_compressions: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::CompressionType_IsValid(value)) { + add_supported_compressions(static_cast< ::mozilla::safebrowsing::CompressionType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else if (tag == 34) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPackedEnumNoInline( + input, + &::mozilla::safebrowsing::CompressionType_IsValid, + this->mutable_supported_compressions()))); + } else { + goto handle_unusual; + } + if (input->ExpectTag(32)) goto parse_supported_compressions; + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints) + return false; +#undef DO_ +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints) + // optional int32 max_update_entries = 1; + if (has_max_update_entries()) { + ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->max_update_entries(), output); + } + + // optional int32 max_database_entries = 2; + if (has_max_database_entries()) { + ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->max_database_entries(), output); + } + + // optional string region = 3; + if (has_region()) { + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 3, this->region(), output); + } + + // repeated .mozilla.safebrowsing.CompressionType supported_compressions = 4; + for (int i = 0; i < this->supported_compressions_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 4, this->supported_compressions(i), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints) +} + +int FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional int32 max_update_entries = 1; + if (has_max_update_entries()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::Int32Size( + this->max_update_entries()); + } + + // optional int32 max_database_entries = 2; + if (has_max_database_entries()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::Int32Size( + this->max_database_entries()); + } + + // optional string region = 3; + if (has_region()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->region()); + } + + } + // repeated .mozilla.safebrowsing.CompressionType supported_compressions = 4; + { + int data_size = 0; + for (int i = 0; i < this->supported_compressions_size(); i++) { + data_size += ::google::protobuf::internal::WireFormatLite::EnumSize( + this->supported_compressions(i)); + } + total_size += 1 * this->supported_compressions_size() + data_size; + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints*>(&from)); +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::MergeFrom(const FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints& from) { + GOOGLE_CHECK_NE(&from, this); + supported_compressions_.MergeFrom(from.supported_compressions_); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_max_update_entries()) { + set_max_update_entries(from.max_update_entries()); + } + if (from.has_max_database_entries()) { + set_max_database_entries(from.max_database_entries()); + } + if (from.has_region()) { + set_region(from.region()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::CopyFrom(const FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::IsInitialized() const { + + return true; +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::Swap(FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints* other) { + if (other != this) { + std::swap(max_update_entries_, other->max_update_entries_); + std::swap(max_database_entries_, other->max_database_entries_); + std::swap(region_, other->region_); + supported_compressions_.Swap(&other->supported_compressions_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::GetTypeName() const { + return "mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints"; +} + + +// ------------------------------------------------------------------- + +#ifndef _MSC_VER +const int FetchThreatListUpdatesRequest_ListUpdateRequest::kThreatTypeFieldNumber; +const int FetchThreatListUpdatesRequest_ListUpdateRequest::kPlatformTypeFieldNumber; +const int FetchThreatListUpdatesRequest_ListUpdateRequest::kThreatEntryTypeFieldNumber; +const int FetchThreatListUpdatesRequest_ListUpdateRequest::kStateFieldNumber; +const int FetchThreatListUpdatesRequest_ListUpdateRequest::kConstraintsFieldNumber; +#endif // !_MSC_VER + +FetchThreatListUpdatesRequest_ListUpdateRequest::FetchThreatListUpdatesRequest_ListUpdateRequest() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest) +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + constraints_ = const_cast< ::mozilla::safebrowsing::FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints*>( + ::mozilla::safebrowsing::FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::internal_default_instance()); +#else + constraints_ = const_cast< ::mozilla::safebrowsing::FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints*>(&::mozilla::safebrowsing::FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::default_instance()); +#endif +} + +FetchThreatListUpdatesRequest_ListUpdateRequest::FetchThreatListUpdatesRequest_ListUpdateRequest(const FetchThreatListUpdatesRequest_ListUpdateRequest& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest) +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + threat_type_ = 0; + platform_type_ = 0; + threat_entry_type_ = 0; + state_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + constraints_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FetchThreatListUpdatesRequest_ListUpdateRequest::~FetchThreatListUpdatesRequest_ListUpdateRequest() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest) + SharedDtor(); +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::SharedDtor() { + if (state_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete state_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete constraints_; + } +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FetchThreatListUpdatesRequest_ListUpdateRequest& FetchThreatListUpdatesRequest_ListUpdateRequest::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FetchThreatListUpdatesRequest_ListUpdateRequest* FetchThreatListUpdatesRequest_ListUpdateRequest::default_instance_ = NULL; + +FetchThreatListUpdatesRequest_ListUpdateRequest* FetchThreatListUpdatesRequest_ListUpdateRequest::New() const { + return new FetchThreatListUpdatesRequest_ListUpdateRequest; +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::Clear() { +#define OFFSET_OF_FIELD_(f) (reinterpret_cast<char*>( \ + &reinterpret_cast<FetchThreatListUpdatesRequest_ListUpdateRequest*>(16)->f) - \ + reinterpret_cast<char*>(16)) + +#define ZR_(first, last) do { \ + size_t f = OFFSET_OF_FIELD_(first); \ + size_t n = OFFSET_OF_FIELD_(last) - f + sizeof(last); \ + ::memset(&first, 0, n); \ + } while (0) + + if (_has_bits_[0 / 32] & 31) { + ZR_(threat_type_, platform_type_); + threat_entry_type_ = 0; + if (has_state()) { + if (state_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + state_->clear(); + } + } + if (has_constraints()) { + if (constraints_ != NULL) constraints_->::mozilla::safebrowsing::FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::Clear(); + } + } + +#undef OFFSET_OF_FIELD_ +#undef ZR_ + + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FetchThreatListUpdatesRequest_ListUpdateRequest::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + case 1: { + if (tag == 8) { + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatType_IsValid(value)) { + set_threat_type(static_cast< ::mozilla::safebrowsing::ThreatType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_platform_type; + break; + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + case 2: { + if (tag == 16) { + parse_platform_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::PlatformType_IsValid(value)) { + set_platform_type(static_cast< ::mozilla::safebrowsing::PlatformType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_state; + break; + } + + // optional bytes state = 3; + case 3: { + if (tag == 26) { + parse_state: + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->mutable_state())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(34)) goto parse_constraints; + break; + } + + // optional .mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints constraints = 4; + case 4: { + if (tag == 34) { + parse_constraints: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_constraints())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(40)) goto parse_threat_entry_type; + break; + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 5; + case 5: { + if (tag == 40) { + parse_threat_entry_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatEntryType_IsValid(value)) { + set_threat_entry_type(static_cast< ::mozilla::safebrowsing::ThreatEntryType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest) + return false; +#undef DO_ +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest) + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 1, this->threat_type(), output); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + if (has_platform_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 2, this->platform_type(), output); + } + + // optional bytes state = 3; + if (has_state()) { + ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( + 3, this->state(), output); + } + + // optional .mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints constraints = 4; + if (has_constraints()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 4, this->constraints(), output); + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 5; + if (has_threat_entry_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 5, this->threat_entry_type(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest) +} + +int FetchThreatListUpdatesRequest_ListUpdateRequest::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_type()); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + if (has_platform_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->platform_type()); + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 5; + if (has_threat_entry_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_entry_type()); + } + + // optional bytes state = 3; + if (has_state()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::BytesSize( + this->state()); + } + + // optional .mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest.Constraints constraints = 4; + if (has_constraints()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->constraints()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FetchThreatListUpdatesRequest_ListUpdateRequest*>(&from)); +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::MergeFrom(const FetchThreatListUpdatesRequest_ListUpdateRequest& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_threat_type()) { + set_threat_type(from.threat_type()); + } + if (from.has_platform_type()) { + set_platform_type(from.platform_type()); + } + if (from.has_threat_entry_type()) { + set_threat_entry_type(from.threat_entry_type()); + } + if (from.has_state()) { + set_state(from.state()); + } + if (from.has_constraints()) { + mutable_constraints()->::mozilla::safebrowsing::FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints::MergeFrom(from.constraints()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::CopyFrom(const FetchThreatListUpdatesRequest_ListUpdateRequest& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FetchThreatListUpdatesRequest_ListUpdateRequest::IsInitialized() const { + + return true; +} + +void FetchThreatListUpdatesRequest_ListUpdateRequest::Swap(FetchThreatListUpdatesRequest_ListUpdateRequest* other) { + if (other != this) { + std::swap(threat_type_, other->threat_type_); + std::swap(platform_type_, other->platform_type_); + std::swap(threat_entry_type_, other->threat_entry_type_); + std::swap(state_, other->state_); + std::swap(constraints_, other->constraints_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FetchThreatListUpdatesRequest_ListUpdateRequest::GetTypeName() const { + return "mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest"; +} + + +// ------------------------------------------------------------------- + +#ifndef _MSC_VER +const int FetchThreatListUpdatesRequest::kClientFieldNumber; +const int FetchThreatListUpdatesRequest::kListUpdateRequestsFieldNumber; +#endif // !_MSC_VER + +FetchThreatListUpdatesRequest::FetchThreatListUpdatesRequest() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest) +} + +void FetchThreatListUpdatesRequest::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + client_ = const_cast< ::mozilla::safebrowsing::ClientInfo*>( + ::mozilla::safebrowsing::ClientInfo::internal_default_instance()); +#else + client_ = const_cast< ::mozilla::safebrowsing::ClientInfo*>(&::mozilla::safebrowsing::ClientInfo::default_instance()); +#endif +} + +FetchThreatListUpdatesRequest::FetchThreatListUpdatesRequest(const FetchThreatListUpdatesRequest& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest) +} + +void FetchThreatListUpdatesRequest::SharedCtor() { + _cached_size_ = 0; + client_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FetchThreatListUpdatesRequest::~FetchThreatListUpdatesRequest() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FetchThreatListUpdatesRequest) + SharedDtor(); +} + +void FetchThreatListUpdatesRequest::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete client_; + } +} + +void FetchThreatListUpdatesRequest::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FetchThreatListUpdatesRequest& FetchThreatListUpdatesRequest::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FetchThreatListUpdatesRequest* FetchThreatListUpdatesRequest::default_instance_ = NULL; + +FetchThreatListUpdatesRequest* FetchThreatListUpdatesRequest::New() const { + return new FetchThreatListUpdatesRequest; +} + +void FetchThreatListUpdatesRequest::Clear() { + if (has_client()) { + if (client_ != NULL) client_->::mozilla::safebrowsing::ClientInfo::Clear(); + } + list_update_requests_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FetchThreatListUpdatesRequest::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FetchThreatListUpdatesRequest) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.ClientInfo client = 1; + case 1: { + if (tag == 10) { + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_client())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_list_update_requests; + break; + } + + // repeated .mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest list_update_requests = 3; + case 3: { + if (tag == 26) { + parse_list_update_requests: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_list_update_requests())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_list_update_requests; + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FetchThreatListUpdatesRequest) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FetchThreatListUpdatesRequest) + return false; +#undef DO_ +} + +void FetchThreatListUpdatesRequest::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FetchThreatListUpdatesRequest) + // optional .mozilla.safebrowsing.ClientInfo client = 1; + if (has_client()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 1, this->client(), output); + } + + // repeated .mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest list_update_requests = 3; + for (int i = 0; i < this->list_update_requests_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 3, this->list_update_requests(i), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FetchThreatListUpdatesRequest) +} + +int FetchThreatListUpdatesRequest::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.ClientInfo client = 1; + if (has_client()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->client()); + } + + } + // repeated .mozilla.safebrowsing.FetchThreatListUpdatesRequest.ListUpdateRequest list_update_requests = 3; + total_size += 1 * this->list_update_requests_size(); + for (int i = 0; i < this->list_update_requests_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->list_update_requests(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FetchThreatListUpdatesRequest::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FetchThreatListUpdatesRequest*>(&from)); +} + +void FetchThreatListUpdatesRequest::MergeFrom(const FetchThreatListUpdatesRequest& from) { + GOOGLE_CHECK_NE(&from, this); + list_update_requests_.MergeFrom(from.list_update_requests_); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_client()) { + mutable_client()->::mozilla::safebrowsing::ClientInfo::MergeFrom(from.client()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FetchThreatListUpdatesRequest::CopyFrom(const FetchThreatListUpdatesRequest& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FetchThreatListUpdatesRequest::IsInitialized() const { + + return true; +} + +void FetchThreatListUpdatesRequest::Swap(FetchThreatListUpdatesRequest* other) { + if (other != this) { + std::swap(client_, other->client_); + list_update_requests_.Swap(&other->list_update_requests_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FetchThreatListUpdatesRequest::GetTypeName() const { + return "mozilla.safebrowsing.FetchThreatListUpdatesRequest"; +} + + +// =================================================================== + +bool FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType_IsValid(int value) { + switch(value) { + case 0: + case 1: + case 2: + return true; + default: + return false; + } +} + +#ifndef _MSC_VER +const FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType FetchThreatListUpdatesResponse_ListUpdateResponse::RESPONSE_TYPE_UNSPECIFIED; +const FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType FetchThreatListUpdatesResponse_ListUpdateResponse::PARTIAL_UPDATE; +const FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType FetchThreatListUpdatesResponse_ListUpdateResponse::FULL_UPDATE; +const FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType FetchThreatListUpdatesResponse_ListUpdateResponse::ResponseType_MIN; +const FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType FetchThreatListUpdatesResponse_ListUpdateResponse::ResponseType_MAX; +const int FetchThreatListUpdatesResponse_ListUpdateResponse::ResponseType_ARRAYSIZE; +#endif // _MSC_VER +#ifndef _MSC_VER +const int FetchThreatListUpdatesResponse_ListUpdateResponse::kThreatTypeFieldNumber; +const int FetchThreatListUpdatesResponse_ListUpdateResponse::kThreatEntryTypeFieldNumber; +const int FetchThreatListUpdatesResponse_ListUpdateResponse::kPlatformTypeFieldNumber; +const int FetchThreatListUpdatesResponse_ListUpdateResponse::kResponseTypeFieldNumber; +const int FetchThreatListUpdatesResponse_ListUpdateResponse::kAdditionsFieldNumber; +const int FetchThreatListUpdatesResponse_ListUpdateResponse::kRemovalsFieldNumber; +const int FetchThreatListUpdatesResponse_ListUpdateResponse::kNewClientStateFieldNumber; +const int FetchThreatListUpdatesResponse_ListUpdateResponse::kChecksumFieldNumber; +#endif // !_MSC_VER + +FetchThreatListUpdatesResponse_ListUpdateResponse::FetchThreatListUpdatesResponse_ListUpdateResponse() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse) +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + checksum_ = const_cast< ::mozilla::safebrowsing::Checksum*>( + ::mozilla::safebrowsing::Checksum::internal_default_instance()); +#else + checksum_ = const_cast< ::mozilla::safebrowsing::Checksum*>(&::mozilla::safebrowsing::Checksum::default_instance()); +#endif +} + +FetchThreatListUpdatesResponse_ListUpdateResponse::FetchThreatListUpdatesResponse_ListUpdateResponse(const FetchThreatListUpdatesResponse_ListUpdateResponse& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse) +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + threat_type_ = 0; + threat_entry_type_ = 0; + platform_type_ = 0; + response_type_ = 0; + new_client_state_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + checksum_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FetchThreatListUpdatesResponse_ListUpdateResponse::~FetchThreatListUpdatesResponse_ListUpdateResponse() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse) + SharedDtor(); +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::SharedDtor() { + if (new_client_state_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete new_client_state_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete checksum_; + } +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FetchThreatListUpdatesResponse_ListUpdateResponse& FetchThreatListUpdatesResponse_ListUpdateResponse::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FetchThreatListUpdatesResponse_ListUpdateResponse* FetchThreatListUpdatesResponse_ListUpdateResponse::default_instance_ = NULL; + +FetchThreatListUpdatesResponse_ListUpdateResponse* FetchThreatListUpdatesResponse_ListUpdateResponse::New() const { + return new FetchThreatListUpdatesResponse_ListUpdateResponse; +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::Clear() { +#define OFFSET_OF_FIELD_(f) (reinterpret_cast<char*>( \ + &reinterpret_cast<FetchThreatListUpdatesResponse_ListUpdateResponse*>(16)->f) - \ + reinterpret_cast<char*>(16)) + +#define ZR_(first, last) do { \ + size_t f = OFFSET_OF_FIELD_(first); \ + size_t n = OFFSET_OF_FIELD_(last) - f + sizeof(last); \ + ::memset(&first, 0, n); \ + } while (0) + + if (_has_bits_[0 / 32] & 207) { + ZR_(threat_type_, response_type_); + if (has_new_client_state()) { + if (new_client_state_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + new_client_state_->clear(); + } + } + if (has_checksum()) { + if (checksum_ != NULL) checksum_->::mozilla::safebrowsing::Checksum::Clear(); + } + } + +#undef OFFSET_OF_FIELD_ +#undef ZR_ + + additions_.Clear(); + removals_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FetchThreatListUpdatesResponse_ListUpdateResponse::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + case 1: { + if (tag == 8) { + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatType_IsValid(value)) { + set_threat_type(static_cast< ::mozilla::safebrowsing::ThreatType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_threat_entry_type; + break; + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 2; + case 2: { + if (tag == 16) { + parse_threat_entry_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatEntryType_IsValid(value)) { + set_threat_entry_type(static_cast< ::mozilla::safebrowsing::ThreatEntryType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(24)) goto parse_platform_type; + break; + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 3; + case 3: { + if (tag == 24) { + parse_platform_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::PlatformType_IsValid(value)) { + set_platform_type(static_cast< ::mozilla::safebrowsing::PlatformType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(32)) goto parse_response_type; + break; + } + + // optional .mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse.ResponseType response_type = 4; + case 4: { + if (tag == 32) { + parse_response_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType_IsValid(value)) { + set_response_type(static_cast< ::mozilla::safebrowsing::FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(42)) goto parse_additions; + break; + } + + // repeated .mozilla.safebrowsing.ThreatEntrySet additions = 5; + case 5: { + if (tag == 42) { + parse_additions: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_additions())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(42)) goto parse_additions; + if (input->ExpectTag(50)) goto parse_removals; + break; + } + + // repeated .mozilla.safebrowsing.ThreatEntrySet removals = 6; + case 6: { + if (tag == 50) { + parse_removals: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_removals())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(50)) goto parse_removals; + if (input->ExpectTag(58)) goto parse_new_client_state; + break; + } + + // optional bytes new_client_state = 7; + case 7: { + if (tag == 58) { + parse_new_client_state: + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->mutable_new_client_state())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(66)) goto parse_checksum; + break; + } + + // optional .mozilla.safebrowsing.Checksum checksum = 8; + case 8: { + if (tag == 66) { + parse_checksum: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_checksum())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse) + return false; +#undef DO_ +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse) + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 1, this->threat_type(), output); + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 2; + if (has_threat_entry_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 2, this->threat_entry_type(), output); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 3; + if (has_platform_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 3, this->platform_type(), output); + } + + // optional .mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse.ResponseType response_type = 4; + if (has_response_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 4, this->response_type(), output); + } + + // repeated .mozilla.safebrowsing.ThreatEntrySet additions = 5; + for (int i = 0; i < this->additions_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 5, this->additions(i), output); + } + + // repeated .mozilla.safebrowsing.ThreatEntrySet removals = 6; + for (int i = 0; i < this->removals_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 6, this->removals(i), output); + } + + // optional bytes new_client_state = 7; + if (has_new_client_state()) { + ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( + 7, this->new_client_state(), output); + } + + // optional .mozilla.safebrowsing.Checksum checksum = 8; + if (has_checksum()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 8, this->checksum(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse) +} + +int FetchThreatListUpdatesResponse_ListUpdateResponse::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_type()); + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 2; + if (has_threat_entry_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_entry_type()); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 3; + if (has_platform_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->platform_type()); + } + + // optional .mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse.ResponseType response_type = 4; + if (has_response_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->response_type()); + } + + // optional bytes new_client_state = 7; + if (has_new_client_state()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::BytesSize( + this->new_client_state()); + } + + // optional .mozilla.safebrowsing.Checksum checksum = 8; + if (has_checksum()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->checksum()); + } + + } + // repeated .mozilla.safebrowsing.ThreatEntrySet additions = 5; + total_size += 1 * this->additions_size(); + for (int i = 0; i < this->additions_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->additions(i)); + } + + // repeated .mozilla.safebrowsing.ThreatEntrySet removals = 6; + total_size += 1 * this->removals_size(); + for (int i = 0; i < this->removals_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->removals(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FetchThreatListUpdatesResponse_ListUpdateResponse*>(&from)); +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::MergeFrom(const FetchThreatListUpdatesResponse_ListUpdateResponse& from) { + GOOGLE_CHECK_NE(&from, this); + additions_.MergeFrom(from.additions_); + removals_.MergeFrom(from.removals_); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_threat_type()) { + set_threat_type(from.threat_type()); + } + if (from.has_threat_entry_type()) { + set_threat_entry_type(from.threat_entry_type()); + } + if (from.has_platform_type()) { + set_platform_type(from.platform_type()); + } + if (from.has_response_type()) { + set_response_type(from.response_type()); + } + if (from.has_new_client_state()) { + set_new_client_state(from.new_client_state()); + } + if (from.has_checksum()) { + mutable_checksum()->::mozilla::safebrowsing::Checksum::MergeFrom(from.checksum()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::CopyFrom(const FetchThreatListUpdatesResponse_ListUpdateResponse& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FetchThreatListUpdatesResponse_ListUpdateResponse::IsInitialized() const { + + return true; +} + +void FetchThreatListUpdatesResponse_ListUpdateResponse::Swap(FetchThreatListUpdatesResponse_ListUpdateResponse* other) { + if (other != this) { + std::swap(threat_type_, other->threat_type_); + std::swap(threat_entry_type_, other->threat_entry_type_); + std::swap(platform_type_, other->platform_type_); + std::swap(response_type_, other->response_type_); + additions_.Swap(&other->additions_); + removals_.Swap(&other->removals_); + std::swap(new_client_state_, other->new_client_state_); + std::swap(checksum_, other->checksum_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FetchThreatListUpdatesResponse_ListUpdateResponse::GetTypeName() const { + return "mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse"; +} + + +// ------------------------------------------------------------------- + +#ifndef _MSC_VER +const int FetchThreatListUpdatesResponse::kListUpdateResponsesFieldNumber; +const int FetchThreatListUpdatesResponse::kMinimumWaitDurationFieldNumber; +#endif // !_MSC_VER + +FetchThreatListUpdatesResponse::FetchThreatListUpdatesResponse() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FetchThreatListUpdatesResponse) +} + +void FetchThreatListUpdatesResponse::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + minimum_wait_duration_ = const_cast< ::mozilla::safebrowsing::Duration*>( + ::mozilla::safebrowsing::Duration::internal_default_instance()); +#else + minimum_wait_duration_ = const_cast< ::mozilla::safebrowsing::Duration*>(&::mozilla::safebrowsing::Duration::default_instance()); +#endif +} + +FetchThreatListUpdatesResponse::FetchThreatListUpdatesResponse(const FetchThreatListUpdatesResponse& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FetchThreatListUpdatesResponse) +} + +void FetchThreatListUpdatesResponse::SharedCtor() { + _cached_size_ = 0; + minimum_wait_duration_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FetchThreatListUpdatesResponse::~FetchThreatListUpdatesResponse() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FetchThreatListUpdatesResponse) + SharedDtor(); +} + +void FetchThreatListUpdatesResponse::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete minimum_wait_duration_; + } +} + +void FetchThreatListUpdatesResponse::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FetchThreatListUpdatesResponse& FetchThreatListUpdatesResponse::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FetchThreatListUpdatesResponse* FetchThreatListUpdatesResponse::default_instance_ = NULL; + +FetchThreatListUpdatesResponse* FetchThreatListUpdatesResponse::New() const { + return new FetchThreatListUpdatesResponse; +} + +void FetchThreatListUpdatesResponse::Clear() { + if (has_minimum_wait_duration()) { + if (minimum_wait_duration_ != NULL) minimum_wait_duration_->::mozilla::safebrowsing::Duration::Clear(); + } + list_update_responses_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FetchThreatListUpdatesResponse::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FetchThreatListUpdatesResponse) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // repeated .mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse list_update_responses = 1; + case 1: { + if (tag == 10) { + parse_list_update_responses: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_list_update_responses())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(10)) goto parse_list_update_responses; + if (input->ExpectTag(18)) goto parse_minimum_wait_duration; + break; + } + + // optional .mozilla.safebrowsing.Duration minimum_wait_duration = 2; + case 2: { + if (tag == 18) { + parse_minimum_wait_duration: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_minimum_wait_duration())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FetchThreatListUpdatesResponse) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FetchThreatListUpdatesResponse) + return false; +#undef DO_ +} + +void FetchThreatListUpdatesResponse::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FetchThreatListUpdatesResponse) + // repeated .mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse list_update_responses = 1; + for (int i = 0; i < this->list_update_responses_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 1, this->list_update_responses(i), output); + } + + // optional .mozilla.safebrowsing.Duration minimum_wait_duration = 2; + if (has_minimum_wait_duration()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 2, this->minimum_wait_duration(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FetchThreatListUpdatesResponse) +} + +int FetchThreatListUpdatesResponse::ByteSize() const { + int total_size = 0; + + if (_has_bits_[1 / 32] & (0xffu << (1 % 32))) { + // optional .mozilla.safebrowsing.Duration minimum_wait_duration = 2; + if (has_minimum_wait_duration()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->minimum_wait_duration()); + } + + } + // repeated .mozilla.safebrowsing.FetchThreatListUpdatesResponse.ListUpdateResponse list_update_responses = 1; + total_size += 1 * this->list_update_responses_size(); + for (int i = 0; i < this->list_update_responses_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->list_update_responses(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FetchThreatListUpdatesResponse::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FetchThreatListUpdatesResponse*>(&from)); +} + +void FetchThreatListUpdatesResponse::MergeFrom(const FetchThreatListUpdatesResponse& from) { + GOOGLE_CHECK_NE(&from, this); + list_update_responses_.MergeFrom(from.list_update_responses_); + if (from._has_bits_[1 / 32] & (0xffu << (1 % 32))) { + if (from.has_minimum_wait_duration()) { + mutable_minimum_wait_duration()->::mozilla::safebrowsing::Duration::MergeFrom(from.minimum_wait_duration()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FetchThreatListUpdatesResponse::CopyFrom(const FetchThreatListUpdatesResponse& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FetchThreatListUpdatesResponse::IsInitialized() const { + + return true; +} + +void FetchThreatListUpdatesResponse::Swap(FetchThreatListUpdatesResponse* other) { + if (other != this) { + list_update_responses_.Swap(&other->list_update_responses_); + std::swap(minimum_wait_duration_, other->minimum_wait_duration_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FetchThreatListUpdatesResponse::GetTypeName() const { + return "mozilla.safebrowsing.FetchThreatListUpdatesResponse"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int FindFullHashesRequest::kClientFieldNumber; +const int FindFullHashesRequest::kClientStatesFieldNumber; +const int FindFullHashesRequest::kThreatInfoFieldNumber; +#endif // !_MSC_VER + +FindFullHashesRequest::FindFullHashesRequest() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FindFullHashesRequest) +} + +void FindFullHashesRequest::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + client_ = const_cast< ::mozilla::safebrowsing::ClientInfo*>( + ::mozilla::safebrowsing::ClientInfo::internal_default_instance()); +#else + client_ = const_cast< ::mozilla::safebrowsing::ClientInfo*>(&::mozilla::safebrowsing::ClientInfo::default_instance()); +#endif +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + threat_info_ = const_cast< ::mozilla::safebrowsing::ThreatInfo*>( + ::mozilla::safebrowsing::ThreatInfo::internal_default_instance()); +#else + threat_info_ = const_cast< ::mozilla::safebrowsing::ThreatInfo*>(&::mozilla::safebrowsing::ThreatInfo::default_instance()); +#endif +} + +FindFullHashesRequest::FindFullHashesRequest(const FindFullHashesRequest& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FindFullHashesRequest) +} + +void FindFullHashesRequest::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + client_ = NULL; + threat_info_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FindFullHashesRequest::~FindFullHashesRequest() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FindFullHashesRequest) + SharedDtor(); +} + +void FindFullHashesRequest::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete client_; + delete threat_info_; + } +} + +void FindFullHashesRequest::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FindFullHashesRequest& FindFullHashesRequest::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FindFullHashesRequest* FindFullHashesRequest::default_instance_ = NULL; + +FindFullHashesRequest* FindFullHashesRequest::New() const { + return new FindFullHashesRequest; +} + +void FindFullHashesRequest::Clear() { + if (_has_bits_[0 / 32] & 5) { + if (has_client()) { + if (client_ != NULL) client_->::mozilla::safebrowsing::ClientInfo::Clear(); + } + if (has_threat_info()) { + if (threat_info_ != NULL) threat_info_->::mozilla::safebrowsing::ThreatInfo::Clear(); + } + } + client_states_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FindFullHashesRequest::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FindFullHashesRequest) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.ClientInfo client = 1; + case 1: { + if (tag == 10) { + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_client())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(18)) goto parse_client_states; + break; + } + + // repeated bytes client_states = 2; + case 2: { + if (tag == 18) { + parse_client_states: + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->add_client_states())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(18)) goto parse_client_states; + if (input->ExpectTag(26)) goto parse_threat_info; + break; + } + + // optional .mozilla.safebrowsing.ThreatInfo threat_info = 3; + case 3: { + if (tag == 26) { + parse_threat_info: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_threat_info())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FindFullHashesRequest) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FindFullHashesRequest) + return false; +#undef DO_ +} + +void FindFullHashesRequest::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FindFullHashesRequest) + // optional .mozilla.safebrowsing.ClientInfo client = 1; + if (has_client()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 1, this->client(), output); + } + + // repeated bytes client_states = 2; + for (int i = 0; i < this->client_states_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteBytes( + 2, this->client_states(i), output); + } + + // optional .mozilla.safebrowsing.ThreatInfo threat_info = 3; + if (has_threat_info()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 3, this->threat_info(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FindFullHashesRequest) +} + +int FindFullHashesRequest::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.ClientInfo client = 1; + if (has_client()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->client()); + } + + // optional .mozilla.safebrowsing.ThreatInfo threat_info = 3; + if (has_threat_info()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->threat_info()); + } + + } + // repeated bytes client_states = 2; + total_size += 1 * this->client_states_size(); + for (int i = 0; i < this->client_states_size(); i++) { + total_size += ::google::protobuf::internal::WireFormatLite::BytesSize( + this->client_states(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FindFullHashesRequest::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FindFullHashesRequest*>(&from)); +} + +void FindFullHashesRequest::MergeFrom(const FindFullHashesRequest& from) { + GOOGLE_CHECK_NE(&from, this); + client_states_.MergeFrom(from.client_states_); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_client()) { + mutable_client()->::mozilla::safebrowsing::ClientInfo::MergeFrom(from.client()); + } + if (from.has_threat_info()) { + mutable_threat_info()->::mozilla::safebrowsing::ThreatInfo::MergeFrom(from.threat_info()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FindFullHashesRequest::CopyFrom(const FindFullHashesRequest& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FindFullHashesRequest::IsInitialized() const { + + return true; +} + +void FindFullHashesRequest::Swap(FindFullHashesRequest* other) { + if (other != this) { + std::swap(client_, other->client_); + client_states_.Swap(&other->client_states_); + std::swap(threat_info_, other->threat_info_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FindFullHashesRequest::GetTypeName() const { + return "mozilla.safebrowsing.FindFullHashesRequest"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int FindFullHashesResponse::kMatchesFieldNumber; +const int FindFullHashesResponse::kMinimumWaitDurationFieldNumber; +const int FindFullHashesResponse::kNegativeCacheDurationFieldNumber; +#endif // !_MSC_VER + +FindFullHashesResponse::FindFullHashesResponse() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.FindFullHashesResponse) +} + +void FindFullHashesResponse::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + minimum_wait_duration_ = const_cast< ::mozilla::safebrowsing::Duration*>( + ::mozilla::safebrowsing::Duration::internal_default_instance()); +#else + minimum_wait_duration_ = const_cast< ::mozilla::safebrowsing::Duration*>(&::mozilla::safebrowsing::Duration::default_instance()); +#endif +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + negative_cache_duration_ = const_cast< ::mozilla::safebrowsing::Duration*>( + ::mozilla::safebrowsing::Duration::internal_default_instance()); +#else + negative_cache_duration_ = const_cast< ::mozilla::safebrowsing::Duration*>(&::mozilla::safebrowsing::Duration::default_instance()); +#endif +} + +FindFullHashesResponse::FindFullHashesResponse(const FindFullHashesResponse& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.FindFullHashesResponse) +} + +void FindFullHashesResponse::SharedCtor() { + _cached_size_ = 0; + minimum_wait_duration_ = NULL; + negative_cache_duration_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +FindFullHashesResponse::~FindFullHashesResponse() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.FindFullHashesResponse) + SharedDtor(); +} + +void FindFullHashesResponse::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete minimum_wait_duration_; + delete negative_cache_duration_; + } +} + +void FindFullHashesResponse::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const FindFullHashesResponse& FindFullHashesResponse::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +FindFullHashesResponse* FindFullHashesResponse::default_instance_ = NULL; + +FindFullHashesResponse* FindFullHashesResponse::New() const { + return new FindFullHashesResponse; +} + +void FindFullHashesResponse::Clear() { + if (_has_bits_[0 / 32] & 6) { + if (has_minimum_wait_duration()) { + if (minimum_wait_duration_ != NULL) minimum_wait_duration_->::mozilla::safebrowsing::Duration::Clear(); + } + if (has_negative_cache_duration()) { + if (negative_cache_duration_ != NULL) negative_cache_duration_->::mozilla::safebrowsing::Duration::Clear(); + } + } + matches_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool FindFullHashesResponse::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.FindFullHashesResponse) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // repeated .mozilla.safebrowsing.ThreatMatch matches = 1; + case 1: { + if (tag == 10) { + parse_matches: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_matches())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(10)) goto parse_matches; + if (input->ExpectTag(18)) goto parse_minimum_wait_duration; + break; + } + + // optional .mozilla.safebrowsing.Duration minimum_wait_duration = 2; + case 2: { + if (tag == 18) { + parse_minimum_wait_duration: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_minimum_wait_duration())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_negative_cache_duration; + break; + } + + // optional .mozilla.safebrowsing.Duration negative_cache_duration = 3; + case 3: { + if (tag == 26) { + parse_negative_cache_duration: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_negative_cache_duration())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.FindFullHashesResponse) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.FindFullHashesResponse) + return false; +#undef DO_ +} + +void FindFullHashesResponse::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.FindFullHashesResponse) + // repeated .mozilla.safebrowsing.ThreatMatch matches = 1; + for (int i = 0; i < this->matches_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 1, this->matches(i), output); + } + + // optional .mozilla.safebrowsing.Duration minimum_wait_duration = 2; + if (has_minimum_wait_duration()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 2, this->minimum_wait_duration(), output); + } + + // optional .mozilla.safebrowsing.Duration negative_cache_duration = 3; + if (has_negative_cache_duration()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 3, this->negative_cache_duration(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.FindFullHashesResponse) +} + +int FindFullHashesResponse::ByteSize() const { + int total_size = 0; + + if (_has_bits_[1 / 32] & (0xffu << (1 % 32))) { + // optional .mozilla.safebrowsing.Duration minimum_wait_duration = 2; + if (has_minimum_wait_duration()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->minimum_wait_duration()); + } + + // optional .mozilla.safebrowsing.Duration negative_cache_duration = 3; + if (has_negative_cache_duration()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->negative_cache_duration()); + } + + } + // repeated .mozilla.safebrowsing.ThreatMatch matches = 1; + total_size += 1 * this->matches_size(); + for (int i = 0; i < this->matches_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->matches(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void FindFullHashesResponse::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const FindFullHashesResponse*>(&from)); +} + +void FindFullHashesResponse::MergeFrom(const FindFullHashesResponse& from) { + GOOGLE_CHECK_NE(&from, this); + matches_.MergeFrom(from.matches_); + if (from._has_bits_[1 / 32] & (0xffu << (1 % 32))) { + if (from.has_minimum_wait_duration()) { + mutable_minimum_wait_duration()->::mozilla::safebrowsing::Duration::MergeFrom(from.minimum_wait_duration()); + } + if (from.has_negative_cache_duration()) { + mutable_negative_cache_duration()->::mozilla::safebrowsing::Duration::MergeFrom(from.negative_cache_duration()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void FindFullHashesResponse::CopyFrom(const FindFullHashesResponse& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool FindFullHashesResponse::IsInitialized() const { + + return true; +} + +void FindFullHashesResponse::Swap(FindFullHashesResponse* other) { + if (other != this) { + matches_.Swap(&other->matches_); + std::swap(minimum_wait_duration_, other->minimum_wait_duration_); + std::swap(negative_cache_duration_, other->negative_cache_duration_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string FindFullHashesResponse::GetTypeName() const { + return "mozilla.safebrowsing.FindFullHashesResponse"; +} + + +// =================================================================== + +bool ThreatHit_ThreatSourceType_IsValid(int value) { + switch(value) { + case 0: + case 1: + case 2: + case 3: + return true; + default: + return false; + } +} + +#ifndef _MSC_VER +const ThreatHit_ThreatSourceType ThreatHit::THREAT_SOURCE_TYPE_UNSPECIFIED; +const ThreatHit_ThreatSourceType ThreatHit::MATCHING_URL; +const ThreatHit_ThreatSourceType ThreatHit::TAB_URL; +const ThreatHit_ThreatSourceType ThreatHit::TAB_REDIRECT; +const ThreatHit_ThreatSourceType ThreatHit::ThreatSourceType_MIN; +const ThreatHit_ThreatSourceType ThreatHit::ThreatSourceType_MAX; +const int ThreatHit::ThreatSourceType_ARRAYSIZE; +#endif // _MSC_VER +#ifndef _MSC_VER +const int ThreatHit_ThreatSource::kUrlFieldNumber; +const int ThreatHit_ThreatSource::kTypeFieldNumber; +const int ThreatHit_ThreatSource::kRemoteIpFieldNumber; +const int ThreatHit_ThreatSource::kReferrerFieldNumber; +#endif // !_MSC_VER + +ThreatHit_ThreatSource::ThreatHit_ThreatSource() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatHit.ThreatSource) +} + +void ThreatHit_ThreatSource::InitAsDefaultInstance() { +} + +ThreatHit_ThreatSource::ThreatHit_ThreatSource(const ThreatHit_ThreatSource& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatHit.ThreatSource) +} + +void ThreatHit_ThreatSource::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + url_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + type_ = 0; + remote_ip_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + referrer_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatHit_ThreatSource::~ThreatHit_ThreatSource() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatHit.ThreatSource) + SharedDtor(); +} + +void ThreatHit_ThreatSource::SharedDtor() { + if (url_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete url_; + } + if (remote_ip_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete remote_ip_; + } + if (referrer_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete referrer_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void ThreatHit_ThreatSource::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatHit_ThreatSource& ThreatHit_ThreatSource::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatHit_ThreatSource* ThreatHit_ThreatSource::default_instance_ = NULL; + +ThreatHit_ThreatSource* ThreatHit_ThreatSource::New() const { + return new ThreatHit_ThreatSource; +} + +void ThreatHit_ThreatSource::Clear() { + if (_has_bits_[0 / 32] & 15) { + if (has_url()) { + if (url_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + url_->clear(); + } + } + type_ = 0; + if (has_remote_ip()) { + if (remote_ip_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + remote_ip_->clear(); + } + } + if (has_referrer()) { + if (referrer_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + referrer_->clear(); + } + } + } + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatHit_ThreatSource::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatHit.ThreatSource) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional string url = 1; + case 1: { + if (tag == 10) { + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_url())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_type; + break; + } + + // optional .mozilla.safebrowsing.ThreatHit.ThreatSourceType type = 2; + case 2: { + if (tag == 16) { + parse_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatHit_ThreatSourceType_IsValid(value)) { + set_type(static_cast< ::mozilla::safebrowsing::ThreatHit_ThreatSourceType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_remote_ip; + break; + } + + // optional string remote_ip = 3; + case 3: { + if (tag == 26) { + parse_remote_ip: + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_remote_ip())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(34)) goto parse_referrer; + break; + } + + // optional string referrer = 4; + case 4: { + if (tag == 34) { + parse_referrer: + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_referrer())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatHit.ThreatSource) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatHit.ThreatSource) + return false; +#undef DO_ +} + +void ThreatHit_ThreatSource::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatHit.ThreatSource) + // optional string url = 1; + if (has_url()) { + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 1, this->url(), output); + } + + // optional .mozilla.safebrowsing.ThreatHit.ThreatSourceType type = 2; + if (has_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 2, this->type(), output); + } + + // optional string remote_ip = 3; + if (has_remote_ip()) { + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 3, this->remote_ip(), output); + } + + // optional string referrer = 4; + if (has_referrer()) { + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 4, this->referrer(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatHit.ThreatSource) +} + +int ThreatHit_ThreatSource::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional string url = 1; + if (has_url()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->url()); + } + + // optional .mozilla.safebrowsing.ThreatHit.ThreatSourceType type = 2; + if (has_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->type()); + } + + // optional string remote_ip = 3; + if (has_remote_ip()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->remote_ip()); + } + + // optional string referrer = 4; + if (has_referrer()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->referrer()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatHit_ThreatSource::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatHit_ThreatSource*>(&from)); +} + +void ThreatHit_ThreatSource::MergeFrom(const ThreatHit_ThreatSource& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_url()) { + set_url(from.url()); + } + if (from.has_type()) { + set_type(from.type()); + } + if (from.has_remote_ip()) { + set_remote_ip(from.remote_ip()); + } + if (from.has_referrer()) { + set_referrer(from.referrer()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatHit_ThreatSource::CopyFrom(const ThreatHit_ThreatSource& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatHit_ThreatSource::IsInitialized() const { + + return true; +} + +void ThreatHit_ThreatSource::Swap(ThreatHit_ThreatSource* other) { + if (other != this) { + std::swap(url_, other->url_); + std::swap(type_, other->type_); + std::swap(remote_ip_, other->remote_ip_); + std::swap(referrer_, other->referrer_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatHit_ThreatSource::GetTypeName() const { + return "mozilla.safebrowsing.ThreatHit.ThreatSource"; +} + + +// ------------------------------------------------------------------- + +#ifndef _MSC_VER +const int ThreatHit::kThreatTypeFieldNumber; +const int ThreatHit::kPlatformTypeFieldNumber; +const int ThreatHit::kEntryFieldNumber; +const int ThreatHit::kResourcesFieldNumber; +#endif // !_MSC_VER + +ThreatHit::ThreatHit() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatHit) +} + +void ThreatHit::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + entry_ = const_cast< ::mozilla::safebrowsing::ThreatEntry*>( + ::mozilla::safebrowsing::ThreatEntry::internal_default_instance()); +#else + entry_ = const_cast< ::mozilla::safebrowsing::ThreatEntry*>(&::mozilla::safebrowsing::ThreatEntry::default_instance()); +#endif +} + +ThreatHit::ThreatHit(const ThreatHit& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatHit) +} + +void ThreatHit::SharedCtor() { + _cached_size_ = 0; + threat_type_ = 0; + platform_type_ = 0; + entry_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatHit::~ThreatHit() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatHit) + SharedDtor(); +} + +void ThreatHit::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete entry_; + } +} + +void ThreatHit::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatHit& ThreatHit::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatHit* ThreatHit::default_instance_ = NULL; + +ThreatHit* ThreatHit::New() const { + return new ThreatHit; +} + +void ThreatHit::Clear() { +#define OFFSET_OF_FIELD_(f) (reinterpret_cast<char*>( \ + &reinterpret_cast<ThreatHit*>(16)->f) - \ + reinterpret_cast<char*>(16)) + +#define ZR_(first, last) do { \ + size_t f = OFFSET_OF_FIELD_(first); \ + size_t n = OFFSET_OF_FIELD_(last) - f + sizeof(last); \ + ::memset(&first, 0, n); \ + } while (0) + + if (_has_bits_[0 / 32] & 7) { + ZR_(threat_type_, platform_type_); + if (has_entry()) { + if (entry_ != NULL) entry_->::mozilla::safebrowsing::ThreatEntry::Clear(); + } + } + +#undef OFFSET_OF_FIELD_ +#undef ZR_ + + resources_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatHit::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatHit) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + case 1: { + if (tag == 8) { + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatType_IsValid(value)) { + set_threat_type(static_cast< ::mozilla::safebrowsing::ThreatType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_platform_type; + break; + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + case 2: { + if (tag == 16) { + parse_platform_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::PlatformType_IsValid(value)) { + set_platform_type(static_cast< ::mozilla::safebrowsing::PlatformType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_entry; + break; + } + + // optional .mozilla.safebrowsing.ThreatEntry entry = 3; + case 3: { + if (tag == 26) { + parse_entry: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_entry())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(34)) goto parse_resources; + break; + } + + // repeated .mozilla.safebrowsing.ThreatHit.ThreatSource resources = 4; + case 4: { + if (tag == 34) { + parse_resources: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_resources())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(34)) goto parse_resources; + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatHit) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatHit) + return false; +#undef DO_ +} + +void ThreatHit::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatHit) + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 1, this->threat_type(), output); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + if (has_platform_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 2, this->platform_type(), output); + } + + // optional .mozilla.safebrowsing.ThreatEntry entry = 3; + if (has_entry()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 3, this->entry(), output); + } + + // repeated .mozilla.safebrowsing.ThreatHit.ThreatSource resources = 4; + for (int i = 0; i < this->resources_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 4, this->resources(i), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatHit) +} + +int ThreatHit::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_type()); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + if (has_platform_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->platform_type()); + } + + // optional .mozilla.safebrowsing.ThreatEntry entry = 3; + if (has_entry()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->entry()); + } + + } + // repeated .mozilla.safebrowsing.ThreatHit.ThreatSource resources = 4; + total_size += 1 * this->resources_size(); + for (int i = 0; i < this->resources_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->resources(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatHit::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatHit*>(&from)); +} + +void ThreatHit::MergeFrom(const ThreatHit& from) { + GOOGLE_CHECK_NE(&from, this); + resources_.MergeFrom(from.resources_); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_threat_type()) { + set_threat_type(from.threat_type()); + } + if (from.has_platform_type()) { + set_platform_type(from.platform_type()); + } + if (from.has_entry()) { + mutable_entry()->::mozilla::safebrowsing::ThreatEntry::MergeFrom(from.entry()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatHit::CopyFrom(const ThreatHit& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatHit::IsInitialized() const { + + return true; +} + +void ThreatHit::Swap(ThreatHit* other) { + if (other != this) { + std::swap(threat_type_, other->threat_type_); + std::swap(platform_type_, other->platform_type_); + std::swap(entry_, other->entry_); + resources_.Swap(&other->resources_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatHit::GetTypeName() const { + return "mozilla.safebrowsing.ThreatHit"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int ClientInfo::kClientIdFieldNumber; +const int ClientInfo::kClientVersionFieldNumber; +#endif // !_MSC_VER + +ClientInfo::ClientInfo() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ClientInfo) +} + +void ClientInfo::InitAsDefaultInstance() { +} + +ClientInfo::ClientInfo(const ClientInfo& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ClientInfo) +} + +void ClientInfo::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + client_id_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + client_version_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ClientInfo::~ClientInfo() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ClientInfo) + SharedDtor(); +} + +void ClientInfo::SharedDtor() { + if (client_id_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete client_id_; + } + if (client_version_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete client_version_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void ClientInfo::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ClientInfo& ClientInfo::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ClientInfo* ClientInfo::default_instance_ = NULL; + +ClientInfo* ClientInfo::New() const { + return new ClientInfo; +} + +void ClientInfo::Clear() { + if (_has_bits_[0 / 32] & 3) { + if (has_client_id()) { + if (client_id_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + client_id_->clear(); + } + } + if (has_client_version()) { + if (client_version_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + client_version_->clear(); + } + } + } + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ClientInfo::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ClientInfo) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional string client_id = 1; + case 1: { + if (tag == 10) { + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_client_id())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(18)) goto parse_client_version; + break; + } + + // optional string client_version = 2; + case 2: { + if (tag == 18) { + parse_client_version: + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_client_version())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ClientInfo) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ClientInfo) + return false; +#undef DO_ +} + +void ClientInfo::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ClientInfo) + // optional string client_id = 1; + if (has_client_id()) { + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 1, this->client_id(), output); + } + + // optional string client_version = 2; + if (has_client_version()) { + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 2, this->client_version(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ClientInfo) +} + +int ClientInfo::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional string client_id = 1; + if (has_client_id()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->client_id()); + } + + // optional string client_version = 2; + if (has_client_version()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->client_version()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ClientInfo::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ClientInfo*>(&from)); +} + +void ClientInfo::MergeFrom(const ClientInfo& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_client_id()) { + set_client_id(from.client_id()); + } + if (from.has_client_version()) { + set_client_version(from.client_version()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ClientInfo::CopyFrom(const ClientInfo& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ClientInfo::IsInitialized() const { + + return true; +} + +void ClientInfo::Swap(ClientInfo* other) { + if (other != this) { + std::swap(client_id_, other->client_id_); + std::swap(client_version_, other->client_version_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ClientInfo::GetTypeName() const { + return "mozilla.safebrowsing.ClientInfo"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int Checksum::kSha256FieldNumber; +#endif // !_MSC_VER + +Checksum::Checksum() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.Checksum) +} + +void Checksum::InitAsDefaultInstance() { +} + +Checksum::Checksum(const Checksum& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.Checksum) +} + +void Checksum::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + sha256_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +Checksum::~Checksum() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.Checksum) + SharedDtor(); +} + +void Checksum::SharedDtor() { + if (sha256_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete sha256_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void Checksum::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const Checksum& Checksum::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +Checksum* Checksum::default_instance_ = NULL; + +Checksum* Checksum::New() const { + return new Checksum; +} + +void Checksum::Clear() { + if (has_sha256()) { + if (sha256_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + sha256_->clear(); + } + } + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool Checksum::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.Checksum) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional bytes sha256 = 1; + case 1: { + if (tag == 10) { + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->mutable_sha256())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.Checksum) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.Checksum) + return false; +#undef DO_ +} + +void Checksum::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.Checksum) + // optional bytes sha256 = 1; + if (has_sha256()) { + ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( + 1, this->sha256(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.Checksum) +} + +int Checksum::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional bytes sha256 = 1; + if (has_sha256()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::BytesSize( + this->sha256()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void Checksum::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const Checksum*>(&from)); +} + +void Checksum::MergeFrom(const Checksum& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_sha256()) { + set_sha256(from.sha256()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void Checksum::CopyFrom(const Checksum& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool Checksum::IsInitialized() const { + + return true; +} + +void Checksum::Swap(Checksum* other) { + if (other != this) { + std::swap(sha256_, other->sha256_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string Checksum::GetTypeName() const { + return "mozilla.safebrowsing.Checksum"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int ThreatEntry::kHashFieldNumber; +const int ThreatEntry::kUrlFieldNumber; +#endif // !_MSC_VER + +ThreatEntry::ThreatEntry() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatEntry) +} + +void ThreatEntry::InitAsDefaultInstance() { +} + +ThreatEntry::ThreatEntry(const ThreatEntry& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatEntry) +} + +void ThreatEntry::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + hash_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + url_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatEntry::~ThreatEntry() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatEntry) + SharedDtor(); +} + +void ThreatEntry::SharedDtor() { + if (hash_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete hash_; + } + if (url_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete url_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void ThreatEntry::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatEntry& ThreatEntry::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatEntry* ThreatEntry::default_instance_ = NULL; + +ThreatEntry* ThreatEntry::New() const { + return new ThreatEntry; +} + +void ThreatEntry::Clear() { + if (_has_bits_[0 / 32] & 3) { + if (has_hash()) { + if (hash_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + hash_->clear(); + } + } + if (has_url()) { + if (url_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + url_->clear(); + } + } + } + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatEntry::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatEntry) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional bytes hash = 1; + case 1: { + if (tag == 10) { + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->mutable_hash())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(18)) goto parse_url; + break; + } + + // optional string url = 2; + case 2: { + if (tag == 18) { + parse_url: + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_url())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatEntry) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatEntry) + return false; +#undef DO_ +} + +void ThreatEntry::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatEntry) + // optional bytes hash = 1; + if (has_hash()) { + ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( + 1, this->hash(), output); + } + + // optional string url = 2; + if (has_url()) { + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 2, this->url(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatEntry) +} + +int ThreatEntry::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional bytes hash = 1; + if (has_hash()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::BytesSize( + this->hash()); + } + + // optional string url = 2; + if (has_url()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->url()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatEntry::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatEntry*>(&from)); +} + +void ThreatEntry::MergeFrom(const ThreatEntry& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_hash()) { + set_hash(from.hash()); + } + if (from.has_url()) { + set_url(from.url()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatEntry::CopyFrom(const ThreatEntry& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatEntry::IsInitialized() const { + + return true; +} + +void ThreatEntry::Swap(ThreatEntry* other) { + if (other != this) { + std::swap(hash_, other->hash_); + std::swap(url_, other->url_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatEntry::GetTypeName() const { + return "mozilla.safebrowsing.ThreatEntry"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int ThreatEntrySet::kCompressionTypeFieldNumber; +const int ThreatEntrySet::kRawHashesFieldNumber; +const int ThreatEntrySet::kRawIndicesFieldNumber; +const int ThreatEntrySet::kRiceHashesFieldNumber; +const int ThreatEntrySet::kRiceIndicesFieldNumber; +#endif // !_MSC_VER + +ThreatEntrySet::ThreatEntrySet() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatEntrySet) +} + +void ThreatEntrySet::InitAsDefaultInstance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + raw_hashes_ = const_cast< ::mozilla::safebrowsing::RawHashes*>( + ::mozilla::safebrowsing::RawHashes::internal_default_instance()); +#else + raw_hashes_ = const_cast< ::mozilla::safebrowsing::RawHashes*>(&::mozilla::safebrowsing::RawHashes::default_instance()); +#endif +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + raw_indices_ = const_cast< ::mozilla::safebrowsing::RawIndices*>( + ::mozilla::safebrowsing::RawIndices::internal_default_instance()); +#else + raw_indices_ = const_cast< ::mozilla::safebrowsing::RawIndices*>(&::mozilla::safebrowsing::RawIndices::default_instance()); +#endif +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + rice_hashes_ = const_cast< ::mozilla::safebrowsing::RiceDeltaEncoding*>( + ::mozilla::safebrowsing::RiceDeltaEncoding::internal_default_instance()); +#else + rice_hashes_ = const_cast< ::mozilla::safebrowsing::RiceDeltaEncoding*>(&::mozilla::safebrowsing::RiceDeltaEncoding::default_instance()); +#endif +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + rice_indices_ = const_cast< ::mozilla::safebrowsing::RiceDeltaEncoding*>( + ::mozilla::safebrowsing::RiceDeltaEncoding::internal_default_instance()); +#else + rice_indices_ = const_cast< ::mozilla::safebrowsing::RiceDeltaEncoding*>(&::mozilla::safebrowsing::RiceDeltaEncoding::default_instance()); +#endif +} + +ThreatEntrySet::ThreatEntrySet(const ThreatEntrySet& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatEntrySet) +} + +void ThreatEntrySet::SharedCtor() { + _cached_size_ = 0; + compression_type_ = 0; + raw_hashes_ = NULL; + raw_indices_ = NULL; + rice_hashes_ = NULL; + rice_indices_ = NULL; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatEntrySet::~ThreatEntrySet() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatEntrySet) + SharedDtor(); +} + +void ThreatEntrySet::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + delete raw_hashes_; + delete raw_indices_; + delete rice_hashes_; + delete rice_indices_; + } +} + +void ThreatEntrySet::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatEntrySet& ThreatEntrySet::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatEntrySet* ThreatEntrySet::default_instance_ = NULL; + +ThreatEntrySet* ThreatEntrySet::New() const { + return new ThreatEntrySet; +} + +void ThreatEntrySet::Clear() { + if (_has_bits_[0 / 32] & 31) { + compression_type_ = 0; + if (has_raw_hashes()) { + if (raw_hashes_ != NULL) raw_hashes_->::mozilla::safebrowsing::RawHashes::Clear(); + } + if (has_raw_indices()) { + if (raw_indices_ != NULL) raw_indices_->::mozilla::safebrowsing::RawIndices::Clear(); + } + if (has_rice_hashes()) { + if (rice_hashes_ != NULL) rice_hashes_->::mozilla::safebrowsing::RiceDeltaEncoding::Clear(); + } + if (has_rice_indices()) { + if (rice_indices_ != NULL) rice_indices_->::mozilla::safebrowsing::RiceDeltaEncoding::Clear(); + } + } + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatEntrySet::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatEntrySet) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.CompressionType compression_type = 1; + case 1: { + if (tag == 8) { + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::CompressionType_IsValid(value)) { + set_compression_type(static_cast< ::mozilla::safebrowsing::CompressionType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(18)) goto parse_raw_hashes; + break; + } + + // optional .mozilla.safebrowsing.RawHashes raw_hashes = 2; + case 2: { + if (tag == 18) { + parse_raw_hashes: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_raw_hashes())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(26)) goto parse_raw_indices; + break; + } + + // optional .mozilla.safebrowsing.RawIndices raw_indices = 3; + case 3: { + if (tag == 26) { + parse_raw_indices: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_raw_indices())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(34)) goto parse_rice_hashes; + break; + } + + // optional .mozilla.safebrowsing.RiceDeltaEncoding rice_hashes = 4; + case 4: { + if (tag == 34) { + parse_rice_hashes: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_rice_hashes())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(42)) goto parse_rice_indices; + break; + } + + // optional .mozilla.safebrowsing.RiceDeltaEncoding rice_indices = 5; + case 5: { + if (tag == 42) { + parse_rice_indices: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, mutable_rice_indices())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatEntrySet) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatEntrySet) + return false; +#undef DO_ +} + +void ThreatEntrySet::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatEntrySet) + // optional .mozilla.safebrowsing.CompressionType compression_type = 1; + if (has_compression_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 1, this->compression_type(), output); + } + + // optional .mozilla.safebrowsing.RawHashes raw_hashes = 2; + if (has_raw_hashes()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 2, this->raw_hashes(), output); + } + + // optional .mozilla.safebrowsing.RawIndices raw_indices = 3; + if (has_raw_indices()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 3, this->raw_indices(), output); + } + + // optional .mozilla.safebrowsing.RiceDeltaEncoding rice_hashes = 4; + if (has_rice_hashes()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 4, this->rice_hashes(), output); + } + + // optional .mozilla.safebrowsing.RiceDeltaEncoding rice_indices = 5; + if (has_rice_indices()) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 5, this->rice_indices(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatEntrySet) +} + +int ThreatEntrySet::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.CompressionType compression_type = 1; + if (has_compression_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->compression_type()); + } + + // optional .mozilla.safebrowsing.RawHashes raw_hashes = 2; + if (has_raw_hashes()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->raw_hashes()); + } + + // optional .mozilla.safebrowsing.RawIndices raw_indices = 3; + if (has_raw_indices()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->raw_indices()); + } + + // optional .mozilla.safebrowsing.RiceDeltaEncoding rice_hashes = 4; + if (has_rice_hashes()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->rice_hashes()); + } + + // optional .mozilla.safebrowsing.RiceDeltaEncoding rice_indices = 5; + if (has_rice_indices()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->rice_indices()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatEntrySet::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatEntrySet*>(&from)); +} + +void ThreatEntrySet::MergeFrom(const ThreatEntrySet& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_compression_type()) { + set_compression_type(from.compression_type()); + } + if (from.has_raw_hashes()) { + mutable_raw_hashes()->::mozilla::safebrowsing::RawHashes::MergeFrom(from.raw_hashes()); + } + if (from.has_raw_indices()) { + mutable_raw_indices()->::mozilla::safebrowsing::RawIndices::MergeFrom(from.raw_indices()); + } + if (from.has_rice_hashes()) { + mutable_rice_hashes()->::mozilla::safebrowsing::RiceDeltaEncoding::MergeFrom(from.rice_hashes()); + } + if (from.has_rice_indices()) { + mutable_rice_indices()->::mozilla::safebrowsing::RiceDeltaEncoding::MergeFrom(from.rice_indices()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatEntrySet::CopyFrom(const ThreatEntrySet& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatEntrySet::IsInitialized() const { + + return true; +} + +void ThreatEntrySet::Swap(ThreatEntrySet* other) { + if (other != this) { + std::swap(compression_type_, other->compression_type_); + std::swap(raw_hashes_, other->raw_hashes_); + std::swap(raw_indices_, other->raw_indices_); + std::swap(rice_hashes_, other->rice_hashes_); + std::swap(rice_indices_, other->rice_indices_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatEntrySet::GetTypeName() const { + return "mozilla.safebrowsing.ThreatEntrySet"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int RawIndices::kIndicesFieldNumber; +#endif // !_MSC_VER + +RawIndices::RawIndices() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.RawIndices) +} + +void RawIndices::InitAsDefaultInstance() { +} + +RawIndices::RawIndices(const RawIndices& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.RawIndices) +} + +void RawIndices::SharedCtor() { + _cached_size_ = 0; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +RawIndices::~RawIndices() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.RawIndices) + SharedDtor(); +} + +void RawIndices::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void RawIndices::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const RawIndices& RawIndices::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +RawIndices* RawIndices::default_instance_ = NULL; + +RawIndices* RawIndices::New() const { + return new RawIndices; +} + +void RawIndices::Clear() { + indices_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool RawIndices::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.RawIndices) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // repeated int32 indices = 1; + case 1: { + if (tag == 8) { + parse_indices: + DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive< + ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( + 1, 8, input, this->mutable_indices()))); + } else if (tag == 10) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline< + ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( + input, this->mutable_indices()))); + } else { + goto handle_unusual; + } + if (input->ExpectTag(8)) goto parse_indices; + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.RawIndices) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.RawIndices) + return false; +#undef DO_ +} + +void RawIndices::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.RawIndices) + // repeated int32 indices = 1; + for (int i = 0; i < this->indices_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteInt32( + 1, this->indices(i), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.RawIndices) +} + +int RawIndices::ByteSize() const { + int total_size = 0; + + // repeated int32 indices = 1; + { + int data_size = 0; + for (int i = 0; i < this->indices_size(); i++) { + data_size += ::google::protobuf::internal::WireFormatLite:: + Int32Size(this->indices(i)); + } + total_size += 1 * this->indices_size() + data_size; + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void RawIndices::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const RawIndices*>(&from)); +} + +void RawIndices::MergeFrom(const RawIndices& from) { + GOOGLE_CHECK_NE(&from, this); + indices_.MergeFrom(from.indices_); + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void RawIndices::CopyFrom(const RawIndices& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool RawIndices::IsInitialized() const { + + return true; +} + +void RawIndices::Swap(RawIndices* other) { + if (other != this) { + indices_.Swap(&other->indices_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string RawIndices::GetTypeName() const { + return "mozilla.safebrowsing.RawIndices"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int RawHashes::kPrefixSizeFieldNumber; +const int RawHashes::kRawHashesFieldNumber; +#endif // !_MSC_VER + +RawHashes::RawHashes() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.RawHashes) +} + +void RawHashes::InitAsDefaultInstance() { +} + +RawHashes::RawHashes(const RawHashes& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.RawHashes) +} + +void RawHashes::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + prefix_size_ = 0; + raw_hashes_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +RawHashes::~RawHashes() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.RawHashes) + SharedDtor(); +} + +void RawHashes::SharedDtor() { + if (raw_hashes_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete raw_hashes_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void RawHashes::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const RawHashes& RawHashes::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +RawHashes* RawHashes::default_instance_ = NULL; + +RawHashes* RawHashes::New() const { + return new RawHashes; +} + +void RawHashes::Clear() { + if (_has_bits_[0 / 32] & 3) { + prefix_size_ = 0; + if (has_raw_hashes()) { + if (raw_hashes_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + raw_hashes_->clear(); + } + } + } + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool RawHashes::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.RawHashes) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional int32 prefix_size = 1; + case 1: { + if (tag == 8) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( + input, &prefix_size_))); + set_has_prefix_size(); + } else { + goto handle_unusual; + } + if (input->ExpectTag(18)) goto parse_raw_hashes; + break; + } + + // optional bytes raw_hashes = 2; + case 2: { + if (tag == 18) { + parse_raw_hashes: + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->mutable_raw_hashes())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.RawHashes) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.RawHashes) + return false; +#undef DO_ +} + +void RawHashes::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.RawHashes) + // optional int32 prefix_size = 1; + if (has_prefix_size()) { + ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->prefix_size(), output); + } + + // optional bytes raw_hashes = 2; + if (has_raw_hashes()) { + ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( + 2, this->raw_hashes(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.RawHashes) +} + +int RawHashes::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional int32 prefix_size = 1; + if (has_prefix_size()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::Int32Size( + this->prefix_size()); + } + + // optional bytes raw_hashes = 2; + if (has_raw_hashes()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::BytesSize( + this->raw_hashes()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void RawHashes::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const RawHashes*>(&from)); +} + +void RawHashes::MergeFrom(const RawHashes& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_prefix_size()) { + set_prefix_size(from.prefix_size()); + } + if (from.has_raw_hashes()) { + set_raw_hashes(from.raw_hashes()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void RawHashes::CopyFrom(const RawHashes& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool RawHashes::IsInitialized() const { + + return true; +} + +void RawHashes::Swap(RawHashes* other) { + if (other != this) { + std::swap(prefix_size_, other->prefix_size_); + std::swap(raw_hashes_, other->raw_hashes_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string RawHashes::GetTypeName() const { + return "mozilla.safebrowsing.RawHashes"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int RiceDeltaEncoding::kFirstValueFieldNumber; +const int RiceDeltaEncoding::kRiceParameterFieldNumber; +const int RiceDeltaEncoding::kNumEntriesFieldNumber; +const int RiceDeltaEncoding::kEncodedDataFieldNumber; +#endif // !_MSC_VER + +RiceDeltaEncoding::RiceDeltaEncoding() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.RiceDeltaEncoding) +} + +void RiceDeltaEncoding::InitAsDefaultInstance() { +} + +RiceDeltaEncoding::RiceDeltaEncoding(const RiceDeltaEncoding& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.RiceDeltaEncoding) +} + +void RiceDeltaEncoding::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + first_value_ = GOOGLE_LONGLONG(0); + rice_parameter_ = 0; + num_entries_ = 0; + encoded_data_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +RiceDeltaEncoding::~RiceDeltaEncoding() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.RiceDeltaEncoding) + SharedDtor(); +} + +void RiceDeltaEncoding::SharedDtor() { + if (encoded_data_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete encoded_data_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void RiceDeltaEncoding::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const RiceDeltaEncoding& RiceDeltaEncoding::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +RiceDeltaEncoding* RiceDeltaEncoding::default_instance_ = NULL; + +RiceDeltaEncoding* RiceDeltaEncoding::New() const { + return new RiceDeltaEncoding; +} + +void RiceDeltaEncoding::Clear() { +#define OFFSET_OF_FIELD_(f) (reinterpret_cast<char*>( \ + &reinterpret_cast<RiceDeltaEncoding*>(16)->f) - \ + reinterpret_cast<char*>(16)) + +#define ZR_(first, last) do { \ + size_t f = OFFSET_OF_FIELD_(first); \ + size_t n = OFFSET_OF_FIELD_(last) - f + sizeof(last); \ + ::memset(&first, 0, n); \ + } while (0) + + if (_has_bits_[0 / 32] & 15) { + ZR_(first_value_, num_entries_); + if (has_encoded_data()) { + if (encoded_data_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + encoded_data_->clear(); + } + } + } + +#undef OFFSET_OF_FIELD_ +#undef ZR_ + + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool RiceDeltaEncoding::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.RiceDeltaEncoding) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional int64 first_value = 1; + case 1: { + if (tag == 8) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>( + input, &first_value_))); + set_has_first_value(); + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_rice_parameter; + break; + } + + // optional int32 rice_parameter = 2; + case 2: { + if (tag == 16) { + parse_rice_parameter: + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( + input, &rice_parameter_))); + set_has_rice_parameter(); + } else { + goto handle_unusual; + } + if (input->ExpectTag(24)) goto parse_num_entries; + break; + } + + // optional int32 num_entries = 3; + case 3: { + if (tag == 24) { + parse_num_entries: + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( + input, &num_entries_))); + set_has_num_entries(); + } else { + goto handle_unusual; + } + if (input->ExpectTag(34)) goto parse_encoded_data; + break; + } + + // optional bytes encoded_data = 4; + case 4: { + if (tag == 34) { + parse_encoded_data: + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->mutable_encoded_data())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.RiceDeltaEncoding) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.RiceDeltaEncoding) + return false; +#undef DO_ +} + +void RiceDeltaEncoding::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.RiceDeltaEncoding) + // optional int64 first_value = 1; + if (has_first_value()) { + ::google::protobuf::internal::WireFormatLite::WriteInt64(1, this->first_value(), output); + } + + // optional int32 rice_parameter = 2; + if (has_rice_parameter()) { + ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->rice_parameter(), output); + } + + // optional int32 num_entries = 3; + if (has_num_entries()) { + ::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->num_entries(), output); + } + + // optional bytes encoded_data = 4; + if (has_encoded_data()) { + ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( + 4, this->encoded_data(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.RiceDeltaEncoding) +} + +int RiceDeltaEncoding::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional int64 first_value = 1; + if (has_first_value()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::Int64Size( + this->first_value()); + } + + // optional int32 rice_parameter = 2; + if (has_rice_parameter()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::Int32Size( + this->rice_parameter()); + } + + // optional int32 num_entries = 3; + if (has_num_entries()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::Int32Size( + this->num_entries()); + } + + // optional bytes encoded_data = 4; + if (has_encoded_data()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::BytesSize( + this->encoded_data()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void RiceDeltaEncoding::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const RiceDeltaEncoding*>(&from)); +} + +void RiceDeltaEncoding::MergeFrom(const RiceDeltaEncoding& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_first_value()) { + set_first_value(from.first_value()); + } + if (from.has_rice_parameter()) { + set_rice_parameter(from.rice_parameter()); + } + if (from.has_num_entries()) { + set_num_entries(from.num_entries()); + } + if (from.has_encoded_data()) { + set_encoded_data(from.encoded_data()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void RiceDeltaEncoding::CopyFrom(const RiceDeltaEncoding& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool RiceDeltaEncoding::IsInitialized() const { + + return true; +} + +void RiceDeltaEncoding::Swap(RiceDeltaEncoding* other) { + if (other != this) { + std::swap(first_value_, other->first_value_); + std::swap(rice_parameter_, other->rice_parameter_); + std::swap(num_entries_, other->num_entries_); + std::swap(encoded_data_, other->encoded_data_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string RiceDeltaEncoding::GetTypeName() const { + return "mozilla.safebrowsing.RiceDeltaEncoding"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int ThreatEntryMetadata_MetadataEntry::kKeyFieldNumber; +const int ThreatEntryMetadata_MetadataEntry::kValueFieldNumber; +#endif // !_MSC_VER + +ThreatEntryMetadata_MetadataEntry::ThreatEntryMetadata_MetadataEntry() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry) +} + +void ThreatEntryMetadata_MetadataEntry::InitAsDefaultInstance() { +} + +ThreatEntryMetadata_MetadataEntry::ThreatEntryMetadata_MetadataEntry(const ThreatEntryMetadata_MetadataEntry& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry) +} + +void ThreatEntryMetadata_MetadataEntry::SharedCtor() { + ::google::protobuf::internal::GetEmptyString(); + _cached_size_ = 0; + key_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + value_ = const_cast< ::std::string*>(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatEntryMetadata_MetadataEntry::~ThreatEntryMetadata_MetadataEntry() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry) + SharedDtor(); +} + +void ThreatEntryMetadata_MetadataEntry::SharedDtor() { + if (key_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete key_; + } + if (value_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + delete value_; + } + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void ThreatEntryMetadata_MetadataEntry::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatEntryMetadata_MetadataEntry& ThreatEntryMetadata_MetadataEntry::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatEntryMetadata_MetadataEntry* ThreatEntryMetadata_MetadataEntry::default_instance_ = NULL; + +ThreatEntryMetadata_MetadataEntry* ThreatEntryMetadata_MetadataEntry::New() const { + return new ThreatEntryMetadata_MetadataEntry; +} + +void ThreatEntryMetadata_MetadataEntry::Clear() { + if (_has_bits_[0 / 32] & 3) { + if (has_key()) { + if (key_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + key_->clear(); + } + } + if (has_value()) { + if (value_ != &::google::protobuf::internal::GetEmptyStringAlreadyInited()) { + value_->clear(); + } + } + } + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatEntryMetadata_MetadataEntry::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional bytes key = 1; + case 1: { + if (tag == 10) { + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->mutable_key())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(18)) goto parse_value; + break; + } + + // optional bytes value = 2; + case 2: { + if (tag == 18) { + parse_value: + DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( + input, this->mutable_value())); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry) + return false; +#undef DO_ +} + +void ThreatEntryMetadata_MetadataEntry::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry) + // optional bytes key = 1; + if (has_key()) { + ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( + 1, this->key(), output); + } + + // optional bytes value = 2; + if (has_value()) { + ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( + 2, this->value(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry) +} + +int ThreatEntryMetadata_MetadataEntry::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional bytes key = 1; + if (has_key()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::BytesSize( + this->key()); + } + + // optional bytes value = 2; + if (has_value()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::BytesSize( + this->value()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatEntryMetadata_MetadataEntry::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatEntryMetadata_MetadataEntry*>(&from)); +} + +void ThreatEntryMetadata_MetadataEntry::MergeFrom(const ThreatEntryMetadata_MetadataEntry& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_key()) { + set_key(from.key()); + } + if (from.has_value()) { + set_value(from.value()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatEntryMetadata_MetadataEntry::CopyFrom(const ThreatEntryMetadata_MetadataEntry& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatEntryMetadata_MetadataEntry::IsInitialized() const { + + return true; +} + +void ThreatEntryMetadata_MetadataEntry::Swap(ThreatEntryMetadata_MetadataEntry* other) { + if (other != this) { + std::swap(key_, other->key_); + std::swap(value_, other->value_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatEntryMetadata_MetadataEntry::GetTypeName() const { + return "mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry"; +} + + +// ------------------------------------------------------------------- + +#ifndef _MSC_VER +const int ThreatEntryMetadata::kEntriesFieldNumber; +#endif // !_MSC_VER + +ThreatEntryMetadata::ThreatEntryMetadata() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatEntryMetadata) +} + +void ThreatEntryMetadata::InitAsDefaultInstance() { +} + +ThreatEntryMetadata::ThreatEntryMetadata(const ThreatEntryMetadata& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatEntryMetadata) +} + +void ThreatEntryMetadata::SharedCtor() { + _cached_size_ = 0; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatEntryMetadata::~ThreatEntryMetadata() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatEntryMetadata) + SharedDtor(); +} + +void ThreatEntryMetadata::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void ThreatEntryMetadata::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatEntryMetadata& ThreatEntryMetadata::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatEntryMetadata* ThreatEntryMetadata::default_instance_ = NULL; + +ThreatEntryMetadata* ThreatEntryMetadata::New() const { + return new ThreatEntryMetadata; +} + +void ThreatEntryMetadata::Clear() { + entries_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatEntryMetadata::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatEntryMetadata) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // repeated .mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry entries = 1; + case 1: { + if (tag == 10) { + parse_entries: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_entries())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(10)) goto parse_entries; + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatEntryMetadata) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatEntryMetadata) + return false; +#undef DO_ +} + +void ThreatEntryMetadata::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatEntryMetadata) + // repeated .mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry entries = 1; + for (int i = 0; i < this->entries_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 1, this->entries(i), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatEntryMetadata) +} + +int ThreatEntryMetadata::ByteSize() const { + int total_size = 0; + + // repeated .mozilla.safebrowsing.ThreatEntryMetadata.MetadataEntry entries = 1; + total_size += 1 * this->entries_size(); + for (int i = 0; i < this->entries_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->entries(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatEntryMetadata::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatEntryMetadata*>(&from)); +} + +void ThreatEntryMetadata::MergeFrom(const ThreatEntryMetadata& from) { + GOOGLE_CHECK_NE(&from, this); + entries_.MergeFrom(from.entries_); + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatEntryMetadata::CopyFrom(const ThreatEntryMetadata& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatEntryMetadata::IsInitialized() const { + + return true; +} + +void ThreatEntryMetadata::Swap(ThreatEntryMetadata* other) { + if (other != this) { + entries_.Swap(&other->entries_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatEntryMetadata::GetTypeName() const { + return "mozilla.safebrowsing.ThreatEntryMetadata"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int ThreatListDescriptor::kThreatTypeFieldNumber; +const int ThreatListDescriptor::kPlatformTypeFieldNumber; +const int ThreatListDescriptor::kThreatEntryTypeFieldNumber; +#endif // !_MSC_VER + +ThreatListDescriptor::ThreatListDescriptor() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ThreatListDescriptor) +} + +void ThreatListDescriptor::InitAsDefaultInstance() { +} + +ThreatListDescriptor::ThreatListDescriptor(const ThreatListDescriptor& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ThreatListDescriptor) +} + +void ThreatListDescriptor::SharedCtor() { + _cached_size_ = 0; + threat_type_ = 0; + platform_type_ = 0; + threat_entry_type_ = 0; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ThreatListDescriptor::~ThreatListDescriptor() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ThreatListDescriptor) + SharedDtor(); +} + +void ThreatListDescriptor::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void ThreatListDescriptor::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ThreatListDescriptor& ThreatListDescriptor::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ThreatListDescriptor* ThreatListDescriptor::default_instance_ = NULL; + +ThreatListDescriptor* ThreatListDescriptor::New() const { + return new ThreatListDescriptor; +} + +void ThreatListDescriptor::Clear() { +#define OFFSET_OF_FIELD_(f) (reinterpret_cast<char*>( \ + &reinterpret_cast<ThreatListDescriptor*>(16)->f) - \ + reinterpret_cast<char*>(16)) + +#define ZR_(first, last) do { \ + size_t f = OFFSET_OF_FIELD_(first); \ + size_t n = OFFSET_OF_FIELD_(last) - f + sizeof(last); \ + ::memset(&first, 0, n); \ + } while (0) + + ZR_(threat_type_, threat_entry_type_); + +#undef OFFSET_OF_FIELD_ +#undef ZR_ + + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ThreatListDescriptor::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ThreatListDescriptor) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + case 1: { + if (tag == 8) { + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatType_IsValid(value)) { + set_threat_type(static_cast< ::mozilla::safebrowsing::ThreatType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_platform_type; + break; + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + case 2: { + if (tag == 16) { + parse_platform_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::PlatformType_IsValid(value)) { + set_platform_type(static_cast< ::mozilla::safebrowsing::PlatformType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectTag(24)) goto parse_threat_entry_type; + break; + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 3; + case 3: { + if (tag == 24) { + parse_threat_entry_type: + int value; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + if (::mozilla::safebrowsing::ThreatEntryType_IsValid(value)) { + set_threat_entry_type(static_cast< ::mozilla::safebrowsing::ThreatEntryType >(value)); + } else { + unknown_fields_stream.WriteVarint32(tag); + unknown_fields_stream.WriteVarint32(value); + } + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ThreatListDescriptor) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ThreatListDescriptor) + return false; +#undef DO_ +} + +void ThreatListDescriptor::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ThreatListDescriptor) + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 1, this->threat_type(), output); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + if (has_platform_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 2, this->platform_type(), output); + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 3; + if (has_threat_entry_type()) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 3, this->threat_entry_type(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ThreatListDescriptor) +} + +int ThreatListDescriptor::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional .mozilla.safebrowsing.ThreatType threat_type = 1; + if (has_threat_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_type()); + } + + // optional .mozilla.safebrowsing.PlatformType platform_type = 2; + if (has_platform_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->platform_type()); + } + + // optional .mozilla.safebrowsing.ThreatEntryType threat_entry_type = 3; + if (has_threat_entry_type()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::EnumSize(this->threat_entry_type()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ThreatListDescriptor::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ThreatListDescriptor*>(&from)); +} + +void ThreatListDescriptor::MergeFrom(const ThreatListDescriptor& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_threat_type()) { + set_threat_type(from.threat_type()); + } + if (from.has_platform_type()) { + set_platform_type(from.platform_type()); + } + if (from.has_threat_entry_type()) { + set_threat_entry_type(from.threat_entry_type()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ThreatListDescriptor::CopyFrom(const ThreatListDescriptor& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ThreatListDescriptor::IsInitialized() const { + + return true; +} + +void ThreatListDescriptor::Swap(ThreatListDescriptor* other) { + if (other != this) { + std::swap(threat_type_, other->threat_type_); + std::swap(platform_type_, other->platform_type_); + std::swap(threat_entry_type_, other->threat_entry_type_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ThreatListDescriptor::GetTypeName() const { + return "mozilla.safebrowsing.ThreatListDescriptor"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int ListThreatListsResponse::kThreatListsFieldNumber; +#endif // !_MSC_VER + +ListThreatListsResponse::ListThreatListsResponse() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.ListThreatListsResponse) +} + +void ListThreatListsResponse::InitAsDefaultInstance() { +} + +ListThreatListsResponse::ListThreatListsResponse(const ListThreatListsResponse& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.ListThreatListsResponse) +} + +void ListThreatListsResponse::SharedCtor() { + _cached_size_ = 0; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +ListThreatListsResponse::~ListThreatListsResponse() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.ListThreatListsResponse) + SharedDtor(); +} + +void ListThreatListsResponse::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void ListThreatListsResponse::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const ListThreatListsResponse& ListThreatListsResponse::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +ListThreatListsResponse* ListThreatListsResponse::default_instance_ = NULL; + +ListThreatListsResponse* ListThreatListsResponse::New() const { + return new ListThreatListsResponse; +} + +void ListThreatListsResponse::Clear() { + threat_lists_.Clear(); + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool ListThreatListsResponse::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.ListThreatListsResponse) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // repeated .mozilla.safebrowsing.ThreatListDescriptor threat_lists = 1; + case 1: { + if (tag == 10) { + parse_threat_lists: + DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( + input, add_threat_lists())); + } else { + goto handle_unusual; + } + if (input->ExpectTag(10)) goto parse_threat_lists; + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.ListThreatListsResponse) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.ListThreatListsResponse) + return false; +#undef DO_ +} + +void ListThreatListsResponse::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.ListThreatListsResponse) + // repeated .mozilla.safebrowsing.ThreatListDescriptor threat_lists = 1; + for (int i = 0; i < this->threat_lists_size(); i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessage( + 1, this->threat_lists(i), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.ListThreatListsResponse) +} + +int ListThreatListsResponse::ByteSize() const { + int total_size = 0; + + // repeated .mozilla.safebrowsing.ThreatListDescriptor threat_lists = 1; + total_size += 1 * this->threat_lists_size(); + for (int i = 0; i < this->threat_lists_size(); i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual( + this->threat_lists(i)); + } + + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void ListThreatListsResponse::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const ListThreatListsResponse*>(&from)); +} + +void ListThreatListsResponse::MergeFrom(const ListThreatListsResponse& from) { + GOOGLE_CHECK_NE(&from, this); + threat_lists_.MergeFrom(from.threat_lists_); + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void ListThreatListsResponse::CopyFrom(const ListThreatListsResponse& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ListThreatListsResponse::IsInitialized() const { + + return true; +} + +void ListThreatListsResponse::Swap(ListThreatListsResponse* other) { + if (other != this) { + threat_lists_.Swap(&other->threat_lists_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string ListThreatListsResponse::GetTypeName() const { + return "mozilla.safebrowsing.ListThreatListsResponse"; +} + + +// =================================================================== + +#ifndef _MSC_VER +const int Duration::kSecondsFieldNumber; +const int Duration::kNanosFieldNumber; +#endif // !_MSC_VER + +Duration::Duration() + : ::google::protobuf::MessageLite() { + SharedCtor(); + // @@protoc_insertion_point(constructor:mozilla.safebrowsing.Duration) +} + +void Duration::InitAsDefaultInstance() { +} + +Duration::Duration(const Duration& from) + : ::google::protobuf::MessageLite() { + SharedCtor(); + MergeFrom(from); + // @@protoc_insertion_point(copy_constructor:mozilla.safebrowsing.Duration) +} + +void Duration::SharedCtor() { + _cached_size_ = 0; + seconds_ = GOOGLE_LONGLONG(0); + nanos_ = 0; + ::memset(_has_bits_, 0, sizeof(_has_bits_)); +} + +Duration::~Duration() { + // @@protoc_insertion_point(destructor:mozilla.safebrowsing.Duration) + SharedDtor(); +} + +void Duration::SharedDtor() { + #ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + if (this != &default_instance()) { + #else + if (this != default_instance_) { + #endif + } +} + +void Duration::SetCachedSize(int size) const { + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); +} +const Duration& Duration::default_instance() { +#ifdef GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER + protobuf_AddDesc_safebrowsing_2eproto(); +#else + if (default_instance_ == NULL) protobuf_AddDesc_safebrowsing_2eproto(); +#endif + return *default_instance_; +} + +Duration* Duration::default_instance_ = NULL; + +Duration* Duration::New() const { + return new Duration; +} + +void Duration::Clear() { +#define OFFSET_OF_FIELD_(f) (reinterpret_cast<char*>( \ + &reinterpret_cast<Duration*>(16)->f) - \ + reinterpret_cast<char*>(16)) + +#define ZR_(first, last) do { \ + size_t f = OFFSET_OF_FIELD_(first); \ + size_t n = OFFSET_OF_FIELD_(last) - f + sizeof(last); \ + ::memset(&first, 0, n); \ + } while (0) + + ZR_(seconds_, nanos_); + +#undef OFFSET_OF_FIELD_ +#undef ZR_ + + ::memset(_has_bits_, 0, sizeof(_has_bits_)); + mutable_unknown_fields()->clear(); +} + +bool Duration::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + ::google::protobuf::io::StringOutputStream unknown_fields_string( + mutable_unknown_fields()); + ::google::protobuf::io::CodedOutputStream unknown_fields_stream( + &unknown_fields_string); + // @@protoc_insertion_point(parse_start:mozilla.safebrowsing.Duration) + for (;;) { + ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // optional int64 seconds = 1; + case 1: { + if (tag == 8) { + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>( + input, &seconds_))); + set_has_seconds(); + } else { + goto handle_unusual; + } + if (input->ExpectTag(16)) goto parse_nanos; + break; + } + + // optional int32 nanos = 2; + case 2: { + if (tag == 16) { + parse_nanos: + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( + input, &nanos_))); + set_has_nanos(); + } else { + goto handle_unusual; + } + if (input->ExpectAtEnd()) goto success; + break; + } + + default: { + handle_unusual: + if (tag == 0 || + ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == + ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + goto success; + } + DO_(::google::protobuf::internal::WireFormatLite::SkipField( + input, tag, &unknown_fields_stream)); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:mozilla.safebrowsing.Duration) + return true; +failure: + // @@protoc_insertion_point(parse_failure:mozilla.safebrowsing.Duration) + return false; +#undef DO_ +} + +void Duration::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:mozilla.safebrowsing.Duration) + // optional int64 seconds = 1; + if (has_seconds()) { + ::google::protobuf::internal::WireFormatLite::WriteInt64(1, this->seconds(), output); + } + + // optional int32 nanos = 2; + if (has_nanos()) { + ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->nanos(), output); + } + + output->WriteRaw(unknown_fields().data(), + unknown_fields().size()); + // @@protoc_insertion_point(serialize_end:mozilla.safebrowsing.Duration) +} + +int Duration::ByteSize() const { + int total_size = 0; + + if (_has_bits_[0 / 32] & (0xffu << (0 % 32))) { + // optional int64 seconds = 1; + if (has_seconds()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::Int64Size( + this->seconds()); + } + + // optional int32 nanos = 2; + if (has_nanos()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::Int32Size( + this->nanos()); + } + + } + total_size += unknown_fields().size(); + + GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); + _cached_size_ = total_size; + GOOGLE_SAFE_CONCURRENT_WRITES_END(); + return total_size; +} + +void Duration::CheckTypeAndMergeFrom( + const ::google::protobuf::MessageLite& from) { + MergeFrom(*::google::protobuf::down_cast<const Duration*>(&from)); +} + +void Duration::MergeFrom(const Duration& from) { + GOOGLE_CHECK_NE(&from, this); + if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) { + if (from.has_seconds()) { + set_seconds(from.seconds()); + } + if (from.has_nanos()) { + set_nanos(from.nanos()); + } + } + mutable_unknown_fields()->append(from.unknown_fields()); +} + +void Duration::CopyFrom(const Duration& from) { + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool Duration::IsInitialized() const { + + return true; +} + +void Duration::Swap(Duration* other) { + if (other != this) { + std::swap(seconds_, other->seconds_); + std::swap(nanos_, other->nanos_); + std::swap(_has_bits_[0], other->_has_bits_[0]); + _unknown_fields_.swap(other->_unknown_fields_); + std::swap(_cached_size_, other->_cached_size_); + } +} + +::std::string Duration::GetTypeName() const { + return "mozilla.safebrowsing.Duration"; +} + + +// @@protoc_insertion_point(namespace_scope) + +} // namespace safebrowsing +} // namespace mozilla + +// @@protoc_insertion_point(global_scope) |