@Override public int compareTo(ExpandoTable expandoTable) { long primaryKey = expandoTable.getPrimaryKey(); if (getPrimaryKey() < primaryKey) { return -1; } else if (getPrimaryKey() > primaryKey) { return 1; } else { return 0; } }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof ExpandoTable)) { return false; } ExpandoTable expandoTable = (ExpandoTable) obj; long primaryKey = expandoTable.getPrimaryKey(); if (getPrimaryKey() == primaryKey) { return true; } else { return false; } }