Fork me on GitHub
  • API

    Show / Hide Table of Contents

    Class EliasFanoDocIdSet

    A DocIdSet in Elias-Fano encoding.

    Note

    This API is for internal purposes only and might change in incompatible ways in the next release.

    Inheritance
    object
    DocIdSet
    EliasFanoDocIdSet
    Inherited Members
    DocIdSet.Bits
    DocIdSet.NewAnonymous(Func<DocIdSetIterator>)
    DocIdSet.NewAnonymous(Func<DocIdSetIterator>, Func<IBits>)
    DocIdSet.NewAnonymous(Func<DocIdSetIterator>, Func<bool>)
    DocIdSet.NewAnonymous(Func<DocIdSetIterator>, Func<IBits>, Func<bool>)
    object.Equals(object, object)
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Lucene.Net.Util.Packed
    Assembly: Lucene.Net.dll
    Syntax
    public class EliasFanoDocIdSet : DocIdSet

    Constructors

    EliasFanoDocIdSet(int, int)

    Construct an EliasFanoDocIdSet. For efficient encoding, the parameters should be chosen as low as possible.

    Declaration
    public EliasFanoDocIdSet(int numValues, int upperBound)
    Parameters
    Type Name Description
    int numValues

    At least the number of document ids that will be encoded.

    int upperBound

    At least the highest document id that will be encoded.

    Properties

    IsCacheable

    This DocIdSet implementation is cacheable.

    Declaration
    public override bool IsCacheable { get; }
    Property Value
    Type Description
    bool

    true

    Overrides
    DocIdSet.IsCacheable

    Methods

    EncodeFromDisi(DocIdSetIterator)

    Encode the document ids from a DocIdSetIterator.

    Declaration
    public virtual void EncodeFromDisi(DocIdSetIterator disi)
    Parameters
    Type Name Description
    DocIdSetIterator disi

    This DocIdSetIterator should provide document ids that are consistent with numValues and upperBound as provided to the constructor.

    Equals(object)

    Determines whether the specified object is equal to the current object.

    Declaration
    public override bool Equals(object other)
    Parameters
    Type Name Description
    object other
    Returns
    Type Description
    bool

    true if the specified object is equal to the current object; otherwise, false.

    Overrides
    object.Equals(object)

    GetHashCode()

    Serves as the default hash function.

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    int

    A hash code for the current object.

    Overrides
    object.GetHashCode()

    GetIterator()

    Provides a DocIdSetIterator to access encoded document ids.

    Declaration
    public override DocIdSetIterator GetIterator()
    Returns
    Type Description
    DocIdSetIterator
    Overrides
    DocIdSet.GetIterator()

    SufficientlySmallerThanBitSet(long, long)

    Provide an indication that is better to use an EliasFanoDocIdSet than a FixedBitSet to encode document identifiers.

    Declaration
    public static bool SufficientlySmallerThanBitSet(long numValues, long upperBound)
    Parameters
    Type Name Description
    long numValues

    The number of document identifiers that is to be encoded. Should be non negative.

    long upperBound

    The maximum possible value for a document identifier. Should be at least numValues.

    Returns
    Type Description
    bool

    See SufficientlySmallerThanBitSet(long, long)

    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.