File indexing completed on 2024-04-14 03:57:39
0001 /* 0002 SPDX-FileCopyrightText: 2018 Billy Laws <blaws05@gmail.com> 0003 0004 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL 0005 */ 0006 0007 #ifndef NETWORKMANAGERQT_VXLAN_SETTING_H 0008 #define NETWORKMANAGERQT_VXLAN_SETTING_H 0009 0010 #include "setting.h" 0011 #include <networkmanagerqt/networkmanagerqt_export.h> 0012 0013 #include <QString> 0014 0015 namespace NetworkManager 0016 { 0017 class VxlanSettingPrivate; 0018 0019 /** 0020 * Represents vxlan setting 0021 */ 0022 class NETWORKMANAGERQT_EXPORT VxlanSetting : public Setting 0023 { 0024 public: 0025 typedef QSharedPointer<VxlanSetting> Ptr; 0026 typedef QList<Ptr> List; 0027 VxlanSetting(); 0028 explicit VxlanSetting(const Ptr &other); 0029 ~VxlanSetting() override; 0030 0031 QString name() const override; 0032 0033 void setAgeing(quint32 ageing); 0034 quint32 ageing() const; 0035 0036 void setDestinationPort(quint32 port); 0037 quint32 destinationPort() const; 0038 0039 void setId(quint32 id); 0040 quint32 id() const; 0041 0042 void setL2Miss(bool enable); 0043 bool l2Miss() const; 0044 0045 void setL3Miss(bool enable); 0046 bool l3Miss() const; 0047 0048 void setLearning(bool enable); 0049 bool learning() const; 0050 0051 void setLimit(quint32 limit); 0052 quint32 limit() const; 0053 0054 void setLocal(QString local); 0055 QString local() const; 0056 0057 void setParent(QString parent); 0058 QString parent() const; 0059 0060 void setProxy(bool enable); 0061 bool proxy() const; 0062 0063 void setRemote(QString remote); 0064 QString remote() const; 0065 0066 void setRsc(bool enable); 0067 bool rsc() const; 0068 0069 void setSourcePortMax(quint32 maxPort); 0070 quint32 sourcePortMax() const; 0071 0072 void setSourcePortMin(quint32 minPort); 0073 quint32 sourcePortMin() const; 0074 0075 void setTos(quint32 tos); 0076 quint32 tos() const; 0077 0078 void setTtl(quint32 ttl); 0079 quint32 ttl() const; 0080 0081 void fromMap(const QVariantMap &setting) override; 0082 0083 QVariantMap toMap() const override; 0084 0085 protected: 0086 VxlanSettingPrivate *d_ptr; 0087 0088 private: 0089 Q_DECLARE_PRIVATE(VxlanSetting) 0090 }; 0091 0092 NETWORKMANAGERQT_EXPORT QDebug operator<<(QDebug dbg, const VxlanSetting &setting); 0093 0094 } 0095 0096 #endif // NETWORKMANAGERQT_VXLAN_SETTING_H