KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > capeclear > www > GlobalWeather_xsd > Temperature


1 /**
2  * Temperature.java
3  *
4  * This file was auto-generated from WSDL
5  * by the Apache Axis WSDL2Java emitter.
6  */

7
8 package com.capeclear.www.GlobalWeather_xsd;
9
10 import java.io.Serializable JavaDoc;
11 import javax.xml.namespace.QName JavaDoc;
12
13 public class Temperature implements Serializable JavaDoc {
14     private double ambient;
15     private double dewpoint;
16     private int relative_humidity;
17     private String JavaDoc string;
18
19     public Temperature() {
20     }
21
22     public double getAmbient() {
23         return ambient;
24     }
25
26     public void setAmbient(double ambient) {
27         this.ambient = ambient;
28     }
29
30     public double getDewpoint() {
31         return dewpoint;
32     }
33
34     public void setDewpoint(double dewpoint) {
35         this.dewpoint = dewpoint;
36     }
37
38     public int getRelative_humidity() {
39         return relative_humidity;
40     }
41
42     public void setRelative_humidity(int relative_humidity) {
43         this.relative_humidity = relative_humidity;
44     }
45
46     public String JavaDoc getString() {
47         return string;
48     }
49
50     public void setString(String JavaDoc string) {
51         this.string = string;
52     }
53
54     private Object JavaDoc __equalsCalc = null;
55     public synchronized boolean equals(Object JavaDoc obj) {
56         if (!(obj instanceof Temperature)) return false;
57         Temperature other = (Temperature) obj;
58         if (obj == null) return false;
59         if (this == obj) return true;
60         if (__equalsCalc != null) {
61             return (__equalsCalc == obj);
62         }
63         __equalsCalc = obj;
64         boolean _equals;
65         _equals = true &&
66             this.ambient == other.getAmbient() &&
67             this.dewpoint == other.getDewpoint() &&
68             this.relative_humidity == other.getRelative_humidity() &&
69             ((this.string==null && other.getString()==null) ||
70              (this.string!=null &&
71               this.string.equals(other.getString())));
72         __equalsCalc = null;
73         return _equals;
74     }
75
76     private boolean __hashCodeCalc = false;
77     public synchronized int hashCode() {
78         if (__hashCodeCalc) {
79             return 0;
80         }
81         __hashCodeCalc = true;
82         int _hashCode = 1;
83         _hashCode += new Double JavaDoc(getAmbient()).hashCode();
84         _hashCode += new Double JavaDoc(getDewpoint()).hashCode();
85         _hashCode += getRelative_humidity();
86         if (getString() != null) {
87             _hashCode += getString().hashCode();
88         }
89         __hashCodeCalc = false;
90         return _hashCode;
91     }
92
93     // Type metadata
94
private static org.apache.axis.description.TypeDesc typeDesc =
95         new org.apache.axis.description.TypeDesc(Temperature.class);
96
97     static {
98         typeDesc.setXmlType(new QName JavaDoc("http://www.capeclear.com/GlobalWeather.xsd", "Temperature"));
99         org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc();
100         elemField.setFieldName("ambient");
101         elemField.setXmlName(new QName JavaDoc("", "ambient"));
102         elemField.setXmlType(new QName JavaDoc("http://www.w3.org/2001/XMLSchema", "double"));
103         typeDesc.addFieldDesc(elemField);
104         elemField = new org.apache.axis.description.ElementDesc();
105         elemField.setFieldName("dewpoint");
106         elemField.setXmlName(new QName JavaDoc("", "dewpoint"));
107         elemField.setXmlType(new QName JavaDoc("http://www.w3.org/2001/XMLSchema", "double"));
108         typeDesc.addFieldDesc(elemField);
109         elemField = new org.apache.axis.description.ElementDesc();
110         elemField.setFieldName("relative_humidity");
111         elemField.setXmlName(new QName JavaDoc("", "relative_humidity"));
112         elemField.setXmlType(new QName JavaDoc("http://www.w3.org/2001/XMLSchema", "int"));
113         typeDesc.addFieldDesc(elemField);
114         elemField = new org.apache.axis.description.ElementDesc();
115         elemField.setFieldName("string");
116         elemField.setXmlName(new QName JavaDoc("", "string"));
117         elemField.setXmlType(new QName JavaDoc("http://www.w3.org/2001/XMLSchema", "string"));
118         typeDesc.addFieldDesc(elemField);
119     }
120
121     /**
122      * Return type metadata object
123      */

124     public static org.apache.axis.description.TypeDesc getTypeDesc() {
125         return typeDesc;
126     }
127
128     /**
129      * Get Custom Serializer
130      */

131     public static org.apache.axis.encoding.Serializer getSerializer(
132            String JavaDoc mechType,
133            Class JavaDoc _javaType,
134            QName JavaDoc _xmlType) {
135         return
136           new org.apache.axis.encoding.ser.BeanSerializer(
137             _javaType, _xmlType, typeDesc);
138     }
139
140     /**
141      * Get Custom Deserializer
142      */

143     public static org.apache.axis.encoding.Deserializer getDeserializer(
144            String JavaDoc mechType,
145            Class JavaDoc _javaType,
146            QName JavaDoc _xmlType) {
147         return
148           new org.apache.axis.encoding.ser.BeanDeserializer(
149             _javaType, _xmlType, typeDesc);
150     }
151
152 }
153
Popular Tags