pulsar-client-cpp
Loading...
Searching...
No Matches
MessageIdBuilder.h
1
19#pragma once
20
21#include <pulsar/MessageId.h>
22
23#include <memory>
24
25namespace pulsar {
26
27namespace proto {
28class MessageIdData;
29}
30
54class PULSAR_PUBLIC MessageIdBuilder {
55 public:
56 explicit MessageIdBuilder();
57
61 static MessageIdBuilder from(const MessageId& messageId);
62
69 static MessageIdBuilder from(const proto::MessageIdData& messageIdData);
70
75
81 MessageIdBuilder& ledgerId(int64_t ledgerId);
82
88 MessageIdBuilder& entryId(int64_t entryId);
89
95 MessageIdBuilder& partition(int32_t partition);
96
102 MessageIdBuilder& batchIndex(int32_t batchIndex);
103
109 MessageIdBuilder& batchSize(int32_t batchSize);
110
111 private:
112 std::shared_ptr<MessageIdImpl> impl_;
113};
114
115} // namespace pulsar
Definition MessageIdBuilder.h:54
MessageIdBuilder & batchSize(int32_t batchSize)
MessageIdBuilder & batchIndex(int32_t batchIndex)
MessageIdBuilder & partition(int32_t partition)
static MessageIdBuilder from(const proto::MessageIdData &messageIdData)
MessageId build() const
static MessageIdBuilder from(const MessageId &messageId)
MessageIdBuilder & ledgerId(int64_t ledgerId)
MessageIdBuilder & entryId(int64_t entryId)
Definition MessageId.h:34
Definition Authentication.h:31