Esempio n. 1
0
  public int compareTo(NoteList other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

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

    lastComparison = Boolean.valueOf(isSetStartIndex()).compareTo(typedOther.isSetStartIndex());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetStartIndex()) {
      lastComparison = TBaseHelper.compareTo(this.startIndex, typedOther.startIndex);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetTotalNotes()).compareTo(typedOther.isSetTotalNotes());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTotalNotes()) {
      lastComparison = TBaseHelper.compareTo(this.totalNotes, typedOther.totalNotes);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetNotes()).compareTo(typedOther.isSetNotes());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetNotes()) {
      lastComparison = TBaseHelper.compareTo(this.notes, typedOther.notes);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetStoppedWords()).compareTo(typedOther.isSetStoppedWords());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetStoppedWords()) {
      lastComparison = TBaseHelper.compareTo(this.stoppedWords, typedOther.stoppedWords);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison =
        Boolean.valueOf(isSetSearchedWords()).compareTo(typedOther.isSetSearchedWords());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSearchedWords()) {
      lastComparison = TBaseHelper.compareTo(this.searchedWords, typedOther.searchedWords);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetUpdateCount()).compareTo(typedOther.isSetUpdateCount());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetUpdateCount()) {
      lastComparison = TBaseHelper.compareTo(this.updateCount, typedOther.updateCount);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }
  public int compareTo(SavedSearch other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

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

    lastComparison = Boolean.valueOf(isSetGuid()).compareTo(typedOther.isSetGuid());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetGuid()) {
      lastComparison = TBaseHelper.compareTo(this.guid, typedOther.guid);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetName()).compareTo(typedOther.isSetName());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetName()) {
      lastComparison = TBaseHelper.compareTo(this.name, typedOther.name);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetQuery()).compareTo(typedOther.isSetQuery());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetQuery()) {
      lastComparison = TBaseHelper.compareTo(this.query, typedOther.query);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetFormat()).compareTo(typedOther.isSetFormat());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFormat()) {
      lastComparison = TBaseHelper.compareTo(this.format, typedOther.format);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison =
        Boolean.valueOf(isSetUpdateSequenceNum()).compareTo(typedOther.isSetUpdateSequenceNum());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetUpdateSequenceNum()) {
      lastComparison = TBaseHelper.compareTo(this.updateSequenceNum, typedOther.updateSequenceNum);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetScope()).compareTo(typedOther.isSetScope());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetScope()) {
      lastComparison = TBaseHelper.compareTo(this.scope, typedOther.scope);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }
  public int compareTo(NoteAttributes other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

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

    lastComparison = Boolean.valueOf(isSetSubjectDate()).compareTo(typedOther.isSetSubjectDate());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSubjectDate()) {
      lastComparison = TBaseHelper.compareTo(this.subjectDate, typedOther.subjectDate);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetLatitude()).compareTo(typedOther.isSetLatitude());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetLatitude()) {
      lastComparison = TBaseHelper.compareTo(this.latitude, typedOther.latitude);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetLongitude()).compareTo(typedOther.isSetLongitude());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetLongitude()) {
      lastComparison = TBaseHelper.compareTo(this.longitude, typedOther.longitude);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetAltitude()).compareTo(typedOther.isSetAltitude());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetAltitude()) {
      lastComparison = TBaseHelper.compareTo(this.altitude, typedOther.altitude);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetAuthor()).compareTo(typedOther.isSetAuthor());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetAuthor()) {
      lastComparison = TBaseHelper.compareTo(this.author, typedOther.author);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetSource()).compareTo(typedOther.isSetSource());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSource()) {
      lastComparison = TBaseHelper.compareTo(this.source, typedOther.source);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetSourceURL()).compareTo(typedOther.isSetSourceURL());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSourceURL()) {
      lastComparison = TBaseHelper.compareTo(this.sourceURL, typedOther.sourceURL);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison =
        Boolean.valueOf(isSetSourceApplication()).compareTo(typedOther.isSetSourceApplication());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSourceApplication()) {
      lastComparison = TBaseHelper.compareTo(this.sourceApplication, typedOther.sourceApplication);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetShareDate()).compareTo(typedOther.isSetShareDate());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetShareDate()) {
      lastComparison = TBaseHelper.compareTo(this.shareDate, typedOther.shareDate);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetPlaceName()).compareTo(typedOther.isSetPlaceName());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetPlaceName()) {
      lastComparison = TBaseHelper.compareTo(this.placeName, typedOther.placeName);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetContentClass()).compareTo(typedOther.isSetContentClass());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetContentClass()) {
      lastComparison = TBaseHelper.compareTo(this.contentClass, typedOther.contentClass);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison =
        Boolean.valueOf(isSetApplicationData()).compareTo(typedOther.isSetApplicationData());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetApplicationData()) {
      lastComparison = TBaseHelper.compareTo(this.applicationData, typedOther.applicationData);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = Boolean.valueOf(isSetLastEditedBy()).compareTo(typedOther.isSetLastEditedBy());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetLastEditedBy()) {
      lastComparison = TBaseHelper.compareTo(this.lastEditedBy, typedOther.lastEditedBy);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison =
        Boolean.valueOf(isSetClassifications()).compareTo(typedOther.isSetClassifications());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetClassifications()) {
      lastComparison = TBaseHelper.compareTo(this.classifications, typedOther.classifications);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }