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 "content/browser/histogram_internals_request_job.h" | 5 #include "content/browser/histogram_internals_request_job.h" |
6 | 6 |
7 #include "base/metrics/histogram.h" | 7 #include "base/metrics/histogram.h" |
8 #include "base/metrics/statistics_recorder.h" | 8 #include "base/metrics/statistics_recorder.h" |
9 #include "content/browser/histogram_synchronizer.h" | 9 #include "content/browser/histogram_synchronizer.h" |
10 #include "googleurl/src/gurl.h" | |
11 #include "net/base/escape.h" | 10 #include "net/base/escape.h" |
12 #include "net/base/net_errors.h" | 11 #include "net/base/net_errors.h" |
13 #include "net/url_request/url_request.h" | 12 #include "net/url_request/url_request.h" |
| 13 #include "url/gurl.h" |
14 | 14 |
15 namespace content { | 15 namespace content { |
16 | 16 |
17 HistogramInternalsRequestJob::HistogramInternalsRequestJob( | 17 HistogramInternalsRequestJob::HistogramInternalsRequestJob( |
18 net::URLRequest* request, net::NetworkDelegate* network_delegate) | 18 net::URLRequest* request, net::NetworkDelegate* network_delegate) |
19 : net::URLRequestSimpleJob(request, network_delegate) { | 19 : net::URLRequestSimpleJob(request, network_delegate) { |
20 const std::string& spec = request->url().possibly_invalid_spec(); | 20 const std::string& spec = request->url().possibly_invalid_spec(); |
21 const url_parse::Parsed& parsed = | 21 const url_parse::Parsed& parsed = |
22 request->url().parsed_for_possibly_invalid_spec(); | 22 request->url().parsed_for_possibly_invalid_spec(); |
23 // + 1 to skip the slash at the beginning of the path. | 23 // + 1 to skip the slash at the beginning of the path. |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 const net::CompletionCallback& callback) const { | 62 const net::CompletionCallback& callback) const { |
63 mime_type->assign("text/html"); | 63 mime_type->assign("text/html"); |
64 charset->assign("UTF8"); | 64 charset->assign("UTF8"); |
65 | 65 |
66 data->clear(); | 66 data->clear(); |
67 AboutHistogram(data, path_); | 67 AboutHistogram(data, path_); |
68 return net::OK; | 68 return net::OK; |
69 } | 69 } |
70 | 70 |
71 } // namespace content | 71 } // namespace content |
OLD | NEW |