10 #include "configproto.h"
12 extern "C" PLUGIN * GetPlugin();
16 class STG_CONFIG_SETTINGS {
18 STG_CONFIG_SETTINGS();
19 virtual ~STG_CONFIG_SETTINGS() {}
20 const std::string & GetStrError() const;
21 int ParseSettings(const MODULE_SETTINGS & s);
22 uint16_t GetPort() const;
24 int ParseIntInRange(const std::string & str, int min, int max, int * val);
28 //-----------------------------------------------------------------------------
29 class STG_CONFIG :public PLUGIN {
32 virtual ~STG_CONFIG(){};
34 void SetUsers(USERS * u);
35 void SetTariffs(TARIFFS * t);
36 void SetAdmins(ADMINS * a);
37 void SetStore(STORE * s);
38 void SetTraffcounter(TRAFFCOUNTER *) {}
39 void SetStgSettings(const SETTINGS * s);
40 void SetSettings(const MODULE_SETTINGS & s);
45 int Reload() { return 0; }
48 const std::string & GetStrError() const;
49 const std::string GetVersion() const;
50 uint16_t GetStartPosition() const;
51 uint16_t GetStopPosition() const;
54 static void * Run(void *);
55 mutable std::string errorStr;
56 STG_CONFIG_SETTINGS stgConfigSettings;
65 MODULE_SETTINGS settings;
66 const SETTINGS * stgSettings;
68 //-----------------------------------------------------------------------------