Changeset View
Changeset View
Standalone View
Standalone View
common/index.h
Show All 34 Lines | 15 | public: | |||
---|---|---|---|---|---|
35 | 35 | | |||
36 | void add(const QByteArray &key, const QByteArray &value); | 36 | void add(const QByteArray &key, const QByteArray &value); | ||
37 | void remove(const QByteArray &key, const QByteArray &value); | 37 | void remove(const QByteArray &key, const QByteArray &value); | ||
38 | 38 | | |||
39 | void lookup(const QByteArray &key, const std::function<void(const QByteArray &value)> &resultHandler, const std::function<void(const Error &error)> &errorHandler, | 39 | void lookup(const QByteArray &key, const std::function<void(const QByteArray &value)> &resultHandler, const std::function<void(const Error &error)> &errorHandler, | ||
40 | bool matchSubStringKeys = false); | 40 | bool matchSubStringKeys = false); | ||
41 | QByteArray lookup(const QByteArray &key); | 41 | QByteArray lookup(const QByteArray &key); | ||
42 | 42 | | |||
43 | void rangeLookup(const QByteArray &lowerBound, const QByteArray &upperBound, | ||||
44 | const std::function<void(const QByteArray &value)> &resultHandler, | ||||
45 | const std::function<void(const Error &error)> &errorHandler); | ||||
46 | | ||||
43 | private: | 47 | private: | ||
44 | Q_DISABLE_COPY(Index); | 48 | Q_DISABLE_COPY(Index); | ||
45 | Sink::Storage::DataStore::Transaction mTransaction; | 49 | Sink::Storage::DataStore::Transaction mTransaction; | ||
46 | Sink::Storage::DataStore::NamedDatabase mDb; | 50 | Sink::Storage::DataStore::NamedDatabase mDb; | ||
47 | QString mName; | 51 | QString mName; | ||
48 | Sink::Log::Context mLogCtx; | 52 | Sink::Log::Context mLogCtx; | ||
49 | }; | 53 | }; |