Solid

upowerdbusinterface.cpp
1/*
2 SPDX-FileCopyrightText: 2023 Stefan BrĂ¼ns <stefan.bruens@rwth-aachen.de>
3
4 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5*/
6
7#include "upower.h"
8#include "upowerdbusinterface.h"
9
10#include <QString>
11
12using DBusInterface = Solid::Backends::UPower::DBusInterface;
13
14namespace {
15
16const auto upowerServiceName = QStringLiteral(UP_DBUS_SERVICE);
17const auto upowerDBusPath = QStringLiteral(UP_DBUS_PATH);
18const char* upowerInterfaceName = UP_DBUS_INTERFACE;
19
20} // anonymous
21
22
23DBusInterface::DBusInterface(const QDBusConnection &connection, QObject *parent)
24 : QDBusAbstractInterface(upowerServiceName, upowerDBusPath, upowerInterfaceName, connection, parent)
25{
26}
27
28DBusInterface::~DBusInterface() = default;
29
30QDBusPendingReply<QList<QDBusObjectPath>> DBusInterface::EnumerateDevices()
31{
32 return asyncCall(QStringLiteral("EnumerateDevices"));
33}
34
35#include "moc_upowerdbusinterface.cpp"
QDBusPendingCall asyncCall(const QString &method, Args &&... args)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri May 24 2024 11:56:28 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.