1/*
2 SPDX-FileCopyrightText: 2013 Jan Grulich <jgrulich@redhat.com>
3
4 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5*/
6
7#ifndef NETWORKMANAGERQT_INFINIBAND_DEVICE_H
8#define NETWORKMANAGERQT_INFINIBAND_DEVICE_H
9
10#include "device.h"
11#include <networkmanagerqt/networkmanagerqt_export.h>
12
13namespace NetworkManager
14{
15class InfinibandDevicePrivate;
16
17/**
18 * An infiniband device interface
19 */
20class NETWORKMANAGERQT_EXPORT InfinibandDevice : public Device
21{
22 Q_OBJECT
23 Q_PROPERTY(bool carrier READ carrier NOTIFY carrierChanged)
24 Q_PROPERTY(QString hwAddress READ hwAddress NOTIFY hwAddressChanged)
25
26public:
27 typedef QSharedPointer<InfinibandDevice> Ptr;
28 typedef QList<Ptr> List;
29 explicit InfinibandDevice(const QString &path, QObject *parent = nullptr);
30 ~InfinibandDevice() override;
31
32 Type type() const override;
33
34 /**
35 * Indicates whether the physical carrier is found
36 */
37 bool carrier() const;
38 /**
39 * Hardware address of the device
40 */
41 QString hwAddress() const;
42
43Q_SIGNALS:
44 /**
45 * Emitted when the carrier of this device has changed
46 */
47 void carrierChanged(bool plugged);
48 /**
49 * Emitted when the hardware address of this device has changed
50 */
51 void hwAddressChanged(const QString &address);
52
53private:
54 Q_DECLARE_PRIVATE(InfinibandDevice)
55};
56
57}
58
59#endif
60

source code of networkmanager-qt/src/infinibanddevice.h