Package org.elasticsearch.index.engine
Class Segment
java.lang.Object
org.elasticsearch.index.engine.Segment
- All Implemented Interfaces:
Writeable
public class Segment extends java.lang.Object implements Writeable
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
Fields Modifier and Type Field Description java.util.Map<java.lang.String,java.lang.String>attributesbooleancommittedjava.lang.BooleancompoundintdelDocCountintdocCountlongmemoryInBytesjava.lang.StringmergeIdorg.apache.lucene.util.AccountableramTreebooleansearchorg.apache.lucene.search.SortsegmentSortlongsizeInBytesorg.apache.lucene.util.Versionversion -
Constructor Summary
Constructors Constructor Description Segment(java.lang.String name)Segment(StreamInput in) -
Method Summary
Modifier and Type Method Description booleanequals(java.lang.Object o)java.util.Map<java.lang.String,java.lang.String>getAttributes()Return segment attributes.intgetDeletedDocs()longgetGeneration()longgetMemoryInBytes()Estimation of the memory usage used by a segment.java.lang.StringgetMergeId()If set, a string representing that the segment is part of a merge, with the value representing the group of segments that represent this merge.java.lang.StringgetName()intgetNumDocs()org.apache.lucene.search.SortgetSegmentSort()Return the sort order of this segment, or null if the segment has no sort.ByteSizeValuegetSize()org.apache.lucene.util.VersiongetVersion()inthashCode()booleanisCommitted()java.lang.BooleanisCompound()booleanisSearch()java.lang.StringtoString()voidwriteTo(StreamOutput out)Write this into the StreamOutput.
-
Field Details
-
committed
public boolean committed -
search
public boolean search -
sizeInBytes
public long sizeInBytes -
docCount
public int docCount -
delDocCount
public int delDocCount -
version
public org.apache.lucene.util.Version version -
compound
public java.lang.Boolean compound -
mergeId
public java.lang.String mergeId -
memoryInBytes
public long memoryInBytes -
segmentSort
public org.apache.lucene.search.Sort segmentSort -
ramTree
public org.apache.lucene.util.Accountable ramTree -
attributes
public java.util.Map<java.lang.String,java.lang.String> attributes
-
-
Constructor Details
-
Method Details
-
getName
public java.lang.String getName() -
getGeneration
public long getGeneration() -
isCommitted
public boolean isCommitted() -
isSearch
public boolean isSearch() -
getNumDocs
public int getNumDocs() -
getDeletedDocs
public int getDeletedDocs() -
getSize
-
getVersion
public org.apache.lucene.util.Version getVersion() -
isCompound
-
getMergeId
If set, a string representing that the segment is part of a merge, with the value representing the group of segments that represent this merge. -
getMemoryInBytes
public long getMemoryInBytes()Estimation of the memory usage used by a segment. -
getSegmentSort
public org.apache.lucene.search.Sort getSegmentSort()Return the sort order of this segment, or null if the segment has no sort. -
getAttributes
public java.util.Map<java.lang.String,java.lang.String> getAttributes()Return segment attributes.- See Also:
SegmentInfo.getAttributes()
-
equals
public boolean equals(java.lang.Object o)- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()- Overrides:
hashCodein classjava.lang.Object
-
writeTo
Description copied from interface:WriteableWrite this into the StreamOutput. -
toString
public java.lang.String toString()- Overrides:
toStringin classjava.lang.Object
-