blob: 5835b4ea96b41debb8852932e0c28190909583e1 [file] [log] [blame]
Elly Jones0b6bd182012-02-14 18:24:22 -05001// Copyright (c) 2012 The Chromium OS 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
Alex Vakulenko262be3f2014-07-30 15:25:50 -07005#ifndef DEBUGD_SRC_DEBUG_LOGS_TOOL_H_
6#define DEBUGD_SRC_DEBUG_LOGS_TOOL_H_
Elly Jones0b6bd182012-02-14 18:24:22 -05007
Eric Caruso0b241882018-04-04 13:43:46 -07008#include <base/files/scoped_file.h>
Ben Chan657bed82014-09-02 20:40:51 -07009#include <base/macros.h>
Brian Norrisca4fc042018-04-03 00:24:26 -070010#include <dbus/bus.h>
Elly Jones0b6bd182012-02-14 18:24:22 -050011
12namespace debugd {
13
14class DebugLogsTool {
15 public:
Brian Norrisca4fc042018-04-03 00:24:26 -070016 explicit DebugLogsTool(scoped_refptr<dbus::Bus> bus) : bus_(bus) {}
Ben Chan78f89532014-08-29 09:35:09 -070017 ~DebugLogsTool() = default;
Elly Jones0b6bd182012-02-14 18:24:22 -050018
Tom Hughesd6c2d392020-08-24 18:12:11 -070019 void GetDebugLogs(bool is_compressed, const base::ScopedFD& fd);
Ben Chana0011d82014-05-13 00:19:29 -070020
Elly Jones0b6bd182012-02-14 18:24:22 -050021 private:
Brian Norrisca4fc042018-04-03 00:24:26 -070022 scoped_refptr<dbus::Bus> bus_;
23
Elly Jones0b6bd182012-02-14 18:24:22 -050024 DISALLOW_COPY_AND_ASSIGN(DebugLogsTool);
25};
26
Ben Chana0011d82014-05-13 00:19:29 -070027} // namespace debugd
Elly Jones0b6bd182012-02-14 18:24:22 -050028
Alex Vakulenko262be3f2014-07-30 15:25:50 -070029#endif // DEBUGD_SRC_DEBUG_LOGS_TOOL_H_