// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: background_fetch.proto

#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
#include "background_fetch.pb.h"

#include <algorithm>

#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.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 content {
namespace proto {
class BackgroundFetchRegistrationDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<BackgroundFetchRegistration> {
} _BackgroundFetchRegistration_default_instance_;
class BackgroundFetchOptions_ImageResource_SizeDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<BackgroundFetchOptions_ImageResource_Size> {
} _BackgroundFetchOptions_ImageResource_Size_default_instance_;
class BackgroundFetchOptions_ImageResourceDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<BackgroundFetchOptions_ImageResource> {
} _BackgroundFetchOptions_ImageResource_default_instance_;
class BackgroundFetchOptionsDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<BackgroundFetchOptions> {
} _BackgroundFetchOptions_default_instance_;
class BackgroundFetchMetadataDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<BackgroundFetchMetadata> {
} _BackgroundFetchMetadata_default_instance_;
class BackgroundFetchPendingRequestDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<BackgroundFetchPendingRequest> {
} _BackgroundFetchPendingRequest_default_instance_;
class BackgroundFetchActiveRequestDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<BackgroundFetchActiveRequest> {
} _BackgroundFetchActiveRequest_default_instance_;
class BackgroundFetchCompletedRequestDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<BackgroundFetchCompletedRequest> {
} _BackgroundFetchCompletedRequest_default_instance_;

namespace protobuf_background_5ffetch_2eproto {

PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::ParseTableField
    const TableStruct::entries[] = {
  {0, 0, 0, ::google::protobuf::internal::kInvalidMask, 0, 0},
};

PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::AuxillaryParseTableField
    const TableStruct::aux[] = {
  ::google::protobuf::internal::AuxillaryParseTableField(),
};
PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::ParseTable const
    TableStruct::schema[] = {
  { NULL, NULL, 0, -1, -1, false },
  { NULL, NULL, 0, -1, -1, false },
  { NULL, NULL, 0, -1, -1, false },
  { NULL, NULL, 0, -1, -1, false },
  { NULL, NULL, 0, -1, -1, false },
  { NULL, NULL, 0, -1, -1, false },
  { NULL, NULL, 0, -1, -1, false },
  { NULL, NULL, 0, -1, -1, false },
};


void TableStruct::Shutdown() {
  _BackgroundFetchRegistration_default_instance_.Shutdown();
  _BackgroundFetchOptions_ImageResource_Size_default_instance_.Shutdown();
  _BackgroundFetchOptions_ImageResource_default_instance_.Shutdown();
  _BackgroundFetchOptions_default_instance_.Shutdown();
  _BackgroundFetchMetadata_default_instance_.Shutdown();
  _BackgroundFetchPendingRequest_default_instance_.Shutdown();
  _BackgroundFetchActiveRequest_default_instance_.Shutdown();
  _BackgroundFetchCompletedRequest_default_instance_.Shutdown();
}

void TableStruct::InitDefaultsImpl() {
  GOOGLE_PROTOBUF_VERIFY_VERSION;

  ::google::protobuf::internal::InitProtobufDefaults();
  _BackgroundFetchRegistration_default_instance_.DefaultConstruct();
  _BackgroundFetchOptions_ImageResource_Size_default_instance_.DefaultConstruct();
  _BackgroundFetchOptions_ImageResource_default_instance_.DefaultConstruct();
  _BackgroundFetchOptions_default_instance_.DefaultConstruct();
  _BackgroundFetchMetadata_default_instance_.DefaultConstruct();
  _BackgroundFetchPendingRequest_default_instance_.DefaultConstruct();
  _BackgroundFetchActiveRequest_default_instance_.DefaultConstruct();
  _BackgroundFetchCompletedRequest_default_instance_.DefaultConstruct();
  _BackgroundFetchMetadata_default_instance_.get_mutable()->registration_ = const_cast< ::content::proto::BackgroundFetchRegistration*>(
      ::content::proto::BackgroundFetchRegistration::internal_default_instance());
  _BackgroundFetchMetadata_default_instance_.get_mutable()->options_ = const_cast< ::content::proto::BackgroundFetchOptions*>(
      ::content::proto::BackgroundFetchOptions::internal_default_instance());
}

void InitDefaults() {
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
  ::google::protobuf::GoogleOnceInit(&once, &TableStruct::InitDefaultsImpl);
}
void AddDescriptorsImpl() {
  InitDefaults();
  ::google::protobuf::internal::OnShutdown(&TableStruct::Shutdown);
}

void AddDescriptors() {
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
  ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl);
}

}  // namespace protobuf_background_5ffetch_2eproto

bool BackgroundFetchOptions_ImageResource_Purpose_IsValid(int value) {
  switch (value) {
    case 1:
    case 2:
      return true;
    default:
      return false;
  }
}

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const BackgroundFetchOptions_ImageResource_Purpose BackgroundFetchOptions_ImageResource::ANY;
const BackgroundFetchOptions_ImageResource_Purpose BackgroundFetchOptions_ImageResource::BADGE;
const BackgroundFetchOptions_ImageResource_Purpose BackgroundFetchOptions_ImageResource::Purpose_MIN;
const BackgroundFetchOptions_ImageResource_Purpose BackgroundFetchOptions_ImageResource::Purpose_MAX;
const int BackgroundFetchOptions_ImageResource::Purpose_ARRAYSIZE;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

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

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BackgroundFetchRegistration::kUniqueIdFieldNumber;
const int BackgroundFetchRegistration::kDeveloperIdFieldNumber;
const int BackgroundFetchRegistration::kUploadTotalFieldNumber;
const int BackgroundFetchRegistration::kUploadedFieldNumber;
const int BackgroundFetchRegistration::kDownloadTotalFieldNumber;
const int BackgroundFetchRegistration::kDownloadedFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

BackgroundFetchRegistration::BackgroundFetchRegistration()
  : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_background_5ffetch_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:content.proto.BackgroundFetchRegistration)
}
BackgroundFetchRegistration::BackgroundFetchRegistration(const BackgroundFetchRegistration& from)
  : ::google::protobuf::MessageLite(),
      _internal_metadata_(NULL),
      _has_bits_(from._has_bits_),
      _cached_size_(0) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  unique_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_unique_id()) {
    unique_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.unique_id_);
  }
  developer_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_developer_id()) {
    developer_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.developer_id_);
  }
  ::memcpy(&upload_total_, &from.upload_total_,
    static_cast<size_t>(reinterpret_cast<char*>(&downloaded_) -
    reinterpret_cast<char*>(&upload_total_)) + sizeof(downloaded_));
  // @@protoc_insertion_point(copy_constructor:content.proto.BackgroundFetchRegistration)
}

void BackgroundFetchRegistration::SharedCtor() {
  _cached_size_ = 0;
  unique_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  developer_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  ::memset(&upload_total_, 0, static_cast<size_t>(
      reinterpret_cast<char*>(&downloaded_) -
      reinterpret_cast<char*>(&upload_total_)) + sizeof(downloaded_));
}

BackgroundFetchRegistration::~BackgroundFetchRegistration() {
  // @@protoc_insertion_point(destructor:content.proto.BackgroundFetchRegistration)
  SharedDtor();
}

void BackgroundFetchRegistration::SharedDtor() {
  unique_id_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  developer_id_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}

void BackgroundFetchRegistration::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const BackgroundFetchRegistration& BackgroundFetchRegistration::default_instance() {
  protobuf_background_5ffetch_2eproto::InitDefaults();
  return *internal_default_instance();
}

BackgroundFetchRegistration* BackgroundFetchRegistration::New(::google::protobuf::Arena* arena) const {
  BackgroundFetchRegistration* n = new BackgroundFetchRegistration;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void BackgroundFetchRegistration::Clear() {
// @@protoc_insertion_point(message_clear_start:content.proto.BackgroundFetchRegistration)
  if (_has_bits_[0 / 32] & 3u) {
    if (has_unique_id()) {
      GOOGLE_DCHECK(!unique_id_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*unique_id_.UnsafeRawStringPointer())->clear();
    }
    if (has_developer_id()) {
      GOOGLE_DCHECK(!developer_id_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*developer_id_.UnsafeRawStringPointer())->clear();
    }
  }
  if (_has_bits_[0 / 32] & 60u) {
    ::memset(&upload_total_, 0, static_cast<size_t>(
        reinterpret_cast<char*>(&downloaded_) -
        reinterpret_cast<char*>(&upload_total_)) + sizeof(downloaded_));
  }
  _has_bits_.Clear();
  _internal_metadata_.Clear();
}

bool BackgroundFetchRegistration::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  ::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
      ::google::protobuf::NewPermanentCallback(&_internal_metadata_,
          &::google::protobuf::internal::InternalMetadataWithArenaLite::
              mutable_unknown_fields));
  ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
      &unknown_fields_string, false);
  // @@protoc_insertion_point(parse_start:content.proto.BackgroundFetchRegistration)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional string unique_id = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(10u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_unique_id()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional bytes developer_id = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(18u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
                input, this->mutable_developer_id()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional uint64 upload_total = 3;
      case 3: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(24u)) {
          set_has_upload_total();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &upload_total_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional uint64 uploaded = 4;
      case 4: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(32u)) {
          set_has_uploaded();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &uploaded_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional uint64 download_total = 5;
      case 5: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(40u)) {
          set_has_download_total();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &download_total_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional uint64 downloaded = 6;
      case 6: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(48u)) {
          set_has_downloaded();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &downloaded_)));
        } else {
          goto handle_unusual;
        }
        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:content.proto.BackgroundFetchRegistration)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:content.proto.BackgroundFetchRegistration)
  return false;
#undef DO_
}

void BackgroundFetchRegistration::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:content.proto.BackgroundFetchRegistration)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  // optional string unique_id = 1;
  if (cached_has_bits & 0x00000001u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      1, this->unique_id(), output);
  }

  // optional bytes developer_id = 2;
  if (cached_has_bits & 0x00000002u) {
    ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased(
      2, this->developer_id(), output);
  }

  // optional uint64 upload_total = 3;
  if (cached_has_bits & 0x00000004u) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(3, this->upload_total(), output);
  }

  // optional uint64 uploaded = 4;
  if (cached_has_bits & 0x00000008u) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(4, this->uploaded(), output);
  }

  // optional uint64 download_total = 5;
  if (cached_has_bits & 0x00000010u) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(5, this->download_total(), output);
  }

  // optional uint64 downloaded = 6;
  if (cached_has_bits & 0x00000020u) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(6, this->downloaded(), output);
  }

  output->WriteRaw(unknown_fields().data(),
                   static_cast<int>(unknown_fields().size()));
  // @@protoc_insertion_point(serialize_end:content.proto.BackgroundFetchRegistration)
}

size_t BackgroundFetchRegistration::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:content.proto.BackgroundFetchRegistration)
  size_t total_size = 0;

  total_size += unknown_fields().size();

  if (_has_bits_[0 / 32] & 63u) {
    // optional string unique_id = 1;
    if (has_unique_id()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->unique_id());
    }

    // optional bytes developer_id = 2;
    if (has_developer_id()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::BytesSize(
          this->developer_id());
    }

    // optional uint64 upload_total = 3;
    if (has_upload_total()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->upload_total());
    }

    // optional uint64 uploaded = 4;
    if (has_uploaded()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->uploaded());
    }

    // optional uint64 download_total = 5;
    if (has_download_total()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->download_total());
    }

    // optional uint64 downloaded = 6;
    if (has_downloaded()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->downloaded());
    }

  }
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BackgroundFetchRegistration::CheckTypeAndMergeFrom(
    const ::google::protobuf::MessageLite& from) {
  MergeFrom(*::google::protobuf::down_cast<const BackgroundFetchRegistration*>(&from));
}

void BackgroundFetchRegistration::MergeFrom(const BackgroundFetchRegistration& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:content.proto.BackgroundFetchRegistration)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 63u) {
    if (cached_has_bits & 0x00000001u) {
      set_has_unique_id();
      unique_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.unique_id_);
    }
    if (cached_has_bits & 0x00000002u) {
      set_has_developer_id();
      developer_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.developer_id_);
    }
    if (cached_has_bits & 0x00000004u) {
      upload_total_ = from.upload_total_;
    }
    if (cached_has_bits & 0x00000008u) {
      uploaded_ = from.uploaded_;
    }
    if (cached_has_bits & 0x00000010u) {
      download_total_ = from.download_total_;
    }
    if (cached_has_bits & 0x00000020u) {
      downloaded_ = from.downloaded_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
}

void BackgroundFetchRegistration::CopyFrom(const BackgroundFetchRegistration& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:content.proto.BackgroundFetchRegistration)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void BackgroundFetchRegistration::Swap(BackgroundFetchRegistration* other) {
  if (other == this) return;
  InternalSwap(other);
}
void BackgroundFetchRegistration::InternalSwap(BackgroundFetchRegistration* other) {
  unique_id_.Swap(&other->unique_id_);
  developer_id_.Swap(&other->developer_id_);
  std::swap(upload_total_, other->upload_total_);
  std::swap(uploaded_, other->uploaded_);
  std::swap(download_total_, other->download_total_);
  std::swap(downloaded_, other->downloaded_);
  std::swap(_has_bits_[0], other->_has_bits_[0]);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  std::swap(_cached_size_, other->_cached_size_);
}

::std::string BackgroundFetchRegistration::GetTypeName() const {
  return "content.proto.BackgroundFetchRegistration";
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BackgroundFetchRegistration

// optional string unique_id = 1;
bool BackgroundFetchRegistration::has_unique_id() const {
  return (_has_bits_[0] & 0x00000001u) != 0;
}
void BackgroundFetchRegistration::set_has_unique_id() {
  _has_bits_[0] |= 0x00000001u;
}
void BackgroundFetchRegistration::clear_has_unique_id() {
  _has_bits_[0] &= ~0x00000001u;
}
void BackgroundFetchRegistration::clear_unique_id() {
  unique_id_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_unique_id();
}
const ::std::string& BackgroundFetchRegistration::unique_id() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchRegistration.unique_id)
  return unique_id_.GetNoArena();
}
void BackgroundFetchRegistration::set_unique_id(const ::std::string& value) {
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchRegistration.unique_id)
}
#if LANG_CXX11
void BackgroundFetchRegistration::set_unique_id(::std::string&& value) {
  set_has_unique_id();
  unique_id_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchRegistration.unique_id)
}
#endif
void BackgroundFetchRegistration::set_unique_id(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchRegistration.unique_id)
}
void BackgroundFetchRegistration::set_unique_id(const char* value, size_t size) {
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchRegistration.unique_id)
}
::std::string* BackgroundFetchRegistration::mutable_unique_id() {
  set_has_unique_id();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchRegistration.unique_id)
  return unique_id_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchRegistration::release_unique_id() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchRegistration.unique_id)
  clear_has_unique_id();
  return unique_id_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchRegistration::set_allocated_unique_id(::std::string* unique_id) {
  if (unique_id != NULL) {
    set_has_unique_id();
  } else {
    clear_has_unique_id();
  }
  unique_id_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), unique_id);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchRegistration.unique_id)
}

// optional bytes developer_id = 2;
bool BackgroundFetchRegistration::has_developer_id() const {
  return (_has_bits_[0] & 0x00000002u) != 0;
}
void BackgroundFetchRegistration::set_has_developer_id() {
  _has_bits_[0] |= 0x00000002u;
}
void BackgroundFetchRegistration::clear_has_developer_id() {
  _has_bits_[0] &= ~0x00000002u;
}
void BackgroundFetchRegistration::clear_developer_id() {
  developer_id_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_developer_id();
}
const ::std::string& BackgroundFetchRegistration::developer_id() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchRegistration.developer_id)
  return developer_id_.GetNoArena();
}
void BackgroundFetchRegistration::set_developer_id(const ::std::string& value) {
  set_has_developer_id();
  developer_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchRegistration.developer_id)
}
#if LANG_CXX11
void BackgroundFetchRegistration::set_developer_id(::std::string&& value) {
  set_has_developer_id();
  developer_id_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchRegistration.developer_id)
}
#endif
void BackgroundFetchRegistration::set_developer_id(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_developer_id();
  developer_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchRegistration.developer_id)
}
void BackgroundFetchRegistration::set_developer_id(const void* value, size_t size) {
  set_has_developer_id();
  developer_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchRegistration.developer_id)
}
::std::string* BackgroundFetchRegistration::mutable_developer_id() {
  set_has_developer_id();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchRegistration.developer_id)
  return developer_id_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchRegistration::release_developer_id() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchRegistration.developer_id)
  clear_has_developer_id();
  return developer_id_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchRegistration::set_allocated_developer_id(::std::string* developer_id) {
  if (developer_id != NULL) {
    set_has_developer_id();
  } else {
    clear_has_developer_id();
  }
  developer_id_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), developer_id);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchRegistration.developer_id)
}

// optional uint64 upload_total = 3;
bool BackgroundFetchRegistration::has_upload_total() const {
  return (_has_bits_[0] & 0x00000004u) != 0;
}
void BackgroundFetchRegistration::set_has_upload_total() {
  _has_bits_[0] |= 0x00000004u;
}
void BackgroundFetchRegistration::clear_has_upload_total() {
  _has_bits_[0] &= ~0x00000004u;
}
void BackgroundFetchRegistration::clear_upload_total() {
  upload_total_ = GOOGLE_ULONGLONG(0);
  clear_has_upload_total();
}
::google::protobuf::uint64 BackgroundFetchRegistration::upload_total() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchRegistration.upload_total)
  return upload_total_;
}
void BackgroundFetchRegistration::set_upload_total(::google::protobuf::uint64 value) {
  set_has_upload_total();
  upload_total_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchRegistration.upload_total)
}

// optional uint64 uploaded = 4;
bool BackgroundFetchRegistration::has_uploaded() const {
  return (_has_bits_[0] & 0x00000008u) != 0;
}
void BackgroundFetchRegistration::set_has_uploaded() {
  _has_bits_[0] |= 0x00000008u;
}
void BackgroundFetchRegistration::clear_has_uploaded() {
  _has_bits_[0] &= ~0x00000008u;
}
void BackgroundFetchRegistration::clear_uploaded() {
  uploaded_ = GOOGLE_ULONGLONG(0);
  clear_has_uploaded();
}
::google::protobuf::uint64 BackgroundFetchRegistration::uploaded() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchRegistration.uploaded)
  return uploaded_;
}
void BackgroundFetchRegistration::set_uploaded(::google::protobuf::uint64 value) {
  set_has_uploaded();
  uploaded_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchRegistration.uploaded)
}

// optional uint64 download_total = 5;
bool BackgroundFetchRegistration::has_download_total() const {
  return (_has_bits_[0] & 0x00000010u) != 0;
}
void BackgroundFetchRegistration::set_has_download_total() {
  _has_bits_[0] |= 0x00000010u;
}
void BackgroundFetchRegistration::clear_has_download_total() {
  _has_bits_[0] &= ~0x00000010u;
}
void BackgroundFetchRegistration::clear_download_total() {
  download_total_ = GOOGLE_ULONGLONG(0);
  clear_has_download_total();
}
::google::protobuf::uint64 BackgroundFetchRegistration::download_total() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchRegistration.download_total)
  return download_total_;
}
void BackgroundFetchRegistration::set_download_total(::google::protobuf::uint64 value) {
  set_has_download_total();
  download_total_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchRegistration.download_total)
}

// optional uint64 downloaded = 6;
bool BackgroundFetchRegistration::has_downloaded() const {
  return (_has_bits_[0] & 0x00000020u) != 0;
}
void BackgroundFetchRegistration::set_has_downloaded() {
  _has_bits_[0] |= 0x00000020u;
}
void BackgroundFetchRegistration::clear_has_downloaded() {
  _has_bits_[0] &= ~0x00000020u;
}
void BackgroundFetchRegistration::clear_downloaded() {
  downloaded_ = GOOGLE_ULONGLONG(0);
  clear_has_downloaded();
}
::google::protobuf::uint64 BackgroundFetchRegistration::downloaded() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchRegistration.downloaded)
  return downloaded_;
}
void BackgroundFetchRegistration::set_downloaded(::google::protobuf::uint64 value) {
  set_has_downloaded();
  downloaded_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchRegistration.downloaded)
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

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

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BackgroundFetchOptions_ImageResource_Size::kWidthFieldNumber;
const int BackgroundFetchOptions_ImageResource_Size::kHeightFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

BackgroundFetchOptions_ImageResource_Size::BackgroundFetchOptions_ImageResource_Size()
  : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_background_5ffetch_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:content.proto.BackgroundFetchOptions.ImageResource.Size)
}
BackgroundFetchOptions_ImageResource_Size::BackgroundFetchOptions_ImageResource_Size(const BackgroundFetchOptions_ImageResource_Size& from)
  : ::google::protobuf::MessageLite(),
      _internal_metadata_(NULL),
      _has_bits_(from._has_bits_),
      _cached_size_(0) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::memcpy(&width_, &from.width_,
    static_cast<size_t>(reinterpret_cast<char*>(&height_) -
    reinterpret_cast<char*>(&width_)) + sizeof(height_));
  // @@protoc_insertion_point(copy_constructor:content.proto.BackgroundFetchOptions.ImageResource.Size)
}

void BackgroundFetchOptions_ImageResource_Size::SharedCtor() {
  _cached_size_ = 0;
  ::memset(&width_, 0, static_cast<size_t>(
      reinterpret_cast<char*>(&height_) -
      reinterpret_cast<char*>(&width_)) + sizeof(height_));
}

BackgroundFetchOptions_ImageResource_Size::~BackgroundFetchOptions_ImageResource_Size() {
  // @@protoc_insertion_point(destructor:content.proto.BackgroundFetchOptions.ImageResource.Size)
  SharedDtor();
}

void BackgroundFetchOptions_ImageResource_Size::SharedDtor() {
}

void BackgroundFetchOptions_ImageResource_Size::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const BackgroundFetchOptions_ImageResource_Size& BackgroundFetchOptions_ImageResource_Size::default_instance() {
  protobuf_background_5ffetch_2eproto::InitDefaults();
  return *internal_default_instance();
}

BackgroundFetchOptions_ImageResource_Size* BackgroundFetchOptions_ImageResource_Size::New(::google::protobuf::Arena* arena) const {
  BackgroundFetchOptions_ImageResource_Size* n = new BackgroundFetchOptions_ImageResource_Size;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void BackgroundFetchOptions_ImageResource_Size::Clear() {
// @@protoc_insertion_point(message_clear_start:content.proto.BackgroundFetchOptions.ImageResource.Size)
  if (_has_bits_[0 / 32] & 3u) {
    ::memset(&width_, 0, static_cast<size_t>(
        reinterpret_cast<char*>(&height_) -
        reinterpret_cast<char*>(&width_)) + sizeof(height_));
  }
  _has_bits_.Clear();
  _internal_metadata_.Clear();
}

bool BackgroundFetchOptions_ImageResource_Size::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  ::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
      ::google::protobuf::NewPermanentCallback(&_internal_metadata_,
          &::google::protobuf::internal::InternalMetadataWithArenaLite::
              mutable_unknown_fields));
  ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
      &unknown_fields_string, false);
  // @@protoc_insertion_point(parse_start:content.proto.BackgroundFetchOptions.ImageResource.Size)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional int32 width = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(8u)) {
          set_has_width();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &width_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional int32 height = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(16u)) {
          set_has_height();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &height_)));
        } else {
          goto handle_unusual;
        }
        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:content.proto.BackgroundFetchOptions.ImageResource.Size)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:content.proto.BackgroundFetchOptions.ImageResource.Size)
  return false;
#undef DO_
}

void BackgroundFetchOptions_ImageResource_Size::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:content.proto.BackgroundFetchOptions.ImageResource.Size)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  // optional int32 width = 1;
  if (cached_has_bits & 0x00000001u) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->width(), output);
  }

  // optional int32 height = 2;
  if (cached_has_bits & 0x00000002u) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->height(), output);
  }

  output->WriteRaw(unknown_fields().data(),
                   static_cast<int>(unknown_fields().size()));
  // @@protoc_insertion_point(serialize_end:content.proto.BackgroundFetchOptions.ImageResource.Size)
}

size_t BackgroundFetchOptions_ImageResource_Size::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:content.proto.BackgroundFetchOptions.ImageResource.Size)
  size_t total_size = 0;

  total_size += unknown_fields().size();

  if (_has_bits_[0 / 32] & 3u) {
    // optional int32 width = 1;
    if (has_width()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::Int32Size(
          this->width());
    }

    // optional int32 height = 2;
    if (has_height()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::Int32Size(
          this->height());
    }

  }
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BackgroundFetchOptions_ImageResource_Size::CheckTypeAndMergeFrom(
    const ::google::protobuf::MessageLite& from) {
  MergeFrom(*::google::protobuf::down_cast<const BackgroundFetchOptions_ImageResource_Size*>(&from));
}

void BackgroundFetchOptions_ImageResource_Size::MergeFrom(const BackgroundFetchOptions_ImageResource_Size& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:content.proto.BackgroundFetchOptions.ImageResource.Size)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 3u) {
    if (cached_has_bits & 0x00000001u) {
      width_ = from.width_;
    }
    if (cached_has_bits & 0x00000002u) {
      height_ = from.height_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
}

void BackgroundFetchOptions_ImageResource_Size::CopyFrom(const BackgroundFetchOptions_ImageResource_Size& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:content.proto.BackgroundFetchOptions.ImageResource.Size)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void BackgroundFetchOptions_ImageResource_Size::Swap(BackgroundFetchOptions_ImageResource_Size* other) {
  if (other == this) return;
  InternalSwap(other);
}
void BackgroundFetchOptions_ImageResource_Size::InternalSwap(BackgroundFetchOptions_ImageResource_Size* other) {
  std::swap(width_, other->width_);
  std::swap(height_, other->height_);
  std::swap(_has_bits_[0], other->_has_bits_[0]);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  std::swap(_cached_size_, other->_cached_size_);
}

::std::string BackgroundFetchOptions_ImageResource_Size::GetTypeName() const {
  return "content.proto.BackgroundFetchOptions.ImageResource.Size";
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BackgroundFetchOptions_ImageResource_Size

// optional int32 width = 1;
bool BackgroundFetchOptions_ImageResource_Size::has_width() const {
  return (_has_bits_[0] & 0x00000001u) != 0;
}
void BackgroundFetchOptions_ImageResource_Size::set_has_width() {
  _has_bits_[0] |= 0x00000001u;
}
void BackgroundFetchOptions_ImageResource_Size::clear_has_width() {
  _has_bits_[0] &= ~0x00000001u;
}
void BackgroundFetchOptions_ImageResource_Size::clear_width() {
  width_ = 0;
  clear_has_width();
}
::google::protobuf::int32 BackgroundFetchOptions_ImageResource_Size::width() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.ImageResource.Size.width)
  return width_;
}
void BackgroundFetchOptions_ImageResource_Size::set_width(::google::protobuf::int32 value) {
  set_has_width();
  width_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchOptions.ImageResource.Size.width)
}

// optional int32 height = 2;
bool BackgroundFetchOptions_ImageResource_Size::has_height() const {
  return (_has_bits_[0] & 0x00000002u) != 0;
}
void BackgroundFetchOptions_ImageResource_Size::set_has_height() {
  _has_bits_[0] |= 0x00000002u;
}
void BackgroundFetchOptions_ImageResource_Size::clear_has_height() {
  _has_bits_[0] &= ~0x00000002u;
}
void BackgroundFetchOptions_ImageResource_Size::clear_height() {
  height_ = 0;
  clear_has_height();
}
::google::protobuf::int32 BackgroundFetchOptions_ImageResource_Size::height() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.ImageResource.Size.height)
  return height_;
}
void BackgroundFetchOptions_ImageResource_Size::set_height(::google::protobuf::int32 value) {
  set_has_height();
  height_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchOptions.ImageResource.Size.height)
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

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

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BackgroundFetchOptions_ImageResource::kSrcFieldNumber;
const int BackgroundFetchOptions_ImageResource::kSizesFieldNumber;
const int BackgroundFetchOptions_ImageResource::kTypeFieldNumber;
const int BackgroundFetchOptions_ImageResource::kPurposeFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

BackgroundFetchOptions_ImageResource::BackgroundFetchOptions_ImageResource()
  : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_background_5ffetch_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:content.proto.BackgroundFetchOptions.ImageResource)
}
BackgroundFetchOptions_ImageResource::BackgroundFetchOptions_ImageResource(const BackgroundFetchOptions_ImageResource& from)
  : ::google::protobuf::MessageLite(),
      _internal_metadata_(NULL),
      _has_bits_(from._has_bits_),
      _cached_size_(0),
      sizes_(from.sizes_),
      purpose_(from.purpose_) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  src_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_src()) {
    src_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.src_);
  }
  type_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_type()) {
    type_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.type_);
  }
  // @@protoc_insertion_point(copy_constructor:content.proto.BackgroundFetchOptions.ImageResource)
}

void BackgroundFetchOptions_ImageResource::SharedCtor() {
  _cached_size_ = 0;
  src_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  type_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}

BackgroundFetchOptions_ImageResource::~BackgroundFetchOptions_ImageResource() {
  // @@protoc_insertion_point(destructor:content.proto.BackgroundFetchOptions.ImageResource)
  SharedDtor();
}

void BackgroundFetchOptions_ImageResource::SharedDtor() {
  src_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  type_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}

void BackgroundFetchOptions_ImageResource::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const BackgroundFetchOptions_ImageResource& BackgroundFetchOptions_ImageResource::default_instance() {
  protobuf_background_5ffetch_2eproto::InitDefaults();
  return *internal_default_instance();
}

BackgroundFetchOptions_ImageResource* BackgroundFetchOptions_ImageResource::New(::google::protobuf::Arena* arena) const {
  BackgroundFetchOptions_ImageResource* n = new BackgroundFetchOptions_ImageResource;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void BackgroundFetchOptions_ImageResource::Clear() {
// @@protoc_insertion_point(message_clear_start:content.proto.BackgroundFetchOptions.ImageResource)
  sizes_.Clear();
  purpose_.Clear();
  if (_has_bits_[0 / 32] & 3u) {
    if (has_src()) {
      GOOGLE_DCHECK(!src_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*src_.UnsafeRawStringPointer())->clear();
    }
    if (has_type()) {
      GOOGLE_DCHECK(!type_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*type_.UnsafeRawStringPointer())->clear();
    }
  }
  _has_bits_.Clear();
  _internal_metadata_.Clear();
}

bool BackgroundFetchOptions_ImageResource::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  ::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
      ::google::protobuf::NewPermanentCallback(&_internal_metadata_,
          &::google::protobuf::internal::InternalMetadataWithArenaLite::
              mutable_unknown_fields));
  ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
      &unknown_fields_string, false);
  // @@protoc_insertion_point(parse_start:content.proto.BackgroundFetchOptions.ImageResource)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional string src = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(10u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_src()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // repeated .content.proto.BackgroundFetchOptions.ImageResource.Size sizes = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(18u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
                input, add_sizes()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional bytes type = 3;
      case 3: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(26u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
                input, this->mutable_type()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // repeated .content.proto.BackgroundFetchOptions.ImageResource.Purpose purpose = 4;
      case 4: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(32u)) {
          int value;
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
                 input, &value)));
          if (::content::proto::BackgroundFetchOptions_ImageResource_Purpose_IsValid(value)) {
            add_purpose(static_cast< ::content::proto::BackgroundFetchOptions_ImageResource_Purpose >(value));
          } else {
            unknown_fields_stream.WriteVarint32(tag);
            unknown_fields_stream.WriteVarint32(
                static_cast< ::google::protobuf::uint32>(value));
          }
        } else if (static_cast< ::google::protobuf::uint8>(tag) ==
                   static_cast< ::google::protobuf::uint8>(34u)) {
          DO_((::google::protobuf::internal::WireFormatLite::ReadPackedEnumPreserveUnknowns(
                 input,
                 4,
                 ::content::proto::BackgroundFetchOptions_ImageResource_Purpose_IsValid,
                 &unknown_fields_stream,
                 this->mutable_purpose())));
        } else {
          goto handle_unusual;
        }
        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:content.proto.BackgroundFetchOptions.ImageResource)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:content.proto.BackgroundFetchOptions.ImageResource)
  return false;
#undef DO_
}

void BackgroundFetchOptions_ImageResource::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:content.proto.BackgroundFetchOptions.ImageResource)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  // optional string src = 1;
  if (cached_has_bits & 0x00000001u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      1, this->src(), output);
  }

  // repeated .content.proto.BackgroundFetchOptions.ImageResource.Size sizes = 2;
  for (unsigned int i = 0,
      n = static_cast<unsigned int>(this->sizes_size()); i < n; i++) {
    ::google::protobuf::internal::WireFormatLite::WriteMessage(
      2, this->sizes(static_cast<int>(i)), output);
  }

  // optional bytes type = 3;
  if (cached_has_bits & 0x00000002u) {
    ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased(
      3, this->type(), output);
  }

  // repeated .content.proto.BackgroundFetchOptions.ImageResource.Purpose purpose = 4;
  for (int i = 0, n = this->purpose_size(); i < n; i++) {
    ::google::protobuf::internal::WireFormatLite::WriteEnum(
      4, this->purpose(i), output);
  }

  output->WriteRaw(unknown_fields().data(),
                   static_cast<int>(unknown_fields().size()));
  // @@protoc_insertion_point(serialize_end:content.proto.BackgroundFetchOptions.ImageResource)
}

size_t BackgroundFetchOptions_ImageResource::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:content.proto.BackgroundFetchOptions.ImageResource)
  size_t total_size = 0;

  total_size += unknown_fields().size();

  // repeated .content.proto.BackgroundFetchOptions.ImageResource.Size sizes = 2;
  {
    unsigned int count = static_cast<unsigned int>(this->sizes_size());
    total_size += 1UL * count;
    for (unsigned int i = 0; i < count; i++) {
      total_size +=
        ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
          this->sizes(static_cast<int>(i)));
    }
  }

  // repeated .content.proto.BackgroundFetchOptions.ImageResource.Purpose purpose = 4;
  {
    size_t data_size = 0;
    unsigned int count = static_cast<unsigned int>(this->purpose_size());for (unsigned int i = 0; i < count; i++) {
      data_size += ::google::protobuf::internal::WireFormatLite::EnumSize(
        this->purpose(static_cast<int>(i)));
    }
    total_size += (1UL * count) + data_size;
  }

  if (_has_bits_[0 / 32] & 3u) {
    // optional string src = 1;
    if (has_src()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->src());
    }

    // optional bytes type = 3;
    if (has_type()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::BytesSize(
          this->type());
    }

  }
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BackgroundFetchOptions_ImageResource::CheckTypeAndMergeFrom(
    const ::google::protobuf::MessageLite& from) {
  MergeFrom(*::google::protobuf::down_cast<const BackgroundFetchOptions_ImageResource*>(&from));
}

void BackgroundFetchOptions_ImageResource::MergeFrom(const BackgroundFetchOptions_ImageResource& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:content.proto.BackgroundFetchOptions.ImageResource)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  sizes_.MergeFrom(from.sizes_);
  purpose_.MergeFrom(from.purpose_);
  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 3u) {
    if (cached_has_bits & 0x00000001u) {
      set_has_src();
      src_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.src_);
    }
    if (cached_has_bits & 0x00000002u) {
      set_has_type();
      type_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.type_);
    }
  }
}

void BackgroundFetchOptions_ImageResource::CopyFrom(const BackgroundFetchOptions_ImageResource& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:content.proto.BackgroundFetchOptions.ImageResource)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void BackgroundFetchOptions_ImageResource::Swap(BackgroundFetchOptions_ImageResource* other) {
  if (other == this) return;
  InternalSwap(other);
}
void BackgroundFetchOptions_ImageResource::InternalSwap(BackgroundFetchOptions_ImageResource* other) {
  sizes_.InternalSwap(&other->sizes_);
  purpose_.InternalSwap(&other->purpose_);
  src_.Swap(&other->src_);
  type_.Swap(&other->type_);
  std::swap(_has_bits_[0], other->_has_bits_[0]);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  std::swap(_cached_size_, other->_cached_size_);
}

::std::string BackgroundFetchOptions_ImageResource::GetTypeName() const {
  return "content.proto.BackgroundFetchOptions.ImageResource";
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BackgroundFetchOptions_ImageResource

// optional string src = 1;
bool BackgroundFetchOptions_ImageResource::has_src() const {
  return (_has_bits_[0] & 0x00000001u) != 0;
}
void BackgroundFetchOptions_ImageResource::set_has_src() {
  _has_bits_[0] |= 0x00000001u;
}
void BackgroundFetchOptions_ImageResource::clear_has_src() {
  _has_bits_[0] &= ~0x00000001u;
}
void BackgroundFetchOptions_ImageResource::clear_src() {
  src_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_src();
}
const ::std::string& BackgroundFetchOptions_ImageResource::src() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.ImageResource.src)
  return src_.GetNoArena();
}
void BackgroundFetchOptions_ImageResource::set_src(const ::std::string& value) {
  set_has_src();
  src_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchOptions.ImageResource.src)
}
#if LANG_CXX11
void BackgroundFetchOptions_ImageResource::set_src(::std::string&& value) {
  set_has_src();
  src_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchOptions.ImageResource.src)
}
#endif
void BackgroundFetchOptions_ImageResource::set_src(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_src();
  src_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchOptions.ImageResource.src)
}
void BackgroundFetchOptions_ImageResource::set_src(const char* value, size_t size) {
  set_has_src();
  src_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchOptions.ImageResource.src)
}
::std::string* BackgroundFetchOptions_ImageResource::mutable_src() {
  set_has_src();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchOptions.ImageResource.src)
  return src_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchOptions_ImageResource::release_src() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchOptions.ImageResource.src)
  clear_has_src();
  return src_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchOptions_ImageResource::set_allocated_src(::std::string* src) {
  if (src != NULL) {
    set_has_src();
  } else {
    clear_has_src();
  }
  src_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), src);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchOptions.ImageResource.src)
}

// repeated .content.proto.BackgroundFetchOptions.ImageResource.Size sizes = 2;
int BackgroundFetchOptions_ImageResource::sizes_size() const {
  return sizes_.size();
}
void BackgroundFetchOptions_ImageResource::clear_sizes() {
  sizes_.Clear();
}
const ::content::proto::BackgroundFetchOptions_ImageResource_Size& BackgroundFetchOptions_ImageResource::sizes(int index) const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.ImageResource.sizes)
  return sizes_.Get(index);
}
::content::proto::BackgroundFetchOptions_ImageResource_Size* BackgroundFetchOptions_ImageResource::mutable_sizes(int index) {
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchOptions.ImageResource.sizes)
  return sizes_.Mutable(index);
}
::content::proto::BackgroundFetchOptions_ImageResource_Size* BackgroundFetchOptions_ImageResource::add_sizes() {
  // @@protoc_insertion_point(field_add:content.proto.BackgroundFetchOptions.ImageResource.sizes)
  return sizes_.Add();
}
::google::protobuf::RepeatedPtrField< ::content::proto::BackgroundFetchOptions_ImageResource_Size >*
BackgroundFetchOptions_ImageResource::mutable_sizes() {
  // @@protoc_insertion_point(field_mutable_list:content.proto.BackgroundFetchOptions.ImageResource.sizes)
  return &sizes_;
}
const ::google::protobuf::RepeatedPtrField< ::content::proto::BackgroundFetchOptions_ImageResource_Size >&
BackgroundFetchOptions_ImageResource::sizes() const {
  // @@protoc_insertion_point(field_list:content.proto.BackgroundFetchOptions.ImageResource.sizes)
  return sizes_;
}

// optional bytes type = 3;
bool BackgroundFetchOptions_ImageResource::has_type() const {
  return (_has_bits_[0] & 0x00000002u) != 0;
}
void BackgroundFetchOptions_ImageResource::set_has_type() {
  _has_bits_[0] |= 0x00000002u;
}
void BackgroundFetchOptions_ImageResource::clear_has_type() {
  _has_bits_[0] &= ~0x00000002u;
}
void BackgroundFetchOptions_ImageResource::clear_type() {
  type_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_type();
}
const ::std::string& BackgroundFetchOptions_ImageResource::type() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.ImageResource.type)
  return type_.GetNoArena();
}
void BackgroundFetchOptions_ImageResource::set_type(const ::std::string& value) {
  set_has_type();
  type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchOptions.ImageResource.type)
}
#if LANG_CXX11
void BackgroundFetchOptions_ImageResource::set_type(::std::string&& value) {
  set_has_type();
  type_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchOptions.ImageResource.type)
}
#endif
void BackgroundFetchOptions_ImageResource::set_type(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_type();
  type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchOptions.ImageResource.type)
}
void BackgroundFetchOptions_ImageResource::set_type(const void* value, size_t size) {
  set_has_type();
  type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchOptions.ImageResource.type)
}
::std::string* BackgroundFetchOptions_ImageResource::mutable_type() {
  set_has_type();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchOptions.ImageResource.type)
  return type_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchOptions_ImageResource::release_type() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchOptions.ImageResource.type)
  clear_has_type();
  return type_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchOptions_ImageResource::set_allocated_type(::std::string* type) {
  if (type != NULL) {
    set_has_type();
  } else {
    clear_has_type();
  }
  type_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), type);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchOptions.ImageResource.type)
}

// repeated .content.proto.BackgroundFetchOptions.ImageResource.Purpose purpose = 4;
int BackgroundFetchOptions_ImageResource::purpose_size() const {
  return purpose_.size();
}
void BackgroundFetchOptions_ImageResource::clear_purpose() {
  purpose_.Clear();
}
::content::proto::BackgroundFetchOptions_ImageResource_Purpose BackgroundFetchOptions_ImageResource::purpose(int index) const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.ImageResource.purpose)
  return static_cast< ::content::proto::BackgroundFetchOptions_ImageResource_Purpose >(purpose_.Get(index));
}
void BackgroundFetchOptions_ImageResource::set_purpose(int index, ::content::proto::BackgroundFetchOptions_ImageResource_Purpose value) {
  assert(::content::proto::BackgroundFetchOptions_ImageResource_Purpose_IsValid(value));
  purpose_.Set(index, value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchOptions.ImageResource.purpose)
}
void BackgroundFetchOptions_ImageResource::add_purpose(::content::proto::BackgroundFetchOptions_ImageResource_Purpose value) {
  assert(::content::proto::BackgroundFetchOptions_ImageResource_Purpose_IsValid(value));
  purpose_.Add(value);
  // @@protoc_insertion_point(field_add:content.proto.BackgroundFetchOptions.ImageResource.purpose)
}
const ::google::protobuf::RepeatedField<int>&
BackgroundFetchOptions_ImageResource::purpose() const {
  // @@protoc_insertion_point(field_list:content.proto.BackgroundFetchOptions.ImageResource.purpose)
  return purpose_;
}
::google::protobuf::RepeatedField<int>*
BackgroundFetchOptions_ImageResource::mutable_purpose() {
  // @@protoc_insertion_point(field_mutable_list:content.proto.BackgroundFetchOptions.ImageResource.purpose)
  return &purpose_;
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

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

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BackgroundFetchOptions::kTitleFieldNumber;
const int BackgroundFetchOptions::kIconsFieldNumber;
const int BackgroundFetchOptions::kDownloadTotalFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

BackgroundFetchOptions::BackgroundFetchOptions()
  : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_background_5ffetch_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:content.proto.BackgroundFetchOptions)
}
BackgroundFetchOptions::BackgroundFetchOptions(const BackgroundFetchOptions& from)
  : ::google::protobuf::MessageLite(),
      _internal_metadata_(NULL),
      _has_bits_(from._has_bits_),
      _cached_size_(0),
      icons_(from.icons_) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  title_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_title()) {
    title_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.title_);
  }
  download_total_ = from.download_total_;
  // @@protoc_insertion_point(copy_constructor:content.proto.BackgroundFetchOptions)
}

void BackgroundFetchOptions::SharedCtor() {
  _cached_size_ = 0;
  title_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  download_total_ = GOOGLE_ULONGLONG(0);
}

BackgroundFetchOptions::~BackgroundFetchOptions() {
  // @@protoc_insertion_point(destructor:content.proto.BackgroundFetchOptions)
  SharedDtor();
}

void BackgroundFetchOptions::SharedDtor() {
  title_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}

void BackgroundFetchOptions::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const BackgroundFetchOptions& BackgroundFetchOptions::default_instance() {
  protobuf_background_5ffetch_2eproto::InitDefaults();
  return *internal_default_instance();
}

BackgroundFetchOptions* BackgroundFetchOptions::New(::google::protobuf::Arena* arena) const {
  BackgroundFetchOptions* n = new BackgroundFetchOptions;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void BackgroundFetchOptions::Clear() {
// @@protoc_insertion_point(message_clear_start:content.proto.BackgroundFetchOptions)
  icons_.Clear();
  if (has_title()) {
    GOOGLE_DCHECK(!title_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
    (*title_.UnsafeRawStringPointer())->clear();
  }
  download_total_ = GOOGLE_ULONGLONG(0);
  _has_bits_.Clear();
  _internal_metadata_.Clear();
}

bool BackgroundFetchOptions::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  ::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
      ::google::protobuf::NewPermanentCallback(&_internal_metadata_,
          &::google::protobuf::internal::InternalMetadataWithArenaLite::
              mutable_unknown_fields));
  ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
      &unknown_fields_string, false);
  // @@protoc_insertion_point(parse_start:content.proto.BackgroundFetchOptions)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional string title = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(10u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_title()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // repeated .content.proto.BackgroundFetchOptions.ImageResource icons = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(18u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
                input, add_icons()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional uint64 download_total = 3;
      case 3: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(24u)) {
          set_has_download_total();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>(
                 input, &download_total_)));
        } else {
          goto handle_unusual;
        }
        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:content.proto.BackgroundFetchOptions)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:content.proto.BackgroundFetchOptions)
  return false;
#undef DO_
}

void BackgroundFetchOptions::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:content.proto.BackgroundFetchOptions)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  // optional string title = 1;
  if (cached_has_bits & 0x00000001u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      1, this->title(), output);
  }

  // repeated .content.proto.BackgroundFetchOptions.ImageResource icons = 2;
  for (unsigned int i = 0,
      n = static_cast<unsigned int>(this->icons_size()); i < n; i++) {
    ::google::protobuf::internal::WireFormatLite::WriteMessage(
      2, this->icons(static_cast<int>(i)), output);
  }

  // optional uint64 download_total = 3;
  if (cached_has_bits & 0x00000002u) {
    ::google::protobuf::internal::WireFormatLite::WriteUInt64(3, this->download_total(), output);
  }

  output->WriteRaw(unknown_fields().data(),
                   static_cast<int>(unknown_fields().size()));
  // @@protoc_insertion_point(serialize_end:content.proto.BackgroundFetchOptions)
}

size_t BackgroundFetchOptions::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:content.proto.BackgroundFetchOptions)
  size_t total_size = 0;

  total_size += unknown_fields().size();

  // repeated .content.proto.BackgroundFetchOptions.ImageResource icons = 2;
  {
    unsigned int count = static_cast<unsigned int>(this->icons_size());
    total_size += 1UL * count;
    for (unsigned int i = 0; i < count; i++) {
      total_size +=
        ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
          this->icons(static_cast<int>(i)));
    }
  }

  if (_has_bits_[0 / 32] & 3u) {
    // optional string title = 1;
    if (has_title()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->title());
    }

    // optional uint64 download_total = 3;
    if (has_download_total()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::UInt64Size(
          this->download_total());
    }

  }
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BackgroundFetchOptions::CheckTypeAndMergeFrom(
    const ::google::protobuf::MessageLite& from) {
  MergeFrom(*::google::protobuf::down_cast<const BackgroundFetchOptions*>(&from));
}

void BackgroundFetchOptions::MergeFrom(const BackgroundFetchOptions& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:content.proto.BackgroundFetchOptions)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  icons_.MergeFrom(from.icons_);
  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 3u) {
    if (cached_has_bits & 0x00000001u) {
      set_has_title();
      title_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.title_);
    }
    if (cached_has_bits & 0x00000002u) {
      download_total_ = from.download_total_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
}

void BackgroundFetchOptions::CopyFrom(const BackgroundFetchOptions& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:content.proto.BackgroundFetchOptions)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void BackgroundFetchOptions::Swap(BackgroundFetchOptions* other) {
  if (other == this) return;
  InternalSwap(other);
}
void BackgroundFetchOptions::InternalSwap(BackgroundFetchOptions* other) {
  icons_.InternalSwap(&other->icons_);
  title_.Swap(&other->title_);
  std::swap(download_total_, other->download_total_);
  std::swap(_has_bits_[0], other->_has_bits_[0]);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  std::swap(_cached_size_, other->_cached_size_);
}

::std::string BackgroundFetchOptions::GetTypeName() const {
  return "content.proto.BackgroundFetchOptions";
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BackgroundFetchOptions

// optional string title = 1;
bool BackgroundFetchOptions::has_title() const {
  return (_has_bits_[0] & 0x00000001u) != 0;
}
void BackgroundFetchOptions::set_has_title() {
  _has_bits_[0] |= 0x00000001u;
}
void BackgroundFetchOptions::clear_has_title() {
  _has_bits_[0] &= ~0x00000001u;
}
void BackgroundFetchOptions::clear_title() {
  title_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_title();
}
const ::std::string& BackgroundFetchOptions::title() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.title)
  return title_.GetNoArena();
}
void BackgroundFetchOptions::set_title(const ::std::string& value) {
  set_has_title();
  title_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchOptions.title)
}
#if LANG_CXX11
void BackgroundFetchOptions::set_title(::std::string&& value) {
  set_has_title();
  title_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchOptions.title)
}
#endif
void BackgroundFetchOptions::set_title(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_title();
  title_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchOptions.title)
}
void BackgroundFetchOptions::set_title(const char* value, size_t size) {
  set_has_title();
  title_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchOptions.title)
}
::std::string* BackgroundFetchOptions::mutable_title() {
  set_has_title();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchOptions.title)
  return title_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchOptions::release_title() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchOptions.title)
  clear_has_title();
  return title_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchOptions::set_allocated_title(::std::string* title) {
  if (title != NULL) {
    set_has_title();
  } else {
    clear_has_title();
  }
  title_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), title);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchOptions.title)
}

// repeated .content.proto.BackgroundFetchOptions.ImageResource icons = 2;
int BackgroundFetchOptions::icons_size() const {
  return icons_.size();
}
void BackgroundFetchOptions::clear_icons() {
  icons_.Clear();
}
const ::content::proto::BackgroundFetchOptions_ImageResource& BackgroundFetchOptions::icons(int index) const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.icons)
  return icons_.Get(index);
}
::content::proto::BackgroundFetchOptions_ImageResource* BackgroundFetchOptions::mutable_icons(int index) {
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchOptions.icons)
  return icons_.Mutable(index);
}
::content::proto::BackgroundFetchOptions_ImageResource* BackgroundFetchOptions::add_icons() {
  // @@protoc_insertion_point(field_add:content.proto.BackgroundFetchOptions.icons)
  return icons_.Add();
}
::google::protobuf::RepeatedPtrField< ::content::proto::BackgroundFetchOptions_ImageResource >*
BackgroundFetchOptions::mutable_icons() {
  // @@protoc_insertion_point(field_mutable_list:content.proto.BackgroundFetchOptions.icons)
  return &icons_;
}
const ::google::protobuf::RepeatedPtrField< ::content::proto::BackgroundFetchOptions_ImageResource >&
BackgroundFetchOptions::icons() const {
  // @@protoc_insertion_point(field_list:content.proto.BackgroundFetchOptions.icons)
  return icons_;
}

// optional uint64 download_total = 3;
bool BackgroundFetchOptions::has_download_total() const {
  return (_has_bits_[0] & 0x00000002u) != 0;
}
void BackgroundFetchOptions::set_has_download_total() {
  _has_bits_[0] |= 0x00000002u;
}
void BackgroundFetchOptions::clear_has_download_total() {
  _has_bits_[0] &= ~0x00000002u;
}
void BackgroundFetchOptions::clear_download_total() {
  download_total_ = GOOGLE_ULONGLONG(0);
  clear_has_download_total();
}
::google::protobuf::uint64 BackgroundFetchOptions::download_total() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchOptions.download_total)
  return download_total_;
}
void BackgroundFetchOptions::set_download_total(::google::protobuf::uint64 value) {
  set_has_download_total();
  download_total_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchOptions.download_total)
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

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

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BackgroundFetchMetadata::kCreationMicrosecondsSinceUnixEpochFieldNumber;
const int BackgroundFetchMetadata::kOriginFieldNumber;
const int BackgroundFetchMetadata::kRegistrationFieldNumber;
const int BackgroundFetchMetadata::kOptionsFieldNumber;
const int BackgroundFetchMetadata::kNumFetchesFieldNumber;
const int BackgroundFetchMetadata::kIconFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

BackgroundFetchMetadata::BackgroundFetchMetadata()
  : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_background_5ffetch_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:content.proto.BackgroundFetchMetadata)
}
BackgroundFetchMetadata::BackgroundFetchMetadata(const BackgroundFetchMetadata& from)
  : ::google::protobuf::MessageLite(),
      _internal_metadata_(NULL),
      _has_bits_(from._has_bits_),
      _cached_size_(0) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  origin_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_origin()) {
    origin_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.origin_);
  }
  icon_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_icon()) {
    icon_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.icon_);
  }
  if (from.has_registration()) {
    registration_ = new ::content::proto::BackgroundFetchRegistration(*from.registration_);
  } else {
    registration_ = NULL;
  }
  if (from.has_options()) {
    options_ = new ::content::proto::BackgroundFetchOptions(*from.options_);
  } else {
    options_ = NULL;
  }
  ::memcpy(&creation_microseconds_since_unix_epoch_, &from.creation_microseconds_since_unix_epoch_,
    static_cast<size_t>(reinterpret_cast<char*>(&num_fetches_) -
    reinterpret_cast<char*>(&creation_microseconds_since_unix_epoch_)) + sizeof(num_fetches_));
  // @@protoc_insertion_point(copy_constructor:content.proto.BackgroundFetchMetadata)
}

void BackgroundFetchMetadata::SharedCtor() {
  _cached_size_ = 0;
  origin_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  icon_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  ::memset(&registration_, 0, static_cast<size_t>(
      reinterpret_cast<char*>(&num_fetches_) -
      reinterpret_cast<char*>(&registration_)) + sizeof(num_fetches_));
}

BackgroundFetchMetadata::~BackgroundFetchMetadata() {
  // @@protoc_insertion_point(destructor:content.proto.BackgroundFetchMetadata)
  SharedDtor();
}

void BackgroundFetchMetadata::SharedDtor() {
  origin_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  icon_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (this != internal_default_instance()) {
    delete registration_;
  }
  if (this != internal_default_instance()) {
    delete options_;
  }
}

void BackgroundFetchMetadata::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const BackgroundFetchMetadata& BackgroundFetchMetadata::default_instance() {
  protobuf_background_5ffetch_2eproto::InitDefaults();
  return *internal_default_instance();
}

BackgroundFetchMetadata* BackgroundFetchMetadata::New(::google::protobuf::Arena* arena) const {
  BackgroundFetchMetadata* n = new BackgroundFetchMetadata;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void BackgroundFetchMetadata::Clear() {
// @@protoc_insertion_point(message_clear_start:content.proto.BackgroundFetchMetadata)
  if (_has_bits_[0 / 32] & 15u) {
    if (has_origin()) {
      GOOGLE_DCHECK(!origin_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*origin_.UnsafeRawStringPointer())->clear();
    }
    if (has_icon()) {
      GOOGLE_DCHECK(!icon_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*icon_.UnsafeRawStringPointer())->clear();
    }
    if (has_registration()) {
      GOOGLE_DCHECK(registration_ != NULL);
      registration_->::content::proto::BackgroundFetchRegistration::Clear();
    }
    if (has_options()) {
      GOOGLE_DCHECK(options_ != NULL);
      options_->::content::proto::BackgroundFetchOptions::Clear();
    }
  }
  if (_has_bits_[0 / 32] & 48u) {
    ::memset(&creation_microseconds_since_unix_epoch_, 0, static_cast<size_t>(
        reinterpret_cast<char*>(&num_fetches_) -
        reinterpret_cast<char*>(&creation_microseconds_since_unix_epoch_)) + sizeof(num_fetches_));
  }
  _has_bits_.Clear();
  _internal_metadata_.Clear();
}

bool BackgroundFetchMetadata::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  ::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
      ::google::protobuf::NewPermanentCallback(&_internal_metadata_,
          &::google::protobuf::internal::InternalMetadataWithArenaLite::
              mutable_unknown_fields));
  ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
      &unknown_fields_string, false);
  // @@protoc_insertion_point(parse_start:content.proto.BackgroundFetchMetadata)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional int64 creation_microseconds_since_unix_epoch = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(8u)) {
          set_has_creation_microseconds_since_unix_epoch();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>(
                 input, &creation_microseconds_since_unix_epoch_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional string origin = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(18u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_origin()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional .content.proto.BackgroundFetchRegistration registration = 3;
      case 3: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(26u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
               input, mutable_registration()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional .content.proto.BackgroundFetchOptions options = 4;
      case 4: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(34u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
               input, mutable_options()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional int32 num_fetches = 5;
      case 5: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(40u)) {
          set_has_num_fetches();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &num_fetches_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional bytes icon = 6;
      case 6: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(50u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
                input, this->mutable_icon()));
        } else {
          goto handle_unusual;
        }
        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:content.proto.BackgroundFetchMetadata)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:content.proto.BackgroundFetchMetadata)
  return false;
#undef DO_
}

void BackgroundFetchMetadata::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:content.proto.BackgroundFetchMetadata)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  // optional int64 creation_microseconds_since_unix_epoch = 1;
  if (cached_has_bits & 0x00000010u) {
    ::google::protobuf::internal::WireFormatLite::WriteInt64(1, this->creation_microseconds_since_unix_epoch(), output);
  }

  // optional string origin = 2;
  if (cached_has_bits & 0x00000001u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      2, this->origin(), output);
  }

  // optional .content.proto.BackgroundFetchRegistration registration = 3;
  if (cached_has_bits & 0x00000004u) {
    ::google::protobuf::internal::WireFormatLite::WriteMessage(
      3, *this->registration_, output);
  }

  // optional .content.proto.BackgroundFetchOptions options = 4;
  if (cached_has_bits & 0x00000008u) {
    ::google::protobuf::internal::WireFormatLite::WriteMessage(
      4, *this->options_, output);
  }

  // optional int32 num_fetches = 5;
  if (cached_has_bits & 0x00000020u) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(5, this->num_fetches(), output);
  }

  // optional bytes icon = 6;
  if (cached_has_bits & 0x00000002u) {
    ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased(
      6, this->icon(), output);
  }

  output->WriteRaw(unknown_fields().data(),
                   static_cast<int>(unknown_fields().size()));
  // @@protoc_insertion_point(serialize_end:content.proto.BackgroundFetchMetadata)
}

size_t BackgroundFetchMetadata::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:content.proto.BackgroundFetchMetadata)
  size_t total_size = 0;

  total_size += unknown_fields().size();

  if (_has_bits_[0 / 32] & 63u) {
    // optional string origin = 2;
    if (has_origin()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->origin());
    }

    // optional bytes icon = 6;
    if (has_icon()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::BytesSize(
          this->icon());
    }

    // optional .content.proto.BackgroundFetchRegistration registration = 3;
    if (has_registration()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
          *this->registration_);
    }

    // optional .content.proto.BackgroundFetchOptions options = 4;
    if (has_options()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
          *this->options_);
    }

    // optional int64 creation_microseconds_since_unix_epoch = 1;
    if (has_creation_microseconds_since_unix_epoch()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::Int64Size(
          this->creation_microseconds_since_unix_epoch());
    }

    // optional int32 num_fetches = 5;
    if (has_num_fetches()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::Int32Size(
          this->num_fetches());
    }

  }
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BackgroundFetchMetadata::CheckTypeAndMergeFrom(
    const ::google::protobuf::MessageLite& from) {
  MergeFrom(*::google::protobuf::down_cast<const BackgroundFetchMetadata*>(&from));
}

void BackgroundFetchMetadata::MergeFrom(const BackgroundFetchMetadata& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:content.proto.BackgroundFetchMetadata)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 63u) {
    if (cached_has_bits & 0x00000001u) {
      set_has_origin();
      origin_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.origin_);
    }
    if (cached_has_bits & 0x00000002u) {
      set_has_icon();
      icon_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.icon_);
    }
    if (cached_has_bits & 0x00000004u) {
      mutable_registration()->::content::proto::BackgroundFetchRegistration::MergeFrom(from.registration());
    }
    if (cached_has_bits & 0x00000008u) {
      mutable_options()->::content::proto::BackgroundFetchOptions::MergeFrom(from.options());
    }
    if (cached_has_bits & 0x00000010u) {
      creation_microseconds_since_unix_epoch_ = from.creation_microseconds_since_unix_epoch_;
    }
    if (cached_has_bits & 0x00000020u) {
      num_fetches_ = from.num_fetches_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
}

void BackgroundFetchMetadata::CopyFrom(const BackgroundFetchMetadata& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:content.proto.BackgroundFetchMetadata)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void BackgroundFetchMetadata::Swap(BackgroundFetchMetadata* other) {
  if (other == this) return;
  InternalSwap(other);
}
void BackgroundFetchMetadata::InternalSwap(BackgroundFetchMetadata* other) {
  origin_.Swap(&other->origin_);
  icon_.Swap(&other->icon_);
  std::swap(registration_, other->registration_);
  std::swap(options_, other->options_);
  std::swap(creation_microseconds_since_unix_epoch_, other->creation_microseconds_since_unix_epoch_);
  std::swap(num_fetches_, other->num_fetches_);
  std::swap(_has_bits_[0], other->_has_bits_[0]);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  std::swap(_cached_size_, other->_cached_size_);
}

::std::string BackgroundFetchMetadata::GetTypeName() const {
  return "content.proto.BackgroundFetchMetadata";
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BackgroundFetchMetadata

// optional int64 creation_microseconds_since_unix_epoch = 1;
bool BackgroundFetchMetadata::has_creation_microseconds_since_unix_epoch() const {
  return (_has_bits_[0] & 0x00000010u) != 0;
}
void BackgroundFetchMetadata::set_has_creation_microseconds_since_unix_epoch() {
  _has_bits_[0] |= 0x00000010u;
}
void BackgroundFetchMetadata::clear_has_creation_microseconds_since_unix_epoch() {
  _has_bits_[0] &= ~0x00000010u;
}
void BackgroundFetchMetadata::clear_creation_microseconds_since_unix_epoch() {
  creation_microseconds_since_unix_epoch_ = GOOGLE_LONGLONG(0);
  clear_has_creation_microseconds_since_unix_epoch();
}
::google::protobuf::int64 BackgroundFetchMetadata::creation_microseconds_since_unix_epoch() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchMetadata.creation_microseconds_since_unix_epoch)
  return creation_microseconds_since_unix_epoch_;
}
void BackgroundFetchMetadata::set_creation_microseconds_since_unix_epoch(::google::protobuf::int64 value) {
  set_has_creation_microseconds_since_unix_epoch();
  creation_microseconds_since_unix_epoch_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchMetadata.creation_microseconds_since_unix_epoch)
}

// optional string origin = 2;
bool BackgroundFetchMetadata::has_origin() const {
  return (_has_bits_[0] & 0x00000001u) != 0;
}
void BackgroundFetchMetadata::set_has_origin() {
  _has_bits_[0] |= 0x00000001u;
}
void BackgroundFetchMetadata::clear_has_origin() {
  _has_bits_[0] &= ~0x00000001u;
}
void BackgroundFetchMetadata::clear_origin() {
  origin_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_origin();
}
const ::std::string& BackgroundFetchMetadata::origin() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchMetadata.origin)
  return origin_.GetNoArena();
}
void BackgroundFetchMetadata::set_origin(const ::std::string& value) {
  set_has_origin();
  origin_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchMetadata.origin)
}
#if LANG_CXX11
void BackgroundFetchMetadata::set_origin(::std::string&& value) {
  set_has_origin();
  origin_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchMetadata.origin)
}
#endif
void BackgroundFetchMetadata::set_origin(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_origin();
  origin_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchMetadata.origin)
}
void BackgroundFetchMetadata::set_origin(const char* value, size_t size) {
  set_has_origin();
  origin_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchMetadata.origin)
}
::std::string* BackgroundFetchMetadata::mutable_origin() {
  set_has_origin();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchMetadata.origin)
  return origin_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchMetadata::release_origin() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchMetadata.origin)
  clear_has_origin();
  return origin_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchMetadata::set_allocated_origin(::std::string* origin) {
  if (origin != NULL) {
    set_has_origin();
  } else {
    clear_has_origin();
  }
  origin_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), origin);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchMetadata.origin)
}

// optional .content.proto.BackgroundFetchRegistration registration = 3;
bool BackgroundFetchMetadata::has_registration() const {
  return (_has_bits_[0] & 0x00000004u) != 0;
}
void BackgroundFetchMetadata::set_has_registration() {
  _has_bits_[0] |= 0x00000004u;
}
void BackgroundFetchMetadata::clear_has_registration() {
  _has_bits_[0] &= ~0x00000004u;
}
void BackgroundFetchMetadata::clear_registration() {
  if (registration_ != NULL) registration_->::content::proto::BackgroundFetchRegistration::Clear();
  clear_has_registration();
}
const ::content::proto::BackgroundFetchRegistration& BackgroundFetchMetadata::registration() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchMetadata.registration)
  return registration_ != NULL ? *registration_
                         : *::content::proto::BackgroundFetchRegistration::internal_default_instance();
}
::content::proto::BackgroundFetchRegistration* BackgroundFetchMetadata::mutable_registration() {
  set_has_registration();
  if (registration_ == NULL) {
    registration_ = new ::content::proto::BackgroundFetchRegistration;
  }
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchMetadata.registration)
  return registration_;
}
::content::proto::BackgroundFetchRegistration* BackgroundFetchMetadata::release_registration() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchMetadata.registration)
  clear_has_registration();
  ::content::proto::BackgroundFetchRegistration* temp = registration_;
  registration_ = NULL;
  return temp;
}
void BackgroundFetchMetadata::set_allocated_registration(::content::proto::BackgroundFetchRegistration* registration) {
  delete registration_;
  registration_ = registration;
  if (registration) {
    set_has_registration();
  } else {
    clear_has_registration();
  }
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchMetadata.registration)
}

// optional .content.proto.BackgroundFetchOptions options = 4;
bool BackgroundFetchMetadata::has_options() const {
  return (_has_bits_[0] & 0x00000008u) != 0;
}
void BackgroundFetchMetadata::set_has_options() {
  _has_bits_[0] |= 0x00000008u;
}
void BackgroundFetchMetadata::clear_has_options() {
  _has_bits_[0] &= ~0x00000008u;
}
void BackgroundFetchMetadata::clear_options() {
  if (options_ != NULL) options_->::content::proto::BackgroundFetchOptions::Clear();
  clear_has_options();
}
const ::content::proto::BackgroundFetchOptions& BackgroundFetchMetadata::options() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchMetadata.options)
  return options_ != NULL ? *options_
                         : *::content::proto::BackgroundFetchOptions::internal_default_instance();
}
::content::proto::BackgroundFetchOptions* BackgroundFetchMetadata::mutable_options() {
  set_has_options();
  if (options_ == NULL) {
    options_ = new ::content::proto::BackgroundFetchOptions;
  }
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchMetadata.options)
  return options_;
}
::content::proto::BackgroundFetchOptions* BackgroundFetchMetadata::release_options() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchMetadata.options)
  clear_has_options();
  ::content::proto::BackgroundFetchOptions* temp = options_;
  options_ = NULL;
  return temp;
}
void BackgroundFetchMetadata::set_allocated_options(::content::proto::BackgroundFetchOptions* options) {
  delete options_;
  options_ = options;
  if (options) {
    set_has_options();
  } else {
    clear_has_options();
  }
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchMetadata.options)
}

// optional int32 num_fetches = 5;
bool BackgroundFetchMetadata::has_num_fetches() const {
  return (_has_bits_[0] & 0x00000020u) != 0;
}
void BackgroundFetchMetadata::set_has_num_fetches() {
  _has_bits_[0] |= 0x00000020u;
}
void BackgroundFetchMetadata::clear_has_num_fetches() {
  _has_bits_[0] &= ~0x00000020u;
}
void BackgroundFetchMetadata::clear_num_fetches() {
  num_fetches_ = 0;
  clear_has_num_fetches();
}
::google::protobuf::int32 BackgroundFetchMetadata::num_fetches() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchMetadata.num_fetches)
  return num_fetches_;
}
void BackgroundFetchMetadata::set_num_fetches(::google::protobuf::int32 value) {
  set_has_num_fetches();
  num_fetches_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchMetadata.num_fetches)
}

// optional bytes icon = 6;
bool BackgroundFetchMetadata::has_icon() const {
  return (_has_bits_[0] & 0x00000002u) != 0;
}
void BackgroundFetchMetadata::set_has_icon() {
  _has_bits_[0] |= 0x00000002u;
}
void BackgroundFetchMetadata::clear_has_icon() {
  _has_bits_[0] &= ~0x00000002u;
}
void BackgroundFetchMetadata::clear_icon() {
  icon_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_icon();
}
const ::std::string& BackgroundFetchMetadata::icon() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchMetadata.icon)
  return icon_.GetNoArena();
}
void BackgroundFetchMetadata::set_icon(const ::std::string& value) {
  set_has_icon();
  icon_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchMetadata.icon)
}
#if LANG_CXX11
void BackgroundFetchMetadata::set_icon(::std::string&& value) {
  set_has_icon();
  icon_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchMetadata.icon)
}
#endif
void BackgroundFetchMetadata::set_icon(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_icon();
  icon_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchMetadata.icon)
}
void BackgroundFetchMetadata::set_icon(const void* value, size_t size) {
  set_has_icon();
  icon_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchMetadata.icon)
}
::std::string* BackgroundFetchMetadata::mutable_icon() {
  set_has_icon();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchMetadata.icon)
  return icon_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchMetadata::release_icon() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchMetadata.icon)
  clear_has_icon();
  return icon_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchMetadata::set_allocated_icon(::std::string* icon) {
  if (icon != NULL) {
    set_has_icon();
  } else {
    clear_has_icon();
  }
  icon_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), icon);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchMetadata.icon)
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

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

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BackgroundFetchPendingRequest::kUniqueIdFieldNumber;
const int BackgroundFetchPendingRequest::kRequestIndexFieldNumber;
const int BackgroundFetchPendingRequest::kSerializedRequestFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

BackgroundFetchPendingRequest::BackgroundFetchPendingRequest()
  : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_background_5ffetch_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:content.proto.BackgroundFetchPendingRequest)
}
BackgroundFetchPendingRequest::BackgroundFetchPendingRequest(const BackgroundFetchPendingRequest& from)
  : ::google::protobuf::MessageLite(),
      _internal_metadata_(NULL),
      _has_bits_(from._has_bits_),
      _cached_size_(0) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  unique_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_unique_id()) {
    unique_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.unique_id_);
  }
  serialized_request_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_serialized_request()) {
    serialized_request_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.serialized_request_);
  }
  request_index_ = from.request_index_;
  // @@protoc_insertion_point(copy_constructor:content.proto.BackgroundFetchPendingRequest)
}

void BackgroundFetchPendingRequest::SharedCtor() {
  _cached_size_ = 0;
  unique_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  serialized_request_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  request_index_ = 0;
}

BackgroundFetchPendingRequest::~BackgroundFetchPendingRequest() {
  // @@protoc_insertion_point(destructor:content.proto.BackgroundFetchPendingRequest)
  SharedDtor();
}

void BackgroundFetchPendingRequest::SharedDtor() {
  unique_id_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  serialized_request_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}

void BackgroundFetchPendingRequest::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const BackgroundFetchPendingRequest& BackgroundFetchPendingRequest::default_instance() {
  protobuf_background_5ffetch_2eproto::InitDefaults();
  return *internal_default_instance();
}

BackgroundFetchPendingRequest* BackgroundFetchPendingRequest::New(::google::protobuf::Arena* arena) const {
  BackgroundFetchPendingRequest* n = new BackgroundFetchPendingRequest;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void BackgroundFetchPendingRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:content.proto.BackgroundFetchPendingRequest)
  if (_has_bits_[0 / 32] & 3u) {
    if (has_unique_id()) {
      GOOGLE_DCHECK(!unique_id_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*unique_id_.UnsafeRawStringPointer())->clear();
    }
    if (has_serialized_request()) {
      GOOGLE_DCHECK(!serialized_request_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*serialized_request_.UnsafeRawStringPointer())->clear();
    }
  }
  request_index_ = 0;
  _has_bits_.Clear();
  _internal_metadata_.Clear();
}

bool BackgroundFetchPendingRequest::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  ::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
      ::google::protobuf::NewPermanentCallback(&_internal_metadata_,
          &::google::protobuf::internal::InternalMetadataWithArenaLite::
              mutable_unknown_fields));
  ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
      &unknown_fields_string, false);
  // @@protoc_insertion_point(parse_start:content.proto.BackgroundFetchPendingRequest)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional string unique_id = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(10u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_unique_id()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional int32 request_index = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(16u)) {
          set_has_request_index();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &request_index_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional string serialized_request = 3;
      case 3: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(26u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_serialized_request()));
        } else {
          goto handle_unusual;
        }
        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:content.proto.BackgroundFetchPendingRequest)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:content.proto.BackgroundFetchPendingRequest)
  return false;
#undef DO_
}

void BackgroundFetchPendingRequest::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:content.proto.BackgroundFetchPendingRequest)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  // optional string unique_id = 1;
  if (cached_has_bits & 0x00000001u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      1, this->unique_id(), output);
  }

  // optional int32 request_index = 2;
  if (cached_has_bits & 0x00000004u) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->request_index(), output);
  }

  // optional string serialized_request = 3;
  if (cached_has_bits & 0x00000002u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      3, this->serialized_request(), output);
  }

  output->WriteRaw(unknown_fields().data(),
                   static_cast<int>(unknown_fields().size()));
  // @@protoc_insertion_point(serialize_end:content.proto.BackgroundFetchPendingRequest)
}

size_t BackgroundFetchPendingRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:content.proto.BackgroundFetchPendingRequest)
  size_t total_size = 0;

  total_size += unknown_fields().size();

  if (_has_bits_[0 / 32] & 7u) {
    // optional string unique_id = 1;
    if (has_unique_id()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->unique_id());
    }

    // optional string serialized_request = 3;
    if (has_serialized_request()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->serialized_request());
    }

    // optional int32 request_index = 2;
    if (has_request_index()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::Int32Size(
          this->request_index());
    }

  }
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BackgroundFetchPendingRequest::CheckTypeAndMergeFrom(
    const ::google::protobuf::MessageLite& from) {
  MergeFrom(*::google::protobuf::down_cast<const BackgroundFetchPendingRequest*>(&from));
}

void BackgroundFetchPendingRequest::MergeFrom(const BackgroundFetchPendingRequest& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:content.proto.BackgroundFetchPendingRequest)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 7u) {
    if (cached_has_bits & 0x00000001u) {
      set_has_unique_id();
      unique_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.unique_id_);
    }
    if (cached_has_bits & 0x00000002u) {
      set_has_serialized_request();
      serialized_request_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.serialized_request_);
    }
    if (cached_has_bits & 0x00000004u) {
      request_index_ = from.request_index_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
}

void BackgroundFetchPendingRequest::CopyFrom(const BackgroundFetchPendingRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:content.proto.BackgroundFetchPendingRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void BackgroundFetchPendingRequest::Swap(BackgroundFetchPendingRequest* other) {
  if (other == this) return;
  InternalSwap(other);
}
void BackgroundFetchPendingRequest::InternalSwap(BackgroundFetchPendingRequest* other) {
  unique_id_.Swap(&other->unique_id_);
  serialized_request_.Swap(&other->serialized_request_);
  std::swap(request_index_, other->request_index_);
  std::swap(_has_bits_[0], other->_has_bits_[0]);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  std::swap(_cached_size_, other->_cached_size_);
}

::std::string BackgroundFetchPendingRequest::GetTypeName() const {
  return "content.proto.BackgroundFetchPendingRequest";
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BackgroundFetchPendingRequest

// optional string unique_id = 1;
bool BackgroundFetchPendingRequest::has_unique_id() const {
  return (_has_bits_[0] & 0x00000001u) != 0;
}
void BackgroundFetchPendingRequest::set_has_unique_id() {
  _has_bits_[0] |= 0x00000001u;
}
void BackgroundFetchPendingRequest::clear_has_unique_id() {
  _has_bits_[0] &= ~0x00000001u;
}
void BackgroundFetchPendingRequest::clear_unique_id() {
  unique_id_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_unique_id();
}
const ::std::string& BackgroundFetchPendingRequest::unique_id() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchPendingRequest.unique_id)
  return unique_id_.GetNoArena();
}
void BackgroundFetchPendingRequest::set_unique_id(const ::std::string& value) {
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchPendingRequest.unique_id)
}
#if LANG_CXX11
void BackgroundFetchPendingRequest::set_unique_id(::std::string&& value) {
  set_has_unique_id();
  unique_id_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchPendingRequest.unique_id)
}
#endif
void BackgroundFetchPendingRequest::set_unique_id(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchPendingRequest.unique_id)
}
void BackgroundFetchPendingRequest::set_unique_id(const char* value, size_t size) {
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchPendingRequest.unique_id)
}
::std::string* BackgroundFetchPendingRequest::mutable_unique_id() {
  set_has_unique_id();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchPendingRequest.unique_id)
  return unique_id_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchPendingRequest::release_unique_id() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchPendingRequest.unique_id)
  clear_has_unique_id();
  return unique_id_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchPendingRequest::set_allocated_unique_id(::std::string* unique_id) {
  if (unique_id != NULL) {
    set_has_unique_id();
  } else {
    clear_has_unique_id();
  }
  unique_id_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), unique_id);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchPendingRequest.unique_id)
}

// optional int32 request_index = 2;
bool BackgroundFetchPendingRequest::has_request_index() const {
  return (_has_bits_[0] & 0x00000004u) != 0;
}
void BackgroundFetchPendingRequest::set_has_request_index() {
  _has_bits_[0] |= 0x00000004u;
}
void BackgroundFetchPendingRequest::clear_has_request_index() {
  _has_bits_[0] &= ~0x00000004u;
}
void BackgroundFetchPendingRequest::clear_request_index() {
  request_index_ = 0;
  clear_has_request_index();
}
::google::protobuf::int32 BackgroundFetchPendingRequest::request_index() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchPendingRequest.request_index)
  return request_index_;
}
void BackgroundFetchPendingRequest::set_request_index(::google::protobuf::int32 value) {
  set_has_request_index();
  request_index_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchPendingRequest.request_index)
}

// optional string serialized_request = 3;
bool BackgroundFetchPendingRequest::has_serialized_request() const {
  return (_has_bits_[0] & 0x00000002u) != 0;
}
void BackgroundFetchPendingRequest::set_has_serialized_request() {
  _has_bits_[0] |= 0x00000002u;
}
void BackgroundFetchPendingRequest::clear_has_serialized_request() {
  _has_bits_[0] &= ~0x00000002u;
}
void BackgroundFetchPendingRequest::clear_serialized_request() {
  serialized_request_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_serialized_request();
}
const ::std::string& BackgroundFetchPendingRequest::serialized_request() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchPendingRequest.serialized_request)
  return serialized_request_.GetNoArena();
}
void BackgroundFetchPendingRequest::set_serialized_request(const ::std::string& value) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchPendingRequest.serialized_request)
}
#if LANG_CXX11
void BackgroundFetchPendingRequest::set_serialized_request(::std::string&& value) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchPendingRequest.serialized_request)
}
#endif
void BackgroundFetchPendingRequest::set_serialized_request(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchPendingRequest.serialized_request)
}
void BackgroundFetchPendingRequest::set_serialized_request(const char* value, size_t size) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchPendingRequest.serialized_request)
}
::std::string* BackgroundFetchPendingRequest::mutable_serialized_request() {
  set_has_serialized_request();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchPendingRequest.serialized_request)
  return serialized_request_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchPendingRequest::release_serialized_request() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchPendingRequest.serialized_request)
  clear_has_serialized_request();
  return serialized_request_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchPendingRequest::set_allocated_serialized_request(::std::string* serialized_request) {
  if (serialized_request != NULL) {
    set_has_serialized_request();
  } else {
    clear_has_serialized_request();
  }
  serialized_request_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), serialized_request);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchPendingRequest.serialized_request)
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

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

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BackgroundFetchActiveRequest::kUniqueIdFieldNumber;
const int BackgroundFetchActiveRequest::kRequestIndexFieldNumber;
const int BackgroundFetchActiveRequest::kSerializedRequestFieldNumber;
const int BackgroundFetchActiveRequest::kDownloadGuidFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

BackgroundFetchActiveRequest::BackgroundFetchActiveRequest()
  : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_background_5ffetch_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:content.proto.BackgroundFetchActiveRequest)
}
BackgroundFetchActiveRequest::BackgroundFetchActiveRequest(const BackgroundFetchActiveRequest& from)
  : ::google::protobuf::MessageLite(),
      _internal_metadata_(NULL),
      _has_bits_(from._has_bits_),
      _cached_size_(0) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  unique_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_unique_id()) {
    unique_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.unique_id_);
  }
  serialized_request_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_serialized_request()) {
    serialized_request_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.serialized_request_);
  }
  download_guid_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_download_guid()) {
    download_guid_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.download_guid_);
  }
  request_index_ = from.request_index_;
  // @@protoc_insertion_point(copy_constructor:content.proto.BackgroundFetchActiveRequest)
}

void BackgroundFetchActiveRequest::SharedCtor() {
  _cached_size_ = 0;
  unique_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  serialized_request_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  download_guid_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  request_index_ = 0;
}

BackgroundFetchActiveRequest::~BackgroundFetchActiveRequest() {
  // @@protoc_insertion_point(destructor:content.proto.BackgroundFetchActiveRequest)
  SharedDtor();
}

void BackgroundFetchActiveRequest::SharedDtor() {
  unique_id_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  serialized_request_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  download_guid_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}

void BackgroundFetchActiveRequest::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const BackgroundFetchActiveRequest& BackgroundFetchActiveRequest::default_instance() {
  protobuf_background_5ffetch_2eproto::InitDefaults();
  return *internal_default_instance();
}

BackgroundFetchActiveRequest* BackgroundFetchActiveRequest::New(::google::protobuf::Arena* arena) const {
  BackgroundFetchActiveRequest* n = new BackgroundFetchActiveRequest;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void BackgroundFetchActiveRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:content.proto.BackgroundFetchActiveRequest)
  if (_has_bits_[0 / 32] & 7u) {
    if (has_unique_id()) {
      GOOGLE_DCHECK(!unique_id_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*unique_id_.UnsafeRawStringPointer())->clear();
    }
    if (has_serialized_request()) {
      GOOGLE_DCHECK(!serialized_request_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*serialized_request_.UnsafeRawStringPointer())->clear();
    }
    if (has_download_guid()) {
      GOOGLE_DCHECK(!download_guid_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*download_guid_.UnsafeRawStringPointer())->clear();
    }
  }
  request_index_ = 0;
  _has_bits_.Clear();
  _internal_metadata_.Clear();
}

bool BackgroundFetchActiveRequest::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  ::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
      ::google::protobuf::NewPermanentCallback(&_internal_metadata_,
          &::google::protobuf::internal::InternalMetadataWithArenaLite::
              mutable_unknown_fields));
  ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
      &unknown_fields_string, false);
  // @@protoc_insertion_point(parse_start:content.proto.BackgroundFetchActiveRequest)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional string unique_id = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(10u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_unique_id()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional int32 request_index = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(16u)) {
          set_has_request_index();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &request_index_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional string serialized_request = 3;
      case 3: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(26u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_serialized_request()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional string download_guid = 4;
      case 4: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(34u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_download_guid()));
        } else {
          goto handle_unusual;
        }
        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:content.proto.BackgroundFetchActiveRequest)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:content.proto.BackgroundFetchActiveRequest)
  return false;
#undef DO_
}

void BackgroundFetchActiveRequest::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:content.proto.BackgroundFetchActiveRequest)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  // optional string unique_id = 1;
  if (cached_has_bits & 0x00000001u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      1, this->unique_id(), output);
  }

  // optional int32 request_index = 2;
  if (cached_has_bits & 0x00000008u) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->request_index(), output);
  }

  // optional string serialized_request = 3;
  if (cached_has_bits & 0x00000002u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      3, this->serialized_request(), output);
  }

  // optional string download_guid = 4;
  if (cached_has_bits & 0x00000004u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      4, this->download_guid(), output);
  }

  output->WriteRaw(unknown_fields().data(),
                   static_cast<int>(unknown_fields().size()));
  // @@protoc_insertion_point(serialize_end:content.proto.BackgroundFetchActiveRequest)
}

size_t BackgroundFetchActiveRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:content.proto.BackgroundFetchActiveRequest)
  size_t total_size = 0;

  total_size += unknown_fields().size();

  if (_has_bits_[0 / 32] & 15u) {
    // optional string unique_id = 1;
    if (has_unique_id()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->unique_id());
    }

    // optional string serialized_request = 3;
    if (has_serialized_request()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->serialized_request());
    }

    // optional string download_guid = 4;
    if (has_download_guid()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->download_guid());
    }

    // optional int32 request_index = 2;
    if (has_request_index()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::Int32Size(
          this->request_index());
    }

  }
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BackgroundFetchActiveRequest::CheckTypeAndMergeFrom(
    const ::google::protobuf::MessageLite& from) {
  MergeFrom(*::google::protobuf::down_cast<const BackgroundFetchActiveRequest*>(&from));
}

void BackgroundFetchActiveRequest::MergeFrom(const BackgroundFetchActiveRequest& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:content.proto.BackgroundFetchActiveRequest)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 15u) {
    if (cached_has_bits & 0x00000001u) {
      set_has_unique_id();
      unique_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.unique_id_);
    }
    if (cached_has_bits & 0x00000002u) {
      set_has_serialized_request();
      serialized_request_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.serialized_request_);
    }
    if (cached_has_bits & 0x00000004u) {
      set_has_download_guid();
      download_guid_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.download_guid_);
    }
    if (cached_has_bits & 0x00000008u) {
      request_index_ = from.request_index_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
}

void BackgroundFetchActiveRequest::CopyFrom(const BackgroundFetchActiveRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:content.proto.BackgroundFetchActiveRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void BackgroundFetchActiveRequest::Swap(BackgroundFetchActiveRequest* other) {
  if (other == this) return;
  InternalSwap(other);
}
void BackgroundFetchActiveRequest::InternalSwap(BackgroundFetchActiveRequest* other) {
  unique_id_.Swap(&other->unique_id_);
  serialized_request_.Swap(&other->serialized_request_);
  download_guid_.Swap(&other->download_guid_);
  std::swap(request_index_, other->request_index_);
  std::swap(_has_bits_[0], other->_has_bits_[0]);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  std::swap(_cached_size_, other->_cached_size_);
}

::std::string BackgroundFetchActiveRequest::GetTypeName() const {
  return "content.proto.BackgroundFetchActiveRequest";
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BackgroundFetchActiveRequest

// optional string unique_id = 1;
bool BackgroundFetchActiveRequest::has_unique_id() const {
  return (_has_bits_[0] & 0x00000001u) != 0;
}
void BackgroundFetchActiveRequest::set_has_unique_id() {
  _has_bits_[0] |= 0x00000001u;
}
void BackgroundFetchActiveRequest::clear_has_unique_id() {
  _has_bits_[0] &= ~0x00000001u;
}
void BackgroundFetchActiveRequest::clear_unique_id() {
  unique_id_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_unique_id();
}
const ::std::string& BackgroundFetchActiveRequest::unique_id() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchActiveRequest.unique_id)
  return unique_id_.GetNoArena();
}
void BackgroundFetchActiveRequest::set_unique_id(const ::std::string& value) {
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchActiveRequest.unique_id)
}
#if LANG_CXX11
void BackgroundFetchActiveRequest::set_unique_id(::std::string&& value) {
  set_has_unique_id();
  unique_id_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchActiveRequest.unique_id)
}
#endif
void BackgroundFetchActiveRequest::set_unique_id(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchActiveRequest.unique_id)
}
void BackgroundFetchActiveRequest::set_unique_id(const char* value, size_t size) {
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchActiveRequest.unique_id)
}
::std::string* BackgroundFetchActiveRequest::mutable_unique_id() {
  set_has_unique_id();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchActiveRequest.unique_id)
  return unique_id_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchActiveRequest::release_unique_id() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchActiveRequest.unique_id)
  clear_has_unique_id();
  return unique_id_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchActiveRequest::set_allocated_unique_id(::std::string* unique_id) {
  if (unique_id != NULL) {
    set_has_unique_id();
  } else {
    clear_has_unique_id();
  }
  unique_id_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), unique_id);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchActiveRequest.unique_id)
}

// optional int32 request_index = 2;
bool BackgroundFetchActiveRequest::has_request_index() const {
  return (_has_bits_[0] & 0x00000008u) != 0;
}
void BackgroundFetchActiveRequest::set_has_request_index() {
  _has_bits_[0] |= 0x00000008u;
}
void BackgroundFetchActiveRequest::clear_has_request_index() {
  _has_bits_[0] &= ~0x00000008u;
}
void BackgroundFetchActiveRequest::clear_request_index() {
  request_index_ = 0;
  clear_has_request_index();
}
::google::protobuf::int32 BackgroundFetchActiveRequest::request_index() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchActiveRequest.request_index)
  return request_index_;
}
void BackgroundFetchActiveRequest::set_request_index(::google::protobuf::int32 value) {
  set_has_request_index();
  request_index_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchActiveRequest.request_index)
}

// optional string serialized_request = 3;
bool BackgroundFetchActiveRequest::has_serialized_request() const {
  return (_has_bits_[0] & 0x00000002u) != 0;
}
void BackgroundFetchActiveRequest::set_has_serialized_request() {
  _has_bits_[0] |= 0x00000002u;
}
void BackgroundFetchActiveRequest::clear_has_serialized_request() {
  _has_bits_[0] &= ~0x00000002u;
}
void BackgroundFetchActiveRequest::clear_serialized_request() {
  serialized_request_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_serialized_request();
}
const ::std::string& BackgroundFetchActiveRequest::serialized_request() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchActiveRequest.serialized_request)
  return serialized_request_.GetNoArena();
}
void BackgroundFetchActiveRequest::set_serialized_request(const ::std::string& value) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchActiveRequest.serialized_request)
}
#if LANG_CXX11
void BackgroundFetchActiveRequest::set_serialized_request(::std::string&& value) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchActiveRequest.serialized_request)
}
#endif
void BackgroundFetchActiveRequest::set_serialized_request(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchActiveRequest.serialized_request)
}
void BackgroundFetchActiveRequest::set_serialized_request(const char* value, size_t size) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchActiveRequest.serialized_request)
}
::std::string* BackgroundFetchActiveRequest::mutable_serialized_request() {
  set_has_serialized_request();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchActiveRequest.serialized_request)
  return serialized_request_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchActiveRequest::release_serialized_request() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchActiveRequest.serialized_request)
  clear_has_serialized_request();
  return serialized_request_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchActiveRequest::set_allocated_serialized_request(::std::string* serialized_request) {
  if (serialized_request != NULL) {
    set_has_serialized_request();
  } else {
    clear_has_serialized_request();
  }
  serialized_request_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), serialized_request);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchActiveRequest.serialized_request)
}

// optional string download_guid = 4;
bool BackgroundFetchActiveRequest::has_download_guid() const {
  return (_has_bits_[0] & 0x00000004u) != 0;
}
void BackgroundFetchActiveRequest::set_has_download_guid() {
  _has_bits_[0] |= 0x00000004u;
}
void BackgroundFetchActiveRequest::clear_has_download_guid() {
  _has_bits_[0] &= ~0x00000004u;
}
void BackgroundFetchActiveRequest::clear_download_guid() {
  download_guid_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_download_guid();
}
const ::std::string& BackgroundFetchActiveRequest::download_guid() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchActiveRequest.download_guid)
  return download_guid_.GetNoArena();
}
void BackgroundFetchActiveRequest::set_download_guid(const ::std::string& value) {
  set_has_download_guid();
  download_guid_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchActiveRequest.download_guid)
}
#if LANG_CXX11
void BackgroundFetchActiveRequest::set_download_guid(::std::string&& value) {
  set_has_download_guid();
  download_guid_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchActiveRequest.download_guid)
}
#endif
void BackgroundFetchActiveRequest::set_download_guid(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_download_guid();
  download_guid_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchActiveRequest.download_guid)
}
void BackgroundFetchActiveRequest::set_download_guid(const char* value, size_t size) {
  set_has_download_guid();
  download_guid_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchActiveRequest.download_guid)
}
::std::string* BackgroundFetchActiveRequest::mutable_download_guid() {
  set_has_download_guid();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchActiveRequest.download_guid)
  return download_guid_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchActiveRequest::release_download_guid() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchActiveRequest.download_guid)
  clear_has_download_guid();
  return download_guid_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchActiveRequest::set_allocated_download_guid(::std::string* download_guid) {
  if (download_guid != NULL) {
    set_has_download_guid();
  } else {
    clear_has_download_guid();
  }
  download_guid_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), download_guid);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchActiveRequest.download_guid)
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

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

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BackgroundFetchCompletedRequest::kUniqueIdFieldNumber;
const int BackgroundFetchCompletedRequest::kRequestIndexFieldNumber;
const int BackgroundFetchCompletedRequest::kSerializedRequestFieldNumber;
const int BackgroundFetchCompletedRequest::kDownloadGuidFieldNumber;
const int BackgroundFetchCompletedRequest::kSucceededFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

BackgroundFetchCompletedRequest::BackgroundFetchCompletedRequest()
  : ::google::protobuf::MessageLite(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_background_5ffetch_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:content.proto.BackgroundFetchCompletedRequest)
}
BackgroundFetchCompletedRequest::BackgroundFetchCompletedRequest(const BackgroundFetchCompletedRequest& from)
  : ::google::protobuf::MessageLite(),
      _internal_metadata_(NULL),
      _has_bits_(from._has_bits_),
      _cached_size_(0) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  unique_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_unique_id()) {
    unique_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.unique_id_);
  }
  serialized_request_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_serialized_request()) {
    serialized_request_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.serialized_request_);
  }
  download_guid_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  if (from.has_download_guid()) {
    download_guid_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.download_guid_);
  }
  ::memcpy(&request_index_, &from.request_index_,
    static_cast<size_t>(reinterpret_cast<char*>(&succeeded_) -
    reinterpret_cast<char*>(&request_index_)) + sizeof(succeeded_));
  // @@protoc_insertion_point(copy_constructor:content.proto.BackgroundFetchCompletedRequest)
}

void BackgroundFetchCompletedRequest::SharedCtor() {
  _cached_size_ = 0;
  unique_id_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  serialized_request_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  download_guid_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  ::memset(&request_index_, 0, static_cast<size_t>(
      reinterpret_cast<char*>(&succeeded_) -
      reinterpret_cast<char*>(&request_index_)) + sizeof(succeeded_));
}

BackgroundFetchCompletedRequest::~BackgroundFetchCompletedRequest() {
  // @@protoc_insertion_point(destructor:content.proto.BackgroundFetchCompletedRequest)
  SharedDtor();
}

void BackgroundFetchCompletedRequest::SharedDtor() {
  unique_id_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  serialized_request_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  download_guid_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}

void BackgroundFetchCompletedRequest::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const BackgroundFetchCompletedRequest& BackgroundFetchCompletedRequest::default_instance() {
  protobuf_background_5ffetch_2eproto::InitDefaults();
  return *internal_default_instance();
}

BackgroundFetchCompletedRequest* BackgroundFetchCompletedRequest::New(::google::protobuf::Arena* arena) const {
  BackgroundFetchCompletedRequest* n = new BackgroundFetchCompletedRequest;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void BackgroundFetchCompletedRequest::Clear() {
// @@protoc_insertion_point(message_clear_start:content.proto.BackgroundFetchCompletedRequest)
  if (_has_bits_[0 / 32] & 7u) {
    if (has_unique_id()) {
      GOOGLE_DCHECK(!unique_id_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*unique_id_.UnsafeRawStringPointer())->clear();
    }
    if (has_serialized_request()) {
      GOOGLE_DCHECK(!serialized_request_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*serialized_request_.UnsafeRawStringPointer())->clear();
    }
    if (has_download_guid()) {
      GOOGLE_DCHECK(!download_guid_.IsDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()));
      (*download_guid_.UnsafeRawStringPointer())->clear();
    }
  }
  if (_has_bits_[0 / 32] & 24u) {
    ::memset(&request_index_, 0, static_cast<size_t>(
        reinterpret_cast<char*>(&succeeded_) -
        reinterpret_cast<char*>(&request_index_)) + sizeof(succeeded_));
  }
  _has_bits_.Clear();
  _internal_metadata_.Clear();
}

bool BackgroundFetchCompletedRequest::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  ::google::protobuf::io::LazyStringOutputStream unknown_fields_string(
      ::google::protobuf::NewPermanentCallback(&_internal_metadata_,
          &::google::protobuf::internal::InternalMetadataWithArenaLite::
              mutable_unknown_fields));
  ::google::protobuf::io::CodedOutputStream unknown_fields_stream(
      &unknown_fields_string, false);
  // @@protoc_insertion_point(parse_start:content.proto.BackgroundFetchCompletedRequest)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // optional string unique_id = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(10u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_unique_id()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional int32 request_index = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(16u)) {
          set_has_request_index();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &request_index_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional string serialized_request = 3;
      case 3: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(26u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_serialized_request()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional string download_guid = 4;
      case 4: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(34u)) {
          DO_(::google::protobuf::internal::WireFormatLite::ReadString(
                input, this->mutable_download_guid()));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // optional bool succeeded = 5;
      case 5: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(40u)) {
          set_has_succeeded();
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
                 input, &succeeded_)));
        } else {
          goto handle_unusual;
        }
        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:content.proto.BackgroundFetchCompletedRequest)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:content.proto.BackgroundFetchCompletedRequest)
  return false;
#undef DO_
}

void BackgroundFetchCompletedRequest::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:content.proto.BackgroundFetchCompletedRequest)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = _has_bits_[0];
  // optional string unique_id = 1;
  if (cached_has_bits & 0x00000001u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      1, this->unique_id(), output);
  }

  // optional int32 request_index = 2;
  if (cached_has_bits & 0x00000008u) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->request_index(), output);
  }

  // optional string serialized_request = 3;
  if (cached_has_bits & 0x00000002u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      3, this->serialized_request(), output);
  }

  // optional string download_guid = 4;
  if (cached_has_bits & 0x00000004u) {
    ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
      4, this->download_guid(), output);
  }

  // optional bool succeeded = 5;
  if (cached_has_bits & 0x00000010u) {
    ::google::protobuf::internal::WireFormatLite::WriteBool(5, this->succeeded(), output);
  }

  output->WriteRaw(unknown_fields().data(),
                   static_cast<int>(unknown_fields().size()));
  // @@protoc_insertion_point(serialize_end:content.proto.BackgroundFetchCompletedRequest)
}

size_t BackgroundFetchCompletedRequest::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:content.proto.BackgroundFetchCompletedRequest)
  size_t total_size = 0;

  total_size += unknown_fields().size();

  if (_has_bits_[0 / 32] & 31u) {
    // optional string unique_id = 1;
    if (has_unique_id()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->unique_id());
    }

    // optional string serialized_request = 3;
    if (has_serialized_request()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->serialized_request());
    }

    // optional string download_guid = 4;
    if (has_download_guid()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::StringSize(
          this->download_guid());
    }

    // optional int32 request_index = 2;
    if (has_request_index()) {
      total_size += 1 +
        ::google::protobuf::internal::WireFormatLite::Int32Size(
          this->request_index());
    }

    // optional bool succeeded = 5;
    if (has_succeeded()) {
      total_size += 1 + 1;
    }

  }
  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void BackgroundFetchCompletedRequest::CheckTypeAndMergeFrom(
    const ::google::protobuf::MessageLite& from) {
  MergeFrom(*::google::protobuf::down_cast<const BackgroundFetchCompletedRequest*>(&from));
}

void BackgroundFetchCompletedRequest::MergeFrom(const BackgroundFetchCompletedRequest& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:content.proto.BackgroundFetchCompletedRequest)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  cached_has_bits = from._has_bits_[0];
  if (cached_has_bits & 31u) {
    if (cached_has_bits & 0x00000001u) {
      set_has_unique_id();
      unique_id_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.unique_id_);
    }
    if (cached_has_bits & 0x00000002u) {
      set_has_serialized_request();
      serialized_request_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.serialized_request_);
    }
    if (cached_has_bits & 0x00000004u) {
      set_has_download_guid();
      download_guid_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.download_guid_);
    }
    if (cached_has_bits & 0x00000008u) {
      request_index_ = from.request_index_;
    }
    if (cached_has_bits & 0x00000010u) {
      succeeded_ = from.succeeded_;
    }
    _has_bits_[0] |= cached_has_bits;
  }
}

void BackgroundFetchCompletedRequest::CopyFrom(const BackgroundFetchCompletedRequest& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:content.proto.BackgroundFetchCompletedRequest)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

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

void BackgroundFetchCompletedRequest::Swap(BackgroundFetchCompletedRequest* other) {
  if (other == this) return;
  InternalSwap(other);
}
void BackgroundFetchCompletedRequest::InternalSwap(BackgroundFetchCompletedRequest* other) {
  unique_id_.Swap(&other->unique_id_);
  serialized_request_.Swap(&other->serialized_request_);
  download_guid_.Swap(&other->download_guid_);
  std::swap(request_index_, other->request_index_);
  std::swap(succeeded_, other->succeeded_);
  std::swap(_has_bits_[0], other->_has_bits_[0]);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  std::swap(_cached_size_, other->_cached_size_);
}

::std::string BackgroundFetchCompletedRequest::GetTypeName() const {
  return "content.proto.BackgroundFetchCompletedRequest";
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BackgroundFetchCompletedRequest

// optional string unique_id = 1;
bool BackgroundFetchCompletedRequest::has_unique_id() const {
  return (_has_bits_[0] & 0x00000001u) != 0;
}
void BackgroundFetchCompletedRequest::set_has_unique_id() {
  _has_bits_[0] |= 0x00000001u;
}
void BackgroundFetchCompletedRequest::clear_has_unique_id() {
  _has_bits_[0] &= ~0x00000001u;
}
void BackgroundFetchCompletedRequest::clear_unique_id() {
  unique_id_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_unique_id();
}
const ::std::string& BackgroundFetchCompletedRequest::unique_id() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchCompletedRequest.unique_id)
  return unique_id_.GetNoArena();
}
void BackgroundFetchCompletedRequest::set_unique_id(const ::std::string& value) {
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchCompletedRequest.unique_id)
}
#if LANG_CXX11
void BackgroundFetchCompletedRequest::set_unique_id(::std::string&& value) {
  set_has_unique_id();
  unique_id_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchCompletedRequest.unique_id)
}
#endif
void BackgroundFetchCompletedRequest::set_unique_id(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchCompletedRequest.unique_id)
}
void BackgroundFetchCompletedRequest::set_unique_id(const char* value, size_t size) {
  set_has_unique_id();
  unique_id_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchCompletedRequest.unique_id)
}
::std::string* BackgroundFetchCompletedRequest::mutable_unique_id() {
  set_has_unique_id();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchCompletedRequest.unique_id)
  return unique_id_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchCompletedRequest::release_unique_id() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchCompletedRequest.unique_id)
  clear_has_unique_id();
  return unique_id_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchCompletedRequest::set_allocated_unique_id(::std::string* unique_id) {
  if (unique_id != NULL) {
    set_has_unique_id();
  } else {
    clear_has_unique_id();
  }
  unique_id_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), unique_id);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchCompletedRequest.unique_id)
}

// optional int32 request_index = 2;
bool BackgroundFetchCompletedRequest::has_request_index() const {
  return (_has_bits_[0] & 0x00000008u) != 0;
}
void BackgroundFetchCompletedRequest::set_has_request_index() {
  _has_bits_[0] |= 0x00000008u;
}
void BackgroundFetchCompletedRequest::clear_has_request_index() {
  _has_bits_[0] &= ~0x00000008u;
}
void BackgroundFetchCompletedRequest::clear_request_index() {
  request_index_ = 0;
  clear_has_request_index();
}
::google::protobuf::int32 BackgroundFetchCompletedRequest::request_index() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchCompletedRequest.request_index)
  return request_index_;
}
void BackgroundFetchCompletedRequest::set_request_index(::google::protobuf::int32 value) {
  set_has_request_index();
  request_index_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchCompletedRequest.request_index)
}

// optional string serialized_request = 3;
bool BackgroundFetchCompletedRequest::has_serialized_request() const {
  return (_has_bits_[0] & 0x00000002u) != 0;
}
void BackgroundFetchCompletedRequest::set_has_serialized_request() {
  _has_bits_[0] |= 0x00000002u;
}
void BackgroundFetchCompletedRequest::clear_has_serialized_request() {
  _has_bits_[0] &= ~0x00000002u;
}
void BackgroundFetchCompletedRequest::clear_serialized_request() {
  serialized_request_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_serialized_request();
}
const ::std::string& BackgroundFetchCompletedRequest::serialized_request() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchCompletedRequest.serialized_request)
  return serialized_request_.GetNoArena();
}
void BackgroundFetchCompletedRequest::set_serialized_request(const ::std::string& value) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchCompletedRequest.serialized_request)
}
#if LANG_CXX11
void BackgroundFetchCompletedRequest::set_serialized_request(::std::string&& value) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchCompletedRequest.serialized_request)
}
#endif
void BackgroundFetchCompletedRequest::set_serialized_request(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchCompletedRequest.serialized_request)
}
void BackgroundFetchCompletedRequest::set_serialized_request(const char* value, size_t size) {
  set_has_serialized_request();
  serialized_request_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchCompletedRequest.serialized_request)
}
::std::string* BackgroundFetchCompletedRequest::mutable_serialized_request() {
  set_has_serialized_request();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchCompletedRequest.serialized_request)
  return serialized_request_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchCompletedRequest::release_serialized_request() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchCompletedRequest.serialized_request)
  clear_has_serialized_request();
  return serialized_request_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchCompletedRequest::set_allocated_serialized_request(::std::string* serialized_request) {
  if (serialized_request != NULL) {
    set_has_serialized_request();
  } else {
    clear_has_serialized_request();
  }
  serialized_request_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), serialized_request);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchCompletedRequest.serialized_request)
}

// optional string download_guid = 4;
bool BackgroundFetchCompletedRequest::has_download_guid() const {
  return (_has_bits_[0] & 0x00000004u) != 0;
}
void BackgroundFetchCompletedRequest::set_has_download_guid() {
  _has_bits_[0] |= 0x00000004u;
}
void BackgroundFetchCompletedRequest::clear_has_download_guid() {
  _has_bits_[0] &= ~0x00000004u;
}
void BackgroundFetchCompletedRequest::clear_download_guid() {
  download_guid_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
  clear_has_download_guid();
}
const ::std::string& BackgroundFetchCompletedRequest::download_guid() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchCompletedRequest.download_guid)
  return download_guid_.GetNoArena();
}
void BackgroundFetchCompletedRequest::set_download_guid(const ::std::string& value) {
  set_has_download_guid();
  download_guid_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchCompletedRequest.download_guid)
}
#if LANG_CXX11
void BackgroundFetchCompletedRequest::set_download_guid(::std::string&& value) {
  set_has_download_guid();
  download_guid_.SetNoArena(
    &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
  // @@protoc_insertion_point(field_set_rvalue:content.proto.BackgroundFetchCompletedRequest.download_guid)
}
#endif
void BackgroundFetchCompletedRequest::set_download_guid(const char* value) {
  GOOGLE_DCHECK(value != NULL);
  set_has_download_guid();
  download_guid_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
  // @@protoc_insertion_point(field_set_char:content.proto.BackgroundFetchCompletedRequest.download_guid)
}
void BackgroundFetchCompletedRequest::set_download_guid(const char* value, size_t size) {
  set_has_download_guid();
  download_guid_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
      ::std::string(reinterpret_cast<const char*>(value), size));
  // @@protoc_insertion_point(field_set_pointer:content.proto.BackgroundFetchCompletedRequest.download_guid)
}
::std::string* BackgroundFetchCompletedRequest::mutable_download_guid() {
  set_has_download_guid();
  // @@protoc_insertion_point(field_mutable:content.proto.BackgroundFetchCompletedRequest.download_guid)
  return download_guid_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BackgroundFetchCompletedRequest::release_download_guid() {
  // @@protoc_insertion_point(field_release:content.proto.BackgroundFetchCompletedRequest.download_guid)
  clear_has_download_guid();
  return download_guid_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BackgroundFetchCompletedRequest::set_allocated_download_guid(::std::string* download_guid) {
  if (download_guid != NULL) {
    set_has_download_guid();
  } else {
    clear_has_download_guid();
  }
  download_guid_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), download_guid);
  // @@protoc_insertion_point(field_set_allocated:content.proto.BackgroundFetchCompletedRequest.download_guid)
}

// optional bool succeeded = 5;
bool BackgroundFetchCompletedRequest::has_succeeded() const {
  return (_has_bits_[0] & 0x00000010u) != 0;
}
void BackgroundFetchCompletedRequest::set_has_succeeded() {
  _has_bits_[0] |= 0x00000010u;
}
void BackgroundFetchCompletedRequest::clear_has_succeeded() {
  _has_bits_[0] &= ~0x00000010u;
}
void BackgroundFetchCompletedRequest::clear_succeeded() {
  succeeded_ = false;
  clear_has_succeeded();
}
bool BackgroundFetchCompletedRequest::succeeded() const {
  // @@protoc_insertion_point(field_get:content.proto.BackgroundFetchCompletedRequest.succeeded)
  return succeeded_;
}
void BackgroundFetchCompletedRequest::set_succeeded(bool value) {
  set_has_succeeded();
  succeeded_ = value;
  // @@protoc_insertion_point(field_set:content.proto.BackgroundFetchCompletedRequest.succeeded)
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

// @@protoc_insertion_point(namespace_scope)

}  // namespace proto
}  // namespace content

// @@protoc_insertion_point(global_scope)
