1 7 8 package org.alfresco.example.webservice.content; 9 10 public class ContentSegment implements java.io.Serializable { 11 private long offset; 12 private long length; 13 14 public ContentSegment() { 15 } 16 17 public ContentSegment( 18 long offset, 19 long length) { 20 this.offset = offset; 21 this.length = length; 22 } 23 24 25 30 public long getOffset() { 31 return offset; 32 } 33 34 35 40 public void setOffset(long offset) { 41 this.offset = offset; 42 } 43 44 45 50 public long getLength() { 51 return length; 52 } 53 54 55 60 public void setLength(long length) { 61 this.length = length; 62 } 63 64 private java.lang.Object __equalsCalc = null; 65 public synchronized boolean equals(java.lang.Object obj) { 66 if (!(obj instanceof ContentSegment)) return false; 67 ContentSegment other = (ContentSegment) 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.offset == other.getOffset() && 77 this.length == other.getLength(); 78 __equalsCalc = null; 79 return _equals; 80 } 81 82 private boolean __hashCodeCalc = false; 83 public synchronized int hashCode() { 84 if (__hashCodeCalc) { 85 return 0; 86 } 87 __hashCodeCalc = true; 88 int _hashCode = 1; 89 _hashCode += new Long (getOffset()).hashCode(); 90 _hashCode += new Long (getLength()).hashCode(); 91 __hashCodeCalc = false; 92 return _hashCode; 93 } 94 95 private static org.apache.axis.description.TypeDesc typeDesc = 97 new org.apache.axis.description.TypeDesc(ContentSegment.class, true); 98 99 static { 100 typeDesc.setXmlType(new javax.xml.namespace.QName ("http://www.alfresco.org/ws/service/content/1.0", "ContentSegment")); 101 org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc(); 102 elemField.setFieldName("offset"); 103 elemField.setXmlName(new javax.xml.namespace.QName ("http://www.alfresco.org/ws/service/content/1.0", "offset")); 104 elemField.setXmlType(new javax.xml.namespace.QName ("http://www.w3.org/2001/XMLSchema", "long")); 105 elemField.setNillable(false); 106 typeDesc.addFieldDesc(elemField); 107 elemField = new org.apache.axis.description.ElementDesc(); 108 elemField.setFieldName("length"); 109 elemField.setXmlName(new javax.xml.namespace.QName ("http://www.alfresco.org/ws/service/content/1.0", "length")); 110 elemField.setXmlType(new javax.xml.namespace.QName ("http://www.w3.org/2001/XMLSchema", "long")); 111 elemField.setNillable(false); 112 typeDesc.addFieldDesc(elemField); 113 } 114 115 118 public static org.apache.axis.description.TypeDesc getTypeDesc() { 119 return typeDesc; 120 } 121 122 125 public static org.apache.axis.encoding.Serializer getSerializer( 126 java.lang.String mechType, 127 java.lang.Class _javaType, 128 javax.xml.namespace.QName _xmlType) { 129 return 130 new org.apache.axis.encoding.ser.BeanSerializer( 131 _javaType, _xmlType, typeDesc); 132 } 133 134 137 public static org.apache.axis.encoding.Deserializer getDeserializer( 138 java.lang.String mechType, 139 java.lang.Class _javaType, 140 javax.xml.namespace.QName _xmlType) { 141 return 142 new org.apache.axis.encoding.ser.BeanDeserializer( 143 _javaType, _xmlType, typeDesc); 144 } 145 146 } 147 | Popular Tags |