@Override
    public boolean equals(Object other) {
        if (other == this) return true;
        if ( ! (other instanceof Infinite)) return false;
        return this.negative == ((Infinite)other).negative;
    }
An infinity value is always less than or greater than.
container-search/src/main/java/com/yahoo/search/grouping/request/Infinite.java