summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Mollekopf <mollekopf@kolabsys.com>2013-09-19 10:42:01 (GMT)
committerChristian Mollekopf <mollekopf@kolabsys.com>2013-09-19 10:42:01 (GMT)
commit3fa9fa63fe6275c7c1633a40319e512ca2121fb0 (patch)
tree0b93eeaaa5bc87f02fe7c2ba566895e7eaa6b960
parent3333595d5f0912dacefb56581ce3d09c88dcd092 (diff)
downloadlibkolabxml-3fa9fa63fe6275c7c1633a40319e512ca2121fb0.tar.gz
cleanup.
-rw-r--r--src/kolabconversions.h22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/kolabconversions.h b/src/kolabconversions.h
index fc511d0..39afc05 100644
--- a/src/kolabconversions.h
+++ b/src/kolabconversions.h
@@ -140,30 +140,30 @@ template <typename T>
std::string serializeObject(const T &, const std::string prod = std::string());
template <>
-std::string serializeObject <Kolab::Configuration> (const Kolab::Configuration &note, const std::string prod)
+std::string serializeObject <Kolab::Configuration> (const Kolab::Configuration &configuration, const std::string prod)
{
try {
- const std::string &uid = getUID(note.uid());
+ const std::string &uid = getUID(configuration.uid());
setCreatedUid(uid);
KolabXSD::Configuration::creation_date_type created(0,0,0,0,0,0);
- if (note.created().isValid()) {
- created = fromDateTime(note.created());
+ if (configuration.created().isValid()) {
+ created = fromDateTime(configuration.created());
} else {
created = fromDateTime(timestamp());
}
KolabXSD::Configuration::last_modification_date_type lastModificationDate(0,0,0,0,0,0);
- if (note.lastModified().isValid()) {
- lastModificationDate = fromDateTime(note.lastModified());
+ if (configuration.lastModified().isValid()) {
+ lastModificationDate = fromDateTime(configuration.lastModified());
} else {
// WARNING("missing last_modification_date, fallback to current timestamp");
lastModificationDate = fromDateTime(timestamp());
}
- KolabXSD::Configuration n(uid, getProductId(prod), created, lastModificationDate, getConfiguratinoType(note.type()));
+ KolabXSD::Configuration n(uid, getProductId(prod), created, lastModificationDate, getConfiguratinoType(configuration.type()));
- switch (note.type()) {
+ switch (configuration.type()) {
case Kolab::Configuration::TypeDictionary: {
- const Kolab::Dictionary &dict = note.dictionary();
+ const Kolab::Dictionary &dict = configuration.dictionary();
n.language(dict.language());
BOOST_FOREACH(const std::string &e, dict.entries()) {
n.e().push_back(e);
@@ -171,10 +171,10 @@ std::string serializeObject <Kolab::Configuration> (const Kolab::Configuration &
}
break;
case Kolab::Configuration::TypeCategoryColor:
- writeColors(n.categorycolor(), note.categoryColor());
+ writeColors(n.categorycolor(), configuration.categoryColor());
break;
case Kolab::Configuration::TypeSnippet: {
- const Kolab::SnippetsCollection &snippets = note.snippets();
+ const Kolab::SnippetsCollection &snippets = configuration.snippets();
n.name(snippets.name());
BOOST_FOREACH(const Kolab::Snippet &s, snippets.snippets()) {
KolabXSD::Snippet::textformat_type type = KolabXSD::Snippet::textformat_type::PLAIN;