File indexing completed on 2024-05-12 17:00:15

0001 /*
0002  * SPDX-FileCopyrightText: 2020 Arjen Hiemstra <ahiemstra@heimr.nl>
0003  * 
0004  * SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0005  */
0006 
0007 #pragma once
0008 
0009 #include <QObject>
0010 
0011 class NetworkDevice;
0012 
0013 class NetworkBackend : public QObject
0014 {
0015     Q_OBJECT
0016 
0017 public:
0018     NetworkBackend(QObject* parent = nullptr) : QObject(parent) { }
0019     ~NetworkBackend() override = default;
0020 
0021     virtual bool isSupported() = 0;
0022     virtual void start() = 0;
0023     virtual void stop() = 0;
0024     virtual void update() {};
0025 
0026     Q_SIGNAL void deviceAdded(NetworkDevice *device);
0027     Q_SIGNAL void deviceRemoved(NetworkDevice *device);
0028 };