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

Side by Side Diff: content/public/browser/tracing_delegate.h

Issue 1874903002: Convert //content from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix indent Created 4 years, 8 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
« no previous file with comments | « content/public/browser/tracing_controller.h ('k') | content/public/browser/web_contents.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 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 #ifndef CONTENT_PUBLIC_BROWSER_TRACING_DELEGATE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_TRACING_DELEGATE_H_
6 #define CONTENT_PUBLIC_BROWSER_TRACING_DELEGATE_H_ 6 #define CONTENT_PUBLIC_BROWSER_TRACING_DELEGATE_H_
7 7
8 #include <memory>
8 #include <string> 9 #include <string>
9 10
10 #include "base/callback.h" 11 #include "base/callback.h"
11 #include "base/memory/scoped_ptr.h"
12 #include "content/common/content_export.h" 12 #include "content/common/content_export.h"
13 13
14 namespace base { 14 namespace base {
15 class DictionaryValue; 15 class DictionaryValue;
16 class Time; 16 class Time;
17 } 17 }
18 18
19 namespace net { 19 namespace net {
20 class URLRequestContextGetter; 20 class URLRequestContextGetter;
21 } 21 }
22 22
23 namespace content { 23 namespace content {
24 class BackgroundTracingConfig; 24 class BackgroundTracingConfig;
25 class TraceUploader; 25 class TraceUploader;
26 26
27 typedef base::Callback<bool(const std::string& metadata_name)> 27 typedef base::Callback<bool(const std::string& metadata_name)>
28 MetadataFilterPredicate; 28 MetadataFilterPredicate;
29 29
30 // This can be implemented by the embedder to provide functionality for the 30 // This can be implemented by the embedder to provide functionality for the
31 // about://tracing WebUI. 31 // about://tracing WebUI.
32 class CONTENT_EXPORT TracingDelegate { 32 class CONTENT_EXPORT TracingDelegate {
33 public: 33 public:
34 virtual ~TracingDelegate() {} 34 virtual ~TracingDelegate() {}
35 35
36 // Provide trace uploading functionality; see trace_uploader.h. 36 // Provide trace uploading functionality; see trace_uploader.h.
37 virtual scoped_ptr<TraceUploader> GetTraceUploader( 37 virtual std::unique_ptr<TraceUploader> GetTraceUploader(
38 net::URLRequestContextGetter* request_context) = 0; 38 net::URLRequestContextGetter* request_context) = 0;
39 39
40 // This can be used to veto a particular background tracing scenario. 40 // This can be used to veto a particular background tracing scenario.
41 virtual bool IsAllowedToBeginBackgroundScenario( 41 virtual bool IsAllowedToBeginBackgroundScenario(
42 const BackgroundTracingConfig& config, 42 const BackgroundTracingConfig& config,
43 bool requires_anonymized_data); 43 bool requires_anonymized_data);
44 44
45 virtual bool IsAllowedToEndBackgroundScenario( 45 virtual bool IsAllowedToEndBackgroundScenario(
46 const content::BackgroundTracingConfig& config, 46 const content::BackgroundTracingConfig& config,
47 bool requires_anonymized_data); 47 bool requires_anonymized_data);
48 48
49 // Used to add any additional metadata to traces. 49 // Used to add any additional metadata to traces.
50 virtual void GenerateMetadataDict(base::DictionaryValue* metadata_dict) {} 50 virtual void GenerateMetadataDict(base::DictionaryValue* metadata_dict) {}
51 51
52 virtual MetadataFilterPredicate GetMetadataFilterPredicate(); 52 virtual MetadataFilterPredicate GetMetadataFilterPredicate();
53 }; 53 };
54 54
55 } // namespace content 55 } // namespace content
56 56
57 #endif // CONTENT_PUBLIC_BROWSER_TRACING_DELEGATE_H_ 57 #endif // CONTENT_PUBLIC_BROWSER_TRACING_DELEGATE_H_
OLDNEW
« no previous file with comments | « content/public/browser/tracing_controller.h ('k') | content/public/browser/web_contents.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698