15#ifndef GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_PUBSUB_EXACTLY_ONCE_ACK_HANDLER_H
16#define GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_PUBSUB_EXACTLY_ONCE_ACK_HANDLER_H
18#include "google/cloud/pubsub/version.h"
19#include "google/cloud/future.h"
20#include "google/cloud/status.h"
26GOOGLE_CLOUD_CPP_INLINE_NAMESPACE_BEGIN
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
80 auto impl = std::move(impl_);
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
101 auto impl = std::move(impl_);
128
129
131 : impl_(std::move(impl)) {}
134 std::unique_ptr<
Impl> impl_;
137GOOGLE_CLOUD_CPP_INLINE_NAMESPACE_END
Status(StatusCode code, std::string message, ErrorInfo info={})
friend friend class future
Allow applications to mock an ExactlyOnceAckHandler.
Definition: exactly_once_ack_handler.h:110
virtual std::int32_t delivery_attempt() const
The implementation for ExactlyOnceAckHandler::delivery_attempt()
Definition: exactly_once_ack_handler.h:124
virtual future< Status > ack()
The implementation for ExactlyOnceAckHandler::ack()
Definition: exactly_once_ack_handler.h:114
virtual future< Status > nack()
The implementation for ExactlyOnceAckHandler::nack()
Definition: exactly_once_ack_handler.h:119
Defines the interface to acknowledge and reject messages.
Definition: exactly_once_ack_handler.h:49
ExactlyOnceAckHandler(std::unique_ptr< Impl > impl)
Applications may use this constructor in their mocks.
Definition: exactly_once_ack_handler.h:130
future< Status > nack() &&
Rejects the message associated with this handler.
Definition: exactly_once_ack_handler.h:100
ExactlyOnceAckHandler(ExactlyOnceAckHandler &&)=default
future< Status > ack() &&
Acknowledges the message associated with this handler.
Definition: exactly_once_ack_handler.h:79
std::int32_t delivery_attempt() const
Returns the approximate number of times that Cloud Pub/Sub has attempted to deliver the associated me...
Definition: exactly_once_ack_handler.h:107
ExactlyOnceAckHandler & operator=(ExactlyOnceAckHandler &&)=default
Contains all the Cloud Pub/Sub C++ client types and functions.
Definition: ack_handler.h:25
The namespace Google Cloud Platform C++ client libraries.
future< typename internal::make_ready_return< T >::type > make_ready_future(T &&t)