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

Side by Side Diff: components/subresource_filter/content/common/document_load_statistics.h

Issue 2697363005: Move DocumentSubresourceFilter to core/common. (Closed)
Patch Set: Address comments from engedy@. Created 3 years, 10 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
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef COMPONENTS_SUBRESOURCE_FILTER_CONTENT_COMMON_DOCUMENT_LOAD_STATISTICS_H_
6 #define COMPONENTS_SUBRESOURCE_FILTER_CONTENT_COMMON_DOCUMENT_LOAD_STATISTICS_H_
7
8 #include <stdint.h>
9
10 #include "base/time/time.h"
11
12 namespace subresource_filter {
13
14 // Contains statistics and performance metrics collected by the
15 // DocumentSubresourceFilter.
16 struct DocumentLoadStatistics {
17 // The number of subresource loads that went through the
18 // DocumentSubresouceFilter::allowLoad method.
19 int32_t num_loads_total = 0;
20
21 // Statistics on the number of subresource loads that were evaluated, were
22 // matched by filtering rules, and were disallowed, respectively, during the
23 // lifetime of a DocumentSubresourceFilter.
24 int32_t num_loads_evaluated = 0;
25 int32_t num_loads_matching_rules = 0;
26 int32_t num_loads_disallowed = 0;
27
28 // Total time spent in allowLoad() calls while evaluating subresource loads.
29 base::TimeDelta evaluation_total_wall_duration;
30 base::TimeDelta evaluation_total_cpu_duration;
31 };
32
33 } // namespace subresource_filter
34
35 #endif // COMPONENTS_SUBRESOURCE_FILTER_CONTENT_COMMON_DOCUMENT_LOAD_STATISTICS _H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698