DeployForm.java

00001 /*
00002  * JOnAS: Java(TM) Open Application Server
00003  * Copyright (C) 1999 Bull S.A.
00004  * Contact: jonas-team@objectweb.org
00005  *
00006  * This library is free software; you can redistribute it and/or
00007  * modify it under the terms of the GNU Lesser General Public
00008  * License as published by the Free Software Foundation; either
00009  * version 2.1 of the License, or any later version.
00010  *
00011  * This library is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014  * Lesser General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU Lesser General Public
00017  * License along with this library; if not, write to the Free Software
00018  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
00019  * USA
00020  *
00021  * --------------------------------------------------------------------------
00022  * $Id: DeployForm.java,v 1.5 2003/09/08 16:11:20 antonma Exp $
00023  * --------------------------------------------------------------------------
00024  */
00025 
00026 package org.objectweb.jonas.webapp.jonasadmin.deploy;
00027 
00028 import java.util.ArrayList;
00029 
00030 import javax.servlet.http.HttpServletRequest;
00031 
00032 import org.apache.struts.action.ActionErrors;
00033 import org.apache.struts.action.ActionForm;
00034 import org.apache.struts.action.ActionMapping;
00035 
00040 public class DeployForm extends ActionForm {
00041 
00042 // --------------------------------------------------------- Constants
00043 
00044 // --------------------------------------------------------- Properties variables
00045 
00046     private ArrayList listDeployable = new ArrayList();
00047     private ArrayList listDeployed = new ArrayList();
00048     private ArrayList listDeploy = new ArrayList();
00049     private ArrayList listUndeploy = new ArrayList();
00050     private String deploy = null;
00051     private String undeploy = null;
00052     private String[] deploySelected = new String[0];
00053     private String[] undeploySelected = new String[0];
00054     private ArrayList listAdd = new ArrayList();
00055     private ArrayList listRemove = new ArrayList();
00056     private boolean confirm = false;
00057 
00058 // --------------------------------------------------------- Public Methods
00059 
00067     public void reset(ActionMapping mapping, HttpServletRequest request) {
00068         deploySelected = new String[0];
00069         undeploySelected = new String[0];
00070     }
00071 
00082     public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
00083         ActionErrors oErrors = new ActionErrors();
00084         return oErrors;
00085     }
00086 
00087     public String toString() {
00088         StringBuffer sb = new StringBuffer();
00089         sb.append(" listDeployable = ").append(listDeployable).append("\n");
00090         sb.append(" listDeployed = ").append(listDeployed).append("\n");
00091         sb.append(" listDeploy = ").append(listDeploy).append("\n");
00092         sb.append(" listUndeploy = ").append(listUndeploy).append("\n");
00093         sb.append(" listAdd = ").append(listAdd).append("\n");
00094         sb.append(" listRemove = ").append(listRemove).append("\n");
00095         sb.append(" deploySelected = [");
00096         for (int i = 0; i < deploySelected.length; i++) {
00097             if (i > 0) {
00098                 sb.append(", ");
00099             }
00100             sb.append(deploySelected[i]);
00101         }
00102         sb.append("]\n");
00103         sb.append(" undeploySelected = [");
00104         for (int i = 0; i < undeploySelected.length; i++) {
00105             if (i > 0) {
00106                 sb.append(", ");
00107             }
00108             sb.append(undeploySelected[i]);
00109         }
00110         sb.append("]\n");
00111 
00112         sb.append(" deploy = ").append(deploy).append("\n");
00113         sb.append(" undeploy = ").append(undeploy).append("\n");
00114 
00115         return sb.toString();
00116     }
00117 
00118 // --------------------------------------------------------- Properties Methods
00119 
00120     public ArrayList getListDeployable() {
00121         return listDeployable;
00122     }
00123 
00124     public void setListDeployable(ArrayList listDeployable) {
00125         this.listDeployable = listDeployable;
00126     }
00127 
00128     public ArrayList getListDeployed() {
00129         return listDeployed;
00130     }
00131 
00132     public void setListDeployed(ArrayList listDeployed) {
00133         this.listDeployed = listDeployed;
00134     }
00135 
00136     public String[] getDeploySelected() {
00137         return deploySelected;
00138     }
00139 
00140     public void setDeploySelected(String[] deploySelected) {
00141         this.deploySelected = deploySelected;
00142     }
00143 
00144     public String[] getUndeploySelected() {
00145         return undeploySelected;
00146     }
00147 
00148     public void setUndeploySelected(String[] undeploySelected) {
00149         this.undeploySelected = undeploySelected;
00150     }
00151 
00152     public ArrayList getListDeploy() {
00153         return listDeploy;
00154     }
00155 
00156     public void setListDeploy(ArrayList listDeploy) {
00157         this.listDeploy = listDeploy;
00158     }
00159 
00160     public ArrayList getListUndeploy() {
00161         return listUndeploy;
00162     }
00163 
00164     public void setListUndeploy(ArrayList listUndeploy) {
00165         this.listUndeploy = listUndeploy;
00166     }
00167 
00168     public String getDeploy() {
00169         return deploy;
00170     }
00171 
00172     public void setDeploy(String deploy) {
00173         this.deploy = deploy;
00174     }
00175 
00176     public String getUndeploy() {
00177         return undeploy;
00178     }
00179 
00180     public void setUndeploy(String undeploy) {
00181         this.undeploy = undeploy;
00182     }
00183 
00184     public ArrayList getListAdd() {
00185         return listAdd;
00186     }
00187 
00188     public void setListAdd(ArrayList listAdd) {
00189         this.listAdd = listAdd;
00190     }
00191 
00192     public ArrayList getListRemove() {
00193         return listRemove;
00194     }
00195 
00196     public void setListRemove(ArrayList listRemove) {
00197         this.listRemove = listRemove;
00198     }
00199 
00200     public boolean isConfirm() {
00201         return confirm;
00202     }
00203 
00204     public void setConfirm(boolean confirm) {
00205         this.confirm = confirm;
00206     }
00207 
00208 }

Generated on Tue Feb 15 15:05:26 2005 for JOnAS by  doxygen 1.3.9.1