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

Side by Side Diff: chrome/browser/metrics_log.h

Issue 3149: Porting changes in chrome/{browser,common}, also enabling more unit tests.... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 12 years, 3 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 // This file defines a set of user experience metrics data recorded by 5 // This file defines a set of user experience metrics data recorded by
6 // the MetricsService. This is the unit of data that is sent to the server. 6 // the MetricsService. This is the unit of data that is sent to the server.
7 7
8 #ifndef CHROME_BROWSER_METRICS_LOG_H__ 8 #ifndef CHROME_BROWSER_METRICS_LOG_H__
9 #define CHROME_BROWSER_METRICS_LOG_H__ 9 #define CHROME_BROWSER_METRICS_LOG_H__
10 10
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 46
47 static const char* WindowEventTypeToString(WindowEventType type); 47 static const char* WindowEventTypeToString(WindowEventType type);
48 48
49 void RecordWindowEvent(WindowEventType type, int window_id, int parent_id); 49 void RecordWindowEvent(WindowEventType type, int window_id, int parent_id);
50 50
51 // Records a page load. 51 // Records a page load.
52 // window_id - the index of the tab in which the load took place 52 // window_id - the index of the tab in which the load took place
53 // url - which URL was loaded 53 // url - which URL was loaded
54 // origin - what kind of action initiated the load 54 // origin - what kind of action initiated the load
55 // load_time - how long it took to load the page 55 // load_time - how long it took to load the page
56 void MetricsLog::RecordLoadEvent(int window_id, 56 void RecordLoadEvent(int window_id,
57 const GURL& url, 57 const GURL& url,
58 PageTransition::Type origin, 58 PageTransition::Type origin,
59 int session_index, 59 int session_index,
60 TimeDelta load_time); 60 TimeDelta load_time);
61 61
62 // Records the current operating environment. Takes the list of installed 62 // Records the current operating environment. Takes the list of installed
63 // plugins as a parameter because that can't be obtained synchronously 63 // plugins as a parameter because that can't be obtained synchronously
64 // from the UI thread. 64 // from the UI thread.
65 // profile_metrics, if non-null, gives a dictionary of all profile metrics 65 // profile_metrics, if non-null, gives a dictionary of all profile metrics
66 // that are to be recorded. Each value in profile_metrics should be a 66 // that are to be recorded. Each value in profile_metrics should be a
67 // dictionary giving the metrics for the profile. 67 // dictionary giving the metrics for the profile.
68 void RecordEnvironment(const std::vector<WebPluginInfo>& plugin_list, 68 void RecordEnvironment(const std::vector<WebPluginInfo>& plugin_list,
69 const DictionaryValue* profile_metrics); 69 const DictionaryValue* profile_metrics);
70 70
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 175
176 xmlBufferPtr buffer_; 176 xmlBufferPtr buffer_;
177 xmlTextWriterPtr writer_; 177 xmlTextWriterPtr writer_;
178 int num_events_; // the number of events recorded in this log 178 int num_events_; // the number of events recorded in this log
179 179
180 DISALLOW_EVIL_CONSTRUCTORS(MetricsLog); 180 DISALLOW_EVIL_CONSTRUCTORS(MetricsLog);
181 }; 181 };
182 182
183 #endif // CHROME_BROWSER_METRICS_LOG_H__ 183 #endif // CHROME_BROWSER_METRICS_LOG_H__
184 184
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698