1 | /* |
2 | SPDX-FileCopyrightText: 2012-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_CDMA_SETTINGS_H |
8 | #define NETWORKMANAGERQT_CDMA_SETTINGS_H |
9 | |
10 | #include "setting.h" |
11 | #include <networkmanagerqt/networkmanagerqt_export.h> |
12 | |
13 | #include <QString> |
14 | |
15 | namespace NetworkManager |
16 | { |
17 | class CdmaSettingPrivate; |
18 | |
19 | /** |
20 | * Represents cdma setting |
21 | */ |
22 | class NETWORKMANAGERQT_EXPORT CdmaSetting : public Setting |
23 | { |
24 | public: |
25 | typedef QSharedPointer<CdmaSetting> Ptr; |
26 | typedef QList<Ptr> List; |
27 | CdmaSetting(); |
28 | explicit CdmaSetting(const Ptr &other); |
29 | ~CdmaSetting() override; |
30 | |
31 | QString name() const override; |
32 | |
33 | void setNumber(const QString &number); |
34 | QString number() const; |
35 | |
36 | void setUsername(const QString &username); |
37 | QString username() const; |
38 | |
39 | void setPassword(const QString &password); |
40 | QString password() const; |
41 | |
42 | void setPasswordFlags(SecretFlags flags); |
43 | SecretFlags passwordFlags() const; |
44 | |
45 | QStringList needSecrets(bool requestNew = false) const override; |
46 | |
47 | void secretsFromMap(const QVariantMap &secrets) override; |
48 | |
49 | QVariantMap secretsToMap() const override; |
50 | |
51 | void fromMap(const QVariantMap &setting) override; |
52 | |
53 | QVariantMap toMap() const override; |
54 | |
55 | protected: |
56 | CdmaSettingPrivate *d_ptr; |
57 | |
58 | private: |
59 | Q_DECLARE_PRIVATE(CdmaSetting) |
60 | }; |
61 | |
62 | NETWORKMANAGERQT_EXPORT QDebug operator<<(QDebug dbg, const CdmaSetting &setting); |
63 | |
64 | } |
65 | |
66 | #endif // NETWORKMANAGERQT_CDMA_SETTINGS_H |
67 | |