示例#1
0
  public int compareTo(BeeswaxException other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

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

    lastComparison = Boolean.valueOf(isSetMessage()).compareTo(typedOther.isSetMessage());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetMessage()) {
      lastComparison = TBaseHelper.compareTo(this.message, typedOther.message);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetLog_context()).compareTo(typedOther.isSetLog_context());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetLog_context()) {
      lastComparison = TBaseHelper.compareTo(this.log_context, typedOther.log_context);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetHandle()).compareTo(typedOther.isSetHandle());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetHandle()) {
      lastComparison = TBaseHelper.compareTo(this.handle, typedOther.handle);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }