Package org.apache.lucene.index
Class SegmentCommitInfo
java.lang.Object
org.apache.lucene.index.SegmentCommitInfo
Embeds a [read-only] SegmentInfo and adds per-commit
  fields.
- 
Field SummaryFields
- 
Constructor SummaryConstructorsConstructorDescriptionSegmentCommitInfo(SegmentInfo info, int delCount, long delGen, long fieldInfosGen) Sole constructor.
- 
Method SummaryModifier and TypeMethodDescriptionclone()files()Returns all files in use by this segment.intReturns the number of deleted docs in the segment.longReturns generation number of the live docs file or -1 if there are no deletes yet.longReturns the generation number of the field infos file or -1 if there are no field updates yet.longReturns the next available generation number of the live docs file.longReturns the next available generation number of the FieldInfos files.Returns the per generation updates files.booleanReturns true if there are any deletions for the segment at this commit.booleanReturns true if there are any field updates for the segment in this commit.voidsetGenUpdatesFiles(Map<Long, Set<String>> genUpdatesFiles) Sets the updates file names per generation.longReturns total size in bytes of all files for this segment.toString()Returns a description of this segment.
- 
Field Details- 
infoTheSegmentInfothat we wrap.
 
- 
- 
Constructor Details- 
SegmentCommitInfoSole constructor.- Parameters:
- info-- SegmentInfothat we wrap
- delCount- number of deleted documents in this segment
- delGen- deletion generation number (used to name deletion files)
- fieldInfosGen- FieldInfos generation number (used to name field-infos files)
 
 
- 
- 
Method Details- 
getUpdatesFilesReturns the per generation updates files.
- 
setGenUpdatesFilesSets the updates file names per generation. Does not deep clone the map.
- 
sizeInBytesReturns 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! - Throws:
- IOException
 
- 
filesReturns all files in use by this segment.- Throws:
- IOException
 
- 
hasDeletionspublic boolean hasDeletions()Returns true if there are any deletions for the segment at this commit.
- 
hasFieldUpdatespublic boolean hasFieldUpdates()Returns true if there are any field updates for the segment in this commit.
- 
getNextFieldInfosGenpublic long getNextFieldInfosGen()Returns the next available generation number of the FieldInfos files.
- 
getFieldInfosGenpublic long getFieldInfosGen()Returns the generation number of the field infos file or -1 if there are no field updates yet.
- 
getNextDelGenpublic long getNextDelGen()Returns the next available generation number of the live docs file.
- 
getDelGenpublic long getDelGen()Returns generation number of the live docs file or -1 if there are no deletes yet.
- 
getDelCountpublic int getDelCount()Returns the number of deleted docs in the segment.
- 
toStringReturns a description of this segment.
- 
toString
- 
clone
 
-