3 /// Null wrapper class for when opensync 0.22 is not available
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.
27 /////////////////////////////////////////////////////////////////////////////
28 // OpenSync22 - public members
30 bool OpenSync22::symbols_loaded
= false;
32 OpenSync22::OpenSync22()
34 throw std::runtime_error("OpenSync 0.22 support was not compiled in.");
37 OpenSync22::~OpenSync22()
41 /////////////////////////////////////////////////////////////////////////////
42 // Null implementations
44 const char* OpenSync22::GetVersion() const
49 const char* OpenSync22::GetEngineName() const
54 void OpenSync22::GetPluginNames(string_list_type
&plugins
)
58 void OpenSync22::GetFormats(format_list_type
&formats
)
62 void OpenSync22::GetGroupNames(string_list_type
&groups
)
66 void OpenSync22::GetMembers(const std::string
&group_name
,
67 member_list_type
&members
)
71 void OpenSync22::AddGroup(const std::string
&group_name
)
75 void OpenSync22::DeleteGroup(const std::string
&group_name
)
79 Converter
& OpenSync22::GetConverter()
81 throw std::logic_error("Not supported on this system.");
84 long OpenSync22::AddMember(const std::string
&group_name
,
85 const std::string
&plugin_name
,
86 const std::string
&member_name
)
91 bool OpenSync22::IsConfigurable(const std::string
&group_name
,
97 std::string
OpenSync22::GetConfiguration(const std::string
&group_name
,
103 void OpenSync22::SetConfiguration(const std::string
&group_name
,
104 long member_id
, const std::string
&config_data
)
108 void OpenSync22::Discover(const std::string
&group_name
)
112 void OpenSync22::Sync(const std::string
&group_name
,
113 SyncStatus
&status_callback
,
114 Config::pst_type sync_types
)
118 //////////////////////////////////////////////////////////////////////////////
119 // Null Converter class
121 Converter22::Converter22(OpenSync::API
&api
)
126 bool Converter22::IsPluginSupported(const std::string
&plugin_name
,
127 std::string
*appname
) const
132 Converter::plugin_ptr
Converter22::CreateAndLoadPlugin(const Member
&member
)
134 return Converter::plugin_ptr();
137 std::string
Converter22::GetPluginName(const Config::Barry
&) const
139 throw std::logic_error("Not supported on this system.");
142 std::string
Converter22::GetPluginName(const Config::Evolution
&) const
144 throw std::logic_error("Not supported on this system.");
147 std::string
Converter22::GetPluginName(const Config::Evolution3
&) const
149 throw std::logic_error("Not supported on this system.");
152 std::string
Converter22::GetPluginName(const Config::Google
&) const
154 throw std::logic_error("Not supported on this system.");
157 std::string
Converter22::GetPluginName(const Config::KDEPim
&) const
159 throw std::logic_error("Not supported on this system.");
162 std::string
Converter22::GetPluginName(const Config::Unsupported
&) const
164 throw std::logic_error("Not supported on this system.");
167 bool Converter22::IsConfigured(const Config::Barry
&) const
172 bool Converter22::IsConfigured(const Config::Evolution
&) const
177 bool Converter22::IsConfigured(const Config::Evolution3
&) const
182 bool Converter22::IsConfigured(const Config::Google
&) const
187 bool Converter22::IsConfigured(const Config::KDEPim
&) const
192 bool Converter22::IsConfigured(const Config::Unsupported
&) const
197 Config::pst_type
Converter22::GetSupportedSyncTypes(const Config::Barry
&) const
202 Config::pst_type
Converter22::GetSupportedSyncTypes(const Config::Evolution
&) const
207 Config::pst_type
Converter22::GetSupportedSyncTypes(const Config::Evolution3
&) const
212 Config::pst_type
Converter22::GetSupportedSyncTypes(const Config::Google
&) const
217 Config::pst_type
Converter22::GetSupportedSyncTypes(const Config::KDEPim
&) const
222 Config::pst_type
Converter22::GetSupportedSyncTypes(const Config::Unsupported
&) const
227 void Converter22::Load(Config::Barry
&config
, const Member
&member
)
229 throw std::logic_error("Not supported on this system.");
232 std::string
Converter22::GrabField(const std::string
&cfg
,
233 const std::string
&name
)
235 throw std::logic_error("Not supported on this system.");
238 void Converter22::Load(Config::Evolution
&config
, const Member
&member
)
240 throw std::logic_error("Not supported on this system.");
243 void Converter22::Load(Config::Evolution3
&config
, const Member
&member
)
245 throw std::logic_error("Not supported on this system.");
248 void Converter22::Load(Config::Google
&config
, const Member
&member
)
250 throw std::logic_error("Not supported on this system.");
253 void Converter22::Load(Config::KDEPim
&config
, const Member
&member
)
255 throw std::logic_error("Not supported on this system.");
258 void Converter22::Load(Config::Unsupported
&config
, const Member
&member
)
260 throw std::logic_error("Not supported on this system.");
263 void Converter22::Save(const Config::Barry
&config
, const std::string
&group_name
)
265 throw std::logic_error("Not supported on this system.");
268 void Converter22::Save(const Config::Evolution
&config
, const std::string
&group_name
)
270 throw std::logic_error("Not supported on this system.");
273 void Converter22::Save(const Config::Evolution3
&config
, const std::string
&group_name
)
275 throw std::logic_error("Not supported on this system.");
278 void Converter22::Save(const Config::Google
&config
, const std::string
&group_name
)
280 throw std::logic_error("Not supported on this system.");
283 void Converter22::Save(const Config::KDEPim
&config
, const std::string
&group_name
)
285 throw std::logic_error("Not supported on this system.");
288 void Converter22::Save(const Config::Unsupported
&config
, const std::string
&group_name
)
290 throw std::logic_error("Not supported on this system.");