Search in sources :

Example 1 with CveSearchApi

use of org.eclipse.sw360.cvesearch.datasource.CveSearchApi in project sw360portal by sw360.

the class SearchLevels method addGuessingSearchLevels.

private void addGuessingSearchLevels(CveSearchApi cveSearchApi, int vendorThreshold, int productThreshold, int cutoff) {
    CveSearchGuesser cveSearchGuesser = new CveSearchGuesser(cveSearchApi);
    cveSearchGuesser.setVendorThreshold(vendorThreshold);
    cveSearchGuesser.setProductThreshold(productThreshold);
    cveSearchGuesser.setCutoff(cutoff);
    // Level 2. search by guessed vendors and products with version
    searchLevels.add(release -> guessForRelease(cveSearchGuesser, release, true));
    // Level 3. search by guessed vendors and products without version
    searchLevels.add(release -> guessForRelease(cveSearchGuesser, release, false));
}
Also used : CveSearchGuesser(org.eclipse.sw360.cvesearch.datasource.CveSearchGuesser)

Aggregations

CveSearchGuesser (org.eclipse.sw360.cvesearch.datasource.CveSearchGuesser)1