From: Benjamin B. <bg...@us...> - 2005-05-31 15:49:00
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/ui/internal/wizards In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29496/Plugin/com/ibm/ecute/rsa/ui/internal/wizards Modified Files: ExportCIMMOFWizardPage.java ImportCIMMOFWizardPage.java Log Message: fixed directory problem caused by "\" on CIMMOF export in linux Index: ExportCIMMOFWizardPage.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/ui/internal/wizards/ExportCIMMOFWizardPage.java,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- ExportCIMMOFWizardPage.java 14 Feb 2005 17:38:06 -0000 1.10 +++ ExportCIMMOFWizardPage.java 31 May 2005 15:48:50 -0000 1.11 @@ -671,9 +671,24 @@ } try { + String selectionPath = getSelectedDestinationPath(); + String osname = System.getProperty("os.name"); + System.out.println(osname); + // Windows system + if(osname.indexOf("win") > -1 || osname.indexOf("Win") > -1){ + if(!selectionPath.endsWith("\\")){ + selectionPath = selectionPath.concat("\\"); + } + System.out.println(selectionPath); + } else { // other system + if(!selectionPath.endsWith("/")){ + selectionPath = selectionPath.concat("/"); + } + System.out.println(selectionPath); + } PropertyList propertyList = new PropertyList(configFile, Constants.toolName); //Set configuration - propertyList.setProperty(Constants.cimMOFOutputPackageName, "Path", getSelectedDestinationPath()); + propertyList.setProperty(Constants.cimMOFOutputPackageName, "Path", selectionPath); propertyList.setProperty(Constants.cimMOFOutputPackageName, "CompleteClasses", fullClasses); propertyList.setProperty(Constants.rsaInputPackageName, "Model", modelDestination); propertyList.setProperty(Constants.rsaInputPackageName, "AllPackages", allPackages); @@ -694,8 +709,6 @@ e.printStackTrace(); } } - - } } Index: ImportCIMMOFWizardPage.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/ui/internal/wizards/ImportCIMMOFWizardPage.java,v retrieving revision 1.17 retrieving revision 1.18 diff -u -d -r1.17 -r1.18 --- ImportCIMMOFWizardPage.java 8 Apr 2005 09:11:20 -0000 1.17 +++ ImportCIMMOFWizardPage.java 31 May 2005 15:48:50 -0000 1.18 @@ -927,7 +927,8 @@ modelName = modelName.substring(0 , modelName.lastIndexOf(FILE_EXT_DOT+FILE_EXT_MODEL)); } - modelDest = destinationPath.toOSString()+"\\" + modelName + ".emx"; + modelDest = destinationPath.toOSString() +"\\" + modelName + ".emx"; + System.out.println(modelDest); IProject newProject = null; if (newProjectRadio.getSelection()) { |