1 #ifndef __TEST_ADMIN_H__
2 #define __TEST_ADMIN_H__
6 class TEST_ADMIN : public ADMIN {
8 TEST_ADMIN() : priv(0xffFF), ip(0) {}
10 ADMIN & operator=(const ADMIN &) { return *this; }
11 ADMIN & operator=(const ADMIN_CONF &) { return *this; }
12 bool operator==(const ADMIN & /*rhs*/) const { return true; }
13 bool operator!=(const ADMIN & /*rhs*/) const { return false; }
14 bool operator<(const ADMIN & /*rhs*/) const { return true; }
15 bool operator<=(const ADMIN & /*rhs*/) const { return true; }
17 const std::string & GetPassword() const { return password; }
18 const std::string & GetLogin() const { return login; }
19 PRIV const * GetPriv() const { return &priv; }
20 uint16_t GetPrivAsInt() const { return priv.ToInt(); }
21 const ADMIN_CONF & GetConf() const { return conf; }
22 uint32_t GetIP() const { return ip; }
23 std::string GetIPStr() const { return inet_ntostring(ip); }
24 void SetIP(uint32_t ip) { TEST_ADMIN::ip = ip; }
25 const std::string GetLogStr() const { return ""; }