diff options
author | Chris Wilson <chris+github@qwirx.com> | 2006-12-03 10:40:26 +0000 |
---|---|---|
committer | Chris Wilson <chris+github@qwirx.com> | 2006-12-03 10:40:26 +0000 |
commit | e0a80f0da840849a5cdb38bcfea7a7e240a2aa2d (patch) | |
tree | ee3c2b1327a16bf04f4f1fa9507af88d7d438df0 /bin/bbackupd/BackupClientContext.h | |
parent | 7a47551a8c2eba625a1f32c4c7dd61015ebeaa36 (diff) |
Moved KeepAlive timer to BackupClientContext object.
Made timeout initialisation non-static, and a property of the context
object. (perhaps should be in rParams, I know).
(refs #3, refs #9)
Diffstat (limited to 'bin/bbackupd/BackupClientContext.h')
-rw-r--r-- | bin/bbackupd/BackupClientContext.h | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/bin/bbackupd/BackupClientContext.h b/bin/bbackupd/BackupClientContext.h index c7e011c8..152d8556 100644 --- a/bin/bbackupd/BackupClientContext.h +++ b/bin/bbackupd/BackupClientContext.h @@ -14,6 +14,7 @@ #include "BackupClientDeleteList.h" #include "BackupStoreFile.h" #include "ExcludeList.h" +#include "Timer.h" class TLSContext; class BackupProtocolClient; @@ -151,7 +152,7 @@ public: // Created: 04/19/2005 // // -------------------------------------------------------------------------- - static void SetMaximumDiffingTime(int iSeconds); + void SetMaximumDiffingTime(int iSeconds); // -------------------------------------------------------------------------- // @@ -161,7 +162,7 @@ public: // Created: 04/19/2005 // // -------------------------------------------------------------------------- - static void SetKeepAliveTime(int iSeconds); + void SetKeepAliveTime(int iSeconds); // -------------------------------------------------------------------------- // @@ -183,18 +184,17 @@ public: // -------------------------------------------------------------------------- void UnManageDiffProcess(); - // -------------------------------------------------------------------------- + // ------------------------------------------------------------------- // // Function // Name: BackupClientContext::DoKeepAlive() - // Purpose: Does something inconsequential over the SSL link to - // keep it up, implements DiffTimer interface + // Purpose: Check whether it's time to send a KeepAlive + // message over the SSL link, and if so, send it. // Created: 04/19/2005 // - // -------------------------------------------------------------------------- + // ------------------------------------------------------------------- virtual void DoKeepAlive(); virtual int GetMaximumDiffingTime(); - virtual int GetKeepAliveTime(); virtual bool IsManaged() { return mbIsManaged; } private: @@ -215,8 +215,10 @@ private: bool mStorageLimitExceeded; ExcludeList *mpExcludeFiles; ExcludeList *mpExcludeDirs; - + Timer mKeepAliveTimer; bool mbIsManaged; + int mKeepAliveTime; + int mMaximumDiffingTime; }; #endif // BACKUPCLIENTCONTEXT__H |