• API

    Show / Hide Table of Contents

    Class SortedTermFreqEnumeratorWrapper

    This wrapper buffers incoming elements and makes sure they are sorted based on given comparer.

    This is a Lucene.NET EXPERIMENTAL API, use at your own risk
    Inheritance
    System.Object
    SortedTermFreqEnumeratorWrapper
    Implements
    ITermFreqEnumerator
    Lucene.Net.Util.IBytesRefEnumerator
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Lucene.Net.Search.Suggest
    Assembly: Lucene.Net.Suggest.dll
    Syntax
    public class SortedTermFreqEnumeratorWrapper : ITermFreqEnumerator, IBytesRefEnumerator

    Constructors

    | Improve this Doc View Source

    SortedTermFreqEnumeratorWrapper(ITermFreqEnumerator)

    Creates a new sorted wrapper, using UTF8SortedAsUnicodeComparer for sorting.

    Declaration
    public SortedTermFreqEnumeratorWrapper(ITermFreqEnumerator source)
    Parameters
    Type Name Description
    ITermFreqEnumerator source
    | Improve this Doc View Source

    SortedTermFreqEnumeratorWrapper(ITermFreqEnumerator, IComparer<BytesRef>)

    Creates a new sorted wrapper, sorting by BytesRef (ascending) then cost (ascending).

    Declaration
    public SortedTermFreqEnumeratorWrapper(ITermFreqEnumerator source, IComparer<BytesRef> comparer)
    Parameters
    Type Name Description
    ITermFreqEnumerator source
    System.Collections.Generic.IComparer<Lucene.Net.Util.BytesRef> comparer

    Properties

    | Improve this Doc View Source

    Comparer

    Declaration
    public virtual IComparer<BytesRef> Comparer { get; }
    Property Value
    Type Description
    System.Collections.Generic.IComparer<Lucene.Net.Util.BytesRef>
    | Improve this Doc View Source

    Current

    Declaration
    public virtual BytesRef Current { get; }
    Property Value
    Type Description
    Lucene.Net.Util.BytesRef
    | Improve this Doc View Source

    Weight

    Declaration
    public virtual long Weight { get; }
    Property Value
    Type Description
    System.Int64

    Methods

    | Improve this Doc View Source

    Decode(BytesRef, ByteArrayDataInput)

    decodes the weight at the current position

    Declaration
    protected virtual long Decode(BytesRef scratch, ByteArrayDataInput tmpInput)
    Parameters
    Type Name Description
    Lucene.Net.Util.BytesRef scratch
    Lucene.Net.Store.ByteArrayDataInput tmpInput
    Returns
    Type Description
    System.Int64
    | Improve this Doc View Source

    Encode(OfflineSorter.ByteSequencesWriter, ByteArrayDataOutput, Byte[], BytesRef, Int64)

    encodes an entry (bytes+weight) to the provided writer

    Declaration
    protected virtual void Encode(OfflineSorter.ByteSequencesWriter writer, ByteArrayDataOutput output, byte[] buffer, BytesRef spare, long weight)
    Parameters
    Type Name Description
    Lucene.Net.Util.OfflineSorter.ByteSequencesWriter writer
    Lucene.Net.Store.ByteArrayDataOutput output
    System.Byte[] buffer
    Lucene.Net.Util.BytesRef spare
    System.Int64 weight
    | Improve this Doc View Source

    MoveNext()

    Declaration
    public virtual bool MoveNext()
    Returns
    Type Description
    System.Boolean

    Implements

    ITermFreqEnumerator
    Lucene.Net.Util.IBytesRefEnumerator
    • Improve this Doc
    • View Source
    Back to top Copyright © 2020 Licensed to the Apache Software Foundation (ASF)