| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "components/metrics/histogram_manager.h" | 5 #include "components/cronet/histogram_manager.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/lazy_instance.h" | 10 #include "base/lazy_instance.h" |
| 11 #include "base/metrics/histogram.h" | 11 #include "base/metrics/histogram.h" |
| 12 #include "base/metrics/histogram_samples.h" | 12 #include "base/metrics/histogram_samples.h" |
| 13 #include "components/metrics/histogram_encoder.h" | 13 #include "components/metrics/histogram_encoder.h" |
| 14 | 14 |
| 15 namespace metrics { | 15 namespace metrics { |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 58 base::Histogram::kNoFlags, base::Histogram::kUmaTargetedHistogramFlag); | 58 base::Histogram::kNoFlags, base::Histogram::kUmaTargetedHistogramFlag); |
| 59 int32_t data_size = uma_proto_.ByteSize(); | 59 int32_t data_size = uma_proto_.ByteSize(); |
| 60 data->resize(data_size); | 60 data->resize(data_size); |
| 61 if (uma_proto_.SerializeToArray(&(*data)[0], data_size)) | 61 if (uma_proto_.SerializeToArray(&(*data)[0], data_size)) |
| 62 return true; | 62 return true; |
| 63 data->clear(); | 63 data->clear(); |
| 64 return false; | 64 return false; |
| 65 } | 65 } |
| 66 | 66 |
| 67 } // namespace metrics | 67 } // namespace metrics |
| OLD | NEW |