Remove the unused SignificantTerms.compareTerm() method (#24714)

This method is not used and not tested. While it exists it forces
implementations of the interface to implement it while it's unused.
This commit is contained in:
Tanguy Leroux 2017-05-18 14:57:12 +02:00 committed by GitHub
parent 779cf3d468
commit 96dac4c670
3 changed files with 0 additions and 13 deletions

View File

@ -76,11 +76,6 @@ public class SignificantLongTerms extends InternalMappedSignificantTerms<Signifi
return term;
}
@Override
public int compareTerm(SignificantTerms.Bucket other) {
return Long.compare(term, ((Number) other.getKey()).longValue());
}
@Override
public String getKeyAsString() {
return format.format(term);

View File

@ -28,7 +28,6 @@ import org.elasticsearch.search.aggregations.bucket.significant.heuristics.Signi
import org.elasticsearch.search.aggregations.pipeline.PipelineAggregator;
import java.io.IOException;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Objects;
@ -82,11 +81,6 @@ public class SignificantStringTerms extends InternalMappedSignificantTerms<Signi
return Double.parseDouble(termBytes.utf8ToString());
}
@Override
public int compareTerm(SignificantTerms.Bucket other) {
return termBytes.compareTo(((Bucket) other).termBytes);
}
@Override
public String getKeyAsString() {
return format.format(termBytes);

View File

@ -40,8 +40,6 @@ public interface SignificantTerms extends MultiBucketsAggregation, Iterable<Sign
long getSupersetSize();
long getSubsetSize();
int compareTerm(SignificantTerms.Bucket other);
}
@Override