Fork me on GitHub
  • API

    Show / Hide Table of Contents

    Class SortedDocValues

    A per-document byte[] with presorted values.

    Per-Document values in a SortedDocValues are deduplicated, dereferenced, and sorted into a dictionary of unique values. A pointer to the dictionary value (ordinal) can be retrieved for each document. Ordinals are dense and in increasing sorted order.

    Inheritance
    System.Object
    BinaryDocValues
    SortedDocValues
    MultiDocValues.MultiSortedDocValues
    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.Index
    Assembly: Lucene.Net.dll
    Syntax
    public abstract class SortedDocValues : BinaryDocValues

    Constructors

    | Improve this Doc View Source

    SortedDocValues()

    Sole constructor. (For invocation by subclass constructors, typically implicit.)

    Declaration
    protected SortedDocValues()

    Properties

    | Improve this Doc View Source

    ValueCount

    Returns the number of unique values.

    Declaration
    public abstract int ValueCount { get; }
    Property Value
    Type Description
    System.Int32

    Number of unique values in this SortedDocValues. This is also equivalent to one plus the maximum ordinal.

    Methods

    | Improve this Doc View Source

    Get(Int32, BytesRef)

    Declaration
    public override void Get(int docID, BytesRef result)
    Parameters
    Type Name Description
    System.Int32 docID
    BytesRef result
    Overrides
    BinaryDocValues.Get(Int32, BytesRef)
    | Improve this Doc View Source

    GetOrd(Int32)

    Returns the ordinal for the specified docID.

    Declaration
    public abstract int GetOrd(int docID)
    Parameters
    Type Name Description
    System.Int32 docID

    document ID to lookup

    Returns
    Type Description
    System.Int32

    ordinal for the document: this is dense, starts at 0, then increments by 1 for the next value in sorted order. Note that missing values are indicated by -1.

    | Improve this Doc View Source

    GetTermsEnum()

    Returns a TermsEnum over the values. The enum supports Ord and SeekExact(Int64).

    Declaration
    public virtual TermsEnum GetTermsEnum()
    Returns
    Type Description
    TermsEnum
    | Improve this Doc View Source

    LookupOrd(Int32, BytesRef)

    Retrieves the value for the specified ordinal.

    Declaration
    public abstract void LookupOrd(int ord, BytesRef result)
    Parameters
    Type Name Description
    System.Int32 ord

    ordinal to lookup (must be >= 0 and < ValueCount)

    BytesRef result

    will be populated with the ordinal's value

    See Also
    GetOrd(Int32)
    | Improve this Doc View Source

    LookupTerm(BytesRef)

    If key exists, returns its ordinal, else returns -insertionPoint-1, like System.Array.BinarySearch(System.Array,System.Int32,System.Int32,System.Object)

    Declaration
    public virtual int LookupTerm(BytesRef key)
    Parameters
    Type Name Description
    BytesRef key

    Key to look up

    Returns
    Type Description
    System.Int32
    • Improve this Doc
    • View Source
    Back to top Copyright © 2021 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.