NetworkInfo QML Type

The NetworkInfo element provides various information about the network status. More...

Properties

Signals

Methods

Detailed Description

Property Documentation

currentNetworkMode : enumeration

This property holds the current network mode. Possible values are:

  • NetworkInfo.UnknownMode - The network is unknown or an error occured.
  • NetworkInfo.GsmMode - Global System for Mobile (GSM) network.
  • NetworkInfo.CdmaMode - Code Division Multiple Access (CDMA) network.
  • NetworkInfo.WcdmaMode - Wideband Code Division Multiple Access (WCDMA) network.
  • NetworkInfo.WlanMode - Wireless local area network (WLAN) network.
  • NetworkInfo.EthernetMode - Local area network (LAN), or Ethernet network.
  • NetworkInfo.BluetoothMode - Bluetooth network.
  • NetworkInfo.WimaxMode - Worldwide Interoperability for Microwave Access (WiMAX) network.
  • NetworkInfo.LteMode - 3GPP Long Term Evolution (LTE) network.
  • NetworkInfo.TdscdmaMode - Time Division Synchronous Code Division Multiple Access (TD-SCDMA) network.

monitorCellId : bool

This property is obsoleted, and will be removed soon. You don't need to use it at all.


monitorCurrentCellDataTechnology : bool

This property is obsoleted, and will be removed soon. You don't need to use it at all.


monitorCurrentMobileCountryCode : bool

This property is obsoleted, and will be removed soon. You don't need to use it at all.


monitorCurrentMobileNetworkCode : bool

This property is obsoleted, and will be removed soon. You don't need to use it at all.


monitorCurrentNetworkMode : bool

This property holds whether or not monitor the change of current network mode.


monitorLocationAreaCode : bool

This property is obsoleted, and will be removed soon. You don't need to use it at all.


monitorNetworkInterfaceCount : bool

This property is obsoleted, and will be removed soon. You don't need to use it at all.


monitorNetworkName : bool

This property holds whether or not monitor the change of network names.


monitorNetworkSignalStrength : bool

This property holds whether or not monitor the change of network signal strength.


monitorNetworkStatus : bool

This property holds whether or not monitor the network status.


Signal Documentation

onCellIdChanged(int interfaceIndex, string id)

This handler is called whenever the cell ID of interfaceIndex has been changed to id. Note that it won't be called unless monitorCellId is set true.

Note: The corresponding handler is onOnCellIdChanged.

See also cellId and monitorCellId.


onCurrentCellDataTechnologyChanged(int interfaceIndex, CellDataTechnology tech)

This handler is called whenever the cell data technology of interfaceIndex has been changed to tech. Note that the signal won't emit until monitorCurrentCellDataTechnology is set true.

Note: The corresponding handler is onOnCurrentCellDataTechnologyChanged.

See also currentCellDataTechnology and monitorCurrentCellDataTechnology.


onCurrentMobileCountryCodeChanged(int interfaceIndex, string mcc)

This handler is called whenever the current mobile country code of interfaceIndex has been changed to mcc. Note that it won't be called unless monitorCurrentMobileCountryCode is set true.

Note: The corresponding handler is onOnCurrentMobileCountryCodeChanged.

See also currentMobileCountryCode and monitorCurrentMobileCountryCode.


onCurrentMobileNetworkCodeChanged(int interfaceIndex, string mnc)

This handler is called whenever the current mobile network code of interfaceIndex has been changed to mnc. Note that it won't be called unless monitorCurrentMobileNetworkCode is set true.

Note: The corresponding handler is onOnCurrentMobileNetworkCodeChanged.

See also currentMobileNetworkCode and monitorCurrentMobileNetworkCode.


onLocationAreaCodeChanged(int interfaceIndex, string lac)

This handler is called whenever the location area code of interfaceIndex has been changed to lac. Note that it won't be called unless monitorLocationAreaCode is set true.

Note: The corresponding handler is onOnLocationAreaCodeChanged.

See also locationAreaCode and monitorLocationAreaCode.


onNetworkInterfaceCountChanged(NetworkMode mode, int count)

This handler is called whenever the number of interfaces of mode has changed to count. Note that it won't called until monitorNetworkInterfaceCount is set true.

Note: The corresponding handler is onOnNetworkInterfaceCountChanged.

See also networkInterfaceCount and monitorNetworkInterfaceCount.


onNetworkNameChanged(NetworkMode mode, int interfaceIndex, string name)

This handler is called whenever the network name of mode and interfaceIndex has been changed to name. Note that it won't called until monitorNetworkName is set true.

Note: The corresponding handler is onOnNetworkNameChanged.

See also networkName and monitorNetworkName.


onNetworkSignalStrengthChanged(NetworkMode mode, int interfaceIndex, int strength)

This handler is called whenever the signal strength for the interfaceIndex of mode has changed to strength. Note that it won't be called until monitorNetworkSignalStrength is set true.

Note: The corresponding handler is onOnNetworkSignalStrengthChanged.

See also networkSignalStrength and monitorNetworkSignalStrength.


onNetworkStatusChanged(NetworkMode mode, int interfaceIndex, NetworkStatus status)

This handler is called whenever the status of mode and interfaceIndex has been changed to status. Note that it won't be called until monitorNetworkStatus is set true.

Note: The corresponding handler is onOnNetworkStatusChanged.

See also networkStatus and monitorNetworkStatus.


Method Documentation

string cellId(int interface)

Returns the cell ID of the given interface. If this information is not available or error occurs, an empty string is returned.

See also onCellIdChanged.


CellDataTechnology currentCellDataTechnology(int interface)

Returns the current cell data technology of the given interface. Possible values are:

  • NetworkInfo.UnknownDataTechnology - The cellular technology is unknown or an error occured.
  • NetworkInfo.GprsDataTechnology - General Packet Radio Service (GPRS) data service.
  • NetworkInfo.EdgeDataTechnology - Enhanced Data Rates for GSM Evolution (EDGE) data service.
  • NetworkInfo.UmtsDataTechnology - Universal Mobile Telecommunications System (UMTS) data service.
  • NetworkInfo.HspaDataTechnology - High Speed Packet Access (HSPA) data service.

string currentMobileCountryCode(int interface)

Returns the current mobile country code of the given interface. If this information is not available or error occurs, an empty string is returned.


string currentMobileNetworkCode(int interface)

Returns the current mobile network code of the given interface. If this information is not available or error occurs, an empty string is returned.


string homeMobileCountryCode(int interface)

Returns the home Mobile Country Code (MCC) for interface. An empty string is returned if the information is not available or on error.


string homeMobileNetworkCode(int interface)

Returns the home Mobile Network Code (MNC) for interface. An empty string is returned if the information is not available or on error.


string imsi(int interface)

Returns the International Mobile Subscriber Identity (IMSI) for interface. If this information is not available, or error occurs, an empty string is returned.


string locationAreaCode(int interface)

Returns the location area code of the given interface. If this information is not available or error occurs, an empty string is returned.


string macAddress(NetworkMode mode, int interface)

Returns the MAC address for interface of mode. If the MAC address is not available or error occurs, an empty string is returned.


int networkInterfaceCount(NetworkMode mode)

Returns the interface count of the given mode.


string networkName(NetworkMode mode, int interface)

Returns the name of the given mode and interface. If the information is not available, or an error occurs, an empty string is returned.

In case of WLAN, the SSID is returned; for Ethernet, the domain name is returned if available.


int networkSignalStrength(NetworkMode mode, int interface)

Returns the signal strength of the given mode and interface. If the information is not available, or error occurs, -1 is returned.


NetworkStatus networkStatus(NetworkMode mode, int interface)

Returns the status of the given mode and interface. Possible values are:

  • NetworkInfo.UnknownStatus - The status is unknown or an error occured.
  • NetworkInfo.NoNetworkAvailable - There is no network available.
  • NetworkInfo.EmergencyOnly - The network only allows emergency calls.
  • NetworkInfo.Searching - The device is searching or connecting to the network.
  • NetworkInfo.Busy - The network is too busy to be connected.
  • NetworkInfo.Denied - The connection to the network has been denied.
  • NetworkInfo.HomeNetwork - The device is connected to the home network.
  • NetworkInfo.Roaming - The device is connected to some roaming network.