Table of Contents

Class LuceneSearchResults

Namespace
Examine.Lucene.Search
Assembly
Examine.Lucene.dll

Represents the search results of a query

public class LuceneSearchResults : ILuceneSearchResults, ISearchResults, IEnumerable<ISearchResult>, IEnumerable, IFacetResults
Inheritance
LuceneSearchResults
Implements
Inherited Members
Extension Methods

Constructors

LuceneSearchResults(IReadOnlyCollection<ISearchResult>, int)

[Obsolete("To remove in Examine V5")]
public LuceneSearchResults(IReadOnlyCollection<ISearchResult> results, int totalItemCount)

Parameters

results IReadOnlyCollection<ISearchResult>
totalItemCount int

LuceneSearchResults(IReadOnlyCollection<ISearchResult>, int, IReadOnlyDictionary<string, IFacetResult>, float, SearchAfterOptions?)

public LuceneSearchResults(IReadOnlyCollection<ISearchResult> results, int totalItemCount, IReadOnlyDictionary<string, IFacetResult> facets, float maxScore, SearchAfterOptions? searchAfterOptions)

Parameters

results IReadOnlyCollection<ISearchResult>
totalItemCount int
facets IReadOnlyDictionary<string, IFacetResult>
maxScore float
searchAfterOptions SearchAfterOptions

Properties

Empty

Gets an empty search result

public static LuceneSearchResults Empty { get; }

Property Value

LuceneSearchResults

Facets

Facets from the search

public IReadOnlyDictionary<string, IFacetResult> Facets { get; }

Property Value

IReadOnlyDictionary<string, IFacetResult>

MaxScore

Returns the maximum score value encountered. Note that in case scores are not tracked, this returns NaN.

public float MaxScore { get; }

Property Value

float

SearchAfter

Options for skipping documents after a previous search

public SearchAfterOptions? SearchAfter { get; }

Property Value

SearchAfterOptions

TotalItemCount

Returns the Total item count for the search regardless of skip/take/max count values

public long TotalItemCount { get; }

Property Value

long

Methods

GetEnumerator()

Returns an enumerator that iterates through the collection.

public IEnumerator<ISearchResult> GetEnumerator()

Returns

IEnumerator<ISearchResult>

An enumerator that can be used to iterate through the collection.