Changeset View
Changeset View
Standalone View
Standalone View
autotests/testremoterunner.h
1 | /* | ||||
---|---|---|---|---|---|
2 | * Copyright (C) 2017 David Edmundson <davidedmundson@kde.org> | ||||
3 | * | ||||
4 | * This program is free software; you can redistribute it and/or modify | ||||
5 | * it under the terms of the GNU Library General Public License version 2 as | ||||
6 | * published by the Free Software Foundation | ||||
7 | * | ||||
8 | * This program is distributed in the hope that it will be useful, | ||||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||||
11 | * GNU General Public License for more details | ||||
12 | * | ||||
13 | * You should have received a copy of the GNU Library General Public | ||||
14 | * License along with this program; if not, write to the | ||||
15 | * Free Software Foundation, Inc., | ||||
16 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||||
17 | */ | ||||
18 | | ||||
1 | #pragma once | 19 | #pragma once | ||
2 | 20 | | |||
3 | #include <QObject> | 21 | #include <KDBusRunner/AbstractRunner> | ||
4 | #include "../src/dbusutils_p.h" | | |||
5 | 22 | | |||
6 | class TestRemoteRunner : public QObject | 23 | class TestRemoteRunner : public KDBusRunner::AbstractRunner | ||
7 | { | 24 | { | ||
8 | Q_OBJECT | 25 | Q_OBJECT | ||
9 | public: | 26 | public: | ||
10 | TestRemoteRunner(const QString &serviceName); | 27 | TestRemoteRunner(const QString &serviceName); | ||
11 | 28 | | |||
12 | public Q_SLOTS: | 29 | public: | ||
13 | RemoteActions Actions(); | 30 | KDBusRunner::Actions actions() const override; | ||
14 | RemoteMatches Match(const QString &searchTerm); | 31 | void handleMatchRequest(const KDBusRunner::MatchReply::Ptr &matchReply) override; | ||
15 | void Run(const QString &id, const QString &actionId); | 32 | void run(const QString &matchId, const QString &actionId) override; | ||
16 | }; | 33 | }; |