[omim] Public kMaximumLevelsEditableByUsers constant.

This commit is contained in:
VladiMihaylenko 2016-04-14 14:27:24 +03:00
parent cebc34f406
commit e04ad0901c
2 changed files with 5 additions and 1 deletions

View file

@ -9,6 +9,9 @@
namespace osm
{
// static
int8_t const EditableMapObject::kMaximumLevelsEditableByUsers = 25;
bool EditableMapObject::IsNameEditable() const { return m_editableProperties.m_name; }
bool EditableMapObject::IsAddressEditable() const { return m_editableProperties.m_address; }
@ -188,7 +191,6 @@ void EditableMapObject::SetFlats(string const & flats)
// static
bool EditableMapObject::ValidateBuildingLevels(string const & buildingLevels)
{
auto constexpr kMaximumLevelsEditableByUsers = 25;
uint64_t levels;
return strings::to_uint64(buildingLevels, levels) && levels <= kMaximumLevelsEditableByUsers;
}

View file

@ -54,6 +54,8 @@ struct LocalizedStreet
class EditableMapObject : public MapObject
{
public:
static int8_t const kMaximumLevelsEditableByUsers;
bool IsNameEditable() const;
bool IsAddressEditable() const;