[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
public delegate bool IPv6AddressCallback(IntPtr ipv6, IntPtr userData);
- [DllImport(Libraries.Connection, EntryPoint = "connection_create")]
- public static extern int Create(out IntPtr handle);
+ [DllImport(Libraries.Connection, EntryPoint = "connection_create_cs")]
+ public static extern int Create(int tid, out IntPtr handle);
- [DllImport(Libraries.Connection, EntryPoint = "connection_destroy")]
- public static extern int Destroy(IntPtr handle);
+ [DllImport(Libraries.Connection, EntryPoint = "connection_destroy_cs")]
+ public static extern int Destroy(int tid, IntPtr handle);
[DllImport(Libraries.Connection, EntryPoint = "connection_get_type")]
public static extern int GetType(IntPtr handle, out int type);
[DllImport(Libraries.Connection, EntryPoint = "connection_reset_statistics")]
public static extern int ResetStatistics(IntPtr handle, int connectionType, int statisticsType);
+ [DllImport(Libraries.Connection, EntryPoint = "connection_add_route_entry")]
+ public static extern int AddRoute(IntPtr handle, AddressFamily family, string interfaceName, string address, string gateway);
+
+ [DllImport(Libraries.Connection, EntryPoint = "connection_remove_route_entry")]
+ public static extern int RemoveRoute(IntPtr handle, AddressFamily family, string interfaceName, string address, string gateway);
+
[DllImport(Libraries.Connection, EntryPoint = "connection_set_type_changed_cb")]
public static extern int SetTypeChangedCallback(IntPtr handle, ConnectionTypeChangedCallback callback, IntPtr userData);
[DllImport(Libraries.Connection, EntryPoint = "connection_profile_get_dns_config_type")]
public static extern int GetDnsConfigType(IntPtr profileHandle, int family, out int type);
+ [DllImport(Libraries.Connection, EntryPoint = "connection_profile_get_dhcp_server_address")]
+ public static extern int GetDhcpServerAddress(IntPtr profileHandle, AddressFamily family, out string dhcpServerAddress);
+
[DllImport(Libraries.Connection, EntryPoint = "connection_profile_refresh")]
public static extern int Refresh(IntPtr profileHandle);
public static extern int SetGatewayAddress(IntPtr profileHandle, int family, string address);
[DllImport(Libraries.Connection, EntryPoint = "connection_profile_set_dns_address")]
- public static extern int SetDnsAddress(IntPtr profileHandle, int family, string address);
+ public static extern int SetDnsAddress(IntPtr profileHandle, int order, int family, string address);
[DllImport(Libraries.Connection, EntryPoint = "connection_profile_set_proxy_address")]
public static extern int SetProxyAddress(IntPtr profileHandle, int family, string address);
public static extern int GetApn(IntPtr profileHandle, out IntPtr apn);
[DllImport(Libraries.Connection, EntryPoint = "connection_profile_get_cellular_auth_info")]
- public static extern int GetAuthInfo(IntPtr profileHandle, out int authType, out IntPtr name, out IntPtr password);
+ public static extern int GetAuthInfo(IntPtr profileHandle, out int authType, out string name, out string password);
[DllImport(Libraries.Connection, EntryPoint = "connection_profile_get_cellular_home_url")]
public static extern int GetHomeUrl(IntPtr profileHandle, out IntPtr homeUrl);