From 885476dba2f1a290d949e4a004383eaf7fbab07c Mon Sep 17 00:00:00 2001 From: Yury Melnichek Date: Thu, 25 Aug 2011 17:01:01 +0200 Subject: [PATCH] [search] Added few comments. --- search/latlon_match.hpp | 3 ++- search/search_trie.hpp | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/search/latlon_match.hpp b/search/latlon_match.hpp index c6670488fb..d9a688259f 100644 --- a/search/latlon_match.hpp +++ b/search/latlon_match.hpp @@ -5,7 +5,8 @@ namespace search { -bool MatchLatLon(string const & s, double & lat, double & lon, +// Check if query can be represented as '(lat, lon)'. +bool MatchLatLon(string const & query, double & lat, double & lon, double & precisionLat, double & precisionLon); } // namespace search diff --git a/search/search_trie.hpp b/search/search_trie.hpp index 4b62760373..9538efb716 100644 --- a/search/search_trie.hpp +++ b/search/search_trie.hpp @@ -15,12 +15,13 @@ namespace search namespace trie { +// Value: feature offset and search rank are stored. struct ValueReader { struct ValueType { - uint8_t m_rank; - uint32_t m_featureId; + uint8_t m_rank; // Search rank of the feature. + uint32_t m_featureId; // Offset of the featuer. }; template void operator() (SourceT & src, ValueType & value) const @@ -30,6 +31,7 @@ struct ValueReader } }; +// Edge value: maximum search rank of the subtree is stored. struct EdgeValueReader { typedef uint8_t ValueType;