Remove app list update method from app manager interface

revert-70aa11f8
manoj 9 years ago
parent 6f2c51ee36
commit 78ee8e334f

@ -69,6 +69,5 @@ public interface ApplicationManager {
void installApplication(Operation operation, List<DeviceIdentifier> deviceIdentifiers) void installApplication(Operation operation, List<DeviceIdentifier> deviceIdentifiers)
throws ApplicationManagementException; throws ApplicationManagementException;
void updateApplicationsForDevice(DeviceIdentifier deviceIdentifier, List<Application> applications)
throws ApplicationManagementException;
} }

@ -64,11 +64,4 @@ public class ApplicationManagementServiceImpl implements ApplicationManager {
} }
DeviceManagementDataHolder.getInstance().getAppManager().installApplication(operation, deviceIdentifiers); DeviceManagementDataHolder.getInstance().getAppManager().installApplication(operation, deviceIdentifiers);
} }
@Override
public void updateApplicationsForDevice(DeviceIdentifier deviceIdentifier, List<Application> applications)
throws ApplicationManagementException {
DeviceManagementDataHolder.getInstance().getAppManager().updateApplicationsForDevice(deviceIdentifier,applications);
}
} }

@ -111,21 +111,6 @@ public class ApplicationManagerProviderServiceImpl implements ApplicationManager
} }
} }
@Override
public void updateApplicationsForDevice(DeviceIdentifier deviceIdentifier, List<Application> applications)
throws ApplicationManagementException {
int tenantId = CarbonContext.getThreadLocalCarbonContext().getTenantId();
try {
Device device = deviceDAO.getDevice(deviceIdentifier, tenantId);
deviceDAO.addDeviceApplications(device.getId(), applications);
}catch (DeviceManagementDAOException deviceDaoEx){
String errorMsg = "Error occurred saving application list to the device";
log.error(errorMsg+":"+deviceIdentifier.toString());
throw new ApplicationManagementException(errorMsg, deviceDaoEx);
}
}
private OAuthConsumerAppDTO getAppInfo() throws ApplicationManagementException { private OAuthConsumerAppDTO getAppInfo() throws ApplicationManagementException {
OAuthConsumerAppDTO appInfo = null; OAuthConsumerAppDTO appInfo = null;
try { try {

@ -124,10 +124,4 @@ public class TestDeviceManager implements DeviceManagementService {
throws ApplicationManagementException { throws ApplicationManagementException {
} }
@Override
public void updateApplicationsForDevice(DeviceIdentifier deviceIdentifier, List<Application> applications)
throws ApplicationManagementException {
}
} }

Loading…
Cancel
Save