|
|
|
@ -315,22 +315,6 @@ public class DeviceManagementProviderServiceImpl implements DeviceManagementProv
|
|
|
|
|
return enrolmentInfos;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public List<Integer> getDeviceEnrolledTenants() throws DeviceManagementException {
|
|
|
|
|
try {
|
|
|
|
|
DeviceManagementDAOFactory.openConnection();
|
|
|
|
|
return deviceDAO.getDeviceEnrolledTenants();
|
|
|
|
|
} catch (DeviceManagementDAOException e) {
|
|
|
|
|
throw new DeviceManagementException("Error occurred while retrieving the tenants " +
|
|
|
|
|
"which have device enrolled.", e);
|
|
|
|
|
} catch (SQLException e) {
|
|
|
|
|
throw new DeviceManagementException("Error occurred while opening a connection to the data source", e);
|
|
|
|
|
} finally {
|
|
|
|
|
DeviceManagementDAOFactory.closeConnection();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public boolean disenrollDevice(DeviceIdentifier deviceId) throws DeviceManagementException {
|
|
|
|
|
DeviceManager deviceManager = this.getDeviceManager(deviceId.getType());
|
|
|
|
|