001: /**
002: * Postal.java
003: *
004: * This file was auto-generated from WSDL
005: * by the Apache Axis 1.2RC3 Feb 28, 2005 (10:15:14 EST) WSDL2Java emitter.
006: */package oasis.names.tc.wsrp.v1.types;
007:
008: public class Postal implements java.io.Serializable {
009: private java.lang.String name;
010: private java.lang.String street;
011: private java.lang.String city;
012: private java.lang.String stateprov;
013: private java.lang.String postalcode;
014: private java.lang.String country;
015: private java.lang.String organization;
016: private oasis.names.tc.wsrp.v1.types.Extension[] extensions;
017:
018: public Postal() {
019: }
020:
021: public Postal(java.lang.String city, java.lang.String country,
022: oasis.names.tc.wsrp.v1.types.Extension[] extensions,
023: java.lang.String name, java.lang.String organization,
024: java.lang.String postalcode, java.lang.String stateprov,
025: java.lang.String street) {
026: this .name = name;
027: this .street = street;
028: this .city = city;
029: this .stateprov = stateprov;
030: this .postalcode = postalcode;
031: this .country = country;
032: this .organization = organization;
033: this .extensions = extensions;
034: }
035:
036: /**
037: * Gets the name value for this Postal.
038: *
039: * @return name
040: */
041: public java.lang.String getName() {
042: return name;
043: }
044:
045: /**
046: * Sets the name value for this Postal.
047: *
048: * @param name
049: */
050: public void setName(java.lang.String name) {
051: this .name = name;
052: }
053:
054: /**
055: * Gets the street value for this Postal.
056: *
057: * @return street
058: */
059: public java.lang.String getStreet() {
060: return street;
061: }
062:
063: /**
064: * Sets the street value for this Postal.
065: *
066: * @param street
067: */
068: public void setStreet(java.lang.String street) {
069: this .street = street;
070: }
071:
072: /**
073: * Gets the city value for this Postal.
074: *
075: * @return city
076: */
077: public java.lang.String getCity() {
078: return city;
079: }
080:
081: /**
082: * Sets the city value for this Postal.
083: *
084: * @param city
085: */
086: public void setCity(java.lang.String city) {
087: this .city = city;
088: }
089:
090: /**
091: * Gets the stateprov value for this Postal.
092: *
093: * @return stateprov
094: */
095: public java.lang.String getStateprov() {
096: return stateprov;
097: }
098:
099: /**
100: * Sets the stateprov value for this Postal.
101: *
102: * @param stateprov
103: */
104: public void setStateprov(java.lang.String stateprov) {
105: this .stateprov = stateprov;
106: }
107:
108: /**
109: * Gets the postalcode value for this Postal.
110: *
111: * @return postalcode
112: */
113: public java.lang.String getPostalcode() {
114: return postalcode;
115: }
116:
117: /**
118: * Sets the postalcode value for this Postal.
119: *
120: * @param postalcode
121: */
122: public void setPostalcode(java.lang.String postalcode) {
123: this .postalcode = postalcode;
124: }
125:
126: /**
127: * Gets the country value for this Postal.
128: *
129: * @return country
130: */
131: public java.lang.String getCountry() {
132: return country;
133: }
134:
135: /**
136: * Sets the country value for this Postal.
137: *
138: * @param country
139: */
140: public void setCountry(java.lang.String country) {
141: this .country = country;
142: }
143:
144: /**
145: * Gets the organization value for this Postal.
146: *
147: * @return organization
148: */
149: public java.lang.String getOrganization() {
150: return organization;
151: }
152:
153: /**
154: * Sets the organization value for this Postal.
155: *
156: * @param organization
157: */
158: public void setOrganization(java.lang.String organization) {
159: this .organization = organization;
160: }
161:
162: /**
163: * Gets the extensions value for this Postal.
164: *
165: * @return extensions
166: */
167: public oasis.names.tc.wsrp.v1.types.Extension[] getExtensions() {
168: return extensions;
169: }
170:
171: /**
172: * Sets the extensions value for this Postal.
173: *
174: * @param extensions
175: */
176: public void setExtensions(
177: oasis.names.tc.wsrp.v1.types.Extension[] extensions) {
178: this .extensions = extensions;
179: }
180:
181: public oasis.names.tc.wsrp.v1.types.Extension getExtensions(int i) {
182: return this .extensions[i];
183: }
184:
185: public void setExtensions(int i,
186: oasis.names.tc.wsrp.v1.types.Extension _value) {
187: this .extensions[i] = _value;
188: }
189:
190: private java.lang.Object __equalsCalc = null;
191:
192: public synchronized boolean equals(java.lang.Object obj) {
193: if (!(obj instanceof Postal))
194: return false;
195: Postal other = (Postal) obj;
196: if (obj == null)
197: return false;
198: if (this == obj)
199: return true;
200: if (__equalsCalc != null) {
201: return (__equalsCalc == obj);
202: }
203: __equalsCalc = obj;
204: boolean _equals;
205: _equals = true
206: && ((this .name == null && other.getName() == null) || (this .name != null && this .name
207: .equals(other.getName())))
208: && ((this .street == null && other.getStreet() == null) || (this .street != null && this .street
209: .equals(other.getStreet())))
210: && ((this .city == null && other.getCity() == null) || (this .city != null && this .city
211: .equals(other.getCity())))
212: && ((this .stateprov == null && other.getStateprov() == null) || (this .stateprov != null && this .stateprov
213: .equals(other.getStateprov())))
214: && ((this .postalcode == null && other.getPostalcode() == null) || (this .postalcode != null && this .postalcode
215: .equals(other.getPostalcode())))
216: && ((this .country == null && other.getCountry() == null) || (this .country != null && this .country
217: .equals(other.getCountry())))
218: && ((this .organization == null && other
219: .getOrganization() == null) || (this .organization != null && this .organization
220: .equals(other.getOrganization())))
221: && ((this .extensions == null && other.getExtensions() == null) || (this .extensions != null && java.util.Arrays
222: .equals(this .extensions, other.getExtensions())));
223: __equalsCalc = null;
224: return _equals;
225: }
226:
227: private boolean __hashCodeCalc = false;
228:
229: public synchronized int hashCode() {
230: if (__hashCodeCalc) {
231: return 0;
232: }
233: __hashCodeCalc = true;
234: int _hashCode = 1;
235: if (getName() != null) {
236: _hashCode += getName().hashCode();
237: }
238: if (getStreet() != null) {
239: _hashCode += getStreet().hashCode();
240: }
241: if (getCity() != null) {
242: _hashCode += getCity().hashCode();
243: }
244: if (getStateprov() != null) {
245: _hashCode += getStateprov().hashCode();
246: }
247: if (getPostalcode() != null) {
248: _hashCode += getPostalcode().hashCode();
249: }
250: if (getCountry() != null) {
251: _hashCode += getCountry().hashCode();
252: }
253: if (getOrganization() != null) {
254: _hashCode += getOrganization().hashCode();
255: }
256: if (getExtensions() != null) {
257: for (int i = 0; i < java.lang.reflect.Array
258: .getLength(getExtensions()); i++) {
259: java.lang.Object obj = java.lang.reflect.Array.get(
260: getExtensions(), i);
261: if (obj != null && !obj.getClass().isArray()) {
262: _hashCode += obj.hashCode();
263: }
264: }
265: }
266: __hashCodeCalc = false;
267: return _hashCode;
268: }
269:
270: // Type metadata
271: private static org.apache.axis.description.TypeDesc typeDesc = new org.apache.axis.description.TypeDesc(
272: Postal.class, true);
273:
274: static {
275: typeDesc.setXmlType(new javax.xml.namespace.QName(
276: "urn:oasis:names:tc:wsrp:v1:types", "Postal"));
277: org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc();
278: elemField.setFieldName("name");
279: elemField.setXmlName(new javax.xml.namespace.QName(
280: "urn:oasis:names:tc:wsrp:v1:types", "name"));
281: elemField.setXmlType(new javax.xml.namespace.QName(
282: "http://www.w3.org/2001/XMLSchema", "string"));
283: elemField.setMinOccurs(0);
284: typeDesc.addFieldDesc(elemField);
285: elemField = new org.apache.axis.description.ElementDesc();
286: elemField.setFieldName("street");
287: elemField.setXmlName(new javax.xml.namespace.QName(
288: "urn:oasis:names:tc:wsrp:v1:types", "street"));
289: elemField.setXmlType(new javax.xml.namespace.QName(
290: "http://www.w3.org/2001/XMLSchema", "string"));
291: elemField.setMinOccurs(0);
292: typeDesc.addFieldDesc(elemField);
293: elemField = new org.apache.axis.description.ElementDesc();
294: elemField.setFieldName("city");
295: elemField.setXmlName(new javax.xml.namespace.QName(
296: "urn:oasis:names:tc:wsrp:v1:types", "city"));
297: elemField.setXmlType(new javax.xml.namespace.QName(
298: "http://www.w3.org/2001/XMLSchema", "string"));
299: elemField.setMinOccurs(0);
300: typeDesc.addFieldDesc(elemField);
301: elemField = new org.apache.axis.description.ElementDesc();
302: elemField.setFieldName("stateprov");
303: elemField.setXmlName(new javax.xml.namespace.QName(
304: "urn:oasis:names:tc:wsrp:v1:types", "stateprov"));
305: elemField.setXmlType(new javax.xml.namespace.QName(
306: "http://www.w3.org/2001/XMLSchema", "string"));
307: elemField.setMinOccurs(0);
308: typeDesc.addFieldDesc(elemField);
309: elemField = new org.apache.axis.description.ElementDesc();
310: elemField.setFieldName("postalcode");
311: elemField.setXmlName(new javax.xml.namespace.QName(
312: "urn:oasis:names:tc:wsrp:v1:types", "postalcode"));
313: elemField.setXmlType(new javax.xml.namespace.QName(
314: "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("country");
319: elemField.setXmlName(new javax.xml.namespace.QName(
320: "urn:oasis:names:tc:wsrp:v1:types", "country"));
321: elemField.setXmlType(new javax.xml.namespace.QName(
322: "http://www.w3.org/2001/XMLSchema", "string"));
323: elemField.setMinOccurs(0);
324: typeDesc.addFieldDesc(elemField);
325: elemField = new org.apache.axis.description.ElementDesc();
326: elemField.setFieldName("organization");
327: elemField.setXmlName(new javax.xml.namespace.QName(
328: "urn:oasis:names:tc:wsrp:v1:types", "organization"));
329: elemField.setXmlType(new javax.xml.namespace.QName(
330: "http://www.w3.org/2001/XMLSchema", "string"));
331: elemField.setMinOccurs(0);
332: typeDesc.addFieldDesc(elemField);
333: elemField = new org.apache.axis.description.ElementDesc();
334: elemField.setFieldName("extensions");
335: elemField.setXmlName(new javax.xml.namespace.QName(
336: "urn:oasis:names:tc:wsrp:v1:types", "extensions"));
337: elemField.setXmlType(new javax.xml.namespace.QName(
338: "urn:oasis:names:tc:wsrp:v1:types", "Extension"));
339: elemField.setMinOccurs(0);
340: typeDesc.addFieldDesc(elemField);
341: }
342:
343: /**
344: * Return type metadata object
345: */
346: public static org.apache.axis.description.TypeDesc getTypeDesc() {
347: return typeDesc;
348: }
349:
350: /**
351: * Get Custom Serializer
352: */
353: public static org.apache.axis.encoding.Serializer getSerializer(
354: java.lang.String mechType, java.lang.Class _javaType,
355: javax.xml.namespace.QName _xmlType) {
356: return new org.apache.axis.encoding.ser.BeanSerializer(
357: _javaType, _xmlType, typeDesc);
358: }
359:
360: /**
361: * Get Custom Deserializer
362: */
363: public static org.apache.axis.encoding.Deserializer getDeserializer(
364: java.lang.String mechType, java.lang.Class _javaType,
365: javax.xml.namespace.QName _xmlType) {
366: return new org.apache.axis.encoding.ser.BeanDeserializer(
367: _javaType, _xmlType, typeDesc);
368: }
369:
370: }
|