Show / Hide Table of Contents

    Class SegmentCommitInfo

    Embeds a [read-only] SegmentInfo and adds per-commit fields.

    This is a Lucene.NET EXPERIMENTAL API, use at your own risk
    Inheritance
    System.Object
    SegmentCommitInfo
    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)
    Namespace: Lucene.Net.Index
    Assembly: Lucene.Net.dll
    Syntax
    public class SegmentCommitInfo

    Constructors

    | Improve this Doc View Source

    SegmentCommitInfo(SegmentInfo, Int32, Int64, Int64)

    Sole constructor.

    Declaration
    public SegmentCommitInfo(SegmentInfo info, int delCount, long delGen, long fieldInfosGen)
    Parameters
    Type Name Description
    SegmentInfo info

    SegmentInfo that we wrap

    System.Int32 delCount

    number of deleted documents in this segment

    System.Int64 delGen

    deletion generation number (used to name deletion files)

    System.Int64 fieldInfosGen

    FieldInfos generation number (used to name field-infos files)

    Properties

    | Improve this Doc View Source

    DelCount

    Returns the number of deleted docs in the segment.

    Declaration
    public virtual int DelCount { get; }
    Property Value
    Type Description
    System.Int32
    | Improve this Doc View Source

    DelGen

    Returns generation number of the live docs file or -1 if there are no deletes yet.

    Declaration
    public virtual long DelGen { get; }
    Property Value
    Type Description
    System.Int64
    | Improve this Doc View Source

    FieldInfosGen

    Returns the generation number of the field infos file or -1 if there are no field updates yet.

    Declaration
    public virtual long FieldInfosGen { get; }
    Property Value
    Type Description
    System.Int64
    | Improve this Doc View Source

    HasDeletions

    Returns true if there are any deletions for the segment at this commit.

    Declaration
    public virtual bool HasDeletions { get; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    HasFieldUpdates

    Returns true if there are any field updates for the segment in this commit.

    Declaration
    public virtual bool HasFieldUpdates { get; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    Info

    The SegmentInfo that we wrap.

    Declaration
    public SegmentInfo Info { get; }
    Property Value
    Type Description
    SegmentInfo
    | Improve this Doc View Source

    NextDelGen

    Returns the next available generation number of the live docs file.

    Declaration
    public virtual long NextDelGen { get; }
    Property Value
    Type Description
    System.Int64
    | Improve this Doc View Source

    NextFieldInfosGen

    Returns the next available generation number of the FieldInfos files.

    Declaration
    public virtual long NextFieldInfosGen { get; }
    Property Value
    Type Description
    System.Int64
    | Improve this Doc View Source

    UpdatesFiles

    Returns the per generation updates files.

    Declaration
    public virtual IDictionary<long, ISet<string>> UpdatesFiles { get; }
    Property Value
    Type Description
    System.Collections.Generic.IDictionary<System.Int64, System.Collections.Generic.ISet<System.String>>

    Methods

    | Improve this Doc View Source

    Clone()

    Declaration
    public virtual object Clone()
    Returns
    Type Description
    System.Object
    | Improve this Doc View Source

    GetFiles()

    Returns all files in use by this segment.

    Declaration
    public virtual ICollection<string> GetFiles()
    Returns
    Type Description
    System.Collections.Generic.ICollection<System.String>
    | Improve this Doc View Source

    GetSizeInBytes()

    Returns total size in bytes of all files for this segment.

    NOTE: this value is not correct for 3.0 segments that have shared docstores. To get the correct value, upgrade!

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

    SetGenUpdatesFiles(IDictionary<Int64, ISet<String>>)

    Sets the updates file names per generation. Does not deep clone the map.

    Declaration
    public virtual void SetGenUpdatesFiles(IDictionary<long, ISet<string>> genUpdatesFiles)
    Parameters
    Type Name Description
    System.Collections.Generic.IDictionary<System.Int64, System.Collections.Generic.ISet<System.String>> genUpdatesFiles
    | Improve this Doc View Source

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    System.String
    Overrides
    System.Object.ToString()
    | Improve this Doc View Source

    ToString(Directory, Int32)

    Returns a description of this segment.

    Declaration
    public virtual string ToString(Directory dir, int pendingDelCount)
    Parameters
    Type Name Description
    Directory dir
    System.Int32 pendingDelCount
    Returns
    Type Description
    System.String

    Extension Methods

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