8 #ifndef __UNIRETRYGEN_H
9 #define __UNIRETRYGEN_H
11 #include "unifiltergen.h"
12 #include "wvtimeutils.h"
45 typedef wv::function<void(UniRetryGen&)> ReconnectCallback;
53 ReconnectCallback reconnect_callback;
55 time_t retry_interval_ms;
56 WvTime next_reconnect_attempt;
58 void maybe_disconnect();
59 void maybe_reconnect();
64 ReconnectCallback _reconect_callback = ReconnectCallback(),
65 time_t _retry_internal_ms = 5000);
82 #endif //__UNIRETRYGEN_H
virtual Iter * iterator(const UniConfKey &key)
Returns an iterator over the children of the specified key.
A WvFastString acts exactly like a WvString, but can take (const char *) strings without needing to a...
Represents a UniConf key which is a path in a hierarchy structured much like the traditional Unix fil...
virtual bool exists(const UniConfKey &key)
Without fetching its value, returns true if a key exists.
virtual void flush_buffers()
Flushes any commitment/notification buffers .
virtual Iter * recursiveiterator(const UniConfKey &key)
Like iterator(), but the returned iterator is recursive, that is, it will return children of the imme...
virtual bool refresh()
Refreshes information about a key recursively.
A UniConfGen that reconnects to an inner generator specified by a moniker whenever the inner generato...
virtual void commit()
Commits any changes.
Based on (and interchangeable with) struct timeval.
virtual bool isok()
Determines if the generator is usable and working properly.
virtual void set(const UniConfKey &key, WvStringParm value)
Stores a string value for a key into the registry.
A UniConfGen that delegates all requests to an inner generator.
virtual void prefetch(const UniConfKey &key, bool recursive)
Indicate that we will eventually be interested in doing get(), haschildren(), or other "get-like" ope...
virtual bool haschildren(const UniConfKey &key)
Returns true if a key has children.
WvString is an implementation of a simple and efficient printable-string class.
A WvLog stream accepts log messages from applications and forwards them to all registered WvLogRcv's...