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

Side by Side Diff: chromeos/dbus/debug_daemon_client.h

Issue 2944403002: Add GetLog method call to DebugDaemonClient (Closed)
Patch Set: Use separate callback type with string parameter Created 3 years, 6 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 | « no previous file | chromeos/dbus/debug_daemon_client.cc » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_ 5 #ifndef CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_
6 #define CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_ 6 #define CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <sys/types.h> 9 #include <sys/types.h>
10 10
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 // waiting for the result. 107 // waiting for the result.
108 virtual void GetPerfOutput(base::TimeDelta duration, 108 virtual void GetPerfOutput(base::TimeDelta duration,
109 const std::vector<std::string>& perf_args, 109 const std::vector<std::string>& perf_args,
110 int file_descriptor, 110 int file_descriptor,
111 const DBusMethodErrorCallback& error_callback) = 0; 111 const DBusMethodErrorCallback& error_callback) = 0;
112 112
113 // Callback type for GetScrubbedLogs(), GetAllLogs() or GetUserLogFiles(). 113 // Callback type for GetScrubbedLogs(), GetAllLogs() or GetUserLogFiles().
114 using GetLogsCallback = 114 using GetLogsCallback =
115 base::Callback<void(bool succeeded, 115 base::Callback<void(bool succeeded,
116 const std::map<std::string, std::string>& logs)>; 116 const std::map<std::string, std::string>& logs)>;
117 // Callback type for GetLog().
118 using GetLogCallback =
119 base::Callback<void(bool succeeded, const std::string& result)>;
117 120
118 // Gets scrubbed logs from debugd. 121 // Gets scrubbed logs from debugd.
119 virtual void GetScrubbedLogs(const GetLogsCallback& callback) = 0; 122 virtual void GetScrubbedLogs(const GetLogsCallback& callback) = 0;
120 123
121 // Gets the scrubbed logs from debugd that are very large and cannot be 124 // Gets the scrubbed logs from debugd that are very large and cannot be
122 // returned directly from D-Bus. These logs will include ARC and cheets 125 // returned directly from D-Bus. These logs will include ARC and cheets
123 // system information. 126 // system information.
124 virtual void GetScrubbedBigLogs(const GetLogsCallback& callback) = 0; 127 virtual void GetScrubbedBigLogs(const GetLogsCallback& callback) = 0;
125 128
126 // Gets all logs collected by debugd. 129 // Gets all logs collected by debugd.
127 virtual void GetAllLogs(const GetLogsCallback& callback) = 0; 130 virtual void GetAllLogs(const GetLogsCallback& callback) = 0;
128 131
129 // Gets list of user log files that must be read by Chrome. 132 // Gets list of user log files that must be read by Chrome.
130 virtual void GetUserLogFiles(const GetLogsCallback& callback) = 0; 133 virtual void GetUserLogFiles(const GetLogsCallback& callback) = 0;
131 134
135 // Gets an individual log source provided by debugd.
136 virtual void GetLog(const std::string& log_name,
137 const GetLogCallback& callback) = 0;
138
132 virtual void SetStopAgentTracingTaskRunner( 139 virtual void SetStopAgentTracingTaskRunner(
133 scoped_refptr<base::TaskRunner> task_runner) = 0; 140 scoped_refptr<base::TaskRunner> task_runner) = 0;
134 141
135 // Returns an empty StopAgentTracingCallback that does nothing. 142 // Returns an empty StopAgentTracingCallback that does nothing.
136 static StopAgentTracingCallback EmptyStopAgentTracingCallback(); 143 static StopAgentTracingCallback EmptyStopAgentTracingCallback();
137 144
138 // Called once TestICMP() is complete. Takes two parameters: 145 // Called once TestICMP() is complete. Takes two parameters:
139 // - succeeded: information was obtained successfully. 146 // - succeeded: information was obtained successfully.
140 // - status: information about ICMP connectivity to a specified host as json. 147 // - status: information about ICMP connectivity to a specified host as json.
141 // For details please refer to 148 // For details please refer to
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 // Create() should be used instead. 264 // Create() should be used instead.
258 DebugDaemonClient(); 265 DebugDaemonClient();
259 266
260 private: 267 private:
261 DISALLOW_COPY_AND_ASSIGN(DebugDaemonClient); 268 DISALLOW_COPY_AND_ASSIGN(DebugDaemonClient);
262 }; 269 };
263 270
264 } // namespace chromeos 271 } // namespace chromeos
265 272
266 #endif // CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_ 273 #endif // CHROMEOS_DBUS_DEBUG_DAEMON_CLIENT_H_
OLDNEW
« no previous file with comments | « no previous file | chromeos/dbus/debug_daemon_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698