|
tuned-switcher 1.1.0
Performance profile manager
|
#include <systemdservice.h>


Public Member Functions | |
| SystemdService (QObject *parent=nullptr) | |
| ~SystemdService () override=default | |
| bool | IsSupported () const override |
| bool | IsRunning () const override |
| bool | Start () const override |
| bool | Stop () const override |
Public Member Functions inherited from ServiceManager | |
| virtual | ~ServiceManager ()=default |
Private Member Functions | |
| QString | GetServiceState (const QString &) const |
Private Attributes | |
| const QString | SystemdBusName = QStringLiteral("org.freedesktop.systemd1") |
| const QString | SystemdBusPath = QStringLiteral("/org/freedesktop/systemd1") |
| const QString | SystemdBusInterfaceManager = QStringLiteral("org.freedesktop.systemd1.Manager") |
| const QString | SystemdBusInterfaceUnit = QStringLiteral("org.freedesktop.systemd1.Unit") |
| const QString | SystemdBusMethodNameGetUnit = QStringLiteral("GetUnit") |
| const QString | SystemdBusMethodNameStart = QStringLiteral("StartUnit") |
| const QString | SystemdBusMethodNameStop = QStringLiteral("StopUnit") |
| const QString | SystemdBusPropertyNameActiveState = QStringLiteral("ActiveState") |
| const QString | SystemdBusPropertyNameSystemState = QStringLiteral("SystemState") |
| const QString | SystemdBusValueServiceActive = QStringLiteral("active") |
| const QString | SystemdTunedServiceName = QStringLiteral("tuned.service") |
| const QString | SystemdTunedServiceMode = QStringLiteral("replace") |
| const QString | DBusPropertyInterface = QStringLiteral("org.freedesktop.DBus.Properties") |
| const QString | DBusPropertyMethodNameGet = QStringLiteral("Get") |
| QDBusConnection | DBusInstance = QDBusConnection::systemBus() |
Additional Inherited Members | |
Static Public Member Functions inherited from ServiceManager | |
| static ServiceManager * | Create (QObject *parent=nullptr) |
Protected Member Functions inherited from ServiceManager | |
| ServiceManager (QObject *parent=nullptr) | |
Class for working with the systemd service manager.
|
explicit |
Main constructor of the SystemdService class.
| parent | Parent. |
|
overridedefault |
Destructor of the SystemdService class.
|
private |
Get the state of the Tuned service.
| BusPath | DBus service object path. |
|
overridevirtual |
Check whether the Tuned service is running using the DBus API.
| true | The Tuned service is running. |
| false | The Tuned servic is not running. |
Implements ServiceManager.
|
overridevirtual |
Check whether the service control feature is supported.
| true | The service control feature is supported. |
| false | The service control feature is not supported. |
Implements ServiceManager.
|
overridevirtual |
Start the Tuned service using the DBus API.
| true | The Tuned service was successfully started. |
| false | An error occurred when trying to start the Tuned service. |
Implements ServiceManager.
|
overridevirtual |
Stop the Tuned service using the DBus API.
| true | The Tuned service was successfully stopped. |
| false | An error occurred when trying to stop the Tuned service. |
Implements ServiceManager.
|
private |
Stores DBus instance.
|
private |
Stores the Systemd Properties DBus interface.
|
private |
Stores the Systemd DBus GetProperty method name.
|
private |
Stores the Systemd Manager DBus interface.
|
private |
Stores the Systemd Unit DBus interface.
|
private |
Stores the Systemd DBus GetUnit method name.
|
private |
Stores the Systemd DBus MethodNameStart method name.
|
private |
Stores the Systemd DBus MethodNameStop method name.
|
private |
Stores the Systemd DBus interface name.
|
private |
Stores the Systemd DBus object path.
|
private |
Stores the Systemd DBus ActiveState property name.
|
private |
Stores the Systemd DBus SystemState property name.
|
private |
Stores the Tuned DBus ServiceActive value.
|
private |
Stores the Systemd start/stop service mode.
|
private |
Stores the Tuned Systemd service name.