+ class FACTORY : public BASE_PARSER::FACTORY
+ {
+ public:
+ FACTORY(Users & users, Store & store, const Tariffs & tariffs)
+ : m_users(users), m_store(store), m_tariffs(tariffs)
+ {}
+ virtual BASE_PARSER * create(const Admin & admin) { return new CHG_USER(admin, m_users, m_store, m_tariffs); }
+ static void Register(REGISTRY & registry, Users & users, Store & store, const Tariffs & tariffs)
+ { registry[ToLower(tag)] = new FACTORY(users, store, tariffs); }
+ private:
+ Users & m_users;
+ Store & m_store;
+ const Tariffs & m_tariffs;
+ };
+
+ static const char * tag;
+
+ CHG_USER(const Admin & admin, Users & users,
+ Store & store, const Tariffs & tariffs)
+ : BASE_PARSER(admin, tag),
+ m_users(users),
+ m_store(store),
+ m_tariffs(tariffs),
+ m_cashMustBeAdded(false) {}
+