We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a357529 commit a85a87bCopy full SHA for a85a87b
include/cppkafka/topic_partition.h
@@ -106,6 +106,11 @@ class CPPKAFKA_API TopicPartition {
106
* Gets the offset
107
*/
108
int64_t get_offset() const;
109
+
110
+ /**
111
+ * @brief Sets the partition
112
+ */
113
+ void set_partition(int partition);
114
115
/**
116
* Sets the offset
src/topic_partition.cpp
@@ -76,6 +76,10 @@ int64_t TopicPartition::get_offset() const {
76
return offset_;
77
}
78
79
+void TopicPartition::set_partition(int partition) {
80
+ partition_ = partition;
81
+}
82
83
void TopicPartition::set_offset(int64_t offset) {
84
offset_ = offset;
85
0 commit comments