From 11a3cd0032aaf6cc9b93041ba5f3ab67fb31ac76 Mon Sep 17 00:00:00 2001 From: Shanshan Jiang <shanshan.jiang@sintef.no> Date: Mon, 21 Jan 2013 15:12:46 +0000 Subject: [PATCH] change to be consistent with the MW2.0 new structure and code --- ucc/ucc.viewjambi/pom.xml | 4 ++-- .../viewjambi/install/DeployConfigView.java | 14 ++++++++++++-- .../viewjambi/install/DeployStrategyView.java | 18 ++++++++++++++---- .../ucc/viewjambi/install/MpaParser.java | 6 +++--- 4 files changed, 31 insertions(+), 11 deletions(-) diff --git a/ucc/ucc.viewjambi/pom.xml b/ucc/ucc.viewjambi/pom.xml index 448ec8471..1f713e94d 100644 --- a/ucc/ucc.viewjambi/pom.xml +++ b/ucc/ucc.viewjambi/pom.xml @@ -29,12 +29,12 @@ </dependency> <dependency> <groupId>org.universAAL.middleware</groupId> - <artifactId>mw.interfaces</artifactId> + <artifactId>mw.interfaces.core</artifactId> <version>1.0.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.universAAL.middleware</groupId> - <artifactId>mw.connectors.api</artifactId> + <artifactId>mw.connectors.api.core</artifactId> <version>1.0.0-SNAPSHOT</version> </dependency> </dependencies> diff --git a/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/DeployConfigView.java b/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/DeployConfigView.java index e52368982..e0b59a469 100644 --- a/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/DeployConfigView.java +++ b/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/DeployConfigView.java @@ -9,7 +9,7 @@ import java.util.List; import java.util.Map; import java.util.Set; -import org.universAAL.middleware.connectors.deploy.model.Part; +import org.universAAL.middleware.interfaces.mpa.model.Part; import org.universAAL.middleware.interfaces.PeerCard; import org.universAAL.middleware.managers.api.InstallationResults; import org.universAAL.ucc.viewjambi.common.SubWindow; @@ -132,7 +132,7 @@ public class DeployConfigView extends SubWindow { System.out.println("[DeployConfigView.nextScreen] The multi-part application has been successfully installed!"); break; - case FAILED: + case FAILURE: QMessageBox.warning(this, "Installation result", "The installation of the multi-part application has been failed!"); System.out.println("[DeployConfigView.nextScreen] The installation of the multi-part application has been failed!"); break; @@ -157,6 +157,16 @@ public class DeployConfigView extends SubWindow { System.out.println("[DeployConfigView.nextScreen] The installation of the multi-part application is locally delegated..."); break; + case NOT_A_DEPLOYMANAGER: + QMessageBox.warning(this, "Installation result", "The installation of the multi-part application: not a deploy manager!"); + System.out.println("[DeployConfigView.ok] The installation of the multi-part application: not a deploy manager!"); + break; + + case MPA_FILE_NOT_VALID: + QMessageBox.warning(this, "Installation result", "The installation of the multi-part application: the MPA file is not valid!"); + System.out.println("[DeployConfigView.ok] The installation of the multi-part application: the MPA file is not valid!"); + break; + default: break; } diff --git a/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/DeployStrategyView.java b/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/DeployStrategyView.java index 7dcbf18be..73bd7d762 100644 --- a/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/DeployStrategyView.java +++ b/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/DeployStrategyView.java @@ -6,9 +6,9 @@ import java.util.List; import java.util.Map; import org.osgi.framework.Bundle; -import org.universAAL.middleware.connectors.deploy.model.AalMpa; -import org.universAAL.middleware.connectors.deploy.model.DeploymentUnit; -import org.universAAL.middleware.connectors.deploy.model.Part; +import org.universAAL.middleware.interfaces.mpa.model.AalMpa; +import org.universAAL.middleware.interfaces.mpa.model.DeploymentUnit; +import org.universAAL.middleware.interfaces.mpa.model.Part; import org.universAAL.middleware.interfaces.PeerCard; import org.universAAL.middleware.managers.api.InstallationResults; import org.universAAL.ucc.viewjambi.common.SubWindow; @@ -80,7 +80,7 @@ public class DeployStrategyView extends SubWindow { System.out.println("[DeployStrategyView.ok] The multi-part application has been successfully installed!"); break; - case FAILED: + case FAILURE: QMessageBox.warning(this, "Installation result", "The installation of the multi-part application has been failed!"); System.out.println("[DeployStrategyView.ok] The installation of the multi-part application has been failed!"); break; @@ -105,6 +105,16 @@ public class DeployStrategyView extends SubWindow { System.out.println("[DeployStrategyView.ok] The installation of the multi-part application is locally delegated..."); break; + case NOT_A_DEPLOYMANAGER: + QMessageBox.warning(this, "Installation result", "The installation of the multi-part application: not a deploy manager!"); + System.out.println("[DeployStrategyView.ok] The installation of the multi-part application: not a deploy manager!"); + break; + + case MPA_FILE_NOT_VALID: + QMessageBox.warning(this, "Installation result", "The installation of the multi-part application: the MPA file is not valid!"); + System.out.println("[DeployStrategyView.ok] The installation of the multi-part application: the MPA file is not valid!"); + break; + default: break; } diff --git a/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/MpaParser.java b/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/MpaParser.java index 09b222f87..b190e5581 100644 --- a/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/MpaParser.java +++ b/ucc/ucc.viewjambi/src/main/java/org/universAAL/ucc/viewjambi/install/MpaParser.java @@ -6,9 +6,9 @@ import java.net.URI; import java.net.URISyntaxException; import javax.xml.bind.*; -import org.universAAL.middleware.connectors.deploy.model.AalMpa; -import org.universAAL.middleware.connectors.deploy.model.AalMpa.ApplicationPart; -import org.universAAL.middleware.connectors.deploy.model.ObjectFactory; +import org.universAAL.middleware.interfaces.mpa.model.AalMpa; +import org.universAAL.middleware.interfaces.mpa.model.AalMpa.ApplicationPart; +import org.universAAL.middleware.interfaces.mpa.model.ObjectFactory; public class MpaParser { AalMpa mpa = null; -- GitLab