1
7
8 package oasis.names.tc.wsrp.v1.types;
9
10 public class Postal implements java.io.Serializable {
11 private java.lang.String name;
12 private java.lang.String street;
13 private java.lang.String city;
14 private java.lang.String stateprov;
15 private java.lang.String postalcode;
16 private java.lang.String country;
17 private java.lang.String organization;
18 private oasis.names.tc.wsrp.v1.types.Extension[] extensions;
19
20 public Postal() {
21 }
22
23 public Postal(
24 java.lang.String city,
25 java.lang.String country,
26 oasis.names.tc.wsrp.v1.types.Extension[] extensions,
27 java.lang.String name,
28 java.lang.String organization,
29 java.lang.String postalcode,
30 java.lang.String stateprov,
31 java.lang.String street) {
32 this.name = name;
33 this.street = street;
34 this.city = city;
35 this.stateprov = stateprov;
36 this.postalcode = postalcode;
37 this.country = country;
38 this.organization = organization;
39 this.extensions = extensions;
40 }
41
42
43
48 public java.lang.String getName() {
49 return name;
50 }
51
52
53
58 public void setName(java.lang.String name) {
59 this.name = name;
60 }
61
62
63
68 public java.lang.String getStreet() {
69 return street;
70 }
71
72
73
78 public void setStreet(java.lang.String street) {
79 this.street = street;
80 }
81
82
83
88 public java.lang.String getCity() {
89 return city;
90 }
91
92
93
98 public void setCity(java.lang.String city) {
99 this.city = city;
100 }
101
102
103
108 public java.lang.String getStateprov() {
109 return stateprov;
110 }
111
112
113
118 public void setStateprov(java.lang.String stateprov) {
119 this.stateprov = stateprov;
120 }
121
122
123
128 public java.lang.String getPostalcode() {
129 return postalcode;
130 }
131
132
133
138 public void setPostalcode(java.lang.String postalcode) {
139 this.postalcode = postalcode;
140 }
141
142
143
148 public java.lang.String getCountry() {
149 return country;
150 }
151
152
153
158 public void setCountry(java.lang.String country) {
159 this.country = country;
160 }
161
162
163
168 public java.lang.String getOrganization() {
169 return organization;
170 }
171
172
173
178 public void setOrganization(java.lang.String organization) {
179 this.organization = organization;
180 }
181
182
183
188 public oasis.names.tc.wsrp.v1.types.Extension[] getExtensions() {
189 return extensions;
190 }
191
192
193
198 public void setExtensions(oasis.names.tc.wsrp.v1.types.Extension[] extensions) {
199 this.extensions = extensions;
200 }
201
202 public oasis.names.tc.wsrp.v1.types.Extension getExtensions(int i) {
203 return this.extensions[i];
204 }
205
206 public void setExtensions(int i, oasis.names.tc.wsrp.v1.types.Extension _value) {
207 this.extensions[i] = _value;
208 }
209
210 private java.lang.Object __equalsCalc = null;
211 public synchronized boolean equals(java.lang.Object obj) {
212 if (!(obj instanceof Postal)) return false;
213 Postal other = (Postal) obj;
214 if (obj == null) return false;
215 if (this == obj) return true;
216 if (__equalsCalc != null) {
217 return (__equalsCalc == obj);
218 }
219 __equalsCalc = obj;
220 boolean _equals;
221 _equals = true &&
222 ((this.name==null && other.getName()==null) ||
223 (this.name!=null &&
224 this.name.equals(other.getName()))) &&
225 ((this.street==null && other.getStreet()==null) ||
226 (this.street!=null &&
227 this.street.equals(other.getStreet()))) &&
228 ((this.city==null && other.getCity()==null) ||
229 (this.city!=null &&
230 this.city.equals(other.getCity()))) &&
231 ((this.stateprov==null && other.getStateprov()==null) ||
232 (this.stateprov!=null &&
233 this.stateprov.equals(other.getStateprov()))) &&
234 ((this.postalcode==null && other.getPostalcode()==null) ||
235 (this.postalcode!=null &&
236 this.postalcode.equals(other.getPostalcode()))) &&
237 ((this.country==null && other.getCountry()==null) ||
238 (this.country!=null &&
239 this.country.equals(other.getCountry()))) &&
240 ((this.organization==null && other.getOrganization()==null) ||
241 (this.organization!=null &&
242 this.organization.equals(other.getOrganization()))) &&
243 ((this.extensions==null && other.getExtensions()==null) ||
244 (this.extensions!=null &&
245 java.util.Arrays.equals(this.extensions, other.getExtensions())));
246 __equalsCalc = null;
247 return _equals;
248 }
249
250 private boolean __hashCodeCalc = false;
251 public synchronized int hashCode() {
252 if (__hashCodeCalc) {
253 return 0;
254 }
255 __hashCodeCalc = true;
256 int _hashCode = 1;
257 if (getName() != null) {
258 _hashCode += getName().hashCode();
259 }
260 if (getStreet() != null) {
261 _hashCode += getStreet().hashCode();
262 }
263 if (getCity() != null) {
264 _hashCode += getCity().hashCode();
265 }
266 if (getStateprov() != null) {
267 _hashCode += getStateprov().hashCode();
268 }
269 if (getPostalcode() != null) {
270 _hashCode += getPostalcode().hashCode();
271 }
272 if (getCountry() != null) {
273 _hashCode += getCountry().hashCode();
274 }
275 if (getOrganization() != null) {
276 _hashCode += getOrganization().hashCode();
277 }
278 if (getExtensions() != null) {
279 for (int i=0;
280 i<java.lang.reflect.Array.getLength(getExtensions());
281 i++) {
282 java.lang.Object obj = java.lang.reflect.Array.get(getExtensions(), i);
283 if (obj != null &&
284 !obj.getClass().isArray()) {
285 _hashCode += obj.hashCode();
286 }
287 }
288 }
289 __hashCodeCalc = false;
290 return _hashCode;
291 }
292
293 private static org.apache.axis.description.TypeDesc typeDesc =
295 new org.apache.axis.description.TypeDesc(Postal.class, true);
296
297 static {
298 typeDesc.setXmlType(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "Postal"));
299 org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc();
300 elemField.setFieldName("name");
301 elemField.setXmlName(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "name"));
302 elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
303 elemField.setMinOccurs(0);
304 typeDesc.addFieldDesc(elemField);
305 elemField = new org.apache.axis.description.ElementDesc();
306 elemField.setFieldName("street");
307 elemField.setXmlName(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "street"));
308 elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
309 elemField.setMinOccurs(0);
310 typeDesc.addFieldDesc(elemField);
311 elemField = new org.apache.axis.description.ElementDesc();
312 elemField.setFieldName("city");
313 elemField.setXmlName(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "city"));
314 elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
315 elemField.setMinOccurs(0);
316 typeDesc.addFieldDesc(elemField);
317 elemField = new org.apache.axis.description.ElementDesc();
318 elemField.setFieldName("stateprov");
319 elemField.setXmlName(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "stateprov"));
320 elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
321 elemField.setMinOccurs(0);
322 typeDesc.addFieldDesc(elemField);
323 elemField = new org.apache.axis.description.ElementDesc();
324 elemField.setFieldName("postalcode");
325 elemField.setXmlName(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "postalcode"));
326 elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
327 elemField.setMinOccurs(0);
328 typeDesc.addFieldDesc(elemField);
329 elemField = new org.apache.axis.description.ElementDesc();
330 elemField.setFieldName("country");
331 elemField.setXmlName(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "country"));
332 elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
333 elemField.setMinOccurs(0);
334 typeDesc.addFieldDesc(elemField);
335 elemField = new org.apache.axis.description.ElementDesc();
336 elemField.setFieldName("organization");
337 elemField.setXmlName(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "organization"));
338 elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
339 elemField.setMinOccurs(0);
340 typeDesc.addFieldDesc(elemField);
341 elemField = new org.apache.axis.description.ElementDesc();
342 elemField.setFieldName("extensions");
343 elemField.setXmlName(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "extensions"));
344 elemField.setXmlType(new javax.xml.namespace.QName("urn:oasis:names:tc:wsrp:v1:types", "Extension"));
345 elemField.setMinOccurs(0);
346 typeDesc.addFieldDesc(elemField);
347 }
348
349
352 public static org.apache.axis.description.TypeDesc getTypeDesc() {
353 return typeDesc;
354 }
355
356
359 public static org.apache.axis.encoding.Serializer getSerializer(
360 java.lang.String mechType,
361 java.lang.Class _javaType,
362 javax.xml.namespace.QName _xmlType) {
363 return
364 new org.apache.axis.encoding.ser.BeanSerializer(
365 _javaType, _xmlType, typeDesc);
366 }
367
368
371 public static org.apache.axis.encoding.Deserializer getDeserializer(
372 java.lang.String mechType,
373 java.lang.Class _javaType,
374 javax.xml.namespace.QName _xmlType) {
375 return
376 new org.apache.axis.encoding.ser.BeanDeserializer(
377 _javaType, _xmlType, typeDesc);
378 }
379
380 }
381