View Javadoc

1   /*
2    * This software was designed and created by Jason Carroll.
3    * Copyright (c) 2002, 2003, 2004 Jason Carroll.
4    * The author can be reached at jcarroll@cowsultants.com
5    * ITracker website: http://www.cowsultants.com
6    * ITracker forums: http://www.cowsultants.com/phpBB/index.php
7    *
8    * This program is free software; you can redistribute it and/or modify
9    * it only under the terms of the GNU General Public License as published by
10   * the Free Software Foundation; either version 2 of the License, or
11   * (at your option) any later version.
12   *
13   * This program is distributed in the hope that it will be useful,
14   * but WITHOUT ANY WARRANTY; without even the implied warranty of
15   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16   * GNU General Public License for more details.
17   */
18  
19  package org.itracker.web.forms;
20  
21  import java.util.HashMap;
22  
23  import javax.servlet.http.HttpServletRequest;
24  
25  import org.apache.struts.action.ActionErrors;
26  import org.apache.struts.action.ActionMapping;
27  import org.apache.struts.validator.ValidatorForm;
28  
29  /**
30   * This is the LoginForm Struts Form. It is used by Login form.
31   * 
32   * @author ready
33   * 
34   */
35  public class ConfigurationForm extends ValidatorForm {
36  	/**
37  	 * 
38  	 */
39  	private static final long serialVersionUID = 1L;
40  	String action;
41  	Integer id;
42  	String value;
43  	Integer order;
44  	String key;
45  
46  	// let's try to put String,String here:
47  	HashMap<String, String> translations = new HashMap<String, String>();
48  
49  	/*
50  	 * public void reset(ActionMapping mapping, HttpServletRequest request) {
51  	 * action = null; id = null; value = null; order = null; key = null;
52  	 * translations = null; }
53  	 */
54  	public ActionErrors validate(ActionMapping mapping,
55  			HttpServletRequest request) {
56  		ActionErrors errors = super.validate(mapping, request);
57  
58  		return errors;
59  	}
60  
61  	public String getAction() {
62  		return action;
63  	}
64  
65  	public void setAction(String action) {
66  		this.action = action;
67  	}
68  
69  	public Integer getId() {
70  		return id;
71  	}
72  
73  	public void setId(Integer id) {
74  		this.id = id;
75  	}
76  
77  	public String getKey() {
78  		return key;
79  	}
80  
81  	public void setKey(String key) {
82  		this.key = key;
83  	}
84  
85  	public Integer getOrder() {
86  		return order;
87  	}
88  
89  	public void setOrder(Integer order) {
90  		this.order = order;
91  	}
92  
93  	// let's try to put String,String here:
94  	public HashMap<String, String> getTranslations() {
95  		return translations;
96  	}
97  
98  	// let's try to put String,String here:
99  	public void setTranslations(HashMap<String, String> translations) {
100 		this.translations = translations;
101 	}
102 
103 	public String getValue() {
104 		return value;
105 	}
106 
107 	public void setValue(String value) {
108 		this.value = value;
109 	}
110 
111 }