OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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 // Message definition file, included multiple times, hence no include guard. | 5 // Message definition file, included multiple times, hence no include guard. |
6 | 6 |
7 #include "base/time/time.h" | 7 #include "base/time/time.h" |
8 #include "components/subresource_filter/core/common/activation_level.h" | 8 #include "components/subresource_filter/core/common/activation_level.h" |
9 #include "components/subresource_filter/core/common/activation_state.h" | 9 #include "components/subresource_filter/core/common/activation_state.h" |
10 #include "components/subresource_filter/core/common/document_load_statistics.h" | 10 #include "components/subresource_filter/core/common/document_load_statistics.h" |
11 #include "content/public/common/common_param_traits_macros.h" | 11 #include "content/public/common/common_param_traits_macros.h" |
12 #include "ipc/ipc_message.h" | 12 #include "ipc/ipc_message.h" |
13 #include "ipc/ipc_message_macros.h" | 13 #include "ipc/ipc_message_macros.h" |
14 #include "ipc/ipc_platform_file.h" | 14 #include "ipc/ipc_platform_file.h" |
15 #include "url/ipc/url_param_traits.h" | 15 #include "url/ipc/url_param_traits.h" |
16 | 16 |
17 #define IPC_MESSAGE_START SubresourceFilterMsgStart | 17 #define IPC_MESSAGE_START SubresourceFilterMsgStart |
18 | 18 |
19 IPC_ENUM_TRAITS_MAX_VALUE(subresource_filter::ActivationLevel, | 19 IPC_ENUM_TRAITS_MAX_VALUE(subresource_filter::ActivationLevel, |
20 subresource_filter::ActivationLevel::LAST); | 20 subresource_filter::ActivationLevel::LAST); |
21 | 21 |
22 IPC_STRUCT_TRAITS_BEGIN(subresource_filter::ActivationState) | 22 IPC_STRUCT_TRAITS_BEGIN(subresource_filter::ActivationState) |
23 IPC_STRUCT_TRAITS_MEMBER(activation_level) | 23 IPC_STRUCT_TRAITS_MEMBER(activation_level) |
24 IPC_STRUCT_TRAITS_MEMBER(filtering_disabled_for_document) | 24 IPC_STRUCT_TRAITS_MEMBER(filtering_disabled_for_document) |
25 IPC_STRUCT_TRAITS_MEMBER(generic_blocking_rules_disabled) | 25 IPC_STRUCT_TRAITS_MEMBER(generic_blocking_rules_disabled) |
26 IPC_STRUCT_TRAITS_MEMBER(measure_performance) | 26 IPC_STRUCT_TRAITS_MEMBER(measure_performance) |
| 27 IPC_STRUCT_TRAITS_MEMBER(enable_logging) |
27 IPC_STRUCT_TRAITS_END() | 28 IPC_STRUCT_TRAITS_END() |
28 | 29 |
29 IPC_STRUCT_TRAITS_BEGIN(subresource_filter::DocumentLoadStatistics) | 30 IPC_STRUCT_TRAITS_BEGIN(subresource_filter::DocumentLoadStatistics) |
30 IPC_STRUCT_TRAITS_MEMBER(num_loads_total) | 31 IPC_STRUCT_TRAITS_MEMBER(num_loads_total) |
31 IPC_STRUCT_TRAITS_MEMBER(num_loads_evaluated) | 32 IPC_STRUCT_TRAITS_MEMBER(num_loads_evaluated) |
32 IPC_STRUCT_TRAITS_MEMBER(num_loads_matching_rules) | 33 IPC_STRUCT_TRAITS_MEMBER(num_loads_matching_rules) |
33 IPC_STRUCT_TRAITS_MEMBER(num_loads_disallowed) | 34 IPC_STRUCT_TRAITS_MEMBER(num_loads_disallowed) |
34 IPC_STRUCT_TRAITS_MEMBER(evaluation_total_wall_duration) | 35 IPC_STRUCT_TRAITS_MEMBER(evaluation_total_wall_duration) |
35 IPC_STRUCT_TRAITS_MEMBER(evaluation_total_cpu_duration) | 36 IPC_STRUCT_TRAITS_MEMBER(evaluation_total_cpu_duration) |
36 IPC_STRUCT_TRAITS_END() | 37 IPC_STRUCT_TRAITS_END() |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 | 72 |
72 // This is sent to a RenderFrameHost in the browser when a document load is | 73 // This is sent to a RenderFrameHost in the browser when a document load is |
73 // finished, just before the DidFinishLoad message, and contains statistics | 74 // finished, just before the DidFinishLoad message, and contains statistics |
74 // collected by the DocumentSubresourceFilter up until that point: the number of | 75 // collected by the DocumentSubresourceFilter up until that point: the number of |
75 // subresources evaluated/disallowed/etc, and total time spent on evaluating | 76 // subresources evaluated/disallowed/etc, and total time spent on evaluating |
76 // subresource loads in its allowLoad method. The time metrics are equal to zero | 77 // subresource loads in its allowLoad method. The time metrics are equal to zero |
77 // if performance measurements were disabled for the load. | 78 // if performance measurements were disabled for the load. |
78 IPC_MESSAGE_ROUTED1( | 79 IPC_MESSAGE_ROUTED1( |
79 SubresourceFilterHostMsg_DocumentLoadStatistics, | 80 SubresourceFilterHostMsg_DocumentLoadStatistics, |
80 subresource_filter::DocumentLoadStatistics /* statistics */); | 81 subresource_filter::DocumentLoadStatistics /* statistics */); |
OLD | NEW |