QWifiDevice Class

Represents a physical device. More...

Header: #include <QWifiDevice>
Inherits: QObject

Public Functions

  • 31 public functions inherited from QObject

Static Public Members

void setWifiInterfaceName(const QByteArray &name)
QByteArray wifiInterfaceName()
bool wifiSupported()
  • 10 static public members inherited from QObject

Additional Inherited Members

  • 1 property inherited from QObject
  • 1 public slot inherited from QObject
  • 2 signals inherited from QObject
  • 1 public variable inherited from QObject
  • 9 protected functions inherited from QObject
  • 2 protected variables inherited from QObject

Detailed Description

Represents a physical device.

Use this class to query if a device is Wifi capable, before attempting to use the functionality of QWifiManager.

QWifiManager *m_wifiManager = 0;
if (QWifiDevice::wifiSupported())
    m_wifiManager = QWifiManager::instance();

if (m_wifiManager) {
    // and other wifi related code

Member Function Documentation


[virtual] QWifiDevice::~QWifiDevice()

Destroys the instance of QWifiDevice. The destructor is virtual.

[static] void QWifiDevice::setWifiInterfaceName(const QByteArray &name)

A conveniece method to set the Wifi interface name.

See also wifiInterfaceName().

[static] QByteArray QWifiDevice::wifiInterfaceName()

Returns Wifi interface name.

Interface name is read from the B2QT_WIFI_INTERFACE environment variable if it is set, otherwise, the default interface name ("wlan0") is used.

See also setWifiInterfaceName().

[static] bool QWifiDevice::wifiSupported()

Returns true if a device is Wifi capable - Wifi driver and firmware has been successfully loaded by the system, otherwise returns false.

Available under certain Qt licenses.
Find out more.