public class OffsetAndMetadata extends Object
Constructor and Description |
---|
OffsetAndMetadata()
Constructor
|
OffsetAndMetadata(JsonObject json)
Constructor (from JSON representation)
|
OffsetAndMetadata(long offset,
String metadata)
Constructor
|
OffsetAndMetadata(OffsetAndMetadata that)
Constructor (copy)
|
Modifier and Type | Method and Description |
---|---|
String |
getMetadata() |
long |
getOffset() |
OffsetAndMetadata |
setMetadata(String metadata)
Set additional metadata for the offset committed
|
OffsetAndMetadata |
setOffset(long offset)
Set the offset to commit
|
JsonObject |
toJson()
Convert object to JSON representation
|
String |
toString() |
public OffsetAndMetadata()
public OffsetAndMetadata(long offset, String metadata)
offset
- offset to commitmetadata
- additional metadata with the offset committedpublic OffsetAndMetadata(JsonObject json)
json
- JSON representationpublic OffsetAndMetadata(OffsetAndMetadata that)
that
- object to copypublic long getOffset()
public OffsetAndMetadata setOffset(long offset)
offset
- offset to commitpublic String getMetadata()
public OffsetAndMetadata setMetadata(String metadata)
metadata
- additional metadatapublic JsonObject toJson()
Copyright © 2022 Eclipse. All rights reserved.