Fork me on GitHub
  • API

    Show / Hide Table of Contents

    Class ShardSearchingTestBase.NodeState.ShardIndexSearcher

    Matches docs in the local shard but scores based on aggregated stats ("mock distributed scoring") from all nodes.

    Inheritance
    object
    IndexSearcher
    ShardSearchingTestBase.NodeState.ShardIndexSearcher
    Inherited Members
    IndexSearcher.m_readerContext
    IndexSearcher.m_leafContexts
    IndexSearcher.m_leafSlices
    IndexSearcher.DefaultSimilarity
    IndexSearcher.GetSlices(IList<AtomicReaderContext>)
    IndexSearcher.IndexReader
    IndexSearcher.Doc(int)
    IndexSearcher.Doc(int, StoredFieldVisitor)
    IndexSearcher.Doc(int, ISet<string>)
    IndexSearcher.Document(int, ISet<string>)
    IndexSearcher.Similarity
    IndexSearcher.WrapFilter(Query, Filter)
    IndexSearcher.SearchAfter(ScoreDoc, Query, Filter, int)
    IndexSearcher.Search(Query, Filter, int)
    IndexSearcher.Search(Query, Filter, ICollector)
    IndexSearcher.Search(Query, ICollector)
    IndexSearcher.Search(Query, Filter, int, Sort)
    IndexSearcher.Search(Query, Filter, int, Sort, bool, bool)
    IndexSearcher.SearchAfter(ScoreDoc, Query, Filter, int, Sort)
    IndexSearcher.SearchAfter(ScoreDoc, Query, int, Sort)
    IndexSearcher.SearchAfter(ScoreDoc, Query, Filter, int, Sort, bool, bool)
    IndexSearcher.Search(Weight, ScoreDoc, int)
    IndexSearcher.Search(IList<AtomicReaderContext>, Weight, ScoreDoc, int)
    IndexSearcher.Search(Weight, int, Sort, bool, bool)
    IndexSearcher.Search(Weight, FieldDoc, int, Sort, bool, bool, bool)
    IndexSearcher.Search(IList<AtomicReaderContext>, Weight, FieldDoc, int, Sort, bool, bool, bool)
    IndexSearcher.Search(IList<AtomicReaderContext>, Weight, ICollector)
    IndexSearcher.Explain(Query, int)
    IndexSearcher.Explain(Weight, int)
    IndexSearcher.CreateNormalizedWeight(Query)
    IndexSearcher.TopReaderContext
    IndexSearcher.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: Lucene.Net.Search
    Assembly: Lucene.Net.TestFramework.dll
    Syntax
    public class ShardSearchingTestBase.NodeState.ShardIndexSearcher : IndexSearcher

    Constructors

    ShardIndexSearcher(NodeState, long[], IndexReader, int)

    Matches docs in the local shard but scores based on aggregated stats ("mock distributed scoring") from all nodes.

    Declaration
    public ShardIndexSearcher(ShardSearchingTestBase.NodeState nodeState, long[] nodeVersions, IndexReader localReader, int nodeID)
    Parameters
    Type Name Description
    ShardSearchingTestBase.NodeState nodeState
    long[] nodeVersions
    IndexReader localReader
    int nodeID

    Properties

    MyNodeID

    Matches docs in the local shard but scores based on aggregated stats ("mock distributed scoring") from all nodes.

    Declaration
    public int MyNodeID { get; }
    Property Value
    Type Description
    int

    Methods

    CollectionStatistics(string)

    Returns Lucene.Net.Search.CollectionStatistics for a field.

    This can be overridden for example, to return a field's statistics across a distributed collection.

    Note

    This API is experimental and might change in incompatible ways in the next release.

    Declaration
    public override CollectionStatistics CollectionStatistics(string field)
    Parameters
    Type Name Description
    string field
    Returns
    Type Description
    CollectionStatistics
    Overrides
    IndexSearcher.CollectionStatistics(string)

    GetNodeVersions()

    Matches docs in the local shard but scores based on aggregated stats ("mock distributed scoring") from all nodes.

    Declaration
    public long[] GetNodeVersions()
    Returns
    Type Description
    long[]

    LocalSearch(Query, int)

    Matches docs in the local shard but scores based on aggregated stats ("mock distributed scoring") from all nodes.

    Declaration
    public virtual TopDocs LocalSearch(Query query, int numHits)
    Parameters
    Type Name Description
    Query query
    int numHits
    Returns
    Type Description
    TopDocs

    LocalSearch(Query, int, Sort)

    Matches docs in the local shard but scores based on aggregated stats ("mock distributed scoring") from all nodes.

    Declaration
    public virtual TopFieldDocs LocalSearch(Query query, int numHits, Sort sort)
    Parameters
    Type Name Description
    Query query
    int numHits
    Sort sort
    Returns
    Type Description
    TopFieldDocs

    LocalSearchAfter(ScoreDoc, Query, int)

    Matches docs in the local shard but scores based on aggregated stats ("mock distributed scoring") from all nodes.

    Declaration
    public virtual TopDocs LocalSearchAfter(ScoreDoc after, Query query, int numHits)
    Parameters
    Type Name Description
    ScoreDoc after
    Query query
    int numHits
    Returns
    Type Description
    TopDocs

    Rewrite(Query)

    Expert: called to re-write queries into primitive queries.

    Declaration
    public override Query Rewrite(Query original)
    Parameters
    Type Name Description
    Query original
    Returns
    Type Description
    Query
    Overrides
    Lucene.Net.Search.IndexSearcher.Rewrite(Lucene.Net.Search.Query)
    Exceptions
    Type Condition
    BooleanQuery.TooManyClausesException

    If a query would exceed Lucene.Net.Search.BooleanQuery.MaxClauseCount clauses.

    ArgumentNullException

    query is null.

    Search(Query, int)

    Finds the top n hits for query.

    Declaration
    public override TopDocs Search(Query query, int numHits)
    Parameters
    Type Name Description
    Query query
    int numHits
    Returns
    Type Description
    TopDocs
    Overrides
    IndexSearcher.Search(Query, int)
    Exceptions
    Type Condition
    BooleanQuery.TooManyClausesException

    If a query would exceed Lucene.Net.Search.BooleanQuery.MaxClauseCount clauses.

    ArgumentNullException

    query is null.

    Search(Query, int, Sort)

    Search implementation with arbitrary sorting and no filter.

    Declaration
    public override TopFieldDocs Search(Query query, int numHits, Sort sort)
    Parameters
    Type Name Description
    Query query

    The query to search for

    int numHits
    Sort sort

    The Lucene.Net.Search.Sort object

    Returns
    Type Description
    TopFieldDocs

    The top docs, sorted according to the supplied Lucene.Net.Search.Sort instance

    Overrides
    IndexSearcher.Search(Query, int, Sort)
    Exceptions
    Type Condition
    IOException

    if there is a low-level I/O error

    ArgumentNullException

    query or sort is null.

    SearchAfter(ScoreDoc, Query, int)

    Finds the top n hits for top query where all results are after a previous result (top after).

    By passing the bottom result from a previous page as after, this method can be used for efficient 'deep-paging' across potentially large result sets.
    Declaration
    public override TopDocs SearchAfter(ScoreDoc after, Query query, int numHits)
    Parameters
    Type Name Description
    ScoreDoc after
    Query query
    int numHits
    Returns
    Type Description
    TopDocs
    Overrides
    IndexSearcher.SearchAfter(ScoreDoc, Query, int)
    Exceptions
    Type Condition
    BooleanQuery.TooManyClausesException

    If a query would exceed Lucene.Net.Search.BooleanQuery.MaxClauseCount clauses.

    ArgumentNullException

    query is null.

    TermStatistics(Term, TermContext)

    Returns Lucene.Net.Search.TermStatistics for a term.

    This can be overridden for example, to return a term's statistics across a distributed collection.

    Note

    This API is experimental and might change in incompatible ways in the next release.

    Declaration
    public override TermStatistics TermStatistics(Term term, TermContext context)
    Parameters
    Type Name Description
    Term term
    TermContext context
    Returns
    Type Description
    TermStatistics
    Overrides
    Lucene.Net.Search.IndexSearcher.TermStatistics(Lucene.Net.Index.Term, Lucene.Net.Index.TermContext)
    Exceptions
    Type Condition
    ArgumentNullException

    term or context is null.

    Back to top Copyright © 2024 The Apache Software Foundation, Licensed under the Apache License, Version 2.0
    Apache Lucene.Net, Lucene.Net, Apache, the Apache feather logo, and the Apache Lucene.Net project logo are trademarks of The Apache Software Foundation.
    All other marks mentioned may be trademarks or registered trademarks of their respective owners.