Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Magidovich <mgsergio@mapswithme.com>2017-06-19 16:50:56 +0300
committerYuri Gorshenin <mipt.vi002@gmail.com>2017-07-05 16:41:38 +0300
commitdec8b3f4876eada9585a1df710965397c728d7d3 (patch)
treeed57f9427ce7a4d6e7a1043da06def4258d35c2f /ugc/api.hpp
parent2abc1da6f13ef3c3e875dfc9f218b8274a732cba (diff)
Add ugc datatypes.
Diffstat (limited to 'ugc/api.hpp')
-rw-r--r--ugc/api.hpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/ugc/api.hpp b/ugc/api.hpp
index 8b13853eae..eb6f731f39 100644
--- a/ugc/api.hpp
+++ b/ugc/api.hpp
@@ -2,6 +2,8 @@
#include "base/worker_thread.hpp"
+#include "ugc/types.hpp"
+
#include <functional>
class Index;
@@ -12,17 +14,17 @@ namespace ugc
class Api
{
public:
- // TODO (@y, @mgsergio): replace void() by void(UGC const &).
- using Callback = std::function<void()>;
+ using UGCCallback = std::function<void(UGC const &)>;
+ using UGCUpdateCallback = std::function<void(UGCUpdate const &)>;
explicit Api(Index const & index);
- void GetStaticUGC(FeatureID const & id, Callback callback);
- void GetDynamicUGC(FeatureID const & id, Callback callback);
+ void GetUGC(FeatureID const & id, UGCCallback callback);
+ void GetUGCUpdate(FeatureID const & id, UGCUpdateCallback callback);
private:
- void GetStaticUGCImpl(FeatureID const & id, Callback callback);
- void GetDynamicUGCImpl(FeatureID const & id, Callback callback);
+ void GetUGCImpl(FeatureID const & id, UGCCallback callback);
+ void GetUGCUpdateImpl(FeatureID const & id, UGCUpdateCallback callback);
Index const & m_index;
base::WorkerThread m_thread;