/** Performs a deep copy on <i>other</i>. */
 public itemReservation(itemReservation other) {
   __isset_bit_vector.clear();
   __isset_bit_vector.or(other.__isset_bit_vector);
   this.uid = other.uid;
   if (other.isSetItemNumber()) {
     this.itemNumber = other.itemNumber;
   }
   this.reserveQuantity = other.reserveQuantity;
   if (other.isSetOrderNumber()) {
     this.orderNumber = other.orderNumber;
   }
   if (other.isSetFromId()) {
     this.fromId = other.fromId;
   }
 }
  public boolean equals(itemReservation that) {
    if (that == null) return false;

    boolean this_present_uid = true;
    boolean that_present_uid = true;
    if (this_present_uid || that_present_uid) {
      if (!(this_present_uid && that_present_uid)) return false;
      if (this.uid != that.uid) return false;
    }

    boolean this_present_itemNumber = true && this.isSetItemNumber();
    boolean that_present_itemNumber = true && that.isSetItemNumber();
    if (this_present_itemNumber || that_present_itemNumber) {
      if (!(this_present_itemNumber && that_present_itemNumber)) return false;
      if (!this.itemNumber.equals(that.itemNumber)) return false;
    }

    boolean this_present_reserveQuantity = true;
    boolean that_present_reserveQuantity = true;
    if (this_present_reserveQuantity || that_present_reserveQuantity) {
      if (!(this_present_reserveQuantity && that_present_reserveQuantity)) return false;
      if (this.reserveQuantity != that.reserveQuantity) return false;
    }

    boolean this_present_orderNumber = true && this.isSetOrderNumber();
    boolean that_present_orderNumber = true && that.isSetOrderNumber();
    if (this_present_orderNumber || that_present_orderNumber) {
      if (!(this_present_orderNumber && that_present_orderNumber)) return false;
      if (!this.orderNumber.equals(that.orderNumber)) return false;
    }

    boolean this_present_fromId = true && this.isSetFromId();
    boolean that_present_fromId = true && that.isSetFromId();
    if (this_present_fromId || that_present_fromId) {
      if (!(this_present_fromId && that_present_fromId)) return false;
      if (!this.fromId.equals(that.fromId)) return false;
    }

    return true;
  }
  public int compareTo(itemReservation other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

    int lastComparison = 0;
    itemReservation typedOther = (itemReservation) other;

    lastComparison = Boolean.valueOf(isSetUid()).compareTo(typedOther.isSetUid());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetUid()) {
      lastComparison = TBaseHelper.compareTo(uid, typedOther.uid);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetItemNumber()).compareTo(typedOther.isSetItemNumber());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetItemNumber()) {
      lastComparison = TBaseHelper.compareTo(itemNumber, typedOther.itemNumber);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison =
        Boolean.valueOf(isSetReserveQuantity()).compareTo(typedOther.isSetReserveQuantity());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetReserveQuantity()) {
      lastComparison = TBaseHelper.compareTo(reserveQuantity, typedOther.reserveQuantity);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetOrderNumber()).compareTo(typedOther.isSetOrderNumber());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetOrderNumber()) {
      lastComparison = TBaseHelper.compareTo(orderNumber, typedOther.orderNumber);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetFromId()).compareTo(typedOther.isSetFromId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFromId()) {
      lastComparison = TBaseHelper.compareTo(fromId, typedOther.fromId);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }