File indexing completed on 2024-03-24 15:41:34

0001 /*
0002     SPDX-FileCopyrightText: 2011 Ilia Kats <ilia-kats@gmx.net>
0003     SPDX-FileCopyrightText: 2011-2013 Lamarque V. Souza <lamarque@kde.org>
0004     SPDX-FileCopyrightText: 2013 Daniel Nicoletti <dantti12@gmail.com>
0005 
0006     SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
0007 */
0008 
0009 #ifndef NETWORKMANAGERQT_WIMAXNSP_H
0010 #define NETWORKMANAGERQT_WIMAXNSP_H
0011 
0012 #include <networkmanagerqt/networkmanagerqt_export.h>
0013 
0014 #include <QSharedPointer>
0015 
0016 namespace NetworkManager
0017 {
0018 class WimaxNspPrivate;
0019 
0020 /**
0021  * Wimax network service provider (access point)
0022  */
0023 class NETWORKMANAGERQT_EXPORT WimaxNsp : public QObject
0024 {
0025     Q_OBJECT
0026 public:
0027     typedef QSharedPointer<WimaxNsp> Ptr;
0028     typedef QList<Ptr> List;
0029     /**
0030      * network types a NSP can have
0031      */
0032     enum NetworkType {
0033         Unknown = 0x1,
0034         Home = 0x2,
0035         Partner = 0x3,
0036         RoamingPartner = 0x4,
0037     };
0038 
0039     explicit WimaxNsp(const QString &path, QObject *parent = nullptr);
0040     ~WimaxNsp() override;
0041 
0042     QString uni() const;
0043     /**
0044      * The network type of the NSP
0045      */
0046     NetworkType networkType() const;
0047     /**
0048      * The name of the NSP
0049      */
0050     QString name() const;
0051     /**
0052      * The current signal quality of the NSP, in percent
0053      */
0054     uint signalQuality() const;
0055 
0056 Q_SIGNALS:
0057     /**
0058      * This signal is emitted when the network type of this NSP has changed.
0059      *
0060      * @param type the new type
0061      */
0062     void networkTypeChanged(NetworkType type);
0063 
0064     /**
0065      * This signal is emitted when the name of this NSP has changed
0066      *
0067      * @param name the new name for this NSP
0068      */
0069     void nameChanged(const QString &name);
0070 
0071     /**
0072      * This signal is emitted when the signal quality of this NSP has changed.
0073      *
0074      * @param quality the new quality
0075      */
0076     void signalQualityChanged(uint quality);
0077 
0078 private:
0079     Q_DECLARE_PRIVATE(WimaxNsp)
0080 
0081     WimaxNspPrivate *const d_ptr;
0082 };
0083 }
0084 #endif