From: Bartosz Szatkowski Date: Thu, 12 Aug 2010 06:25:57 +0000 (+0200) Subject: Added docstrings and changed file header (license + file doc) X-Git-Tag: 0.4~56 X-Git-Url: http://vcs.maemo.org/git/?a=commitdiff_plain;h=fc1dc74f67e399fc531dae862ff1e9dc404c2418;p=mdictionary Added docstrings and changed file header (license + file doc) --- diff --git a/trunk/src/base/backbone/backbone.cpp b/trunk/src/base/backbone/backbone.cpp index 97e302f..9e6ce45 100644 --- a/trunk/src/base/backbone/backbone.cpp +++ b/trunk/src/base/backbone/backbone.cpp @@ -18,8 +18,12 @@ Copyright 2010 Comarch S.A. *******************************************************************************/ +/*! /file backbone.cpp +\brief Backbone/core main file \see Backbone -// Created by Bartosz Szatkowski + +\author Bartosz Szatkowski +*/ #include "backbone.h" #include @@ -248,7 +252,6 @@ void Backbone::loadPlugins() { QStringList nameFilter; nameFilter << "*.so"; QStringList files = getFilesFromDir(_pluginPath, nameFilter); - qDebug() << files; foreach(QString file, files) { QPluginLoader loader(file); @@ -316,7 +319,6 @@ void Backbone::loadDicts(QString fileName, bool _default) { if(dryRun) return; QFileInfo file(QDir::toNativeSeparators(fileName)); - qDebug() << file.filePath(); QDir confDir(file.dir()); if(!confDir.exists()){ qDebug() << "Configuration file dosn't exists (" @@ -358,7 +360,6 @@ void Backbone::loadDicts(QString fileName, bool _default) { void Backbone::dictUpdated() { if(dryRun) return; - qDebug() << "UPDATE"; QFileInfo file(QDir::toNativeSeparators(_configPath)); QDir confDir(file.dir()); if(!confDir.exists()) diff --git a/trunk/src/base/backbone/backbone.h b/trunk/src/base/backbone/backbone.h index 685569f..a7dba3e 100644 --- a/trunk/src/base/backbone/backbone.h +++ b/trunk/src/base/backbone/backbone.h @@ -19,7 +19,12 @@ *******************************************************************************/ -// Created by Bartosz Szatkowski +/*! /file backbone.cpp +\brief Backbone/core main header \see Backbone + + +\author Bartosz Szatkowski +*/ #ifndef BACKBONE_H #define BACKBONE_H diff --git a/trunk/src/includes/CommonDictInterface.h b/trunk/src/includes/CommonDictInterface.h index fa094ce..b709454 100644 --- a/trunk/src/includes/CommonDictInterface.h +++ b/trunk/src/includes/CommonDictInterface.h @@ -19,7 +19,11 @@ *******************************************************************************/ -// Created by Bartosz Szatkowski +/*! /file CommonDictInterface.h +\brief Common interface for all dicts and plugins \see CommonDictInterface + +\author Bartosz Szatkowski +*/ #ifndef COMMONDICTINTERFACE_H #define COMMONDICTINTERFACE_H diff --git a/trunk/src/includes/settings.h b/trunk/src/includes/settings.h index ae529f6..a6faba7 100644 --- a/trunk/src/includes/settings.h +++ b/trunk/src/includes/settings.h @@ -19,7 +19,11 @@ *******************************************************************************/ -//Created by Bartosz Szatkowski +/*! /file settings.h +\brief Settings object for pluggins \see Settings + +\author Bartosz Szatkowski +*/ #ifndef SETTINGS_H #define SETTINGS_H @@ -30,7 +34,11 @@ class CommonDictInterface; -//! Plugin specific configuration +/*! Plugins or dictionaries may need to keep some of configuration between + sessions, moreover Backbone or GUI may want store some additional info in + plugin Settings. + + Its important for plugin to store all information given it in Settings.*/ class Settings { public: Settings(){} diff --git a/trunk/src/includes/translation.h b/trunk/src/includes/translation.h index a157c19..8d4332b 100644 --- a/trunk/src/includes/translation.h +++ b/trunk/src/includes/translation.h @@ -19,7 +19,11 @@ *******************************************************************************/ -//Created by Bartosz Szatkowski +/*! /file translation.h +\brief Interface for translation instances \see Translation + +\author Bartosz Szatkowski +*/ #ifndef TRANSLATION_H #define TRANSLATION_H @@ -28,7 +32,9 @@ #include -//! Keeping raw form of translation to be parsed only when needed +/*! Translation is kind of GoF proxy, it stores key:translation pair and + provide it in lazy way -> key is available always, but translation is fetched + as late as possible*/ class Translation { public: //! \return word to be translated diff --git a/trunk/tests/mDictionaryTests/CommonDictInterfaceMock.h b/trunk/tests/mDictionaryTests/CommonDictInterfaceMock.h index 418ffaa..540e85c 100644 --- a/trunk/tests/mDictionaryTests/CommonDictInterfaceMock.h +++ b/trunk/tests/mDictionaryTests/CommonDictInterfaceMock.h @@ -19,7 +19,11 @@ *******************************************************************************/ -// Created by Bartosz Szatkowski +/*! /file CommonDictInterfaceMock.h +\brief Mock for dictionary/plugin behaviour testing + +\author Bartosz Szatkowski +*/ @@ -30,6 +34,8 @@ #include "../../src/includes/CommonDictInterface.h" #include "TranslationMock.h" +/*! CommonDictInterfaceMock simulates dict/plugin behaviour without any + non-testMock dependencies, files, etc.*/ class CommonDictInterfaceMock : public CommonDictInterface { public: diff --git a/trunk/tests/mDictionaryTests/TranslationMock.h b/trunk/tests/mDictionaryTests/TranslationMock.h index 56fdf28..992a309 100644 --- a/trunk/tests/mDictionaryTests/TranslationMock.h +++ b/trunk/tests/mDictionaryTests/TranslationMock.h @@ -18,9 +18,11 @@ Copyright 2010 Comarch S.A. *******************************************************************************/ +/*! /file TranslationMock.cpp +\brief Testing mock for translation object -// Created by Bartosz Szatkowski - +\author Bartosz Szatkowski +*/ @@ -29,6 +31,8 @@ #include "../../src/includes/translation.h" +/*! Translation mock is intended to simulate behaviour of real plugins + translation, but without dependency and any kind of complicated operations*/ class TranslationMock : public Translation { public: diff --git a/trunk/tests/mDictionaryTests/tst_Backbone.cpp b/trunk/tests/mDictionaryTests/tst_Backbone.cpp index 013f98b..9f4f798 100644 --- a/trunk/tests/mDictionaryTests/tst_Backbone.cpp +++ b/trunk/tests/mDictionaryTests/tst_Backbone.cpp @@ -18,10 +18,11 @@ Copyright 2010 Comarch S.A. *******************************************************************************/ +/*! /file tst_backbone.cpp +\brief Backbone tests -// Created by Bartosz Szatkowski - - +\author Bartosz Szatkowski +*/ #include