Add API doc
This commit is contained in:
parent
c6f12b31f9
commit
dcfadcc5d8
|
@ -27,6 +27,10 @@ set(TEST_SRC_FILES
|
||||||
tests/passwordfiletests.cpp
|
tests/passwordfiletests.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
|
set(DOC_FILES
|
||||||
|
README.md
|
||||||
|
)
|
||||||
|
|
||||||
# meta data
|
# meta data
|
||||||
set(META_PROJECT_NAME passwordfile)
|
set(META_PROJECT_NAME passwordfile)
|
||||||
set(META_PROJECT_VARNAME PASSWORD_FILE)
|
set(META_PROJECT_VARNAME PASSWORD_FILE)
|
||||||
|
@ -36,10 +40,10 @@ set(META_APP_URL "https://github.com/${META_APP_AUTHOR}/${META_PROJECT_NAME}")
|
||||||
set(META_APP_DESCRIPTION "C++ library to read/write passwords from/to encrypted files.")
|
set(META_APP_DESCRIPTION "C++ library to read/write passwords from/to encrypted files.")
|
||||||
set(META_VERSION_MAJOR 3)
|
set(META_VERSION_MAJOR 3)
|
||||||
set(META_VERSION_MINOR 1)
|
set(META_VERSION_MINOR 1)
|
||||||
set(META_VERSION_PATCH 1)
|
set(META_VERSION_PATCH 2)
|
||||||
|
|
||||||
# find c++utilities
|
# find c++utilities
|
||||||
find_package(c++utilities 3.3.0 REQUIRED)
|
find_package(c++utilities 4.0.0 REQUIRED)
|
||||||
use_cpp_utilities()
|
use_cpp_utilities()
|
||||||
|
|
||||||
# find zlib
|
# find zlib
|
||||||
|
@ -57,3 +61,4 @@ include(BasicConfig)
|
||||||
include(WindowsResources)
|
include(WindowsResources)
|
||||||
include(LibraryTarget)
|
include(LibraryTarget)
|
||||||
include(TestTarget)
|
include(TestTarget)
|
||||||
|
include(Doxygen)
|
||||||
|
|
|
@ -245,6 +245,7 @@ void PasswordFile::load()
|
||||||
/*!
|
/*!
|
||||||
* \brief Writes the current root entry to the file.
|
* \brief Writes the current root entry to the file.
|
||||||
* \param useEncryption Specifies whether encryption should be used.
|
* \param useEncryption Specifies whether encryption should be used.
|
||||||
|
* \param useCompression Specifies whether compression should be used.
|
||||||
* \throws Throws ios_base::failure when an IO error occurs.
|
* \throws Throws ios_base::failure when an IO error occurs.
|
||||||
* \throws Throws runtime_error when no root entry is present.
|
* \throws Throws runtime_error when no root entry is present.
|
||||||
* \throws Throws Io::CryptoException when a decryption error occurs.
|
* \throws Throws Io::CryptoException when a decryption error occurs.
|
||||||
|
|
|
@ -13,6 +13,9 @@ using namespace Io;
|
||||||
|
|
||||||
using namespace CPPUNIT_NS;
|
using namespace CPPUNIT_NS;
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief The PasswordFileTests class tests the Io::PasswordFile class.
|
||||||
|
*/
|
||||||
class PasswordFileTests : public TestFixture
|
class PasswordFileTests : public TestFixture
|
||||||
{
|
{
|
||||||
CPPUNIT_TEST_SUITE(PasswordFileTests);
|
CPPUNIT_TEST_SUITE(PasswordFileTests);
|
||||||
|
|
|
@ -4,10 +4,19 @@
|
||||||
#include <openssl/err.h>
|
#include <openssl/err.h>
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief Contains utility classes and functions.
|
||||||
|
*/
|
||||||
namespace Util {
|
namespace Util {
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief Contains functions utilizing the usage of OpenSSL.
|
||||||
|
*/
|
||||||
namespace OpenSsl {
|
namespace OpenSsl {
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief Initializes OpenSSL.
|
||||||
|
*/
|
||||||
void init()
|
void init()
|
||||||
{
|
{
|
||||||
// load the human readable error strings for libcrypto
|
// load the human readable error strings for libcrypto
|
||||||
|
@ -18,6 +27,9 @@ void init()
|
||||||
OPENSSL_config(NULL);
|
OPENSSL_config(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief Cleans resources of OpenSSL.
|
||||||
|
*/
|
||||||
void clean()
|
void clean()
|
||||||
{
|
{
|
||||||
// removes all digests and ciphers
|
// removes all digests and ciphers
|
||||||
|
|
Loading…
Reference in New Issue