| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "webkit/browser/appcache/appcache_histograms.h" | 5 #include "webkit/browser/appcache/appcache_histograms.h" |
| 6 | 6 |
| 7 #include "base/metrics/histogram.h" | 7 #include "base/metrics/histogram.h" |
| 8 | 8 |
| 9 namespace appcache { | 9 namespace appcache { |
| 10 | 10 |
| 11 void AppCacheHistograms::CountInitResult(InitResultType init_result) { | 11 void AppCacheHistograms::CountInitResult(InitResultType init_result) { |
| 12 UMA_HISTOGRAM_ENUMERATION( | 12 UMA_HISTOGRAM_ENUMERATION( |
| 13 "appcache.InitResult", | 13 "appcache.InitResult", |
| 14 init_result, NUM_INIT_RESULT_TYPES); | 14 init_result, NUM_INIT_RESULT_TYPES); |
| 15 } | 15 } |
| 16 | 16 |
| 17 void AppCacheHistograms::CountReinitAttempt(bool repeated_attempt) { | 17 void AppCacheHistograms::CountReinitAttempt(bool repeated_attempt) { |
| 18 UMA_HISTOGRAM_BOOLEAN("appcache.ReinitAttempt", repeated_attempt); | 18 UMA_HISTOGRAM_BOOLEAN("appcache.ReinitAttempt", repeated_attempt); |
| 19 } | 19 } |
| 20 | 20 |
| 21 void AppCacheHistograms::CountCorruptionDetected() { |
| 22 UMA_HISTOGRAM_BOOLEAN("appcache.CorruptionDetected", true); |
| 23 } |
| 24 |
| 21 void AppCacheHistograms::CountCheckResponseResult( | 25 void AppCacheHistograms::CountCheckResponseResult( |
| 22 CheckResponseResultType result) { | 26 CheckResponseResultType result) { |
| 23 UMA_HISTOGRAM_ENUMERATION( | 27 UMA_HISTOGRAM_ENUMERATION( |
| 24 "appcache.CheckResponseResult", | 28 "appcache.CheckResponseResult", |
| 25 result, NUM_CHECK_RESPONSE_RESULT_TYPES); | 29 result, NUM_CHECK_RESPONSE_RESULT_TYPES); |
| 26 } | 30 } |
| 27 | 31 |
| 28 void AppCacheHistograms::AddTaskQueueTimeSample( | 32 void AppCacheHistograms::AddTaskQueueTimeSample( |
| 29 const base::TimeDelta& duration) { | 33 const base::TimeDelta& duration) { |
| 30 UMA_HISTOGRAM_TIMES("appcache.TaskQueueTime", duration); | 34 UMA_HISTOGRAM_TIMES("appcache.TaskQueueTime", duration); |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 } | 69 } |
| 66 | 70 |
| 67 void AppCacheHistograms::AddMissingManifestDetectedAtCallsite( | 71 void AppCacheHistograms::AddMissingManifestDetectedAtCallsite( |
| 68 MissingManifestCallsiteType callsite) { | 72 MissingManifestCallsiteType callsite) { |
| 69 UMA_HISTOGRAM_ENUMERATION( | 73 UMA_HISTOGRAM_ENUMERATION( |
| 70 "appcache.MissingManifestDetectedAtCallsite", | 74 "appcache.MissingManifestDetectedAtCallsite", |
| 71 callsite, NUM_MISSING_MANIFEST_CALLSITE_TYPES); | 75 callsite, NUM_MISSING_MANIFEST_CALLSITE_TYPES); |
| 72 } | 76 } |
| 73 | 77 |
| 74 } // namespace appcache | 78 } // namespace appcache |
| OLD | NEW |