public boolean equals()

in messages/src/main/java/com/epam/deltix/timebase/messages/schema/SchemaChangeMessage.java [250:283]


  public boolean equals(Object obj) {
    if (this == obj) return true;
    boolean superEquals = super.equals(obj);
    if (!superEquals) return false;
    if (!(obj instanceof SchemaChangeMessage)) return false;
    SchemaChangeMessage other =(SchemaChangeMessage)obj;
    if (hasPreviousState() != other.hasPreviousState()) return false;
    if (hasPreviousState()) {
      if (getPreviousState().size() != other.getPreviousState().size()) return false;
      else for (int j = 0; j < getPreviousState().size(); ++j) {
        if ((getPreviousState().get(j) != null) != (other.getPreviousState().get(j) != null)) return false;
        if (getPreviousState().get(j) != null && !getPreviousState().get(j).equals(other.getPreviousState().get(j))) return false;
      }
    }
    if (hasNewState() != other.hasNewState()) return false;
    if (hasNewState()) {
      if (getNewState().size() != other.getNewState().size()) return false;
      else for (int j = 0; j < getNewState().size(); ++j) {
        if ((getNewState().get(j) != null) != (other.getNewState().get(j) != null)) return false;
        if (getNewState().get(j) != null && !getNewState().get(j).equals(other.getNewState().get(j))) return false;
      }
    }
    if (hasDescriptorChangeActions() != other.hasDescriptorChangeActions()) return false;
    if (hasDescriptorChangeActions()) {
      if (getDescriptorChangeActions().size() != other.getDescriptorChangeActions().size()) return false;
      else for (int j = 0; j < getDescriptorChangeActions().size(); ++j) {
        if ((getDescriptorChangeActions().get(j) != null) != (other.getDescriptorChangeActions().get(j) != null)) return false;
        if (getDescriptorChangeActions().get(j) != null && !getDescriptorChangeActions().get(j).equals(other.getDescriptorChangeActions().get(j))) return false;
      }
    }
    if (hasVersion() != other.hasVersion()) return false;
    if (hasVersion() && getVersion() != other.getVersion()) return false;
    return true;
  }