From 78ee8e334fe81ccb48e485539ed38243c7e803e5 Mon Sep 17 00:00:00 2001 From: manoj Date: Mon, 22 Jun 2015 22:03:23 +0530 Subject: [PATCH] Remove app list update method from app manager interface --- .../mgt/common/app/mgt/ApplicationManager.java | 3 +-- .../app/mgt/ApplicationManagementServiceImpl.java | 7 ------- .../ApplicationManagerProviderServiceImpl.java | 15 --------------- .../carbon/device/mgt/core/TestDeviceManager.java | 6 ------ 4 files changed, 1 insertion(+), 30 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.common/src/main/java/org/wso2/carbon/device/mgt/common/app/mgt/ApplicationManager.java b/components/device-mgt/org.wso2.carbon.device.mgt.common/src/main/java/org/wso2/carbon/device/mgt/common/app/mgt/ApplicationManager.java index 27560bf683b..a341768d17f 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.common/src/main/java/org/wso2/carbon/device/mgt/common/app/mgt/ApplicationManager.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.common/src/main/java/org/wso2/carbon/device/mgt/common/app/mgt/ApplicationManager.java @@ -69,6 +69,5 @@ public interface ApplicationManager { void installApplication(Operation operation, List deviceIdentifiers) throws ApplicationManagementException; - void updateApplicationsForDevice(DeviceIdentifier deviceIdentifier, List applications) - throws ApplicationManagementException; + } diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/app/mgt/ApplicationManagementServiceImpl.java b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/app/mgt/ApplicationManagementServiceImpl.java index 4814713f9db..cb64b7d6144 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/app/mgt/ApplicationManagementServiceImpl.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/app/mgt/ApplicationManagementServiceImpl.java @@ -64,11 +64,4 @@ public class ApplicationManagementServiceImpl implements ApplicationManager { } DeviceManagementDataHolder.getInstance().getAppManager().installApplication(operation, deviceIdentifiers); } - - @Override - public void updateApplicationsForDevice(DeviceIdentifier deviceIdentifier, List applications) - throws ApplicationManagementException { - - DeviceManagementDataHolder.getInstance().getAppManager().updateApplicationsForDevice(deviceIdentifier,applications); - } } diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/app/mgt/ApplicationManagerProviderServiceImpl.java b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/app/mgt/ApplicationManagerProviderServiceImpl.java index e08f6dedc0b..914f3d51734 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/app/mgt/ApplicationManagerProviderServiceImpl.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/app/mgt/ApplicationManagerProviderServiceImpl.java @@ -111,21 +111,6 @@ public class ApplicationManagerProviderServiceImpl implements ApplicationManager } } - @Override - public void updateApplicationsForDevice(DeviceIdentifier deviceIdentifier, List 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 { OAuthConsumerAppDTO appInfo = null; try { diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/test/java/org/wso2/carbon/device/mgt/core/TestDeviceManager.java b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/test/java/org/wso2/carbon/device/mgt/core/TestDeviceManager.java index a6ba1dc0ca3..29fe4ea006f 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/test/java/org/wso2/carbon/device/mgt/core/TestDeviceManager.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/test/java/org/wso2/carbon/device/mgt/core/TestDeviceManager.java @@ -124,10 +124,4 @@ public class TestDeviceManager implements DeviceManagementService { throws ApplicationManagementException { } - - @Override - public void updateApplicationsForDevice(DeviceIdentifier deviceIdentifier, List applications) - throws ApplicationManagementException { - - } }