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

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

    lastComparison =
        Boolean.valueOf(isSetInterpretations()).compareTo(typedOther.isSetInterpretations());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetInterpretations()) {
      lastComparison = TBaseHelper.compareTo(this.interpretations, typedOther.interpretations);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetDebugLines()).compareTo(typedOther.isSetDebugLines());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetDebugLines()) {
      lastComparison = TBaseHelper.compareTo(this.debugLines, typedOther.debugLines);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison =
        Boolean.valueOf(isSetRequestWktGeometry()).compareTo(typedOther.isSetRequestWktGeometry());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetRequestWktGeometry()) {
      lastComparison =
          TBaseHelper.compareTo(this.requestWktGeometry, typedOther.requestWktGeometry);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }