licensing, initial documentation initiative
This commit is contained in:
parent
f5612dc3c5
commit
763d956bf8
30 changed files with 1178 additions and 383 deletions
10
doc/CMakeLists.txt
Normal file
10
doc/CMakeLists.txt
Normal file
|
@ -0,0 +1,10 @@
|
|||
set(DOXYGEN_GENERATE_HTML YES)
|
||||
set(DOXYGEN_GENERATE_MAN YES)
|
||||
|
||||
doxygen_add_docs(
|
||||
documentation
|
||||
${PROJECT_SOURCE_DIR}/src
|
||||
mainpage.dox
|
||||
ALL
|
||||
COMMENT "Generate man and html pages"
|
||||
)
|
30
doc/mainpage.dox
Normal file
30
doc/mainpage.dox
Normal file
|
@ -0,0 +1,30 @@
|
|||
/*! \mainpage Getting Started
|
||||
*
|
||||
* Everything begins with a data nase represented by the class LMDBAL::Base.
|
||||
* It repesents a collection of key-value storages that are going to be stored in a sigle data base directory.
|
||||
* To create a LMDBAL::Base you need to pick up a name of a directory that is going to be created on your machine.
|
||||
*
|
||||
* LMDBAL::Base creates or opens existing directory with the given name in the location acquired with
|
||||
* <a class="el" href="https://doc.qt.io/qt-6/qstandardpaths.html">QStandardPaths</a>::<a class="el" href="https://doc.qt.io/qt-6/qstandardpaths.html#writableLocation">writableLocation</a>(<a class="el" href="https://doc.qt.io/qt-6/qstandardpaths.html">QStandardPaths</a>::<a class="el" href="https://doc.qt.io/qt-6/qstandardpaths.html#StandardLocation-enum">CacheLocation</a>)
|
||||
* so, the file system destination of your data would depend on the
|
||||
* <a class="el" href="https://doc.qt.io/qt-6/qcoreapplication.html">QCoreApplication</a> configuration of your app.
|
||||
*
|
||||
* After you have created a LMDBAL::Base you probably want to obtain storage handlers.
|
||||
* Now there are only two available types of them: LMDBAL::Storage and LMDBAL::Cache.
|
||||
* The only difference between them is that LMDBAL::Cache additionally stores elements in a
|
||||
* <a class="el" href="https://en.cppreference.com/w/cpp/container/map">std::map</a>
|
||||
* to speed up the access.
|
||||
*
|
||||
* You can obtain handlers by calling LMDBAL::Base::addStorage(const std::string&) or LMDBAL::Base::addCache(const std::string& name).
|
||||
* Note that the handlers still belong to the LMDBAL::Base and it's his responsibility to destroy them.
|
||||
* You are not obliged to save those handlers,
|
||||
* you can obtain them at any time later using methods LMDBAL::Base::getStorage(const std::string&) or LMDBAL::Base::getCache(const std::string&)
|
||||
* calling them with the same template types and names.
|
||||
*
|
||||
* After you have added all the storages you wanted it's time to open the data base with LMDBAL::Base::open().
|
||||
* At this point you are not allowed to add any more storages, otherwise LMDBAL::Opened exception will be thrown.
|
||||
* It's currently the limitation of this little library and I might solve it in the future.
|
||||
* Database will throw no exception if you will try to close the closed LMDBAL::Base or open again already opened one.
|
||||
* Also it will automatically close itself you will try to destoroy onpened LMDBAL::Base.
|
||||
*
|
||||
*/
|
Loading…
Add table
Add a link
Reference in a new issue