fixed code issues

revert-dabc3590
hasuniea 9 years ago
parent 4205ad18dd
commit f32bdf4021

@ -298,9 +298,8 @@ public class WindowsDeviceManager implements DeviceManager {
}
} catch (MobileDeviceManagementDAOException e) {
WindowsDAOFactory.rollbackTransaction();
String msg =
"Error while enrolling the windows device : " + device.getDeviceIdentifier();
throw new DeviceManagementException(msg, e);
throw new DeviceManagementException("Error while enrolling the windows device : "
+ device.getDeviceIdentifier(), e);
}
return status;
}

@ -22,24 +22,13 @@ import org.wso2.carbon.device.mgt.mobile.dto.MobileDevice;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.Map;
/**
* Contains utility methods which are used by Windows plugin.
*/
public class WindowsUtils {
public static String getDeviceProperty(Map<String, String> deviceProperties, String property) {
String deviceProperty = deviceProperties.get(property);
if (deviceProperty == null) {
return null;
}
return deviceProperty;
}
public static MobileDevice loadMobileDevices(ResultSet rs) throws SQLException {
MobileDevice mobileDevice = new MobileDevice();
mobileDevice.setMobileDeviceId(rs.getString(WindowsPluginConstants.DEVICE_ID));
mobileDevice.setImei(rs.getString(WindowsPluginConstants.IMEI));

Loading…
Cancel
Save