QNetworkSettingsWireless Class

The QNetworkSettingsWireless class encapsulates the configuration for a Wifi network service. More...

Header: #include <QNetworkSettingsWireless>
qmake: QT += networksettings
Inherits: QObject

Public Types

flags Securities
enum class Security { None, WEP, WPA, WPA2 }

Properties

Public Functions

QNetworkSettingsWireless(QObject *parent = nullptr)
bool hidden() const
bool outOfRange() const
void setHidden(const bool hidden)
void setOutOfRange(const bool aOutOfRange)
void setSecurity(const QNetworkSettingsWireless::Securities securities)
void setSignalStrength(const int signalStrength)
int signalStrength() const
bool supportsSecurity(QNetworkSettingsWireless::Security security)

Signals

Detailed Description

Member Type Documentation

enum class QNetworkSettingsWireless::Security
flags QNetworkSettingsWireless::Securities

This enum type holds the wireless security protocol used to protect the connection.

ConstantValueDescription
QNetworkSettingsWireless::Security::None0x0000Not protected
QNetworkSettingsWireless::Security::WEP0x0002Wired Equivalent Privacy (WEP)
QNetworkSettingsWireless::Security::WPA0x0004Wi-Fi Protected Access (WPA)
QNetworkSettingsWireless::Security::WPA20x0008Wi-Fi Protected Access, version 2 (WPA2)

The Securities type is a typedef for QFlags<Security>. It stores an OR combination of Security values.

Property Documentation

[read-only] hidden : const bool

Holds whether the wireless SSID is hidden.

Access functions:

bool hidden() const

Notifier signal:

void hiddenChanged()

isOutOfRange : bool

Holds whether the Wifi access point is out of range.

Access functions:

bool outOfRange() const
void setOutOfRange(const bool aOutOfRange)

Notifier signal:

void outOfRangeChanged()

signalStrength : int

Holds the Wifi signal strength, in the range from 0 to 100.

Access functions:

int signalStrength() const
void setSignalStrength(const int signalStrength)

Notifier signal:

void signalStrengthChanged()

Member Function Documentation

[explicit] QNetworkSettingsWireless::QNetworkSettingsWireless(QObject *parent = nullptr)

Creates a new Wifi network configuration with the parent parent.

[signal] void QNetworkSettingsWireless::passwordChanged()

This signal is sent when the password has changed.

void QNetworkSettingsWireless::setHidden(const bool hidden)

Sets hidden status.

The QNetworkSettingsWireless::hiddenChanged signal is emitted when the hidden status is changed.

See also hidden().

void QNetworkSettingsWireless::setSecurity(const QNetworkSettingsWireless::Securities securities)

Sets securities flags.

[invokable] bool QNetworkSettingsWireless::supportsSecurity(QNetworkSettingsWireless::Security security)

Returns whether the Wifi network supports the wireless security protocol specified in security.

Note: This function can be invoked via the meta-object system and from QML. See Q_INVOKABLE.

See also QNetworkSettingsWireless::Security.

© 2024 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.