diff options
author | Topi Reinio <topi.reinio@theqtcompany.com> | 2016-08-23 15:12:03 +0200 |
---|---|---|
committer | Topi Reiniƶ <topi.reinio@theqtcompany.com> | 2016-09-06 07:22:31 +0000 |
commit | 57b15814c8865e517c43fe173c0ffcadf8557ade (patch) | |
tree | 35c238f57be475e69abd3e34baa32a136739dfd5 /src/networksettings/qnetworksettingsinterface.cpp | |
parent | 1812b8e95b8b27b0879c97e66fcda739b502f7aa (diff) |
Doc: Document QtDeviceUtilities
Added documentation for the following QML modules:
QtDeviceUtilities.BluetoothSettings
QtDeviceUtilities.DisplaySettings
QtDeviceUtilities.LocalDeviceSettings
QtDeviceUtilities.LocaleSettings
QtDeviceUtilities.NetworkSettings
QtDeviceUtilities.TimeDateSettings
QtDeviceUtilities.SettingsUI
And changed the name of this documentation module to
'Qt Device Utilities'.
Task-number: QTBUG-55320
Change-Id: Iee0d8467dccddc0ee75d7a395ae91f68b12ab9f2
Reviewed-by: Kimmo Ollila <kimmo.ollila@theqtcompany.com>
Diffstat (limited to 'src/networksettings/qnetworksettingsinterface.cpp')
-rw-r--r-- | src/networksettings/qnetworksettingsinterface.cpp | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/src/networksettings/qnetworksettingsinterface.cpp b/src/networksettings/qnetworksettingsinterface.cpp index 91a8fa5..fcde01a 100644 --- a/src/networksettings/qnetworksettingsinterface.cpp +++ b/src/networksettings/qnetworksettingsinterface.cpp @@ -30,6 +30,20 @@ #include "qnetworksettingsinterface_p.h" #include "qnetworksettings.h" +/*! + \qmltype NetworkInterface + \inqmlmodule QtDeviceUtilities.NetworkSettings + \brief Represents a network interface. + + The NetworkInterface QML type represents a network interface attached + to the host. + + Instances of NetworkInterface cannot be created directly; instead, they can + be retrieved via NetworkSettingsManager. + + \sa {NetworkSettingsManager::interfaces}{NetworkSettingsManager.interfaces} +*/ + QNetworkSettingsInterface::QNetworkSettingsInterface(QObject *parent) : QObject(parent) ,d_ptr(new QNetworkSettingsInterfacePrivate(this)) @@ -37,24 +51,76 @@ QNetworkSettingsInterface::QNetworkSettingsInterface(QObject *parent) : } +/*! + \qmlproperty string NetworkInterface::name + \readonly + \brief Holds the name of the network interface. +*/ QString QNetworkSettingsInterface::name() const { Q_D(const QNetworkSettingsInterface); return d->m_name; } +/*! + \qmlproperty enumeration NetworkInterface::state + \readonly + \brief Holds the state of the network interface. + + Possible values: + + \value NetworkSettingsState.Idle + Idle + + \value NetworkSettingsState.Failure + Failed to connect + + \value NetworkSettingsState.Association + Authentication in progress + + \value NetworkSettingsState.Configuration + Configuration in progress + + \value NetworkSettingsState.Ready + Connected to a network + + \value NetworkSettingsState.Disconnect + Disconnected from a network + + \value NetworkSettingsState.Online + Online (acquired an IP address) + + \value NetworkSettingsState.Undefined + Undefined state. +*/ QNetworkSettingsState::States QNetworkSettingsInterface::state() { Q_D(QNetworkSettingsInterface); return d->m_state.state(); } +/*! + \qmlproperty enumeration NetworkInterface::type + \readonly + \brief Holds the type of the network interface. + + Possible values: + + \value NetworkSettingsType.Wired Wired network + \value NetworkSettingsType.Wifi Wifi network + \value NetworkSettingsType.Bluetooth Bluetooth network + \value NetworkSettingsType.Unknown Unknown network type +*/ QNetworkSettingsType::Types QNetworkSettingsInterface::type() { Q_D(QNetworkSettingsInterface); return d->m_type.type(); } +/*! + \qmlproperty bool NetworkInterface::powered + \brief Holds whether the network interface is powered on of off. +*/ bool QNetworkSettingsInterface::powered() const { Q_D(const QNetworkSettingsInterface); @@ -67,6 +133,10 @@ void QNetworkSettingsInterface::setPowered(const bool powered) d->setPowered(powered); } +/*! + \qmlmethod void NetworkInterface::scanServices() + \brief Initiates a scan for network interface services. +*/ void QNetworkSettingsInterface::scanServices() { Q_D(QNetworkSettingsInterface); |