Package io.vertx.kafka.client.consumer
Class OffsetAndTimestamp
java.lang.Object
io.vertx.kafka.client.consumer.OffsetAndTimestamp
Represent information related to a Offset with timestamp information
-
Constructor Summary
ConstructorsConstructorDescriptionConstructorOffsetAndTimestamp(long offset, long timestamp) ConstructorOffsetAndTimestamp(JsonObject json) Constructor (from JSON representation)Constructor (copy) -
Method Summary
Modifier and TypeMethodDescriptionlonglongsetOffset(long offset) Set the offsetsetTimestamp(long timestamp) Set the timestamptoJson()Convert object to JSON representationtoString()
-
Constructor Details
-
OffsetAndTimestamp
public OffsetAndTimestamp()Constructor -
OffsetAndTimestamp
public OffsetAndTimestamp(long offset, long timestamp) Constructor- Parameters:
offset- the offsettimestamp- the timestamp
-
OffsetAndTimestamp
Constructor (from JSON representation)- Parameters:
json- JSON representation
-
OffsetAndTimestamp
Constructor (copy)- Parameters:
that- object to copy
-
-
Method Details
-
getOffset
public long getOffset()- Returns:
- the offset
-
setOffset
Set the offset- Parameters:
offset- the offset- Returns:
- current instance of the class to be fluent
-
getTimestamp
public long getTimestamp()- Returns:
- the timestamp
-
setTimestamp
Set the timestamp- Parameters:
timestamp- the timestamp- Returns:
- current instance of the class to be fluent
-
toJson
Convert object to JSON representation- Returns:
- JSON representation
-
toString
-