lib: removed dead code from Bookmark parser
[barry/progweb.git] / desktop / src / os22.h
blobfdacf0822eddf234bdd243dfeee253c2992a753c
1 ///
2 /// \file os22.h
3 /// Wrapper class for opensync 0.22 syncing behaviour
4 ///
6 /*
7 Copyright (C) 2009-2012, Net Direct Inc. (http://www.netdirect.ca/)
9 This program is free software; you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation; either version 2 of the License, or
12 (at your option) any later version.
14 This program is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
18 See the GNU General Public License in the COPYING file at the
19 root directory of this project for more details.
22 #ifndef __BARRYDESKTOP_OS22_H__
23 #define __BARRYDESKTOP_OS22_H__
25 #include "dlopen.h"
26 #include "osbase.h"
28 namespace OpenSync {
30 class OpenSync22Private;
32 class OpenSync22 : public DlOpen, public OpenSync::API
34 static bool symbols_loaded;
36 OpenSync22Private *m_priv;
38 protected:
39 void SetupEnvironment(OpenSync22Private *p);
41 public:
42 OpenSync22();
43 ~OpenSync22();
45 static bool SymbolsLoaded() { return symbols_loaded; }
48 // Virtual API overrides
51 // Functional abilities information... this does not come from
52 // the engine itself, but is information the osbase library
53 // determines useful for applications to know
54 bool IsSlowSyncSupported() const { return false; }
56 // General engine information
57 const char* GetVersion() const;
58 const char* GetEngineName() const;
59 void GetPluginNames(string_list_type &plugins);
60 void GetFormats(format_list_type &formats);
62 // Information about configured groups
63 void GetGroupNames(string_list_type &groups);
64 void GetMembers(const std::string &group_name,
65 member_list_type &members);
67 // Group configuration
68 void AddGroup(const std::string &group_name);
69 void DeleteGroup(const std::string &group_name);
71 // Plugin configuration helper
72 Converter& GetConverter();
74 // Member configuration
75 long AddMember(const std::string &group_name,
76 const std::string &plugin_name,
77 const std::string &member_name);
78 // DeleteMember() not possible to implement in 0.22
79 bool IsConfigurable(const std::string &group_name,
80 long member_id);
81 std::string GetConfiguration(const std::string &group_name,
82 long member_id);
83 void SetConfiguration(const std::string &group_name,
84 long member_id, const std::string &config_data);
85 void Discover(const std::string &group_name);
87 // Syncing
88 void Sync(const std::string &group_name, SyncStatus &status_callback,
89 Config::pst_type sync_types/* = PST_DO_NOT_SET*/);
92 } // namespace OpenSync
94 #endif