]> git.stg.codes - stg.git/blobdiff - include/stg/user_stat.h
Use simple parser fro CHG_ADMIN.
[stg.git] / include / stg / user_stat.h
index 42d436fdc96c472675eef9f2e5d0ce980d4db05e..7775c3b51ac1d4855d1adac8d18b494aedb60df3 100644 (file)
@@ -113,7 +113,6 @@ struct STAT_NODE
 //-----------------------------------------------------------------------------
 struct USER_STAT
 {
-    //USER_STAT & operator= (const USER_STAT_RES & usr);
     USER_STAT()
         : up(),
           down(),
@@ -123,7 +122,7 @@ struct USER_STAT
           lastCashAddTime(0),
           passiveTime(0),
           lastActivityTime(0)
-    {};
+    {}
 
     DIR_TRAFF   up;
     DIR_TRAFF   down;
@@ -161,20 +160,20 @@ struct USER_STAT_RES
         up = us.up;
         down = us.down;
         return * this;
-    };
-    operator USER_STAT() const
+    }
+    USER_STAT GetData() const
     {
         USER_STAT us;
-        us.cash             = cash;
-        us.freeMb           = freeMb;
-        us.lastCashAdd      = lastCashAdd;
-        us.lastCashAddTime  = lastCashAddTime;
-        us.passiveTime      = passiveTime;
-        us.lastActivityTime = lastActivityTime;
-        us.up               = up;
-        us.down             = down;
+        us.cash             = cash.data();
+        us.freeMb           = freeMb.data();
+        us.lastCashAdd      = lastCashAdd.data();
+        us.lastCashAddTime  = lastCashAddTime.data();
+        us.passiveTime      = passiveTime.data();
+        us.lastActivityTime = lastActivityTime.data();
+        us.up               = up.data();
+        us.down             = down.data();
         return us;
-    };
+    }
 
     RESETABLE<double>      cash;
     RESETABLE<double>      freeMb;