diff options
author | vng <viktor.govako@gmail.com> | 2011-02-08 01:06:04 +0300 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:11:54 +0300 |
commit | 2680e4a2a79b7a8fc2490212d6de11c3afad47a8 (patch) | |
tree | 1ff6e6154583b1ed502966c751ee90da7846e8aa /indexer/geometry_serialization.hpp | |
parent | 5c736831eb56d740c84fc1d99bbdd4c1f74e2bca (diff) |
Remove obsolete feature-points serialization functions.
Diffstat (limited to 'indexer/geometry_serialization.hpp')
-rw-r--r-- | indexer/geometry_serialization.hpp | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/indexer/geometry_serialization.hpp b/indexer/geometry_serialization.hpp index d29f0bf058..fe42a4b772 100644 --- a/indexer/geometry_serialization.hpp +++ b/indexer/geometry_serialization.hpp @@ -30,13 +30,20 @@ namespace serial typedef vector<m2::PointU> PointsT; typedef vector<uint64_t> DeltasT; + /// @name Encode and Decode function types. + //@{ typedef void (*EncodeFunT)(PointsT const &, m2::PointU const &, m2::PointU const &, DeltasT &); typedef void (*DecodeFunT)(DeltasT const &, m2::PointU const &, m2::PointU const &, PointsT &); + //@} void Encode(EncodeFunT fn, vector<m2::PointD> const & points, int64_t base, DeltasT & deltas); typedef buffer_vector<m2::PointD, 32> OutPointsT; + /// @name Overloads for different out container types. + //@{ void Decode(DecodeFunT fn, DeltasT const & deltas, int64_t base, OutPointsT & points, size_t reserveF = 1); + void Decode(DecodeFunT fn, DeltasT const & deltas, int64_t base, vector<m2::PointD> & points, size_t reserveF = 1); + //@} template <class TSink> void SaveInner(EncodeFunT fn, vector<m2::PointD> const & points, int64_t base, TSink & sink) @@ -69,8 +76,8 @@ namespace serial void const * LoadInner(DecodeFunT fn, void const * pBeg, size_t count, int64_t base, OutPointsT & points); - template <class TSource> - void LoadOuter(DecodeFunT fn, TSource & src, int64_t base, OutPointsT & points, size_t reserveF = 1) + template <class TSource, class TPoints> + void LoadOuter(DecodeFunT fn, TSource & src, int64_t base, TPoints & points, size_t reserveF = 1) { uint32_t const count = ReadVarUint<uint32_t>(src); vector<char> buffer(count); @@ -103,8 +110,8 @@ namespace serial return LoadInner(&geo_coding::DecodePolyline, pBeg, count, base, points); } - template <class TSource> - void LoadOuterPath(TSource & src, int64_t base, OutPointsT & points) + template <class TSource, class TPoints> + void LoadOuterPath(TSource & src, int64_t base, TPoints & points) { LoadOuter(&geo_coding::DecodePolyline, src, base, points); } |