KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > test > TestBean


1 /*
2  * TestBean.java
3  *
4  * Created on 22. leden 2004, 14:13
5  */

6
7 package test;
8
9 /**
10  *
11  * @author lm97939
12  */

13 public class TestBean {
14     
15     /**
16      * Holds value of property stringProperty.
17      */

18     private String JavaDoc stringProperty;
19     
20     /**
21      * Holds value of property intProperty.
22      */

23     private int intProperty;
24     
25     /** Creates a new instance of TestBean */
26     public TestBean() {
27     }
28     
29     /**
30      * Getter for property stringProperty.
31      * @return Value of property stringProperty.
32      */

33     public String JavaDoc getStringProperty() {
34         return this.stringProperty;
35     }
36     
37     /**
38      * Setter for property stringProperty.
39      * @param stringProperty New value of property stringProperty.
40      */

41     public void setStringProperty(String JavaDoc stringProperty) {
42         this.stringProperty = stringProperty;
43     }
44     
45     /**
46      * Getter for property intProperty.
47      * @return Value of property intProperty.
48      */

49     public int getIntProperty() {
50         return this.intProperty;
51     }
52     
53     /**
54      * Setter for property intProperty.
55      * @param intProperty New value of property intProperty.
56      */

57     public void setIntProperty(int intProperty) {
58         this.intProperty = intProperty;
59     }
60     
61     public int add(int x) {
62         return getIntProperty() + x ;
63     }
64     
65 }
66
Popular Tags