Class WiFiManager

Definition

Namespace:
Tizen.Network.WiFi
Assembly:
Tizen.Network.WiFi.dll
API Level:
3

A manager class which allows applications to connect to a Wireless Local Area Network (WLAN) and transfer data over the network. The Wi-Fi Manager enables your application to activate and deactivate a local Wi-Fi device, and to connect to a WLAN network in the infrastructure mode.

C#
Copy
public static class WiFiManager : object
Inheritance
WiFiManager

Properties

View Source

ConnectionState

The network connection state.

Declaration
C#
Copy
public static WiFiConnectionState ConnectionState { get; }
Property Value
Type Description
WiFiConnectionState

Represents the connection state of the Wi-Fi.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
View Source

InterfaceName

The name of the network interface.

Declaration
C#
Copy
public static string InterfaceName { get; }
Property Value
Type Description
String

Interface name of the Wi-Fi.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
View Source

IsActive

A property to check whether Wi-Fi is activated.

Declaration
C#
Copy
public static bool IsActive { get; }
Property Value
Type Description
Boolean

Boolean value to check whether Wi-Fi is activated or not.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
View Source

MacAddress

The local MAC address.

Declaration
C#
Copy
public static string MacAddress { get; }
Property Value
Type Description
String

Represents the MAC address of the Wi-Fi.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
View Source

ScanState

The Wi-Fi scan state.

Declaration
C#
Copy
public static WiFiScanState ScanState { get; }
Property Value
Type Description
WiFiScanState

Represents the scan state of the Wi-Fi.

API Level: 6

Methods

View Source

ActivateAsync()

Activates the Wi-Fi asynchronously.

Declaration
C#
Copy
public static Task ActivateAsync()
Returns
Type Description
Task

A task indicating whether the activate method is done or not.

Exceptions
Type Condition
NowInProgressException

Thrown when the Wi-Fi activation is now in progress.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.sethttp://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

ActivateWithPickerAsync()

Activates the Wi-Fi asynchronously and displays the Wi-Fi picker (popup) when the Wi-Fi is not automatically connected.

Declaration
C#
Copy
public static Task ActivateWithPickerAsync()
Returns
Type Description
Task

A task indicating whether the ActivateWithPicker method is done or not.

Exceptions
Type Condition
NowInProgressException

Thrown when the Wi-Fi activation is now in progress.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.sethttp://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

BssidScanAsync()

Starts BSSID scan asynchronously.

Declaration
C#
Copy
public static Task BssidScanAsync()
Returns
Type Description
Task

A task indicating whether the BssidScanAsync method is done or not.

Remarks

This method must be called from MainThread.

API Level: 5
Privilege Level: public
Privilege: http://tizen.org/privilege/network.sethttp://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

DeactivateAsync()

Deactivates the Wi-Fi asynchronously.

Declaration
C#
Copy
public static Task DeactivateAsync()
Returns
Type Description
Task

A task indicating whether the deactivate method is done or not.

Exceptions
Type Condition
NowInProgressException

Thrown when the Wi-Fi deactivation is now in progress.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.sethttp://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

GetConnectedAP()

Gets the object of the connected WiFiAP.

Declaration
C#
Copy
public static WiFiAP GetConnectedAP()
Returns
Type Description
WiFiAP

The connected Wi-Fi access point (AP) information.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

GetFoundAPs()

Gets the result of the scan.

Declaration
C#
Copy
public static IEnumerable<WiFiAP> GetFoundAPs()
Returns
Type Description
IEnumerable<WiFiAP>

A list of the WiFiAP objects.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

GetFoundBssids()

Gets the result of the BssidScanAsync() API.

Declaration
C#
Copy
public static IEnumerable<WiFiAP> GetFoundBssids()
Returns
Type Description
IEnumerable<WiFiAP>

A list of the WiFiAP objects.

API Level: 5
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

GetFoundSpecificAPs()

Gets the result of ScanSpecificAPAsync(string essid) API.

Declaration
C#
Copy
public static IEnumerable<WiFiAP> GetFoundSpecificAPs()
Returns
Type Description
IEnumerable<WiFiAP>

A list containing the WiFiAP objects.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

GetWiFiConfigurations()

Gets the list of Wi-Fi configurations.

Declaration
C#
Copy
public static IEnumerable<WiFiConfiguration> GetWiFiConfigurations()
Returns
Type Description
IEnumerable<WiFiConfiguration>

A list containing the WiFiConfiguration objects.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.profile
Feature: http://tizen.org/feature/network.wifi
View Source

GetWiFiHandle()

Gets the Wi-Fi safe handle.

Declaration
C#
Copy
public static SafeWiFiManagerHandle GetWiFiHandle()
Returns
Type Description
SafeWiFiManagerHandle

The instance of the SafeWiFiManagerHandle.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

SaveWiFiConfiguration(WiFiConfiguration)

Saves the Wi-Fi configuration of the access point.

Declaration
C#
Copy
public static void SaveWiFiConfiguration(WiFiConfiguration configuration)
Parameters
Type Name Description
WiFiConfiguration configuration

The configuration to be stored.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.profile
Feature: http://tizen.org/feature/network.wifi
View Source

ScanAsync()

Starts the scan asynchronously.

Declaration
C#
Copy
public static Task ScanAsync()
Returns
Type Description
Task

A task indicating whether the scan method is done or not.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.sethttp://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

ScanSpecificAPAsync(String)

Starts a specific access point scan asynchronously.

Declaration
C#
Copy
public static Task ScanSpecificAPAsync(string essid)
Parameters
Type Name Description
String essid

The ESSID of the hidden AP.

Returns
Type Description
Task

A task indicating whether the ScanSpecificAP method is done or not.

API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.sethttp://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi

Events

View Source

BackgroundScanFinished

BackgroundScanFinished is raised when the background scan is finished. The background scan starts automatically when Wi-Fi is activated. The callback will be invoked periodically.

Declaration
C#
Copy
public static event EventHandler BackgroundScanFinished
Event Type
Type Description
EventHandler
API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

ConnectionStateChanged

ConnectionStateChanged is raised when the connection state is changed.

Declaration
C#
Copy
public static event EventHandler<ConnectionStateChangedEventArgs> ConnectionStateChanged
Event Type
Type Description
EventHandler<ConnectionStateChangedEventArgs>
API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

DeviceStateChanged

DeviceStateChanged is raised when the device state is changed.

Declaration
C#
Copy
public static event EventHandler<DeviceStateChangedEventArgs> DeviceStateChanged
Event Type
Type Description
EventHandler<DeviceStateChangedEventArgs>
API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

RssiLevelChanged

RssiLevelChanged is raised when the RSSI of the connected Wi-Fi is changed.

Declaration
C#
Copy
public static event EventHandler<RssiLevelChangedEventArgs> RssiLevelChanged
Event Type
Type Description
EventHandler<RssiLevelChangedEventArgs>
API Level: 3
Privilege Level: public
Privilege: http://tizen.org/privilege/network.get
Feature: http://tizen.org/feature/network.wifi
View Source

ScanStateChanged

ScanStateChanged is raised when the scan state is changed.

Declaration
C#
Copy
public static event EventHandler<ScanStateChangedEventArgs> ScanStateChanged
Event Type
Type Description
EventHandler<ScanStateChangedEventArgs>
API Level: 6
Feature: http://tizen.org/feature/network.wifi