KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > test > xml > multispaced > XMBeanAttributeMetaData


1 /*
2  * JBoss, the OpenSource J2EE webOS
3  *
4  * Distributable under LGPL license.
5  * See terms of license at gnu.org.
6  */

7 package org.jboss.test.xml.multispaced;
8
9 /**
10  * @version <tt>$Revision: 1.1 $</tt>
11  * @author <a HREF="mailto:alex@jboss.org">Alexey Loubyansky</a>
12  */

13 public class XMBeanAttributeMetaData
14 {
15    private String JavaDoc access;
16    private String JavaDoc getMethod;
17    private String JavaDoc setMethod;
18    private String JavaDoc description;
19    private String JavaDoc name;
20    private String JavaDoc type;
21
22    public String JavaDoc getAccess()
23    {
24       return access;
25    }
26
27    public void setAccess(String JavaDoc access)
28    {
29       this.access = access;
30    }
31
32    public String JavaDoc getGetMethod()
33    {
34       return getMethod;
35    }
36
37    public void setGetMethod(String JavaDoc getMethod)
38    {
39       this.getMethod = getMethod;
40    }
41
42    public String JavaDoc getSetMethod()
43    {
44       return setMethod;
45    }
46
47    public void setSetMethod(String JavaDoc setMethod)
48    {
49       this.setMethod = setMethod;
50    }
51
52    public String JavaDoc getDescription()
53    {
54       return description;
55    }
56
57    public void setDescription(String JavaDoc description)
58    {
59       this.description = description;
60    }
61
62    public String JavaDoc getName()
63    {
64       return name;
65    }
66
67    public void setName(String JavaDoc name)
68    {
69       this.name = name;
70    }
71
72    public String JavaDoc getType()
73    {
74       return type;
75    }
76
77    public void setType(String JavaDoc type)
78    {
79       this.type = type;
80    }
81
82    public String JavaDoc toString()
83    {
84       return
85          "[description=" + description +
86          ", access=" + access +
87          ", getMethod=" + getMethod +
88          ", setMethod=" + setMethod +
89          ", name=" + name +
90          ", type=" + type + ']';
91    }
92
93    public boolean equals(Object JavaDoc o)
94    {
95       if(this == o) return true;
96       if(!(o instanceof XMBeanAttributeMetaData)) return false;
97
98       final XMBeanAttributeMetaData mBeanAttributeMetaData = (XMBeanAttributeMetaData)o;
99
100       if(access != null ? !access.equals(mBeanAttributeMetaData.access) : mBeanAttributeMetaData.access != null) return false;
101       if(description != null ? !description.equals(mBeanAttributeMetaData.description) : mBeanAttributeMetaData.description != null) return false;
102       if(getMethod != null ? !getMethod.equals(mBeanAttributeMetaData.getMethod) : mBeanAttributeMetaData.getMethod != null) return false;
103       if(name != null ? !name.equals(mBeanAttributeMetaData.name) : mBeanAttributeMetaData.name != null) return false;
104       if(setMethod != null ? !setMethod.equals(mBeanAttributeMetaData.setMethod) : mBeanAttributeMetaData.setMethod != null) return false;
105       if(type != null ? !type.equals(mBeanAttributeMetaData.type) : mBeanAttributeMetaData.type != null) return false;
106
107       return true;
108    }
109
110    public int hashCode()
111    {
112       int result;
113       result = (access != null ? access.hashCode() : 0);
114       result = 29 * result + (getMethod != null ? getMethod.hashCode() : 0);
115       result = 29 * result + (setMethod != null ? setMethod.hashCode() : 0);
116       result = 29 * result + (description != null ? description.hashCode() : 0);
117       result = 29 * result + (name != null ? name.hashCode() : 0);
118       result = 29 * result + (type != null ? type.hashCode() : 0);
119       return result;
120    }
121 }
122
Popular Tags