6 #include <zk/config.hpp> 33 const buffer& data()
const & {
return _data; }
34 buffer& data() & {
return _data; }
35 buffer data() && {
return std::move(_data); }
37 const zk::stat& stat()
const {
return _stat; }
45 std::ostream& operator<<(std::ostream&,
const get_result&);
53 using children_list_type = std::vector<std::string>;
61 const children_list_type&
children() const & {
return _children; }
62 children_list_type& children() & {
return _children; }
63 children_list_type children() && {
return std::move(_children); }
67 stat& parent_stat() {
return _parent_stat; }
70 children_list_type _children;
86 explicit operator bool()
const {
return bool(_stat); }
87 bool operator!()
const {
return !_stat; }
89 const optional<zk::stat>& stat()
const {
return _stat; }
90 optional<zk::stat>& stat() {
return _stat; }
93 optional<zk::stat> _stat;
96 std::ostream& operator<<(std::ostream&,
const exists_result&);
110 const std::string& name()
const & {
return _name; }
111 std::string& name() & {
return _name; }
112 std::string name() && {
return std::move(_name); }
118 std::ostream& operator<<(std::ostream&,
const create_result&);
130 const zk::stat& stat()
const {
return _stat; }
137 std::ostream& operator<<(std::ostream&,
const set_result&);
149 const zk::acl& acl()
const & {
return _acl; }
150 zk::acl& acl() & {
return _acl; }
151 zk::acl acl() && {
return std::move(_acl); }
153 const zk::stat& stat()
const {
return _stat; }
193 std::ostream& operator<<(std::ostream&,
const event&);
195 std::string to_string(
const event&);
210 get_result initial() && {
return std::move(_initial); }
213 const future<event>&
next() const & {
return _next; }
214 future<event>& next() & {
return _next; }
215 future<event> next() && {
return std::move(_next); }
222 std::ostream& operator<<(std::ostream&,
const watch_result&);
242 const future<event>&
next() const & {
return _next; }
243 future<event>& next() & {
return _next; }
244 future<event> next() && {
return std::move(_next); }
271 const future<event>&
next() const & {
return _next; }
272 future<event>& next() & {
return _next; }
273 future<event> next() && {
return std::move(_next); }
Data delivered when a watched event triggers.
state
Enumeration of states the client may be at when a watch triggers.
const future< event > & next() const &
Future to be delivered when the watch is triggered.
The result type of client::get_acl.
The result type of client::watch_exists.
const get_result & initial() const &
The initial result of the fetch.
The result type of client::create.
Controls the import of the optional and nullopt_t types, as well as the nullopt constexpr.
The result type of client::exists.
The result type of client::watch.
The result type of client::watch_children.
Statistics about a znode, similar to the UNIX stat structure.
const children_list_type & children() const &
The list of children of the parent znode.
const get_children_result & initial() const &
The initial result of the fetch.
const exists_result & initial() const &
The initial result of the fetch.
const future< event > & next() const &
Future to be delivered when the watch is triggered.
Controls the import of future and promise types.
The result type of client::set.
const zk::state & state() const
The state of the connection when the event occurred.
event_type
Enumeration of types of events that may occur.
An access control list is a wrapper around acl_rule instances.
Controls the buffer type.
The result type of client::get_children.
const future< event > & next() const &
Future to be delivered when the watch is triggered.
const stat & parent_stat() const
The stat of the znode client::get_children was called on.
ZKPP_BUFFER_TYPE buffer
The buffer type.
The result type of client::get.
const event_type & type() const
The type of event that occurred.