| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2012 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 | |
| 5 #ifndef COMPONENTS_SYNC_CORE_DATA_TYPE_DEBUG_INFO_LISTENER_H_ | |
| 6 #define COMPONENTS_SYNC_CORE_DATA_TYPE_DEBUG_INFO_LISTENER_H_ | |
| 7 | |
| 8 #include <vector> | |
| 9 | |
| 10 #include "components/sync/base/model_type.h" | |
| 11 #include "components/sync/core/data_type_association_stats.h" | |
| 12 | |
| 13 namespace syncer { | |
| 14 | |
| 15 struct DataTypeConfigurationStats { | |
| 16 DataTypeConfigurationStats(); | |
| 17 DataTypeConfigurationStats(const DataTypeConfigurationStats& other); | |
| 18 ~DataTypeConfigurationStats(); | |
| 19 | |
| 20 // The datatype that was configured. | |
| 21 ModelType model_type; | |
| 22 | |
| 23 // Waiting time before downloading starts. | |
| 24 base::TimeDelta download_wait_time; | |
| 25 | |
| 26 // Time spent on downloading data for first-sync data types. | |
| 27 base::TimeDelta download_time; | |
| 28 | |
| 29 // Waiting time for association of higher priority types to finish before | |
| 30 // asking association manager to associate. | |
| 31 base::TimeDelta association_wait_time_for_high_priority; | |
| 32 | |
| 33 // Types configured before this type. | |
| 34 ModelTypeSet high_priority_types_configured_before; | |
| 35 ModelTypeSet same_priority_types_configured_before; | |
| 36 | |
| 37 // Association stats. | |
| 38 DataTypeAssociationStats association_stats; | |
| 39 }; | |
| 40 | |
| 41 // Interface for the sync internals to listen to external sync events. | |
| 42 class DataTypeDebugInfoListener { | |
| 43 public: | |
| 44 // Notify the listener that configuration of data types has completed. | |
| 45 virtual void OnDataTypeConfigureComplete( | |
| 46 const std::vector<DataTypeConfigurationStats>& configuration_stats) = 0; | |
| 47 }; | |
| 48 | |
| 49 } // namespace syncer | |
| 50 | |
| 51 #endif // COMPONENTS_SYNC_CORE_DATA_TYPE_DEBUG_INFO_LISTENER_H_ | |
| OLD | NEW |