public final class OffsetRange
extends java.lang.Object
implements scala.Serializable
OffsetRange.create()
.
param: topic Kafka topic name
param: partition Kafka partition id
param: fromOffset Inclusive starting offset
param: untilOffset Exclusive ending offsetModifier and Type | Method and Description |
---|---|
static OffsetRange |
apply(java.lang.String topic,
int partition,
long fromOffset,
long untilOffset) |
static OffsetRange |
apply(kafka.common.TopicAndPartition topicAndPartition,
long fromOffset,
long untilOffset) |
long |
count()
Number of messages this OffsetRange refers to
|
static OffsetRange |
create(java.lang.String topic,
int partition,
long fromOffset,
long untilOffset) |
static OffsetRange |
create(kafka.common.TopicAndPartition topicAndPartition,
long fromOffset,
long untilOffset) |
boolean |
equals(java.lang.Object obj) |
long |
fromOffset() |
int |
hashCode() |
int |
partition() |
java.lang.String |
topic() |
kafka.common.TopicAndPartition |
topicAndPartition()
Kafka TopicAndPartition object, for convenience
|
java.lang.String |
toString() |
long |
untilOffset() |
public static OffsetRange create(java.lang.String topic, int partition, long fromOffset, long untilOffset)
public static OffsetRange create(kafka.common.TopicAndPartition topicAndPartition, long fromOffset, long untilOffset)
public static OffsetRange apply(java.lang.String topic, int partition, long fromOffset, long untilOffset)
public static OffsetRange apply(kafka.common.TopicAndPartition topicAndPartition, long fromOffset, long untilOffset)
public java.lang.String topic()
public int partition()
public long fromOffset()
public long untilOffset()
public kafka.common.TopicAndPartition topicAndPartition()
public long count()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object