View Javadoc
1   /*
2    * $Id$
3    *
4    * Licensed to the Apache Software Foundation (ASF) under one
5    * or more contributor license agreements.  See the NOTICE file
6    * distributed with this work for additional information
7    * regarding copyright ownership.  The ASF licenses this file
8    * to you under the Apache License, Version 2.0 (the
9    * "License"); you may not use this file except in compliance
10   * with the License.  You may obtain a copy of the License at
11   *
12   *  http://www.apache.org/licenses/LICENSE-2.0
13   *
14   * Unless required by applicable law or agreed to in writing,
15   * software distributed under the License is distributed on an
16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17   * KIND, either express or implied.  See the License for the
18   * specific language governing permissions and limitations
19   * under the License.
20   */
21  
22  package examples;
23  
24  import java.io.Serializable;
25  
26  
27  /**
28   * An example bean for Bean Examples
29   *
30   * @version $Rev$ $Date$
31   */
32  public class TestBean implements Serializable {
33      private static final long serialVersionUID = 1119235675677502359L;
34  
35      // ------------------------------------------------------ Instance Variables
36  
37      /** A boolean value */
38      private boolean booleanValue = false;
39  
40      /** A double value */
41      private double doubleValue = 45213.451;
42  
43      /** A float value */
44      private float floatValue = -123.582F;
45  
46      /** An integer value */
47      private int intValue = 256;
48  
49      /** A long integer value */
50      private long longValue = 1321546L;
51  
52      /** A short integer value */
53      private short shortValue = 257;
54  
55      /** A string value */
56      private String stringValue = "Hello, world!";
57  
58      /** A dateValue value */
59      private java.util.Date dateValue = new java.util.Date();
60  
61      // ------------------------------------------------------------ Constructors
62  
63      /**
64       * Constructor for TestBean.
65       */
66      public TestBean() {
67          super();
68      }
69  
70      // -------------------------------------------------------------- Properties
71  
72      /**
73       * Returns the booleanValue.
74       * @return boolean
75       */
76      public boolean isBooleanValue() {
77          return booleanValue;
78      }
79  
80      /**
81       * Returns the doubleValue.
82       * @return double
83       */
84      public double getDoubleValue() {
85          return doubleValue;
86      }
87  
88      /**
89       * Returns the floatValue.
90       * @return float
91       */
92      public float getFloatValue() {
93          return floatValue;
94      }
95  
96      /**
97       * Returns the intValue.
98       * @return int
99       */
100     public int getIntValue() {
101         return intValue;
102     }
103 
104     /**
105      * Returns the longValue.
106      * @return long
107      */
108     public long getLongValue() {
109         return longValue;
110     }
111 
112     /**
113      * Returns the shortValue.
114      * @return short
115      */
116     public short getShortValue() {
117         return shortValue;
118     }
119 
120     /**
121      * Returns the stringValue.
122      * @return String
123      */
124     public String getStringValue() {
125         return stringValue;
126     }
127 
128     /**
129      * Sets the booleanValue.
130      * @param booleanValue The booleanValue to set
131      */
132     public void setBooleanValue(boolean booleanValue) {
133         this.booleanValue = booleanValue;
134     }
135 
136     /**
137      * Sets the doubleValue.
138      * @param doubleValue The doubleValue to set
139      */
140     public void setDoubleValue(double doubleValue) {
141         this.doubleValue = doubleValue;
142     }
143 
144     /**
145      * Sets the floatValue.
146      * @param floatValue The floatValue to set
147      */
148     public void setFloatValue(float floatValue) {
149         this.floatValue = floatValue;
150     }
151 
152     /**
153      * Sets the intValue.
154      * @param intValue The intValue to set
155      */
156     public void setIntValue(int intValue) {
157         this.intValue = intValue;
158     }
159 
160     /**
161      * Sets the longValue.
162      * @param longValue The longValue to set
163      */
164     public void setLongValue(long longValue) {
165         this.longValue = longValue;
166     }
167 
168     /**
169      * Sets the shortValue.
170      * @param shortValue The shortValue to set
171      */
172     public void setShortValue(short shortValue) {
173         this.shortValue = shortValue;
174     }
175 
176     /**
177      * Sets the stringValue.
178      * @param stringValue The stringValue to set
179      */
180     public void setStringValue(String stringValue) {
181         this.stringValue = stringValue;
182     }
183 
184     /**
185      * Returns the dateValue.
186      * @return java.util.Date
187      */
188     public java.util.Date getDateValue() {
189         return dateValue;
190     }
191 
192     /**
193      * Sets the dateValue.
194      * @param date The date to set
195      */
196     public void setDateValue(java.util.Date date) {
197         this.dateValue = date;
198     }
199 
200 }