Index: components/data_use_measurement/core/data_use_measurement.h |
diff --git a/components/data_use_measurement/content/data_use_measurement.h b/components/data_use_measurement/core/data_use_measurement.h |
similarity index 87% |
rename from components/data_use_measurement/content/data_use_measurement.h |
rename to components/data_use_measurement/core/data_use_measurement.h |
index a5b8f7136359a70c26fe085c11fb0471549bb004..e250ec3dfd8e723261bfa02200995b4c87dbe380 100644 |
--- a/components/data_use_measurement/content/data_use_measurement.h |
+++ b/components/data_use_measurement/core/data_use_measurement.h |
@@ -2,8 +2,8 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#ifndef COMPONENTS_DATA_USE_MEASUREMENT_CONTENT_DATA_USE_MEASUREMENT_H_ |
-#define COMPONENTS_DATA_USE_MEASUREMENT_CONTENT_DATA_USE_MEASUREMENT_H_ |
+#ifndef COMPONENTS_DATA_USE_MEASUREMENT_CORE_DATA_USE_MEASUREMENT_H_ |
+#define COMPONENTS_DATA_USE_MEASUREMENT_CORE_DATA_USE_MEASUREMENT_H_ |
#include <stdint.h> |
@@ -12,6 +12,7 @@ |
#include "base/macros.h" |
#include "base/memory/scoped_ptr.h" |
#include "build/build_config.h" |
+#include "components/data_use_measurement/core/data_use_measurement_delegate.h" |
#include "components/data_use_measurement/core/data_use_user_data.h" |
#if defined(OS_ANDROID) |
@@ -32,7 +33,8 @@ namespace data_use_measurement { |
// http://crbug.com/527460 |
class DataUseMeasurement { |
public: |
- DataUseMeasurement(); |
+ // This class gets the ownership of data_use_measurement_delegate object. |
+ DataUseMeasurement(DataUseMeasurementDelegate* data_use_measurement_delegate); |
~DataUseMeasurement(); |
// Records the data use of the |request|, thus |request| must be non-null. |
@@ -81,6 +83,8 @@ class DataUseMeasurement { |
TrafficDirection dir, |
int64_t message_size) const; |
+ scoped_ptr<DataUseMeasurementDelegate> data_use_measurement_delegate_; |
+ |
#if defined(OS_ANDROID) |
// Application listener store the last known state of the application in this |
// field. |
@@ -96,4 +100,4 @@ class DataUseMeasurement { |
} // namespace data_use_measurement |
-#endif // COMPONENTS_DATA_USE_MEASUREMENT_CONTENT_DATA_USE_MEASUREMENT_H_ |
+#endif // COMPONENTS_DATA_USE_MEASUREMENT_CORE_DATA_USE_MEASUREMENT_H_ |