mirror of
https://github.com/znc/znc.git
synced 2026-08-11 03:12:50 +02:00
Merge pull request #1020 from jpnurmi/traffic
Calculate per-network traffic (#963)
This commit is contained in:
@@ -196,6 +196,12 @@ public:
|
||||
unsigned short int GetJoinDelay() const { return m_uJoinDelay; }
|
||||
void SetJoinDelay(unsigned short int uJoinDelay) { m_uJoinDelay = uJoinDelay; }
|
||||
|
||||
unsigned long long BytesRead() const { return m_uBytesRead; }
|
||||
unsigned long long BytesWritten() const { return m_uBytesWritten; }
|
||||
|
||||
void AddBytesRead(unsigned long long u) { m_uBytesRead += u; }
|
||||
void AddBytesWritten(unsigned long long u) { m_uBytesWritten += u; }
|
||||
|
||||
CString ExpandString(const CString& sStr) const;
|
||||
CString& ExpandString(const CString& sStr, CString& sRet) const;
|
||||
private:
|
||||
@@ -245,6 +251,8 @@ protected:
|
||||
CIRCNetworkJoinTimer* m_pJoinTimer;
|
||||
|
||||
unsigned short int m_uJoinDelay;
|
||||
unsigned long long m_uBytesRead;
|
||||
unsigned long long m_uBytesWritten;
|
||||
};
|
||||
|
||||
#endif // !ZNC_IRCNETWORK_H
|
||||
|
||||
+2
-2
@@ -187,8 +187,8 @@ public:
|
||||
bool AutoClearQueryBuffer() const;
|
||||
bool IsBeingDeleted() const { return m_bBeingDeleted; }
|
||||
CString GetTimezone() const { return m_sTimezone; }
|
||||
unsigned long long BytesRead() const { return m_uBytesRead; }
|
||||
unsigned long long BytesWritten() const { return m_uBytesWritten; }
|
||||
unsigned long long BytesRead() const;
|
||||
unsigned long long BytesWritten() const;
|
||||
unsigned int JoinTries() const { return m_uMaxJoinTries; }
|
||||
unsigned int MaxJoins() const { return m_uMaxJoins; }
|
||||
CString GetSkinName() const;
|
||||
|
||||
@@ -92,6 +92,7 @@ public:
|
||||
// generated through ZNC.
|
||||
TrafficStatsMap GetTrafficStats(TrafficStatsPair &Users,
|
||||
TrafficStatsPair &ZNC, TrafficStatsPair &Total);
|
||||
TrafficStatsMap GetNetworkTrafficStats(const CString& sUsername, TrafficStatsPair& Total);
|
||||
|
||||
// Authenticate a user.
|
||||
// The result is passed back via callbacks to CAuthBase.
|
||||
|
||||
Reference in New Issue
Block a user