Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(456)

Unified Diff: components/physical_web/data_source/fake_physical_web_data_source.cc

Issue 2648973004: Remove GetMetadata from PhysicalWebDataSource and PhysicalWebScanner (Closed)
Patch Set: nil -> null Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/physical_web/data_source/fake_physical_web_data_source.cc
diff --git a/components/physical_web/data_source/fake_physical_web_data_source.cc b/components/physical_web/data_source/fake_physical_web_data_source.cc
index fb04e9f9e4148aed0bf6a049ba3963e62b143079..db5d4ff72180987badb48d4df0601d1bfad6ac1d 100644
--- a/components/physical_web/data_source/fake_physical_web_data_source.cc
+++ b/components/physical_web/data_source/fake_physical_web_data_source.cc
@@ -5,13 +5,9 @@
#include "components/physical_web/data_source/fake_physical_web_data_source.h"
#include "base/strings/string_number_conversions.h"
-#include "base/values.h"
#include "components/physical_web/data_source/physical_web_listener.h"
#include "url/gurl.h"
-using base::ListValue;
-using base::DictionaryValue;
-
namespace physical_web {
std::unique_ptr<Metadata> CreatePhysicalWebPage(
@@ -58,8 +54,7 @@ std::unique_ptr<MetadataList> CreateDummyPhysicalWebPages(
return list;
}
-FakePhysicalWebDataSource::FakePhysicalWebDataSource()
- : metadata_(base::MakeUnique<base::ListValue>()) {}
+FakePhysicalWebDataSource::FakePhysicalWebDataSource() {}
FakePhysicalWebDataSource::~FakePhysicalWebDataSource() = default;
@@ -71,10 +66,6 @@ void FakePhysicalWebDataSource::StopDiscovery() {
// Ignored.
}
-std::unique_ptr<base::ListValue> FakePhysicalWebDataSource::GetMetadata() {
- return metadata_->CreateDeepCopy();
-}
-
std::unique_ptr<MetadataList> FakePhysicalWebDataSource::GetMetadataList() {
return base::MakeUnique<MetadataList>(*metadata_list_.get());
}
@@ -93,11 +84,6 @@ void FakePhysicalWebDataSource::UnregisterListener(
observer_list_.RemoveObserver(physical_web_listener);
}
-void FakePhysicalWebDataSource::SetMetadata(
- std::unique_ptr<ListValue> metadata) {
- metadata_ = std::move(metadata);
-}
-
void FakePhysicalWebDataSource::SetMetadataList(
std::unique_ptr<MetadataList> metadata_list) {
metadata_list_ = std::move(metadata_list);

Powered by Google App Engine
This is Rietveld 408576698