1 25 26 package org.objectweb.jonas.webapp.jonasadmin.deploy; 27 28 import java.util.ArrayList ; 29 30 import javax.servlet.http.HttpServletRequest ; 31 32 import org.apache.struts.action.ActionErrors; 33 import org.apache.struts.action.ActionForm; 34 import org.apache.struts.action.ActionMapping; 35 36 39 40 public class DeployForm extends ActionForm { 41 42 44 46 private ArrayList listDeployable = new ArrayList (); 47 private ArrayList listDeployed = new ArrayList (); 48 private ArrayList listDeploy = new ArrayList (); 49 private ArrayList listUndeploy = new ArrayList (); 50 private String deploy = null; 51 private String undeploy = null; 52 private String [] deploySelected = new String [0]; 53 private String [] undeploySelected = new String [0]; 54 private ArrayList listAdd = new ArrayList (); 55 private ArrayList listRemove = new ArrayList (); 56 private boolean confirm = false; 57 58 60 66 67 public void reset(ActionMapping mapping, HttpServletRequest request) { 68 deploySelected = new String [0]; 69 undeploySelected = new String [0]; 70 } 71 72 82 public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) { 83 ActionErrors oErrors = new ActionErrors(); 84 return oErrors; 85 } 86 87 public String toString() { 88 StringBuffer sb = new StringBuffer (); 89 sb.append(" listDeployable = ").append(listDeployable).append("\n"); 90 sb.append(" listDeployed = ").append(listDeployed).append("\n"); 91 sb.append(" listDeploy = ").append(listDeploy).append("\n"); 92 sb.append(" listUndeploy = ").append(listUndeploy).append("\n"); 93 sb.append(" listAdd = ").append(listAdd).append("\n"); 94 sb.append(" listRemove = ").append(listRemove).append("\n"); 95 sb.append(" deploySelected = ["); 96 for (int i = 0; i < deploySelected.length; i++) { 97 if (i > 0) { 98 sb.append(", "); 99 } 100 sb.append(deploySelected[i]); 101 } 102 sb.append("]\n"); 103 sb.append(" undeploySelected = ["); 104 for (int i = 0; i < undeploySelected.length; i++) { 105 if (i > 0) { 106 sb.append(", "); 107 } 108 sb.append(undeploySelected[i]); 109 } 110 sb.append("]\n"); 111 112 sb.append(" deploy = ").append(deploy).append("\n"); 113 sb.append(" undeploy = ").append(undeploy).append("\n"); 114 115 return sb.toString(); 116 } 117 118 120 public ArrayList getListDeployable() { 121 return listDeployable; 122 } 123 124 public void setListDeployable(ArrayList listDeployable) { 125 this.listDeployable = listDeployable; 126 } 127 128 public ArrayList getListDeployed() { 129 return listDeployed; 130 } 131 132 public void setListDeployed(ArrayList listDeployed) { 133 this.listDeployed = listDeployed; 134 } 135 136 public String [] getDeploySelected() { 137 return deploySelected; 138 } 139 140 public void setDeploySelected(String [] deploySelected) { 141 this.deploySelected = deploySelected; 142 } 143 144 public String [] getUndeploySelected() { 145 return undeploySelected; 146 } 147 148 public void setUndeploySelected(String [] undeploySelected) { 149 this.undeploySelected = undeploySelected; 150 } 151 152 public ArrayList getListDeploy() { 153 return listDeploy; 154 } 155 156 public void setListDeploy(ArrayList listDeploy) { 157 this.listDeploy = listDeploy; 158 } 159 160 public ArrayList getListUndeploy() { 161 return listUndeploy; 162 } 163 164 public void setListUndeploy(ArrayList listUndeploy) { 165 this.listUndeploy = listUndeploy; 166 } 167 168 public String getDeploy() { 169 return deploy; 170 } 171 172 public void setDeploy(String deploy) { 173 this.deploy = deploy; 174 } 175 176 public String getUndeploy() { 177 return undeploy; 178 } 179 180 public void setUndeploy(String undeploy) { 181 this.undeploy = undeploy; 182 } 183 184 public ArrayList getListAdd() { 185 return listAdd; 186 } 187 188 public void setListAdd(ArrayList listAdd) { 189 this.listAdd = listAdd; 190 } 191 192 public ArrayList getListRemove() { 193 return listRemove; 194 } 195 196 public void setListRemove(ArrayList listRemove) { 197 this.listRemove = listRemove; 198 } 199 200 public boolean isConfirm() { 201 return confirm; 202 } 203 204 public void setConfirm(boolean confirm) { 205 this.confirm = confirm; 206 } 207 208 } | Popular Tags |