Ditto 4.2.1
Loading...
Searching...
No Matches
MutableCounter.hpp
1
2#ifndef _DITTO_MUTABLE_COUNTER_
3#define _DITTO_MUTABLE_COUNTER_
4#include "Counter.hpp"
5#include "MutableDocumentPath.hpp"
6#include "json.hpp"
7
8namespace ditto {
9
10class MutableCounter : public Counter {
11 friend class MutableDocumentPath;
12
13public:
20 void increment(double amount);
21
22private:
24 MutableDocumentPath doc_path;
25};
26} // namespace ditto
27
28#endif
Definition Counter.hpp:9
Definition MutableCounter.hpp:10
void increment(double amount)
increment the value of the counter by the given amount
Definition MutableCounter.cpp:11
Provides an interface to specify a path to a key in a document that you can then call various update ...
Definition MutableDocumentPath.hpp:31
basic_json<> json
default JSON class
Definition json.hpp:2933