1// SPDX-FileCopyrightText: 2023 UnionTech Software Technology Co., Ltd.
2//
3// SPDX-License-Identifier: GPL-3.0-or-later
4
5#ifndef DEBUGGERSERVICE_H
6#define DEBUGGERSERVICE_H
7
8#include <framework/framework.h>
9#include "base/abstractdebugger.h"
10
11namespace dpfservice {
12
13class DebuggerService final : public dpf::PluginService,
14 dpf::AutoServiceRegister<DebuggerService>
15{
16 Q_OBJECT
17 Q_DISABLE_COPY(DebuggerService)
18
19public:
20 explicit DebuggerService(QObject *parent = nullptr)
21 : dpf::PluginService (parent)
22 {
23
24 }
25
26 static QString name()
27 {
28 return "org.deepin.service.DebuggerService";
29 }
30
31 /**
32 * @brief runCoredump launch debugger and debug coredump file.
33 * @param target debugee file path.
34 * @param core coredump file path.
35 * @param kit current project kit.
36 */
37 DPF_INTERFACE(bool, runCoredump, const QString &target, const QString &core, const QString &kit);
38
39 /**
40 * @brief DPF_INTERFACE
41 * @param kit
42 * @param debugger
43 */
44 DPF_INTERFACE(void, registerDebugger, const QString &kit, AbstractDebugger *debugger);
45};
46
47} // namespace dpfservice
48#endif // DEBUGGERSERVICE_H
49