public Object getFieldValue(_Fields field) { switch (field) { case SUCCESS: return getSuccess(); } throw new IllegalStateException(); }
@Override public int compareTo(getBaggageRestrictions_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); if (lastComparison != 0) { return lastComparison; } if (isSetSuccess()) { lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success); if (lastComparison != 0) { return lastComparison; } } return 0; }
private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException { try { read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in))); } catch (org.apache.thrift.TException te) { throw new java.io.IOException(te); } }
struct.setSuccessIsSet(true); } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); struct.validate();
@Override public void read(org.apache.thrift.protocol.TProtocol prot, getBaggageRestrictions_result struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { { org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); struct.success = new ArrayList<BaggageRestriction>(_list5.size); BaggageRestriction _elem6; for (int _i7 = 0; _i7 < _list5.size; ++_i7) { _elem6 = new BaggageRestriction(); _elem6.read(iprot); struct.success.add(_elem6); } } struct.setSuccessIsSet(true); } } }
public void write(org.apache.thrift.protocol.TProtocol oprot, getBaggageRestrictions_result struct) throws org.apache.thrift.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); if (struct.success != null) { oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); for (BaggageRestriction _iter3 : struct.success) { _iter3.write(oprot); } oprot.writeListEnd(); } oprot.writeFieldEnd(); } oprot.writeFieldStop(); oprot.writeStructEnd(); }
@Override public void write(org.apache.thrift.protocol.TProtocol prot, getBaggageRestrictions_result struct) throws org.apache.thrift.TException { TTupleProtocol oprot = (TTupleProtocol) prot; BitSet optionals = new BitSet(); if (struct.isSetSuccess()) { optionals.set(0); } oprot.writeBitSet(optionals, 1); if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); for (BaggageRestriction _iter4 : struct.success) { _iter4.write(oprot); } } } }
public void onError(Exception e) { byte msgType = org.apache.thrift.protocol.TMessageType.REPLY; org.apache.thrift.TBase msg; getBaggageRestrictions_result result = new getBaggageRestrictions_result(); { msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION; msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage()); } try { fcall.sendResponse(fb,msg,msgType,seqid); return; } catch (Exception ex) { LOGGER.error("Exception writing to internal frame buffer", ex); } fb.close(); } };
public getBaggageRestrictions_result deepCopy() { return new getBaggageRestrictions_result(this); }
public boolean equals(getBaggageRestrictions_result that) { if (that == null) return false; boolean this_present_success = true && this.isSetSuccess(); boolean that_present_success = true && that.isSetSuccess(); if (this_present_success || that_present_success) { if (!(this_present_success && that_present_success)) return false; if (!this.success.equals(that.success)) return false; } return true; }
@Override public boolean equals(Object that) { if (that == null) return false; if (that instanceof getBaggageRestrictions_result) return this.equals((getBaggageRestrictions_result)that); return false; }
public List<BaggageRestriction> recv_getBaggageRestrictions() throws org.apache.thrift.TException { getBaggageRestrictions_result result = new getBaggageRestrictions_result(); receiveBase(result, "getBaggageRestrictions"); if (result.isSetSuccess()) { return result.success; } throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getBaggageRestrictions failed: unknown result"); }
@Override public int hashCode() { List<Object> list = new ArrayList<Object>(); boolean present_success = true && (isSetSuccess()); list.add(present_success); if (present_success) list.add(success); return list.hashCode(); }
public getBaggageRestrictions_result getResult(I iface, getBaggageRestrictions_args args) throws org.apache.thrift.TException { getBaggageRestrictions_result result = new getBaggageRestrictions_result(); result.success = iface.getBaggageRestrictions(args.serviceName); return result; } }
public void onComplete(List<BaggageRestriction> o) { getBaggageRestrictions_result result = new getBaggageRestrictions_result(); result.success = o; try { fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid); return; } catch (Exception e) { LOGGER.error("Exception writing to internal frame buffer", e); } fb.close(); } public void onError(Exception e) {
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */ public boolean isSet(_Fields field) { if (field == null) { throw new IllegalArgumentException(); } switch (field) { case SUCCESS: return isSetSuccess(); } throw new IllegalStateException(); }
/** * Performs a deep copy on <i>other</i>. */ public getBaggageRestrictions_result(getBaggageRestrictions_result other) { if (other.isSetSuccess()) { List<BaggageRestriction> __this__success = new ArrayList<BaggageRestriction>(other.success.size()); for (BaggageRestriction other_element : other.success) { __this__success.add(new BaggageRestriction(other_element)); } this.success = __this__success; } }
private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException { try { write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out))); } catch (org.apache.thrift.TException te) { throw new java.io.IOException(te); } }
public void setFieldValue(_Fields field, Object value) { switch (field) { case SUCCESS: if (value == null) { unsetSuccess(); } else { setSuccess((List<BaggageRestriction>)value); } break; } }