コード例 #1
0
  public int compareTo(IndexAlreadyExistsException other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

    int lastComparison = 0;
    IndexAlreadyExistsException typedOther = (IndexAlreadyExistsException) 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;
      }
    }
    return 0;
  }
コード例 #2
0
  public boolean equals(IndexAlreadyExistsException that) {
    if (that == null) return false;

    boolean this_present_message = true && this.isSetMessage();
    boolean that_present_message = true && that.isSetMessage();
    if (this_present_message || that_present_message) {
      if (!(this_present_message && that_present_message)) return false;
      if (!this.message.equals(that.message)) return false;
    }

    return true;
  }
コード例 #3
0
 /** Performs a deep copy on <i>other</i>. */
 public IndexAlreadyExistsException(IndexAlreadyExistsException other) {
   if (other.isSetMessage()) {
     this.message = other.message;
   }
 }