+int _connection_libnet_set_cellular_service_profile_async(connection_cellular_service_type_e type,
+ connection_profile_h profile, connection_set_default_cb callback, void* user_data)
+{
+ if (!(_connection_libnet_check_profile_validity(profile))) {
+ CONNECTION_LOG(CONNECTION_ERROR, "Wrong Parameter Passed\n");
+ return CONNECTION_ERROR_INVALID_PARAMETER;
+ }
+
+ net_profile_info_t *profile_info = profile;
+ connection_cellular_service_type_e service_type;
+
+ service_type = _profile_convert_to_connection_cellular_service_type(profile_info->ProfileInfo.Pdp.ServiceType);
+
+ if (service_type != type)
+ return CONNECTION_ERROR_INVALID_PARAMETER;
+
+ if (net_set_default_cellular_service_profile_async(profile_info->ProfileName) != NET_ERR_NONE)
+ return CONNECTION_ERROR_OPERATION_FAILED;
+
+ __libnet_set_default_cb(callback, user_data);
+
+ return CONNECTION_ERROR_NONE;
+}
+