diff --git a/storage/country.hpp b/storage/country.hpp index b1634d5d38..21e9876e80 100644 --- a/storage/country.hpp +++ b/storage/country.hpp @@ -27,6 +27,7 @@ namespace storage : m_fileName(fName), m_remoteSize(remoteSize), m_price(price) {} string GetFileWithExt() const { return m_fileName + DATA_FILE_EXTENSION; } + string const & GetFileWithoutExt() const { return m_fileName; } uint32_t GetFileSize() const; diff --git a/storage/storage.cpp b/storage/storage.cpp index db13247913..b3a3fdfcbc 100644 --- a/storage/storage.cpp +++ b/storage/storage.cpp @@ -117,6 +117,11 @@ namespace storage return NodeFromIndex(m_countries, index).Value().Flag(); } + string const & Storage::CountryFileName(TIndex const & index) const + { + return NodeFromIndex(m_countries, index).Value().GetFile().GetFileWithoutExt(); + } + LocalAndRemoteSizeT Storage::CountrySizeInBytes(TIndex const & index) const { return CountryByIndex(index).Size(); diff --git a/storage/storage.hpp b/storage/storage.hpp index 1e838e81d3..169414197d 100644 --- a/storage/storage.hpp +++ b/storage/storage.hpp @@ -109,6 +109,8 @@ namespace storage size_t CountriesCount(TIndex const & index) const; string const & CountryName(TIndex const & index) const; string const & CountryFlag(TIndex const & index) const; + //country file name without extension + string const & CountryFileName(TIndex const & index) const; LocalAndRemoteSizeT CountrySizeInBytes(TIndex const & index) const; TStatus CountryStatus(TIndex const & index) const; //m2::RectD CountryBounds(TIndex const & index) const;