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

Unified Diff: net/reporting/reporting_browsing_data_remover.h

Issue 2829683004: Reporting: Plumb from //chrome/browser/browsing_data. (Closed)
Patch Set: Created 3 years, 8 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: net/reporting/reporting_browsing_data_remover.h
diff --git a/net/reporting/reporting_browsing_data_remover.h b/net/reporting/reporting_browsing_data_remover.h
index db2bfb6df196b8ab14c46b894320eb3b72118f10..77eda2bf498e9324ce21f5f7ef6a3c41dedebada 100644
--- a/net/reporting/reporting_browsing_data_remover.h
+++ b/net/reporting/reporting_browsing_data_remover.h
@@ -5,6 +5,8 @@
#ifndef NET_REPORTING_REPORTING_BROWSING_DATA_REMOVER_H_
#define NET_REPORTING_REPORTING_BROWSING_DATA_REMOVER_H_
+#include <memory>
+
#include "base/callback.h"
#include "base/macros.h"
#include "net/base/net_export.h"
@@ -22,13 +24,20 @@ class NET_EXPORT ReportingBrowsingDataRemover {
DATA_TYPE_CLIENTS = 0x2,
};
- static void RemoveBrowsingData(
- ReportingContext* context,
- int data_type_mask,
- base::Callback<bool(const GURL&)> origin_filter);
+ // Creates a ReportingBrowsingDataRemover. |context| must outlive the
+ // browsing data remover.
+ static std::unique_ptr<ReportingBrowsingDataRemover> Create(
+ ReportingContext* context);
- private:
- DISALLOW_IMPLICIT_CONSTRUCTORS(ReportingBrowsingDataRemover);
+ virtual ~ReportingBrowsingDataRemover();
+
+ // Removes browsing data from the Reporting system. |data_type_mask| specifies
+ // which types of data to remove: reports queued by browser features and/or
+ // clients (endpoints configured by origins). |origin_filter|, if not null,
+ // specifies which origins' data to remove.
+ virtual void RemoveBrowsingData(
+ int data_type_mask,
+ base::Callback<bool(const GURL&)> origin_filter) = 0;
};
} // namespace net

Powered by Google App Engine
This is Rietveld 408576698