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:
authorYuri Gorshenin <y@maps.me>2017-06-20 10:23:28 +0300
committerYuri Gorshenin <mipt.vi002@gmail.com>2017-07-05 16:41:38 +0300
commitf5bdec0ba48a300b4c5718da3fbbc932531ffb09 (patch)
tree5d78761b24357ece2c5711fb7c8d01afe002373f /ugc/types.hpp
parent3e71c85a46215bd54a151b45477053d5fcdb0b86 (diff)
[ugc] std::string -> TranslationKey
Diffstat (limited to 'ugc/types.hpp')
-rw-r--r--ugc/types.hpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/ugc/types.hpp b/ugc/types.hpp
index 1a4aa3b956..5f4f9bcf20 100644
--- a/ugc/types.hpp
+++ b/ugc/types.hpp
@@ -10,15 +10,17 @@
namespace ugc
{
+using TranslationKey = std::string;
+
struct RatingRecord
{
- RatingRecord(std::string const & key, float const value)
+ RatingRecord(TranslationKey const & key, float const value)
: m_key(key)
, m_value(value)
{
}
- std::string m_key;
+ TranslationKey m_key;
float m_value;
};
@@ -93,23 +95,22 @@ struct Review
Text m_text;
Author m_author;
- // A rating of a review itself. It is accumulated from other users likes or dislakes.
+ // A rating of a review itself. It is accumulated from other users
+ // likes or dislakes.
float m_rating;
- // A positive/negative evaluation given to a place by a user.
+ // A positive/negative evaluation given to a place by an author.
bool m_evaluation;
std::chrono::time_point<std::chrono::system_clock> m_time;
};
struct Attribute
{
- Attribute(std::string const & key, std::string const & value)
- : m_key(key)
- , m_value(value)
+ Attribute(TranslationKey const & key, TranslationKey const & value) : m_key(key), m_value(value)
{
}
- std::string m_key;
- std::string m_value;
+ TranslationKey m_key;
+ TranslationKey m_value;
};
// struct Media
@@ -151,8 +152,7 @@ struct ReviewAbuse
{
ReviewAbuse(std::string const & reason,
std::chrono::time_point<std::chrono::system_clock> const & time)
- : m_reason(reason)
- , m_time(time)
+ : m_reason(reason), m_time(time)
{
}