Package com.hazelcast.jet.kafka
Class TopicsConfig.TopicConfig
- java.lang.Object
-
- com.hazelcast.jet.kafka.TopicsConfig.TopicConfig
-
- All Implemented Interfaces:
java.io.Serializable
- Enclosing class:
- TopicsConfig
public static class TopicsConfig.TopicConfig extends java.lang.Object implements java.io.Serializable
Contains the configuration for a single Kafka topic.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description TopicConfig(java.lang.String topicName)
Creates new topic configuration for given topic name.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TopicsConfig.TopicConfig
addPartitionInitialOffset(int partition, long offset)
Adds the initial offset for given partition to the configuration.java.lang.Long
getPartitionInitialOffset(int partition)
Returns the initial offset for given partition ornull
if it was not defined.java.util.Map<java.lang.Integer,java.lang.Long>
getPartitionsInitialOffsets()
Returns partitions initial offsets map.java.lang.String
getTopicName()
Returns the name of the topic.java.lang.String
toString()
-
-
-
Method Detail
-
getTopicName
public java.lang.String getTopicName()
Returns the name of the topic.
-
getPartitionsInitialOffsets
public java.util.Map<java.lang.Integer,java.lang.Long> getPartitionsInitialOffsets()
Returns partitions initial offsets map.
-
getPartitionInitialOffset
@Nullable public java.lang.Long getPartitionInitialOffset(int partition)
Returns the initial offset for given partition ornull
if it was not defined.
-
addPartitionInitialOffset
public TopicsConfig.TopicConfig addPartitionInitialOffset(int partition, long offset)
Adds the initial offset for given partition to the configuration.- Parameters:
partition
- the number of partitionoffset
- the initial offset for the partition
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-