diff options
author | Vadim Dashevskiy <watcherhd@gmail.com> | 2012-07-28 19:25:08 +0000 |
---|---|---|
committer | Vadim Dashevskiy <watcherhd@gmail.com> | 2012-07-28 19:25:08 +0000 |
commit | 66526765714b08969548a414d3fa87dbe333242d (patch) | |
tree | d3fc2027140f97edfdfc5023e70ff8b4db920c11 /plugins/!NotAdopted/XSoundNotify/SoundNotifyDataStorage.h | |
parent | 3ccd712341ed9e76252bd595c5a797d6c8ea8992 (diff) |
"!Deprecated" folders moved from root directory to plugins
git-svn-id: http://svn.miranda-ng.org/main/trunk@1230 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/!NotAdopted/XSoundNotify/SoundNotifyDataStorage.h')
-rw-r--r-- | plugins/!NotAdopted/XSoundNotify/SoundNotifyDataStorage.h | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/plugins/!NotAdopted/XSoundNotify/SoundNotifyDataStorage.h b/plugins/!NotAdopted/XSoundNotify/SoundNotifyDataStorage.h new file mode 100644 index 0000000000..7dbf03c494 --- /dev/null +++ b/plugins/!NotAdopted/XSoundNotify/SoundNotifyDataStorage.h @@ -0,0 +1,34 @@ +#ifndef _XSN_DATA_STORAGE
+#define _XSN_DATA_STORAGE
+
+#include "SoundNotifyData.h"
+#include <newpluginapi.h>
+#include <boost/function.hpp>
+
+class SoundNotifyDataStorage
+{
+public:
+ SoundNotifyDataStorage(PLUGINLINK * pl);
+
+ void init();
+ void commit();
+
+ ProtocolTable & getData();
+
+protected:
+ void addContact(HANDLE contact);
+ xsn_string getContactId(HANDLE contact, const ModuleString & module, const ProtocolString & proto);
+ void registerProtocols();
+
+private:
+ PLUGINLINK * pluginLink;
+
+ ProtocolTable _protocolTable;
+ ModuleConvertTable _moduleTable;
+
+ typedef boost::function<xsn_string (HANDLE contact, const ModuleString & module)> getContactIdFunc;
+ typedef std::unordered_map<ProtocolString, getContactIdFunc> RegisteredProtocols;
+ RegisteredProtocols _registeredProtocols;
+};
+
+#endif
|