Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1294)

Unified Diff: content/browser/histogram_internals_request_job.h

Issue 2874623002: Implement chrome://histograms with network service. (Closed)
Patch Set: add comment Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/browser/histogram_internals_request_job.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/histogram_internals_request_job.h
diff --git a/content/browser/histogram_internals_request_job.h b/content/browser/histogram_internals_request_job.h
index 475188d7c3afa5609f50cf39dfc4f4118723bd9c..1dd090233dba5e3c38b02dafb4b40ea3511f5a4a 100644
--- a/content/browser/histogram_internals_request_job.h
+++ b/content/browser/histogram_internals_request_job.h
@@ -10,6 +10,7 @@
#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "net/url_request/url_request_simple_job.h"
+#include "url/gurl.h"
namespace content {
@@ -25,14 +26,21 @@ class HistogramInternalsRequestJob : public net::URLRequestSimpleJob {
std::string* data,
const net::CompletionCallback& callback) const override;
+ // Generates the HTML for chrome://histograms. If |url| has a path, it's used
+ // to display a single histogram.
+ // base::StatisticsRecorder::ImportProvidedHistograms must have been called
+ // on the UI thread first.
+ static std::string GenerateHTML(const GURL& url);
+
private:
~HistogramInternalsRequestJob() override;
// Starts the real URL request.
void StartUrlRequest();
- // The string to select histograms which have |path_| as a substring.
- std::string path_;
+ // The URL that was requested, which might have a path component to a specific
+ // histogram.
+ GURL url_;
base::WeakPtrFactory<HistogramInternalsRequestJob> weak_factory_;
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/browser/histogram_internals_request_job.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698