1 25 26 package org.objectweb.jonas.webapp.jonasadmin.service.container; 27 28 import java.net.URL ; 29 import java.util.ArrayList ; 30 import java.util.Collections ; 31 32 import javax.servlet.http.HttpServletRequest ; 33 34 import org.apache.struts.action.ActionErrors; 35 import org.apache.struts.action.ActionForm; 36 import org.apache.struts.action.ActionMapping; 37 import org.objectweb.jonas.webapp.jonasadmin.common.ModuleItemByName; 39 40 44 public class EarForm extends ActionForm { 45 46 48 51 private String filename = null; 52 55 private String earPath = null; 56 59 private String xmlDeploymentDescriptor = null; 60 67 private ArrayList ejbjars = new ArrayList (); 68 71 private ArrayList wars = new ArrayList (); 72 75 private ArrayList rars = new ArrayList (); 76 77 79 85 86 public void reset(ActionMapping mapping, HttpServletRequest request) { 87 filename = null; 88 earPath = null; 89 xmlDeploymentDescriptor = null; 90 ejbjars = new ArrayList (); 92 wars = new ArrayList (); 93 rars = new ArrayList (); 94 } 95 96 107 public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) { 108 ActionErrors oErrors = new ActionErrors(); 109 return oErrors; 110 } 111 112 116 public String getFilename() { 117 return filename; 118 } 119 122 public void setFilename(String filename) { 123 this.filename = filename; 124 } 125 126 129 public String getEarPath() { 130 return earPath; 131 } 132 133 136 public void setEarPath(URL pUrl) { 137 this.earPath = null; 138 if (pUrl != null) { 139 this.earPath = pUrl.getPath(); 140 } 141 } 142 143 171 public String getXmlDeploymentDescriptor() { 172 return xmlDeploymentDescriptor; 173 } 174 175 178 public void setXmlDeploymentDescriptor(String xmlDeploymentDescriptor) { 179 this.xmlDeploymentDescriptor = xmlDeploymentDescriptor; 180 } 181 184 public ArrayList getEjbjars() { 185 return ejbjars; 186 } 187 190 public void setEjbjars(ArrayList ejbjars) { 191 this.ejbjars = ejbjars; 192 } 193 196 public ArrayList getWars() { 197 return wars; 198 } 199 202 public void setWars(ArrayList wars) { 203 this.wars = wars; 204 Collections.sort(wars, new ModuleItemByName()); 205 } 206 207 210 public ArrayList getRars() { 211 return rars; 212 } 213 214 215 218 public void setRars(ArrayList rars) { 219 this.rars = rars; 220 } 221 222 } 223 | Popular Tags |