Interface SearchResults<T>

Type Parameters:
T - The entity type
All Superinterfaces:
Iterable<SearchResult<T>>

public interface SearchResults<T> extends Iterable<SearchResult<T>>
Iterable wrapper of vector search results with entity and score.
Since:
5.0.0
  • Method Details

    • results

      List<SearchResult<T>> results()
      Returns:
      The matched results with scores
    • of

      static <T> SearchResults<T> of(List<SearchResult<T>> results)
      Creates an immutable results wrapper.
      Type Parameters:
      T - The entity type
      Parameters:
      results - The matched results
      Returns:
      Search results wrapper
    • iterator

      default Iterator<SearchResult<T>> iterator()
      Returns an iterator over the matched search results.
      Specified by:
      iterator in interface Iterable<T>
      Returns:
      result iterator