public boolean get_not_found() { if (getSetField() == _Fields.NOT_FOUND) { return (Boolean)getFieldValue(); } else { throw new RuntimeException("Cannot get field 'not_found' because union is currently set to " + getFieldDesc(getSetField()).name); } }
public HankException get_xception() { if (getSetField() == _Fields.XCEPTION) { return (HankException)getFieldValue(); } else { throw new RuntimeException("Cannot get field 'xception' because union is currently set to " + getFieldDesc(getSetField()).name); } }
public ByteBuffer buffer_for_value() { if (getSetField() == _Fields.VALUE) { return (ByteBuffer)getFieldValue(); } else { throw new RuntimeException("Cannot get field 'value' because union is currently set to " + getFieldDesc(getSetField()).name); } }
@Override public int compareTo(HankResponse other) { int lastComparison = org.apache.thrift.TBaseHelper.compareTo(getSetField(), other.getSetField()); if (lastComparison == 0) { return org.apache.thrift.TBaseHelper.compareTo(getFieldValue(), other.getFieldValue()); } return lastComparison; }
public boolean equals(HankResponse other) { return other != null && getSetField() == other.getSetField() && getFieldValue().equals(other.getFieldValue()); }
@Override public int hashCode() { HashCodeBuilder hcb = new HashCodeBuilder(); hcb.append(this.getClass().getName()); org.apache.thrift.TFieldIdEnum setField = getSetField(); if (setField != null) { hcb.append(setField.getThriftFieldId()); Object value = getFieldValue(); if (value instanceof org.apache.thrift.TEnum) { hcb.append(((org.apache.thrift.TEnum)getFieldValue()).getValue()); } else { hcb.append(value); } } return hcb.toHashCode(); } private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {