download_db_entry.cc 795 B

1234567891011121314151617181920212223242526272829
  1. // Copyright 2018 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #include "components/download/database/download_db_entry.h"
  5. namespace download {
  6. DownloadDBEntry::DownloadDBEntry() = default;
  7. DownloadDBEntry::DownloadDBEntry(const DownloadDBEntry& other) = default;
  8. DownloadDBEntry::~DownloadDBEntry() = default;
  9. bool DownloadDBEntry::operator==(const DownloadDBEntry& other) const {
  10. return download_info == other.download_info;
  11. }
  12. std::string DownloadDBEntry::GetGuid() const {
  13. if (!download_info)
  14. return std::string();
  15. return download_info->guid;
  16. }
  17. bool DownloadDBEntry::operator!=(const DownloadDBEntry& other) const {
  18. return !(*this == other);
  19. }
  20. } // namespace download