From 2f66785c63e7481662e95d3a871186d6bd99b833 Mon Sep 17 00:00:00 2001 From: Mathew Sutcliffe Date: Tue, 5 May 2015 22:24:28 +0100 Subject: [PATCH] refs #413 Doxygen. --- src/blackmisc/blackmiscfreefunctions.h | 6 ++++++ src/blackmisc/compare.h | 6 ++++++ src/blackmisc/dbus.h | 6 ++++++ src/blackmisc/json.h | 6 ++++++ src/blackmisc/propertyindexvariantmap.h | 3 +++ src/blackmisc/valueobject.h | 7 ++----- src/blackmisc/variant.h | 4 ++++ 7 files changed, 33 insertions(+), 5 deletions(-) diff --git a/src/blackmisc/blackmiscfreefunctions.h b/src/blackmisc/blackmiscfreefunctions.h index d73d39724..03981b72f 100644 --- a/src/blackmisc/blackmiscfreefunctions.h +++ b/src/blackmisc/blackmiscfreefunctions.h @@ -118,6 +118,8 @@ namespace BlackMisc /*! * CRTP class template from which a derived class can inherit common methods dealing with hashing instances by metatuple. + * + * \tparam Derived Must be registered with BLACK_DECLARE_TUPLE_CONVERSION. */ template class HashByTuple : private Private::EncapsulationBreaker @@ -141,6 +143,10 @@ namespace BlackMisc /*! * CRTP class template from which a derived class can inherit string streaming operations. + * + * \tparam Derived Must implement a public method QString convertToQString(bool i18n = false) const. + * + * \see BLACKMISC_DECLARE_USING_MIXIN_STRING */ template class String diff --git a/src/blackmisc/compare.h b/src/blackmisc/compare.h index 90fe2221e..6aebf64a7 100644 --- a/src/blackmisc/compare.h +++ b/src/blackmisc/compare.h @@ -22,6 +22,8 @@ namespace BlackMisc /*! * CRTP class template from which a derived class can inherit operator== implemented using its compare function. + * + * \tparam Derived Must overload a function bool compare(const Derived &, const Derived &) which can be found by ADL. */ template class EqualsByCompare @@ -58,6 +60,8 @@ namespace BlackMisc /*! * CRTP class template from which a derived class can inherit operator< implemented using its compare function. + * + * \tparam Derived Must overload a function bool compare(const Derived &, const Derived &) which can be found by ADL. */ template class LessThanByCompare @@ -107,6 +111,8 @@ namespace BlackMisc /*! * CRTP class template from which a derived class can inherit non-member compare() implemented by metatuple. + * + * \tparam Derived Must be registered with BLACK_DECLARE_TUPLE_CONVERSION. */ template class CompareByTuple : private Private::EncapsulationBreaker diff --git a/src/blackmisc/dbus.h b/src/blackmisc/dbus.h index d0c733909..0924db50e 100644 --- a/src/blackmisc/dbus.h +++ b/src/blackmisc/dbus.h @@ -24,6 +24,8 @@ namespace BlackMisc /*! * CRTP class template which will generate marshalling operators for a derived class with its own marshalling implementation. + * + * \tparam Derived Must implement public methods void marshallToDbus(QDBusArgument &arg) const and void unmarshallFromDbus(const QDBusArgument &arg). */ template class DBusOperators @@ -50,6 +52,10 @@ namespace BlackMisc /*! * CRTP class template from which a derived class can inherit common methods dealing with marshalling instances by metatuple. + * + * \tparam Derived Must be registered with BLACK_DECLARE_TUPLE_CONVERSION. + * + * \see BLACKMISC_DECLARE_USING_MIXIN_DBUS */ template class DBusByTuple : public DBusOperators, private Private::EncapsulationBreaker diff --git a/src/blackmisc/json.h b/src/blackmisc/json.h index da361ab7c..839308e79 100644 --- a/src/blackmisc/json.h +++ b/src/blackmisc/json.h @@ -136,6 +136,8 @@ namespace BlackMisc /*! * CRTP class template which will generate marshalling operators for a derived class with its own marshalling implementation. + * + * \tparam Must implement public methods QJsonObject toJson() const and void convertFromJson(const QJsonObject &json). */ template class JsonOperators @@ -179,6 +181,10 @@ namespace BlackMisc /*! * CRTP class template from which a derived class can inherit common methods dealing with JSON by metatuple. + * + * \tparam Derived Must be registered with BLACK_DECLARE_TUPLE_CONVERSION. + * + * \see BLACKMISC_DECLARE_USING_MIXIN_JSON */ template class JsonByTuple : public JsonOperators, private Private::EncapsulationBreaker diff --git a/src/blackmisc/propertyindexvariantmap.h b/src/blackmisc/propertyindexvariantmap.h index 7d5044d24..7ed2ddaa2 100644 --- a/src/blackmisc/propertyindexvariantmap.h +++ b/src/blackmisc/propertyindexvariantmap.h @@ -29,6 +29,9 @@ namespace BlackMisc { /*! * CRTP class template from which a derived class can inherit property indexing functions. + * + * This is only a placeholder for future support of implementing property indexing through the tuple system. + * At the moment, it just implements the default properties: String, Icon, and Pixmap. */ template class Index diff --git a/src/blackmisc/valueobject.h b/src/blackmisc/valueobject.h index d387a80fa..f5f2ce0fe 100644 --- a/src/blackmisc/valueobject.h +++ b/src/blackmisc/valueobject.h @@ -60,11 +60,8 @@ namespace BlackMisc }; /*! - * Standard implementation of CValueObject using meta tuple system. - * - * This uses policy-based design. Specialize the class template CValueObjectPolicy - * to specify different policy classes. - * + * Mix of the most commonly used mixin classes. + * \see BlackMisc::Mixin * \tparam Derived The class which is inheriting from this one (CRTP). * \tparam Base The class which this one shall inherit from (default is CEmpty, * but this can be changed to create a deeper inheritance hierarchy). diff --git a/src/blackmisc/variant.h b/src/blackmisc/variant.h index 5befc4d80..5e0e12493 100644 --- a/src/blackmisc/variant.h +++ b/src/blackmisc/variant.h @@ -36,6 +36,8 @@ namespace BlackMisc /*! * CRTP class template from which a derived class can inherit common methods dealing with the metatype of the class. + * + * \see BLACKMISC_DECLARE_USING_MIXIN_METATYPE */ template class MetaType @@ -95,6 +97,8 @@ namespace BlackMisc /*! * Variant of MetaType mixin which also registers QList with the type system. + * + * \see BLACKMISC_DECLARE_USING_MIXIN_METATYPE_AND_QLIST */ template class MetaTypeAndQList : public MetaType>