KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > alfresco > example > webservice > repository > RepositoryFault


1 /**
2  * RepositoryFault.java
3  *
4  * This file was auto-generated from WSDL
5  * by the Apache Axis 1.2.1 Jun 14, 2005 (09:15:57 EDT) WSDL2Java emitter.
6  */

7
8 package org.alfresco.example.webservice.repository;
9
10 public class RepositoryFault extends org.apache.axis.AxisFault implements java.io.Serializable JavaDoc {
11     private int errorCode;
12     private java.lang.String JavaDoc message1;
13
14     public RepositoryFault() {
15     }
16
17     public RepositoryFault(
18            int errorCode,
19            java.lang.String JavaDoc message1) {
20         this.errorCode = errorCode;
21         this.message1 = message1;
22     }
23
24
25     /**
26      * Gets the errorCode value for this RepositoryFault.
27      *
28      * @return errorCode
29      */

30     public int getErrorCode() {
31         return errorCode;
32     }
33
34
35     /**
36      * Sets the errorCode value for this RepositoryFault.
37      *
38      * @param errorCode
39      */

40     public void setErrorCode(int errorCode) {
41         this.errorCode = errorCode;
42     }
43
44
45     /**
46      * Gets the message1 value for this RepositoryFault.
47      *
48      * @return message1
49      */

50     public java.lang.String JavaDoc getMessage1() {
51         return message1;
52     }
53
54
55     /**
56      * Sets the message1 value for this RepositoryFault.
57      *
58      * @param message1
59      */

60     public void setMessage1(java.lang.String JavaDoc message1) {
61         this.message1 = message1;
62     }
63
64     private java.lang.Object JavaDoc __equalsCalc = null;
65     public synchronized boolean equals(java.lang.Object JavaDoc obj) {
66         if (!(obj instanceof RepositoryFault)) return false;
67         RepositoryFault other = (RepositoryFault) obj;
68         if (obj == null) return false;
69         if (this == obj) return true;
70         if (__equalsCalc != null) {
71             return (__equalsCalc == obj);
72         }
73         __equalsCalc = obj;
74         boolean _equals;
75         _equals = true &&
76             this.errorCode == other.getErrorCode() &&
77             ((this.message1==null && other.getMessage1()==null) ||
78              (this.message1!=null &&
79               this.message1.equals(other.getMessage1())));
80         __equalsCalc = null;
81         return _equals;
82     }
83
84     private boolean __hashCodeCalc = false;
85     public synchronized int hashCode() {
86         if (__hashCodeCalc) {
87             return 0;
88         }
89         __hashCodeCalc = true;
90         int _hashCode = 1;
91         _hashCode += getErrorCode();
92         if (getMessage1() != null) {
93             _hashCode += getMessage1().hashCode();
94         }
95         __hashCodeCalc = false;
96         return _hashCode;
97     }
98
99     // Type metadata
100
private static org.apache.axis.description.TypeDesc typeDesc =
101         new org.apache.axis.description.TypeDesc(RepositoryFault.class, true);
102
103     static {
104         typeDesc.setXmlType(new javax.xml.namespace.QName JavaDoc("http://www.alfresco.org/ws/service/repository/1.0", "RepositoryFault"));
105         org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc();
106         elemField.setFieldName("errorCode");
107         elemField.setXmlName(new javax.xml.namespace.QName JavaDoc("http://www.alfresco.org/ws/service/repository/1.0", "errorCode"));
108         elemField.setXmlType(new javax.xml.namespace.QName JavaDoc("http://www.w3.org/2001/XMLSchema", "int"));
109         elemField.setNillable(false);
110         typeDesc.addFieldDesc(elemField);
111         elemField = new org.apache.axis.description.ElementDesc();
112         elemField.setFieldName("message1");
113         elemField.setXmlName(new javax.xml.namespace.QName JavaDoc("http://www.alfresco.org/ws/service/repository/1.0", "message"));
114         elemField.setXmlType(new javax.xml.namespace.QName JavaDoc("http://www.w3.org/2001/XMLSchema", "string"));
115         elemField.setNillable(false);
116         typeDesc.addFieldDesc(elemField);
117     }
118
119     /**
120      * Return type metadata object
121      */

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

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

141     public static org.apache.axis.encoding.Deserializer getDeserializer(
142            java.lang.String JavaDoc mechType,
143            java.lang.Class JavaDoc _javaType,
144            javax.xml.namespace.QName JavaDoc _xmlType) {
145         return
146           new org.apache.axis.encoding.ser.BeanDeserializer(
147             _javaType, _xmlType, typeDesc);
148     }
149
150
151     /**
152      * Writes the exception data to the faultDetails
153      */

154     public void writeDetails(javax.xml.namespace.QName JavaDoc qname, org.apache.axis.encoding.SerializationContext context) throws java.io.IOException JavaDoc {
155         context.serialize(qname, null, this);
156     }
157 }
158
Popular Tags