Package org.apache.druid.segment
Class SegmentSchemaMapping
- java.lang.Object
-
- org.apache.druid.segment.SegmentSchemaMapping
-
public class SegmentSchemaMapping extends Object
Compact representation of segment schema for multiple segments. Note, that this is a mutable class.
-
-
Constructor Summary
Constructors Constructor Description SegmentSchemaMapping(int schemaVersion)SegmentSchemaMapping(Map<String,SegmentMetadata> segmentIdToMetadataMap, Map<String,SchemaPayload> schemaFingerprintToPayloadMap, int schemaVersion)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddSchema(SegmentId segmentId, SchemaPayloadPlus schemaPayloadPlus, String fingerprint)Add schema information for the segment.booleanequals(Object o)intgetSchemaCount()Map<String,SchemaPayload>getSchemaFingerprintToPayloadMap()intgetSchemaVersion()Map<String,SegmentMetadata>getSegmentIdToMetadataMap()inthashCode()booleanisNonEmpty()voidmerge(SegmentSchemaMapping other)Merge with another instance.StringtoString()
-
-
-
Constructor Detail
-
SegmentSchemaMapping
public SegmentSchemaMapping(Map<String,SegmentMetadata> segmentIdToMetadataMap, Map<String,SchemaPayload> schemaFingerprintToPayloadMap, int schemaVersion)
-
SegmentSchemaMapping
public SegmentSchemaMapping(int schemaVersion)
-
-
Method Detail
-
getSegmentIdToMetadataMap
public Map<String,SegmentMetadata> getSegmentIdToMetadataMap()
-
getSchemaFingerprintToPayloadMap
public Map<String,SchemaPayload> getSchemaFingerprintToPayloadMap()
-
getSchemaVersion
public int getSchemaVersion()
-
isNonEmpty
public boolean isNonEmpty()
-
addSchema
public void addSchema(SegmentId segmentId, SchemaPayloadPlus schemaPayloadPlus, String fingerprint)
Add schema information for the segment.
-
merge
public void merge(SegmentSchemaMapping other)
Merge with another instance.
-
getSchemaCount
public int getSchemaCount()
-
-