Class ConnectionProfileManager
Definition
- Namespace:
- Tizen.Network.Connection
- Assembly:
- Tizen.Network.Connection.dll
This is the ConnectionProfileManager class. It provides functions to add, get, connect, or modify the connection profile.
public static class ConnectionProfileManager
- Inheritance
-
objectConnectionProfileManager
Methods
View SourceAddCellularProfile(CellularProfile)
Adds a new profile.
Declaration
public static void AddCellularProfile(CellularProfile profile)
Parameters
Type | Name | Description |
---|---|---|
CellularProfile | profile | The cellular profile object. |
ConnectProfileAsync(ConnectionProfile)
Opens a connection of profile asynchronously.
Declaration
public static Task ConnectProfileAsync(ConnectionProfile profile)
Parameters
Type | Name | Description |
---|---|---|
ConnectionProfile | profile | The connection profile object. |
Returns
Type | Description |
---|---|
Task | A task indicates whether the ConnectProfileAsync method is done successfully or not. |
Remarks
This method must be called from MainThread.
DisconnectProfileAsync(ConnectionProfile)
Closes a connection of profile.
Declaration
public static Task DisconnectProfileAsync(ConnectionProfile profile)
Parameters
Type | Name | Description |
---|---|---|
ConnectionProfile | profile | The connection profile object. |
Returns
Type | Description |
---|---|
Task | A task indicates whether the DisconnectProfileAsync method is done successfully or not. |
Remarks
This method must be called from MainThread.
GetCurrentProfile()
Gets the name of the default profile.
Declaration
public static ConnectionProfile GetCurrentProfile()
Returns
Type | Description |
---|---|
ConnectionProfile | Connection profile object. |
GetDefaultCellularProfile(CellularServiceType)
Gets the default profile, which provides the given cellular service.
Declaration
public static ConnectionProfile GetDefaultCellularProfile(CellularServiceType type)
Parameters
Type | Name | Description |
---|---|---|
CellularServiceType | type | The cellular service type. |
Returns
Type | Description |
---|---|
ConnectionProfile | Connection profile object. |
GetProfileListAsync(ProfileListType)
Gets the list of the profile with the profile list type.
Declaration
public static Task<IEnumerable<ConnectionProfile>> GetProfileListAsync(ProfileListType type)
Parameters
Type | Name | Description |
---|---|---|
ProfileListType | type | The type of profile. |
Returns
Type | Description |
---|---|
Task<><IEnumerable<><ConnectionProfile>> | List of connection profile objects. |
RemoveProfile(ConnectionProfile)
Removes an existing profile.
Declaration
public static void RemoveProfile(ConnectionProfile profile)
Parameters
Type | Name | Description |
---|---|---|
ConnectionProfile | profile | The connection profile object. |
SetDefaultCellularProfile(CellularServiceType, ConnectionProfile)
Sets the default profile, which provides the given cellular service.
Declaration
public static Task SetDefaultCellularProfile(CellularServiceType type, ConnectionProfile profile)
Parameters
Type | Name | Description |
---|---|---|
CellularServiceType | type | The cellular service type. |
ConnectionProfile | profile | The connection profile object. |
Returns
Type | Description |
---|---|
Task | A task indicates whether the SetDefaultCellularProfile method is done successfully or not. |
Remarks
This method must be called from MainThread.
UpdateProfile(ConnectionProfile)
Updates an existing profile. When a profile is changed, these changes will be not applied to the ConnectionProfileManager immediately. When you call this function, your changes affect the ConnectionProfileManager and the existing profile is updated.
Declaration
public static void UpdateProfile(ConnectionProfile profile)
Parameters
Type | Name | Description |
---|---|---|
ConnectionProfile | profile | The connection profile object. |