Show / Hide Table of Contents

    Class TopTermsRewrite<Q>

    Base rewrite method for collecting only the top terms via a priority queue.

    @lucene.internal - Only public to be accessible by spans package.

    Inheritance
    System.Object
    MultiTermQuery.RewriteMethod
    TermCollectingRewrite<Q>
    TopTermsRewrite<Q>
    MultiTermQuery.TopTermsBoostOnlyBooleanQueryRewrite
    MultiTermQuery.TopTermsScoringBooleanQueryRewrite
    Inherited Members
    TermCollectingRewrite<Q>.GetTopLevelQuery()
    TermCollectingRewrite<Q>.AddClause(Q, Term, Int32, Single)
    TermCollectingRewrite<Q>.AddClause(Q, Term, Int32, Single, TermContext)
    MultiTermQuery.RewriteMethod.GetTermsEnum(MultiTermQuery, Terms, AttributeSource)
    Namespace: Lucene.Net.Search
    Assembly: Lucene.Net.dll
    Syntax
    public abstract class TopTermsRewrite<Q> : TermCollectingRewrite<Q>, ITopTermsRewrite where Q : Query
    Type Parameters
    Name Description
    Q

    Constructors

    | Improve this Doc View Source

    TopTermsRewrite(Int32)

    Create a TopTermsRewrite<Q> for at most count terms.

    NOTE: if MaxClauseCount is smaller than count, then it will be used instead.

    Declaration
    public TopTermsRewrite(int count)
    Parameters
    Type Name Description
    System.Int32 count

    Properties

    | Improve this Doc View Source

    Count

    Return the maximum priority queue size.

    NOTE: This was size() in Lucene.

    Declaration
    public virtual int Count { get; }
    Property Value
    Type Description
    System.Int32
    | Improve this Doc View Source

    MaxSize

    Return the maximum size of the priority queue (for boolean rewrites this is MaxClauseCount).

    Declaration
    protected abstract int MaxSize { get; }
    Property Value
    Type Description
    System.Int32

    Methods

    | Improve this Doc View Source

    Equals(Object)

    Declaration
    public override bool Equals(object obj)
    Parameters
    Type Name Description
    System.Object obj
    Returns
    Type Description
    System.Boolean
    | Improve this Doc View Source

    GetHashCode()

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    System.Int32
    | Improve this Doc View Source

    Rewrite(IndexReader, MultiTermQuery)

    Declaration
    public override Query Rewrite(IndexReader reader, MultiTermQuery query)
    Parameters
    Type Name Description
    IndexReader reader
    MultiTermQuery query
    Returns
    Type Description
    Query
    Overrides
    MultiTermQuery.RewriteMethod.Rewrite(IndexReader, MultiTermQuery)
    • Improve this Doc
    • View Source
    Back to top Copyright © 2020 Licensed to the Apache Software Foundation (ASF)