Show / Hide Table of Contents

    Class EliasFanoDecoder

    A decoder for an EliasFanoEncoder.

    This is a Lucene.NET INTERNAL API, use at your own risk
    Inheritance
    System.Object
    EliasFanoDecoder
    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.Util.Packed
    Assembly: Lucene.Net.dll
    Syntax
    public class EliasFanoDecoder

    Constructors

    | Improve this Doc View Source

    EliasFanoDecoder(EliasFanoEncoder)

    Construct a decoder for a given EliasFanoEncoder. The decoding index is set to just before the first encoded value.

    Declaration
    public EliasFanoDecoder(EliasFanoEncoder efEncoder)
    Parameters
    Type Name Description
    EliasFanoEncoder efEncoder

    Fields

    | Improve this Doc View Source

    NO_MORE_VALUES

    Declaration
    public const long NO_MORE_VALUES = -1L
    Field Value
    Type Description
    System.Int64

    Properties

    | Improve this Doc View Source

    EliasFanoEncoder

    Declaration
    public virtual EliasFanoEncoder EliasFanoEncoder { get; }
    Property Value
    Type Description
    EliasFanoEncoder

    The Elias-Fano encoder that is decoded.

    | Improve this Doc View Source

    NumEncoded

    The number of values encoded by the encoder.

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

    The number of values encoded by the encoder.

    Methods

    | Improve this Doc View Source

    AdvanceToIndex(Int64)

    Advance the decoding index to a given index. and return true iff it is available.

    See also CurrentValue().

    The current implementation does not use the index on the upper bit zero bit positions.

    Note: there is currently no implementation of BackToIndex().

    Declaration
    public virtual bool AdvanceToIndex(long index)
    Parameters
    Type Name Description
    System.Int64 index
    Returns
    Type Description
    System.Boolean
    | Improve this Doc View Source

    AdvanceToValue(Int64)

    Given a target value, advance the decoding index to the first bigger or equal value and return it if it is available. Otherwise return NO_MORE_VALUES.

    The current implementation uses the index on the upper zero bit positions.

    Declaration
    public virtual long AdvanceToValue(long target)
    Parameters
    Type Name Description
    System.Int64 target
    Returns
    Type Description
    System.Int64
    | Improve this Doc View Source

    BackToValue(Int64)

    Given a target value, go back to the first smaller or equal value and return it if it is available. Otherwise return NO_MORE_VALUES.

    The current implementation does not use the index on the upper zero bit positions.

    Declaration
    public virtual long BackToValue(long target)
    Parameters
    Type Name Description
    System.Int64 target
    Returns
    Type Description
    System.Int64
    | Improve this Doc View Source

    CurrentIndex()

    The current decoding index. The first value encoded by EncodeNext(Int64) has index 0. Only valid directly after NextValue(), AdvanceToValue(Int64), PreviousValue(), or BackToValue(Int64) returned another value than NO_MORE_VALUES, or AdvanceToIndex(Int64) returned true.

    Declaration
    public virtual long CurrentIndex()
    Returns
    Type Description
    System.Int64

    The decoding index of the last decoded value, or as last set by AdvanceToIndex(Int64).

    | Improve this Doc View Source

    CurrentValue()

    The value at the current decoding index. Only valid when CurrentIndex() would return a valid result.

    This is only intended for use after AdvanceToIndex(Int64) returned true.

    Declaration
    public virtual long CurrentValue()
    Returns
    Type Description
    System.Int64

    The value encoded at CurrentIndex().

    | Improve this Doc View Source

    NextValue()

    If another value is available after the current decoding index, return this value and and increase the decoding index by 1. Otherwise return NO_MORE_VALUES.

    Declaration
    public virtual long NextValue()
    Returns
    Type Description
    System.Int64
    | Improve this Doc View Source

    PreviousValue()

    If another value is available before the current decoding index, return this value and decrease the decoding index by 1. Otherwise return NO_MORE_VALUES.

    Declaration
    public virtual long PreviousValue()
    Returns
    Type Description
    System.Int64
    | Improve this Doc View Source

    ToAfterSequence()

    Set the decoding index to just after the last encoded value.

    Declaration
    public virtual void ToAfterSequence()
    | Improve this Doc View Source

    ToBeforeSequence()

    Set the decoding index to just before the first encoded value.

    Declaration
    public virtual void ToBeforeSequence()

    Extension Methods

    Number.IsNumber(Object)
    • Improve this Doc
    • View Source
    Back to top Copyright © 2019 Licensed to the Apache Software Foundation (ASF)