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 org.apache.struts.action.ActionErrors;
22  import org.apache.struts.action.ActionMapping;
23  import org.apache.struts.validator.ValidatorForm;
24  
25  import javax.servlet.http.HttpServletRequest;
26  import java.util.HashMap;
27  import java.util.Map;
28  
29  /**
30   * This is the LoginForm Struts Form. It is used by Login form.
31   *
32   * @author ready
33   */
34  public class LanguageForm extends ValidatorForm {
35      /**
36       *
37       */
38      private static final long serialVersionUID = 1L;
39      private String action = null;
40      private String parentLocale = null;
41      private String key = null;
42      private String locale = null;
43      private String localeTitle = null;
44      private Map<String, String> items = new HashMap<String, String>();
45      private String localeBaseTitle;
46  
47      /*
48        * public void reset(ActionMapping mapping, HttpServletRequest request) {
49        * action = null; parentLocale = null; key= null; locale= null; HashMap<String,String>
50        * items = new HashMap<String,String>(); }
51        */
52      public ActionErrors validate(ActionMapping mapping,
53                                   HttpServletRequest request) {
54          ActionErrors errors = super.validate(mapping, request);
55          return errors;
56      }
57  
58      public String getAction() {
59          return action;
60      }
61  
62      public void setAction(String action) {
63          this.action = action;
64      }
65  
66      public Map<String, String> getItems() {
67          return items;
68      }
69  
70      public void setItems(Map<String, String> items) {
71          this.items = items;
72      }
73  
74      public String getKey() {
75          return key;
76      }
77  
78      public void setKey(String key) {
79          this.key = key;
80      }
81  
82      public String getLocale() {
83          return locale;
84      }
85  
86      public void setLocale(String locale) {
87          this.locale = locale;
88      }
89  
90      public String getParentLocale() {
91          return parentLocale;
92      }
93  
94      public void setParentLocale(String parentLocale) {
95          this.parentLocale = parentLocale;
96      }
97  
98      public String getLocaleTitle() {
99          return localeTitle;
100     }
101 
102     public void setLocaleTitle(String localeTitle) {
103         this.localeTitle = localeTitle;
104     }
105 
106     public void setLocaleBaseTitle(String resourceValue) {
107         this.localeBaseTitle = resourceValue;
108 
109     }
110 
111     public String getLocaleBaseTitle() {
112         return localeBaseTitle;
113     }
114 
115 }