class CveSearchGuesser {

    public List<Match> getBest(List<Match> matches, int threshold) {
        if(matches.size() == 0){
            return Collections.EMPTY_LIST;
        }
        List<Match> bestMatches = new ArrayList<>();
        int minDistance = matches.get(0).getDistance();

        Iterator<Match> matchesIterator = matches.iterator();
        Match current;
        do{
            current = matchesIterator.next();
            if(current.getDistance() > minDistance + threshold || current.getDistance() >= cutoff){
                break;
            }
            bestMatches.add(current);
        }while(matchesIterator.hasNext());

        return bestMatches;
    }

    public  CveSearchGuesser(CveSearchApi cveSearchApi);

}