public Map<Integer, PartitionRegistration> partitions() {
        return partitions;
    }
Represents a topic in the metadata image.

This class is thread-safe.
metadata/src/main/java/org/apache/kafka/image/TopicImage.java