OLD | NEW |
1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2015 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 "components/tracing/trace_config_file.h" | 5 #include "components/tracing/browser/trace_config_file.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <memory> | 9 #include <memory> |
10 #include <string> | 10 #include <string> |
11 | 11 |
12 #include "base/command_line.h" | 12 #include "base/command_line.h" |
13 #include "base/files/file_util.h" | 13 #include "base/files/file_util.h" |
14 #include "base/json/json_reader.h" | 14 #include "base/json/json_reader.h" |
15 #include "base/logging.h" | 15 #include "base/logging.h" |
16 #include "base/memory/singleton.h" | 16 #include "base/memory/singleton.h" |
17 #include "base/values.h" | 17 #include "base/values.h" |
18 #include "build/build_config.h" | 18 #include "build/build_config.h" |
19 #include "components/tracing/tracing_switches.h" | 19 #include "components/tracing/common/tracing_switches.h" |
20 | 20 |
21 namespace tracing { | 21 namespace tracing { |
22 | 22 |
23 namespace { | 23 namespace { |
24 | 24 |
25 // Maximum trace config file size that will be loaded, in bytes. | 25 // Maximum trace config file size that will be loaded, in bytes. |
26 const size_t kTraceConfigFileSizeLimit = 64 * 1024; | 26 const size_t kTraceConfigFileSizeLimit = 64 * 1024; |
27 | 27 |
28 // Trace config file path: | 28 // Trace config file path: |
29 // - Android: /data/local/chrome-trace-config.json | 29 // - Android: /data/local/chrome-trace-config.json |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
138 } | 138 } |
139 | 139 |
140 #if !defined(OS_ANDROID) | 140 #if !defined(OS_ANDROID) |
141 base::FilePath TraceConfigFile::GetResultFile() const { | 141 base::FilePath TraceConfigFile::GetResultFile() const { |
142 DCHECK(IsEnabled()); | 142 DCHECK(IsEnabled()); |
143 return result_file_; | 143 return result_file_; |
144 } | 144 } |
145 #endif | 145 #endif |
146 | 146 |
147 } // namespace tracing | 147 } // namespace tracing |
OLD | NEW |