| OLD | NEW |
| (Empty) |
| 1 // Copyright 2013 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_AUTOFILL_CONTENT_BROWSER_AUTOCHECKOUT_STATISTIC_H__ | |
| 6 #define COMPONENTS_AUTOFILL_CONTENT_BROWSER_AUTOCHECKOUT_STATISTIC_H__ | |
| 7 | |
| 8 #include <vector> | |
| 9 | |
| 10 #include "base/memory/scoped_ptr.h" | |
| 11 #include "base/time/time.h" | |
| 12 #include "components/autofill/content/browser/autocheckout_steps.h" | |
| 13 | |
| 14 namespace base { | |
| 15 class DictionaryValue; | |
| 16 } | |
| 17 | |
| 18 namespace autofill { | |
| 19 | |
| 20 // Per page statistics gathered in Autocheckout flow. | |
| 21 struct AutocheckoutStatistic { | |
| 22 AutocheckoutStatistic(); | |
| 23 ~AutocheckoutStatistic(); | |
| 24 | |
| 25 // Page number for which this statistic is being recorded. | |
| 26 int page_number; | |
| 27 | |
| 28 // Autocheckout steps that are part of |page_number|. | |
| 29 std::vector<AutocheckoutStepType> steps; | |
| 30 | |
| 31 // Time taken for performing |steps|, used for measuring latency. | |
| 32 base::TimeDelta time_taken; | |
| 33 | |
| 34 // Helper method to convert AutocheckoutStatistic to json representation. | |
| 35 scoped_ptr<base::DictionaryValue> ToDictionary() const; | |
| 36 }; | |
| 37 | |
| 38 } // namespace autofill | |
| 39 | |
| 40 #endif // COMPONENTS_AUTOFILL_CONTENT_BROWSER_AUTOCHECKOUT_STATISTIC_H__ | |
| OLD | NEW |