version 0.3.33
[fms.git] / freenet / identityinserter.h
1 #ifndef _identity_inserter_\r
2 #define _identity_inserter_\r
3 \r
4 #include "../idatabase.h"\r
5 #include "../ilogger.h"\r
6 #include "../datetime.h"\r
7 #include "ifreenetregistrable.h"\r
8 #include "ifcpconnected.h"\r
9 #include "ifcpmessagehandler.h"\r
10 #include "iperiodicprocessor.h"\r
11 \r
12 class IdentityInserter:public IFreenetRegistrable,public IFCPConnected,public IFCPMessageHandler,public IPeriodicProcessor,public IDatabase,public ILogger\r
13 {\r
14 public:\r
15         IdentityInserter();\r
16         IdentityInserter(FCPv2 *fcp);\r
17 \r
18         void FCPConnected();\r
19         void FCPDisconnected();\r
20 \r
21         const bool HandleMessage(FCPMessage &message);\r
22 \r
23         void Process();\r
24 \r
25         void RegisterWithThread(FreenetMasterThread *thread);\r
26 \r
27 private:\r
28         void Initialize();\r
29         void CheckForNeededInsert();\r
30         void StartInsert(const long localidentityid);\r
31 \r
32         DateTime m_lastchecked;\r
33 \r
34 };\r
35 \r
36 #endif  // _identity_inserter_\r