1 16 17 package test.wsdl.interop3.groupE; 18 19 26 public class SOAPStruct { 27 28 private float varFloat; 30 private int varInt; 31 private String varString; 32 33 36 public SOAPStruct() {} 37 38 41 public SOAPStruct(float f, int i, String s) { 42 this.varFloat = f; 43 this.varInt = i; 44 this.varString = s; 45 } 46 47 50 public int getVarInt() { 51 return varInt; 52 } 53 54 57 public void setVarInt(int varInt) { 58 this.varInt = varInt; 59 } 60 61 64 public String getVarString() { 65 return varString; 66 } 67 68 71 public void setVarString(String varString) { 72 this.varString = varString; 73 } 74 75 78 public float getVarFloat() { 79 return varFloat; 80 } 81 82 85 public void setVarFloat(float varFloat) { 86 this.varFloat=varFloat; 87 } 88 89 92 public boolean equals(Object object) { 93 if (!(object instanceof SOAPStruct)) return false; 94 95 SOAPStruct that = (SOAPStruct)object; 96 97 if (this.varInt != that.varInt) return false; 98 99 if (this.varFloat != that.varFloat) return false; 100 101 if (this.varString == null) { 102 if (that.varString != null) return false; 103 } else { 104 if (!this.varString.equals(that.varString)) return false; 105 } 106 107 return true; 108 } 109 110 113 public String toString() { 114 return "{" + varInt + ", \"" + varString + "\", " + varFloat + "}"; 115 } 116 } 117 | Popular Tags |