Fork me on GitHub
  • API

    Show / Hide Table of Contents

    Class PostingsReaderBase

    The core terms dictionaries (BlockTermsReader, BlockTreeTermsReader<TSubclassState>) interact with a single instance of this class to manage creation of DocsEnum and DocsAndPositionsEnum instances. It provides an IndexInput (termsIn) where this class may read any previously stored data that it had written in its corresponding PostingsWriterBase at indexing time.

    Note

    This API is experimental and might change in incompatible ways in the next release.

    Inheritance
    object
    PostingsReaderBase
    Lucene40PostingsReader
    Lucene41PostingsReader
    Implements
    IDisposable
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Lucene.Net.Codecs
    Assembly: Lucene.Net.dll
    Syntax
    public abstract class PostingsReaderBase : IDisposable

    Constructors

    PostingsReaderBase()

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

    Declaration
    protected PostingsReaderBase()

    Methods

    CheckIntegrity()

    Checks consistency of this reader.

    Note that this may be costly in terms of I/O, e.g. may involve computing a checksum value against large data files.

    Note

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

    Declaration
    public abstract void CheckIntegrity()

    DecodeTerm(long[], DataInput, FieldInfo, BlockTermState, bool)

    Actually decode metadata for next term.

    Declaration
    public abstract void DecodeTerm(long[] longs, DataInput @in, FieldInfo fieldInfo, BlockTermState state, bool absolute)
    Parameters
    Type Name Description
    long[] longs
    DataInput in
    FieldInfo fieldInfo
    BlockTermState state
    bool absolute
    See Also
    EncodeTerm(long[], DataOutput, FieldInfo, BlockTermState, bool)

    Dispose()

    Disposes all resources used by this object.

    Declaration
    public void Dispose()

    Dispose(bool)

    Implementations must override and should dispose all resources used by this instance.

    Declaration
    protected abstract void Dispose(bool disposing)
    Parameters
    Type Name Description
    bool disposing

    Docs(FieldInfo, BlockTermState, IBits, DocsEnum, DocsFlags)

    Must fully consume state, since after this call that TermState may be reused.

    Declaration
    public abstract DocsEnum Docs(FieldInfo fieldInfo, BlockTermState state, IBits skipDocs, DocsEnum reuse, DocsFlags flags)
    Parameters
    Type Name Description
    FieldInfo fieldInfo
    BlockTermState state
    IBits skipDocs
    DocsEnum reuse
    DocsFlags flags
    Returns
    Type Description
    DocsEnum

    DocsAndPositions(FieldInfo, BlockTermState, IBits, DocsAndPositionsEnum, DocsAndPositionsFlags)

    Must fully consume state, since after this call that TermState may be reused.

    Declaration
    public abstract DocsAndPositionsEnum DocsAndPositions(FieldInfo fieldInfo, BlockTermState state, IBits skipDocs, DocsAndPositionsEnum reuse, DocsAndPositionsFlags flags)
    Parameters
    Type Name Description
    FieldInfo fieldInfo
    BlockTermState state
    IBits skipDocs
    DocsAndPositionsEnum reuse
    DocsAndPositionsFlags flags
    Returns
    Type Description
    DocsAndPositionsEnum

    Init(IndexInput)

    Performs any initialization, such as reading and verifying the header from the provided terms dictionary IndexInput.

    Declaration
    public abstract void Init(IndexInput termsIn)
    Parameters
    Type Name Description
    IndexInput termsIn

    NewTermState()

    Return a newly created empty TermState.

    Declaration
    public abstract BlockTermState NewTermState()
    Returns
    Type Description
    BlockTermState

    RamBytesUsed()

    Returns approximate RAM bytes used.

    Declaration
    public abstract long RamBytesUsed()
    Returns
    Type Description
    long

    Implements

    IDisposable
    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.