Skip to content

Commit

Permalink
adapt for Java 11
Browse files Browse the repository at this point in the history
  • Loading branch information
uschindler committed May 27, 2024
1 parent 7452d03 commit 67d80db
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3295,11 +3295,11 @@ private static boolean supportsVectorEncoding(
}

protected static KnnVectorsFormat randomVectorFormat(VectorEncoding vectorEncoding) {
List<KnnVectorsFormat> availableFormats =
KnnVectorsFormat[] availableFormats =
KnnVectorsFormat.availableKnnVectorsFormats().stream()
.map(KnnVectorsFormat::forName)
.filter(format -> supportsVectorEncoding(format, vectorEncoding))
.toList();
.toArray(KnnVectorsFormat[]::new);
return RandomPicks.randomFrom(random(), availableFormats);
}
}

0 comments on commit 67d80db

Please sign in to comment.