public boolean includes(Criterion other) { if (isEquivalent(other)) { return true; } for (Criterion each : this.getChildren()) { if (each.includes(other)) { return true; } } return false; }
@Override public int compare(Criterion o1, Criterion o2) { if (o1.isEquivalent(o2)) { return 0; } if (o1.includes(o2)) { return -1; } else { return 1; } }