Class PartitionMetadata<K extends Serializable>

  • Type Parameters:
    K - the key type of its partitions.

    public final class PartitionMetadata<K extends Serializable>
    extends Object
    This class represents a metadata for a partition.
    • Constructor Detail

      • PartitionMetadata

        public PartitionMetadata​(K key,
                                 int partitionSize,
                                 long offset)
        Constructor.
        Parameters:
        key - the key of this partition.
        partitionSize - the size of this partition.
        offset - the offset of this partition.
    • Method Detail

      • getKey

        public K getKey()
        Returns:
        the key of this partition.
      • getPartitionSize

        public int getPartitionSize()
        Returns:
        the size of this partition.
      • getOffset

        public long getOffset()
        Returns:
        the offset of this partition.