1 23 24 package com.sun.enterprise.tools.upgrade.common; 25 26 import java.util.*; 27 28 33 34 public class CommonProperties{ 35 36 private static final String TRANSFORMATION_MODULE = "com.sun.enterprise.tools.upgrade.transform.TransformManager"; 37 private static final String NSS_TO_JKS_MODULE = "com.sun.enterprise.tools.upgrade.certconversion.NSStoJKSConversionModule"; 38 private static final String JKS_TO_JKS_MODULE = "com.sun.enterprise.tools.upgrade.certconversion.JKStoJKSConversionModule"; 39 private static final String NSS_TO_NSS_MODULE = "com.sun.enterprise.tools.upgrade.certconversion.NSStoNSSConversionModule"; 40 private static final String JKS_TO_NSS_MODULE = "com.sun.enterprise.tools.upgrade.certconversion.JKStoNSSConversionModule"; 41 private static final String REALM_MODULE = "com.sun.enterprise.tools.upgrade.realm.RealmUpgrade"; 42 private static final String DEPLOYMENT_MODULE = "com.sun.enterprise.tools.upgrade.deployment.DeploymentUpgrade"; 43 private static final String MISC_MODULE = "com.sun.enterprise.tools.upgrade.miscconfig.ConfigTransfers"; 44 45 48 49 public static List getRegisteredModules(CommonInfoModel model){ 50 List list = new LinkedList(); 51 list.add(TRANSFORMATION_MODULE); 52 53 if(model.getCertificateConversionFlag()){ 54 if (model.getTargetEdition().equals(UpgradeConstants.EDITION_PE)){ 55 if (model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS7X_PE) || 56 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS7X_SE) || 57 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS7X_EE) || 58 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS81_EE)) { 59 list.add(NSS_TO_JKS_MODULE); 60 } else if (model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS80_PE) || 61 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS81_PE)) { 62 list.add(JKS_TO_JKS_MODULE); 63 } 64 } else if (model.getTargetEdition().equals(UpgradeConstants.EDITION_EE) || 65 model.getTargetEdition().equals(UpgradeConstants.EDITION_SE)){ 66 if (model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS7X_PE) || 67 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS7X_SE) || 68 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS7X_EE) || 69 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS81_EE)) { 70 list.add(NSS_TO_NSS_MODULE); 71 } else if (model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS80_PE) || 72 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS81_PE)|| 73 model.getSourceVersionAndEdition().equals(UpgradeConstants.VERSION_AS90_PE)) { 74 list.add(JKS_TO_NSS_MODULE); 75 } 76 } 77 } 78 list.add(MISC_MODULE); 79 list.add(DEPLOYMENT_MODULE); 80 list.add(REALM_MODULE); 81 return list; 82 } 83 } 84 | Popular Tags |