+ const STG::Admins & admins;
+};
+
+class TotalServicesSensor : public Sensor {
+ public:
+ explicit TotalServicesSensor(const STG::Services & s) : services(s) {}
+
+ void GetValue(ObjectSyntax_t * objectSyntax) const override
+ {
+ ValueToOS(services.Count(), objectSyntax);
+ }
+
+#ifdef DEBUG
+ std::string ToString() const override
+ { std::string res; std::to_string(services.Count(), res); return res; }
+#endif
+
+ private:
+ const STG::Services & services;
+};
+
+class TotalCorporationsSensor : public Sensor {
+ public:
+ explicit TotalCorporationsSensor(const STG::Corporations & c) : corporations(c) {}
+
+ void GetValue(ObjectSyntax_t * objectSyntax) const override
+ {
+ ValueToOS(corporations.Count(), objectSyntax);
+ }
+
+#ifdef DEBUG
+ std::string ToString() const override
+ { std::string res; std::to_string(corporations.Count(), res); return res; }
+#endif
+
+ private:
+ const STG::Corporations & corporations;
+};
+
+class TotalRulesSensor : public Sensor {
+ public:
+ explicit TotalRulesSensor(const STG::TraffCounter & t) : traffcounter(t) {}
+
+ void GetValue(ObjectSyntax_t * objectSyntax) const override
+ {
+ ValueToOS(traffcounter.rulesCount(), objectSyntax);
+ }
+
+#ifdef DEBUG
+ std::string ToString() const override
+ { std::string res; std::to_string(traffcounter.rulesCount(), res); return res; }
+#endif
+
+ private:
+ const STG::TraffCounter & traffcounter;