aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2006-04-20 00:48:25 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2006-04-20 00:48:25 +0000
commit6bdd6a584971bb3dbc151720ca60063f8b5e9188 (patch)
tree3a5edfe8456670dc9c7878ccabeda65038ae92a1
parent96dd07171192274afe63c1969f4db3253c892add (diff)
downloadpaludis-6bdd6a584971bb3dbc151720ca60063f8b5e9188.tar.gz
paludis-6bdd6a584971bb3dbc151720ca60063f8b5e9188.tar.xz
Docs update for paludis/util/
-rw-r--r--doc/doc_main.doxygen131
-rw-r--r--paludis/util/attributes.hh6
-rw-r--r--paludis/util/collection.hh11
-rw-r--r--paludis/util/compare.hh16
-rw-r--r--paludis/util/composite_pattern.hh4
-rw-r--r--paludis/util/container_entry.hh6
-rw-r--r--paludis/util/counted_ptr.hh37
-rw-r--r--paludis/util/counted_ptr_TEST.cc103
-rw-r--r--paludis/util/deleter.cc6
-rw-r--r--paludis/util/deleter.hh6
-rw-r--r--paludis/util/deleter_TEST.cc36
-rw-r--r--paludis/util/destringify.cc6
-rw-r--r--paludis/util/destringify.hh17
-rw-r--r--paludis/util/destringify_TEST.cc10
-rw-r--r--paludis/util/dir_iterator.cc2
-rw-r--r--paludis/util/dir_iterator.hh8
-rw-r--r--paludis/util/dir_iterator_TEST.cc6
-rw-r--r--paludis/util/exception.cc6
-rw-r--r--paludis/util/exception.hh20
-rw-r--r--paludis/util/files.m49
-rw-r--r--paludis/util/fs_entry.cc2
-rw-r--r--paludis/util/fs_entry.hh20
-rw-r--r--paludis/util/fs_entry_TEST.cc15
-rw-r--r--paludis/util/instantiation_policy.cc21
-rw-r--r--paludis/util/instantiation_policy.hh41
-rw-r--r--paludis/util/instantiation_policy_TEST.cc75
-rw-r--r--paludis/util/is_const.cc21
-rw-r--r--paludis/util/is_const.hh60
-rw-r--r--paludis/util/is_const_TEST.cc58
-rw-r--r--paludis/util/is_file_with_extension.cc2
-rw-r--r--paludis/util/is_file_with_extension.hh4
-rw-r--r--paludis/util/is_file_with_extension_TEST.cc10
-rw-r--r--paludis/util/iterator.hh30
-rw-r--r--paludis/util/iterator_TEST.cc22
-rw-r--r--paludis/util/join.cc21
-rw-r--r--paludis/util/join.hh10
-rw-r--r--paludis/util/join_TEST.cc9
-rw-r--r--paludis/util/log.cc8
-rw-r--r--paludis/util/log.hh10
-rw-r--r--paludis/util/log_TEST.cc8
-rw-r--r--paludis/util/match_sequence.cc6
-rw-r--r--paludis/util/match_sequence.hh35
-rw-r--r--paludis/util/match_sequence_TEST.cc11
-rw-r--r--paludis/util/private_implementation_pattern.cc21
-rw-r--r--paludis/util/private_implementation_pattern.hh10
-rw-r--r--paludis/util/pstream.cc6
-rw-r--r--paludis/util/pstream.hh15
-rw-r--r--paludis/util/pstream_TEST.cc11
-rw-r--r--paludis/util/random.cc6
-rw-r--r--paludis/util/random.hh10
-rw-r--r--paludis/util/save.cc21
-rw-r--r--paludis/util/save.hh4
-rw-r--r--paludis/util/save_TEST.cc5
-rw-r--r--paludis/util/smart_record.hh.m451
-rw-r--r--paludis/util/smart_record_TEST.cc6
-rw-r--r--paludis/util/stringify.hh14
-rw-r--r--paludis/util/stringify_TEST.cc12
-rw-r--r--paludis/util/strip.cc6
-rw-r--r--paludis/util/strip.hh24
-rw-r--r--paludis/util/strip_TEST.cc10
-rw-r--r--paludis/util/system.cc11
-rw-r--r--paludis/util/system.hh33
-rw-r--r--paludis/util/system_TEST.cc18
-rw-r--r--paludis/util/test_extras.cc6
-rw-r--r--paludis/util/tokeniser.hh24
-rw-r--r--paludis/util/tokeniser_TEST.cc7
-rw-r--r--paludis/util/validated.hh10
-rw-r--r--paludis/util/validated_TEST.cc6
-rw-r--r--paludis/util/virtual_constructor.hh16
-rw-r--r--paludis/util/virtual_constructor_TEST.cc27
-rw-r--r--paludis/util/visitor.hh26
-rw-r--r--paludis/util/visitor_TEST.cc7
72 files changed, 854 insertions, 514 deletions
diff --git a/doc/doc_main.doxygen b/doc/doc_main.doxygen
index 677809e..4944e4c 100644
--- a/doc/doc_main.doxygen
+++ b/doc/doc_main.doxygen
@@ -180,3 +180,134 @@
* \ingroup grpdepparser
*/
+// ----- grplibpaludisutil Subgroups -----
+
+/** \defgroup grpcollections Collections
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grpcompare Comparisons
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grppatterns Patterns
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grpcontainerentries Container entries
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grppointers Pointers
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grpdeleter Deleter
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grpfilesystem Filesystem
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grpstrings Strings
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grplog Log
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grplog System
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grprandom Random numbers
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grpsave Save
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grprecords Records
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+/** \defgroup grpvalidated Validated
+ *
+ * \ingroup grplibpaludisutil
+ */
+
+// ----- grppatterns Subgroups -----
+
+/** \defgroup grpcomposite Composite pattern
+ *
+ * \ingroup grppatterns
+ */
+
+/** \defgroup grpinstance Instance patterns
+ *
+ * \ingroup grppointers
+ */
+
+/** \defgroup grppimp Private implementation pattern
+ *
+ * \ingroup grppatterns
+ */
+
+/** \defgroup grpvc Virtual constructor
+ *
+ * \ingroup grppatterns
+ */
+
+/** \defgroup grpvisitor Visitor
+ *
+ * \ingroup grpvisitor
+ */
+
+// ----- grpstrings Subgroups -----
+
+/** \defgroup grpdestringify Destringify
+ *
+ * \ingroup grpstrings
+ */
+
+/** \defgroup grpjoin Join
+ *
+ * \ingroup grpstrings
+ */
+
+/** \defgroup grpstringify Stringify
+ *
+ * \ingroup grpstrings
+ */
+
+/** \defgroup grptokenise Tokenise
+ *
+ * \ingroup grpstrings
+ */
+
+/** \defgroup grpmatch Match
+ *
+ * \ingroup grpstrings
+ */
+
+/** \defgroup grpstrippers Strippers
+ *
+ * \ingroup grpstrings
+ */
+
diff --git a/paludis/util/attributes.hh b/paludis/util/attributes.hh
index f4d1d72..711a0a3 100644
--- a/paludis/util/attributes.hh
+++ b/paludis/util/attributes.hh
@@ -23,21 +23,21 @@
/** \file
* Declare the PALUDIS_ATTRIBUTE macro.
*
- * \ingroup Utility
+ * \ingroup grplibpaludisutil
*/
/** \def PALUDIS_ATTRIBUTE
* If we're using a recent GCC or ICC, expands to __attribute__, otherwise
* discards its arguments.
*
- * \ingroup Utility
+ * \ingroup grplibpaludisutil
*/
/** \def PALUDIS_CAN_USE_ATTRIBUTE
* Defined if we can rely upon PALUDIS_ATTRIBUTE working (for example, for
* weak).
*
- * \ingroup Utility
+ * \ingroup grplibpaludisutil
*/
#if (defined(__GNUC__) || defined(DOXYGEN))
diff --git a/paludis/util/collection.hh b/paludis/util/collection.hh
index aff5056..e8d615f 100644
--- a/paludis/util/collection.hh
+++ b/paludis/util/collection.hh
@@ -27,11 +27,20 @@
#include <paludis/util/counted_ptr.hh>
#include <paludis/util/instantiation_policy.hh>
+/** \file
+ * Various wrappers around collections of items, for convenience and
+ * avoiding passing around huge containers.
+ *
+ * \ingroup grpcollections
+ */
+
namespace paludis
{
/**
* Wrapper around a std::list of a particular item. Multiple items
* with the same value are disallowed.
+ *
+ * \ingroup grpcollections
*/
template <typename T_>
class SequentialCollection :
@@ -119,6 +128,8 @@ namespace paludis
/**
* Wrapper around a std::set of a particular item. May be changed at some
* point to support template find.
+ *
+ * \ingroup grpcollections
*/
template <typename T_>
class SortedCollection :
diff --git a/paludis/util/compare.hh b/paludis/util/compare.hh
index 3784251..225fd3e 100644
--- a/paludis/util/compare.hh
+++ b/paludis/util/compare.hh
@@ -27,7 +27,7 @@
/** \file
* Declarations for the compare functions.
*
- * \ingroup Utility
+ * \ingroup grpcompare
*/
namespace paludis
@@ -37,7 +37,7 @@ namespace paludis
*
* \retval -1 if t1 < t2, 1 if t1 > t2, 0 otherwise.
*
- * \ingroup Utility
+ * \ingroup grpcompare
*/
inline int compare(int t1, int t2) PALUDIS_ATTRIBUTE((always_inline));
@@ -56,7 +56,7 @@ namespace paludis
*
* \retval -1 if t1 < t2, 1 if t1 > t2, 0 otherwise.
*
- * \ingroup Utility
+ * \ingroup grpcompare
*/
inline int compare(unsigned t1, unsigned t2) PALUDIS_ATTRIBUTE((always_inline));
@@ -75,7 +75,7 @@ namespace paludis
*
* \retval -1 if t1 < t2, 1 if t1 > t2, 0 otherwise.
*
- * \ingroup Utility
+ * \ingroup grpcompare
*/
inline int long compare(unsigned long t1, unsigned long t2) PALUDIS_ATTRIBUTE((always_inline));
@@ -94,7 +94,7 @@ namespace paludis
*
* \retval -1 if t1 < t2, 1 if t1 > t2, 0 otherwise.
*
- * \ingroup Utility
+ * \ingroup grpcompare
*/
inline int compare(long t1, long t2) PALUDIS_ATTRIBUTE((always_inline));
@@ -113,7 +113,7 @@ namespace paludis
*
* \retval -1 if t1 < t2, 1 if t1 > t2, 0 otherwise.
*
- * \ingroup Utility
+ * \ingroup grpcompare
*/
template <typename T_>
inline int compare(
@@ -140,7 +140,7 @@ namespace paludis
*
* \retval -1 if t1 < t2, 1 if t1 > t2, 0 otherwise.
*
- * \ingroup Utility
+ * \ingroup grpcompare
*/
template <typename T_, typename U_>
inline int compare(
@@ -155,7 +155,7 @@ namespace paludis
*
* \retval -1 if t1 < t2, 1 if t1 > t2, 0 otherwise.
*
- * \ingroup Utility
+ * \ingroup grpcompare
*/
template <typename T_>
int compare(
diff --git a/paludis/util/composite_pattern.hh b/paludis/util/composite_pattern.hh
index 3238b3e..215bfb3 100644
--- a/paludis/util/composite_pattern.hh
+++ b/paludis/util/composite_pattern.hh
@@ -23,7 +23,7 @@
/** \file
* Declarations for the Composite template class.
*
- * \ingroup Utility
+ * \ingroup grpcomposite
*/
namespace paludis
@@ -32,7 +32,7 @@ namespace paludis
* A Composite class represents both a class and a collection of
* child instances of the same class.
*
- * \ingroup Utility
+ * \ingroup grpcomposite
*/
template <typename ChildClass_, typename CompositeClass_ = ChildClass_>
class Composite
diff --git a/paludis/util/container_entry.hh b/paludis/util/container_entry.hh
index 2f7cfda..737033a 100644
--- a/paludis/util/container_entry.hh
+++ b/paludis/util/container_entry.hh
@@ -25,7 +25,7 @@
/** \file
* Declarations for the ContainerEntry class.
*
- * \ingroup Utility
+ * \ingroup grpcontainerentries
*/
namespace paludis
@@ -34,7 +34,7 @@ namespace paludis
* Hold an entry in a container for as long as our ContainerEntry instance
* is in scope (RAII, see \ref EffCpp item 13 or \ref TCppPL section 14.4).
*
- * \ingroup Utility
+ * \ingroup grpcontainerentries
*/
template <typename Container_>
struct ContainerEntry;
@@ -44,7 +44,7 @@ namespace paludis
* is in scope (RAII, see \ref EffCpp item 13 or \ref TCppPL section 14.4;
* partial specialisation for std::list).
*
- * \ingroup Utility
+ * \ingroup grpcontainerentries
*/
template <typename Item_>
class ContainerEntry<std::list<Item_> >
diff --git a/paludis/util/counted_ptr.hh b/paludis/util/counted_ptr.hh
index a0289a8..c433aa6 100644
--- a/paludis/util/counted_ptr.hh
+++ b/paludis/util/counted_ptr.hh
@@ -27,8 +27,7 @@
/** \file
* Declaration for the CountedPtr template class.
*
- * \ingroup Pointer
- * \ingroup Exception
+ * \ingroup grppointers
*/
namespace paludis
@@ -36,8 +35,8 @@ namespace paludis
/**
* Thrown when a CountedPtr check fails.
*
- * \ingroup Pointer
- * \ingroup Exception
+ * \ingroup grppointers
+ * \ingroup grpexceptions
*/
class CountedPtrError : public Exception
{
@@ -51,14 +50,14 @@ namespace paludis
/**
* Contains CountedPtr count policies.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
namespace count_policy
{
/**
* CountedPtr policy: reference counts are stored separately.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
struct ExternalCountTag
{
@@ -68,7 +67,7 @@ namespace paludis
* CountedPtr policy: reference counts are stored by the class via the
* Counted subclass.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
struct InternalCountTag
{
@@ -78,14 +77,14 @@ namespace paludis
/**
* Contains CountedPtr dereference policies.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
namespace dereference_policy
{
/**
* CountedPtr dereferences are not checked.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
struct UncheckedDereferenceTag
{
@@ -95,7 +94,7 @@ namespace paludis
* CountedPtr dereferences are checked, and a CountedPtrError is
* thrown for 0 dereferences.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
struct CheckedDereferenceTag
{
@@ -105,18 +104,22 @@ namespace paludis
/**
* CountedPtr internals.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
namespace counted_ptr_internals
{
/**
* Base class for CountedPtr.
+ *
+ * \ingroup grppointers
*/
template <typename T_, typename DereferencePolicy_>
class CountedPtrBase;
/**
* Base class for CountedPtr (specialisation for UncheckedDereferenceTag).
+ *
+ * \ingroup grppointers
*/
template <typename T_>
class CountedPtrBase<T_, dereference_policy::UncheckedDereferenceTag> :
@@ -217,6 +220,8 @@ namespace paludis
}
/**
* Base class for CountedPtr (specialisation for CheckedDereferenceTag).
+ *
+ * \ingroup grppointers
*/
template <typename T_>
class CountedPtrBase<T_, dereference_policy::CheckedDereferenceTag> :
@@ -328,7 +333,7 @@ namespace paludis
/**
* Reference counted pointer class.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
template <typename T_, typename CountPolicy_ = count_policy::InternalCountTag,
typename DereferencePolicy_ = dereference_policy::UncheckedDereferenceTag>
@@ -337,7 +342,7 @@ namespace paludis
/**
* Base for an internal counted class.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
template <typename T_, typename DereferencePolicy_ = dereference_policy::UncheckedDereferenceTag>
class InternalCounted;
@@ -345,7 +350,7 @@ namespace paludis
/**
* Reference counted pointer class (specialisation for ExternalCountTag).
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
template <typename T_, typename DereferencePolicy_>
class CountedPtr<T_, count_policy::ExternalCountTag, DereferencePolicy_> :
@@ -446,7 +451,7 @@ namespace paludis
/**
* Reference counted pointer class (specialisation for InternalCountTag).
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
template <typename T_, typename DereferencePolicy_>
class CountedPtr<T_, count_policy::InternalCountTag, DereferencePolicy_> :
@@ -549,7 +554,7 @@ namespace paludis
/**
* Base class for an internally counted class.
*
- * \ingroup Pointer
+ * \ingroup grppointers
*/
template <typename T_, typename DereferencePolicy_>
class InternalCounted :
diff --git a/paludis/util/counted_ptr_TEST.cc b/paludis/util/counted_ptr_TEST.cc
index 7ae5844..b07cb29 100644
--- a/paludis/util/counted_ptr_TEST.cc
+++ b/paludis/util/counted_ptr_TEST.cc
@@ -28,58 +28,63 @@ using namespace paludis;
/** \file
* Test cases for counted_ptr.hh .
*
- * \ingroup Test
- * \ingroup Pointer
+ * \ingroup grptestcases
*/
-#ifndef DOXYGEN
-class MyClass : public InternalCounted<MyClass>
+namespace
{
- private:
- int _v;
-
- public:
- MyClass(const int v) :
- _v(v)
- {
- }
-
- MyClass(const MyClass & other) :
- InternalCounted<MyClass>(),
- _v(other._v)
- {
- }
-
- const MyClass & operator= (const MyClass & other)
- {
- _v = other._v;
- return *this;
- }
-
- bool operator== (const MyClass & other) const
- {
- return _v == other._v;
- }
-
- int value() const
- {
- return _v;
- }
-};
+ /**
+ * Test InternalCounted class.
+ *
+ * \ingroup grptestcases
+ */
+ class MyClass : public InternalCounted<MyClass>
+ {
+ private:
+ int _v;
+
+ public:
+ MyClass(const int v) :
+ _v(v)
+ {
+ }
+
+ MyClass(const MyClass & other) :
+ InternalCounted<MyClass>(),
+ _v(other._v)
+ {
+ }
+
+ const MyClass & operator= (const MyClass & other)
+ {
+ _v = other._v;
+ return *this;
+ }
+
+ bool operator== (const MyClass & other) const
+ {
+ return _v == other._v;
+ }
+
+ int value() const
+ {
+ return _v;
+ }
+ };
+}
std::ostream & operator<< (std::ostream & s, const MyClass & c)
{
s << c.value();
return s;
}
-#endif
namespace test_cases
{
/**
* \test CountedPtr creation tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrCreationTests : TestCase
{
@@ -95,7 +100,7 @@ namespace test_cases
/**
* \test CountedPtr dereference tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrDereferenceTests : TestCase
{
@@ -115,7 +120,7 @@ namespace test_cases
/**
* \test CountedPtr copy tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrCopyTests : TestCase
{
@@ -135,7 +140,7 @@ namespace test_cases
/**
* \test CountedPtr dereference-assign tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrDereferenceAssignTests : TestCase
{
@@ -165,7 +170,7 @@ namespace test_cases
/**
* \test CountedPtr assign value tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrAssignValueTests : TestCase
{
@@ -188,7 +193,7 @@ namespace test_cases
/**
* \test CountedPtr assign pointer tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrAssignPointerTests : TestCase
{
@@ -220,7 +225,7 @@ namespace test_cases
/**
* \test CountedPtr internal creation tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrInternalCreationTests : TestCase
{
@@ -235,7 +240,7 @@ namespace test_cases
/**
* \test CountedPtr internal dereference tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrInternalDereferenceTests : TestCase
{
@@ -254,7 +259,7 @@ namespace test_cases
/**
* \test CountedPtr internal copy tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrInternalCopyTests : TestCase
{
@@ -274,7 +279,7 @@ namespace test_cases
/**
* \test CountedPtr internal dereference-assign tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrInternalDereferenceAssignTests : TestCase
{
@@ -305,7 +310,7 @@ namespace test_cases
/**
* \test CountedPtr internal assign value tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrInternalAssignValueTests : TestCase
{
@@ -329,7 +334,7 @@ namespace test_cases
/**
* \test CountedPtr internal assign pointer tests.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrInternalAssignPointerTests : TestCase
{
@@ -362,7 +367,7 @@ namespace test_cases
/**
* \test CountedPtr zero dereferences.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CountedPtrZeroDeferenceTests : TestCase
{
diff --git a/paludis/util/deleter.cc b/paludis/util/deleter.cc
index e8e4f2d..76e7ff7 100644
--- a/paludis/util/deleter.cc
+++ b/paludis/util/deleter.cc
@@ -19,6 +19,12 @@
#include <paludis/util/deleter.hh>
+/** \file
+ * Implementation for Deleter.
+ *
+ * \ingroup grpdeleter
+ */
+
using namespace paludis;
Deleter::Deleter()
diff --git a/paludis/util/deleter.hh b/paludis/util/deleter.hh
index 3b5bf76..8ae9bee 100644
--- a/paludis/util/deleter.hh
+++ b/paludis/util/deleter.hh
@@ -23,7 +23,7 @@
/** \file
* Declarations for the Deleter class.
*
- * \ingroup Utility
+ * \ingroup grpdeleter
*/
namespace paludis
@@ -31,7 +31,9 @@ namespace paludis
/**
* A Deleter is a functor that deletes something.
*
- * \ingroup Utility
+ * See \ref EffSTL item 7.
+ *
+ * \ingroup grpdeleter
*/
class Deleter
{
diff --git a/paludis/util/deleter_TEST.cc b/paludis/util/deleter_TEST.cc
index 780cb58..05b6006 100644
--- a/paludis/util/deleter_TEST.cc
+++ b/paludis/util/deleter_TEST.cc
@@ -29,34 +29,40 @@ using namespace paludis;
/** \file
* Test cases for deleter.hh.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
-#ifndef DOXYGEN
-struct MyClass
+namespace
{
- static int instances;
-
- MyClass()
+ /**
+ * Test class to be deleted, with an instance count.
+ *
+ * \ingroup grptestcases
+ */
+ struct MyClass
{
- ++instances;
- }
+ static int instances;
- ~MyClass()
- {
- --instances;
- }
-};
+ MyClass()
+ {
+ ++instances;
+ }
+
+ ~MyClass()
+ {
+ --instances;
+ }
+ };
+}
int MyClass::instances = 0;
-#endif
namespace test_cases
{
/**
* Test Deleter.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct DeleterTest : TestCase
{
diff --git a/paludis/util/destringify.cc b/paludis/util/destringify.cc
index 0037ef6..f601261 100644
--- a/paludis/util/destringify.cc
+++ b/paludis/util/destringify.cc
@@ -20,6 +20,12 @@
#include <paludis/util/destringify.hh>
+/** \file
+ * Implementation for DestringifyError.
+ *
+ * \ingroup grpdestringify
+ */
+
using namespace paludis;
DestringifyError::DestringifyError(const std::string & str) throw () :
diff --git a/paludis/util/destringify.hh b/paludis/util/destringify.hh
index 2eb1379..183d305 100644
--- a/paludis/util/destringify.hh
+++ b/paludis/util/destringify.hh
@@ -26,12 +26,17 @@
/** \file
* Destringify functions.
+ *
+ * \ingroup grpdestringify
*/
namespace paludis
{
/**
* Default exception type thrown by destringify when it fails.
+ *
+ * \ingroup grpdestringify
+ * \ingroup grpexceptions
*/
class DestringifyError : public Exception
{
@@ -44,11 +49,15 @@ namespace paludis
/**
* For internal use by destringify.
+ *
+ * \ingroup grpdestringify
*/
namespace destringify_internals
{
/**
* Basic destringifier.
+ *
+ * \ingroup grpdestringify
*/
template <typename Type_, typename Exception_>
struct Destringifier
@@ -69,6 +78,8 @@ namespace paludis
/**
* Specialised destringify for std::string.
+ *
+ * \ingroup grpdestringify
*/
template <typename Exception_>
struct Destringifier<std::string, Exception_>
@@ -84,6 +95,8 @@ namespace paludis
/**
* Specialised destringify for bool.
+ *
+ * \ingroup grpdestringify
*/
template <typename Exception_>
struct Destringifier<bool, Exception_>
@@ -114,6 +127,8 @@ namespace paludis
/**
* Extract a value of some type from a string.
+ *
+ * \ingroup grpdestringify
*/
template <typename Type_, typename Exception_>
Type_ destringify(const std::string & s)
@@ -127,6 +142,8 @@ namespace paludis
/**
* Extract a value of some type from a string (overload with a default
* exception of DestringifyError).
+ *
+ * \ingroup grpdestringify
*/
template <typename Type_>
Type_ destringify(const std::string & s)
diff --git a/paludis/util/destringify_TEST.cc b/paludis/util/destringify_TEST.cc
index 945ab22..8ea4cd6 100644
--- a/paludis/util/destringify_TEST.cc
+++ b/paludis/util/destringify_TEST.cc
@@ -28,7 +28,7 @@ using namespace paludis;
/** \file
* Test cases for destringify.hh
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace test_cases
@@ -36,7 +36,7 @@ namespace test_cases
/** \test
* Test destringify for integers.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct DestringifyIntTests : TestCase
{
@@ -56,7 +56,7 @@ namespace test_cases
/** \test
* Test destringify for floats.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct DestringifyFloatTests : TestCase
{
@@ -75,7 +75,7 @@ namespace test_cases
/** \test
* Test destringify for strings.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct DestringifyStringTests : TestCase
{
@@ -91,7 +91,7 @@ namespace test_cases
/** \test
* Test destringify for bool.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct DestringifyBoolTests : TestCase
{
diff --git a/paludis/util/dir_iterator.cc b/paludis/util/dir_iterator.cc
index a8f0580..4e94931 100644
--- a/paludis/util/dir_iterator.cc
+++ b/paludis/util/dir_iterator.cc
@@ -26,7 +26,7 @@
/** \file
* Implementation of paludis::DirIterator.
*
- * \ingroup Filesystem
+ * \ingroup grpfilesystem
*/
using namespace paludis;
diff --git a/paludis/util/dir_iterator.hh b/paludis/util/dir_iterator.hh
index cdfe154..43062ea 100644
--- a/paludis/util/dir_iterator.hh
+++ b/paludis/util/dir_iterator.hh
@@ -28,8 +28,7 @@
/** \file
* Declarations for paludis::DirIterator.
*
- * \ingroup Filesystem
- * \ingroup Exception
+ * \ingroup grpfilesystem
*/
namespace paludis
@@ -37,7 +36,8 @@ namespace paludis
/**
* Raised when a directory open fails.
*
- * \ingroup Exception
+ * \ingroup grpfilesystem
+ * \ingroup grpexceptions
*/
class DirOpenError : public FSError
{
@@ -55,7 +55,7 @@ namespace paludis
* if it turns out that it's quicker to use opendir and seekdir for each
* instance.
*
- * \ingroup Filesystem
+ * \ingroup grpfilesystem
*/
class DirIterator : public std::iterator<std::forward_iterator_tag, FSEntry>
{
diff --git a/paludis/util/dir_iterator_TEST.cc b/paludis/util/dir_iterator_TEST.cc
index 022e0cf..217f48a 100644
--- a/paludis/util/dir_iterator_TEST.cc
+++ b/paludis/util/dir_iterator_TEST.cc
@@ -27,13 +27,15 @@ using namespace test;
/** \file
* Test cases for dir_iterator.hh.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace test_cases
{
/**
* \test Test DirIterator construction and manipulation.
+ *
+ * \ingroup grptestcases
*/
struct DirIteratorManipulationTest : TestCase
{
@@ -52,6 +54,8 @@ namespace test_cases
/**
* \test Test DirIterator iterating abilities
+ *
+ * \ingroup grptestcases
*/
struct DirIteratorIterateTest : TestCase
{
diff --git a/paludis/util/exception.cc b/paludis/util/exception.cc
index 0332240..07d787e 100644
--- a/paludis/util/exception.cc
+++ b/paludis/util/exception.cc
@@ -19,6 +19,12 @@
#include <paludis/util/exception.hh>
+/** \file
+ * Exception class implementations.
+ *
+ * \ingroup grpexceptions
+ */
+
using namespace paludis;
Exception::Exception(const std::string & message) throw () :
diff --git a/paludis/util/exception.hh b/paludis/util/exception.hh
index c343634..6f93ba8 100644
--- a/paludis/util/exception.hh
+++ b/paludis/util/exception.hh
@@ -31,7 +31,7 @@
* Declaration for the Exception base class, the InternalError exception
* class, the NameError class and related utilities.
*
- * \ingroup Exception
+ * \ingroup grpexceptions
*/
namespace paludis
@@ -39,7 +39,7 @@ namespace paludis
/**
* Context tag for libebt.
*
- * \ingroup Exception
+ * \ingroup grpexceptions
*/
struct PaludisBacktraceTag
{
@@ -48,14 +48,14 @@ namespace paludis
/**
* Backtrace context class.
*
- * \ingroup Exception
+ * \ingroup grpexceptions
*/
typedef libebt::BacktraceContext<PaludisBacktraceTag> Context;
/**
* Base exception class.
*
- * \ingroup Exception
+ * \ingroup grpexceptions
*/
class Exception :
public std::exception,
@@ -86,7 +86,7 @@ namespace paludis
* An InternalError is an Exception that is thrown if something that is
* never supposed to happen happens.
*
- * \ingroup Exception
+ * \ingroup grpexceptions
*/
class InternalError : public Exception
{
@@ -115,8 +115,8 @@ namespace paludis
* A NameError is an Exception that is thrown when some kind of invalid
* name is encountered.
*
- * \ingroup Exception
- * \ingroup Database
+ * \ingroup grpexceptions
+ * \ingroup grpnames
*/
class NameError : public Exception
{
@@ -133,8 +133,8 @@ namespace paludis
/**
* A ConfigurationError is thrown when an invalid configuration occurs.
*
- * \ingroup Exception
- * \ingroup ConfigFile
+ * \ingroup grpexceptions
+ * \ingroup grpconfigfile
*/
class ConfigurationError : public Exception
{
@@ -150,7 +150,7 @@ namespace paludis
* Expands to the current function name, file and line, for use with
* paludis::InternalError.
*
- * \ingroup Exception
+ * \ingroup grpexceptions
*/
#define PALUDIS_HERE (paludis::stringify(__PRETTY_FUNCTION__) + " at " + \
paludis::stringify(__FILE__) + ":" + paludis::stringify(__LINE__))
diff --git a/paludis/util/files.m4 b/paludis/util/files.m4
index e15b08e..947aadd 100644
--- a/paludis/util/files.m4
+++ b/paludis/util/files.m4
@@ -21,16 +21,15 @@ add(`dir_iterator', `hh', `cc', `test', `testscript')
add(`exception', `hh', `cc')
add(`fs_entry', `hh', `cc', `test', `testscript')
add(`iterator', `hh', `test')
-add(`instantiation_policy', `hh', `cc', `test')
-add(`is_const', `hh', `cc', `test')
+add(`instantiation_policy', `hh', `test')
add(`is_file_with_extension', `hh', `cc', `test', `testscript')
-add(`join', `hh', `cc', `test')
+add(`join', `hh', `test')
add(`log', `hh', `cc', `test')
add(`match_sequence', `hh', `cc', `test')
-add(`private_implementation_pattern', `hh', `cc')
+add(`private_implementation_pattern', `hh')
add(`pstream', `hh', `cc', `test')
add(`random', `hh', `cc')
-add(`save', `hh', `cc', `test')
+add(`save', `hh', `test')
add(`smart_record', `hh', `test')
add(`stringify', `hh', `test')
add(`strip', `hh', `cc', `test')
diff --git a/paludis/util/fs_entry.cc b/paludis/util/fs_entry.cc
index b101479..7f481ab 100644
--- a/paludis/util/fs_entry.cc
+++ b/paludis/util/fs_entry.cc
@@ -32,7 +32,7 @@
/** \file
* Implementation of paludis::FSEntry.
*
- * \ingroup Filesystem
+ * \ingroup grpfilesystem
*/
using namespace paludis;
diff --git a/paludis/util/fs_entry.hh b/paludis/util/fs_entry.hh
index 9a421c0..6b3e6bb 100644
--- a/paludis/util/fs_entry.hh
+++ b/paludis/util/fs_entry.hh
@@ -31,8 +31,7 @@
/** \file
* Declarations for paludis::Filesystem.
*
- * \ingroup Filesystem
- * \ingroup Exception
+ * \ingroup grpfilesystem
*/
namespace paludis
@@ -40,7 +39,8 @@ namespace paludis
/**
* Generic filesystem error class.
*
- * \ingroup Exception
+ * \ingroup grpexceptions
+ * \ingroup grpfilesystem
*/
class FSError : public Exception
{
@@ -52,7 +52,9 @@ namespace paludis
};
/**
- * File permissions used by FSEntry
+ * File permissions used by FSEntry.
+ *
+ * \ingroup grpfilesystem
*/
enum FSPermission
{
@@ -62,7 +64,9 @@ namespace paludis
};
/**
- * User classes used by FSEntry
+ * User classes used by FSEntry.
+ *
+ * \ingroup grpfilesystem
*/
enum FSUserGroup
{
@@ -74,7 +78,7 @@ namespace paludis
/**
* Represents an entry (which may or may not exist) in the filesystem.
*
- * \ingroup Filesystem
+ * \ingroup grpfilesystem
*/
class FSEntry : public ComparisonPolicy<
FSEntry,
@@ -99,7 +103,7 @@ namespace paludis
/**
* Runs lstat() on the current path if we have not done so already
- * Note: lstat() will give information on the symbolic link itself, and not what
+ * Note: lstat() will give information on the symlink itself, and not what
* the link points to, which is how stat() works.
*/
void _stat() const;
@@ -219,6 +223,8 @@ namespace paludis
/**
* An FSEntry can be written to an ostream.
+ *
+ * \ingroup grpfilesystem
*/
std::ostream & operator<< (std::ostream & s, const FSEntry & f);
}
diff --git a/paludis/util/fs_entry_TEST.cc b/paludis/util/fs_entry_TEST.cc
index d4971b5..1d1c630 100644
--- a/paludis/util/fs_entry_TEST.cc
+++ b/paludis/util/fs_entry_TEST.cc
@@ -31,13 +31,15 @@ using namespace test;
*
* \todo this is nowhere near complete.
*
- * \ingroup Test
+ * \ingroup grpfilesystem
*/
namespace test_cases
{
/**
* \test Test FSEntry construction and manipulation.
+ *
+ * \ingroup grpfilesystem
*/
struct FSEntryManipulationTest : TestCase
{
@@ -65,6 +67,8 @@ namespace test_cases
/**
* \test Test FSEntry realpath.
+ *
+ * \ingroup grpfilesystem
*/
struct FSEntryRealpathTest : TestCase
{
@@ -106,6 +110,8 @@ namespace test_cases
/**
* \test Test FSEntry has_permission methods.
+ *
+ * \ingroup grpfilesystem
*/
struct FSEntryHasPermission: TestCase
{
@@ -143,6 +149,8 @@ namespace test_cases
/**
* \test Test FSEntry ctime and mtime methods
+ *
+ * \ingroup grpfilesystem
*/
struct FSEntryTime : TestCase
{
@@ -166,6 +174,8 @@ namespace test_cases
/**
* \test Test FSEntry file_size
+ *
+ * \ingroup grpfilesystem
*/
struct FSEntryFileSize : TestCase
{
@@ -185,6 +195,8 @@ namespace test_cases
/**
* \test Test FSEntry basename and dirname methods
+ *
+ * \ingroup grpfilesystem
*/
struct FSEntryBaseDirName : TestCase
{
@@ -211,3 +223,4 @@ namespace test_cases
}
} test_fs_entry_dir_base_name;
}
+
diff --git a/paludis/util/instantiation_policy.cc b/paludis/util/instantiation_policy.cc
deleted file mode 100644
index fe8d9e5..0000000
--- a/paludis/util/instantiation_policy.cc
+++ /dev/null
@@ -1,21 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2005, 2006 Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk>
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include <paludis/util/instantiation_policy.hh>
-
diff --git a/paludis/util/instantiation_policy.hh b/paludis/util/instantiation_policy.hh
index e0464b2..b9a23dd 100644
--- a/paludis/util/instantiation_policy.hh
+++ b/paludis/util/instantiation_policy.hh
@@ -20,59 +20,72 @@
#ifndef PALUDIS_GUARD_PALUDIS_INSTANTIATION_POLICY_HH
#define PALUDIS_GUARD_PALUDIS_INSTANTIATION_POLICY_HH 1
+/** \file
+ * InstantiationPolicy patterns.
+ *
+ * \ingroup grpinstance
+ */
+
namespace paludis
{
/**
* Instantiation policies for paludis::InstantiationPolicy.
+ *
+ * \ingroup grpinstance
*/
namespace instantiation_method
{
/**
- * Cannot be copied or assigned to.
+ * Cannot be copie
+ *
+ * \ingroup grpinstanced or assigned to.
*/
struct NonCopyableTag
{
};
/**
- * Cannot be instantiated.
+ * Cannot be instantia
+ *
+ * \ingroup grpinstanceted.
*/
struct NonInstantiableTag
{
};
/**
- * Single instance created at startup.
+ * Single instance cre
+ *
+ * \ingroup grpinstanceated at startup.
*/
struct SingletonAtStartupTag
{
};
/**
- * Single instance created when needed.
+ * Single instance cre
+ *
+ * \ingroup grpinstanceated when needed.
*/
struct SingletonAsNeededTag
{
};
}
-#ifdef DOXYGEN
/**
* InstantiationPolicy is used to specify behaviour of classes that have
* something other than the default C++ instantiation behaviour.
+ *
+ * \ingroup grpinstance
*/
template <typename OurType_, typename InstantiationMethodTag_>
- struct InstantiationPolicy
- {
- };
-#else
- template <typename OurType_, typename InstantiationMethodTag_>
struct InstantiationPolicy;
-#endif
/**
* InstantiationPolicy: specialisation for classes that cannot be copied
* or assigned to.
+ *
+ * \ingroup grpinstance
*/
template<typename OurType_>
class InstantiationPolicy<OurType_, instantiation_method::NonCopyableTag>
@@ -94,6 +107,8 @@ namespace paludis
/**
* InstantiationPolicy: specialisation for classes that cannot be created.
+ *
+ * \ingroup grpinstance
*/
template<typename OurType_>
class InstantiationPolicy<OurType_, instantiation_method::NonInstantiableTag>
@@ -119,6 +134,8 @@ namespace paludis
/**
* InstantiationPolicy: specialisation for singleton classes that are
* created at startup.
+ *
+ * \ingroup grpinstance
*/
template<typename OurType_>
class InstantiationPolicy<OurType_, instantiation_method::SingletonAtStartupTag>
@@ -153,6 +170,8 @@ namespace paludis
/**
* InstantiationPolicy: specialisation for singleton classes that are
* created as needed.
+ *
+ * \ingroup grpinstance
*/
template<typename OurType_>
class InstantiationPolicy<OurType_, instantiation_method::SingletonAsNeededTag>
diff --git a/paludis/util/instantiation_policy_TEST.cc b/paludis/util/instantiation_policy_TEST.cc
index 43d9f1e..ad9cdf2 100644
--- a/paludis/util/instantiation_policy_TEST.cc
+++ b/paludis/util/instantiation_policy_TEST.cc
@@ -25,57 +25,64 @@
using namespace test;
using namespace paludis;
-/**
- * \file
+/** \file
* Test cases for instantiation_policy.hh .
+ *
+ * \ingroup grptestcases
*/
-#ifndef DOXYGEN
-
-class MyClass :
- public InstantiationPolicy<MyClass, instantiation_method::SingletonAsNeededTag>
+namespace
{
- friend class InstantiationPolicy<MyClass, instantiation_method::SingletonAsNeededTag>;
-
- private:
- MyClass()
- {
- ++instances;
- }
+ /**
+ * Test class for InstantiationPolicy.
+ *
+ * \ingroup grptestcases
+ */
+ class MyClass :
+ public InstantiationPolicy<MyClass, instantiation_method::SingletonAsNeededTag>
+ {
+ friend class InstantiationPolicy<MyClass, instantiation_method::SingletonAsNeededTag>;
- public:
- std::string s;
+ private:
+ MyClass()
+ {
+ ++instances;
+ }
- static int instances;
-};
+ public:
+ std::string s;
-int MyClass::instances = 0;
+ static int instances;
+ };
-struct MyLoadAtStartupClass :
- public InstantiationPolicy<MyLoadAtStartupClass, instantiation_method::SingletonAtStartupTag>
-{
- friend class InstantiationPolicy<MyLoadAtStartupClass, instantiation_method::SingletonAtStartupTag>;
+ int MyClass::instances = 0;
- private:
- MyLoadAtStartupClass()
- {
- ++instances;
- }
+ struct MyLoadAtStartupClass :
+ public InstantiationPolicy<MyLoadAtStartupClass, instantiation_method::SingletonAtStartupTag>
+ {
+ friend class InstantiationPolicy<MyLoadAtStartupClass, instantiation_method::SingletonAtStartupTag>;
- public:
- std::string s;
+ private:
+ MyLoadAtStartupClass()
+ {
+ ++instances;
+ }
- static int instances;
-};
+ public:
+ std::string s;
-int MyLoadAtStartupClass::instances = 0;
+ static int instances;
+ };
-#endif
+ int MyLoadAtStartupClass::instances = 0;
+}
namespace test_cases
{
/**
* \test Test singleton behaviour.
+ *
+ * \ingroup grptestcases
*/
struct SingletonPatternTest : TestCase
{
@@ -100,6 +107,8 @@ namespace test_cases
/**
* \test Test singleton create at startup behaviour.
+ *
+ * \ingroup grptestcases
*/
struct SingletonPatternCreateAtStartupTest : TestCase
{
diff --git a/paludis/util/is_const.cc b/paludis/util/is_const.cc
deleted file mode 100644
index 7f68c16..0000000
--- a/paludis/util/is_const.cc
+++ /dev/null
@@ -1,21 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2005, 2006 Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk>
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include <paludis/util/is_const.hh>
-
diff --git a/paludis/util/is_const.hh b/paludis/util/is_const.hh
deleted file mode 100644
index 3919118..0000000
--- a/paludis/util/is_const.hh
+++ /dev/null
@@ -1,60 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2005, 2006 Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk>
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#ifndef PALUDIS_GUARD_PALUDIS_IS_CONST_HH
-#define PALUDIS_GUARD_PALUDIS_IS_CONST_HH 1
-
-/** \file
- * Declarations for the IsConst class.
- */
-
-namespace paludis
-{
- /**
- * The value member will be true if a type is const and false otherwise.
- */
- template <typename T_>
- struct IsConst
- {
- /// Are we const?
- static const bool value = false;
- };
-
- /**
- * IsConst: specialisation for const.
- */
- template <typename T_>
- struct IsConst<const T_>
- {
- /// Are we const?
- static const bool value = true;
- };
-
- /**
- * IsConst: specialisation for const references.
- */
- template <typename T_>
- struct IsConst<const T_ &>
- {
- /// Are we const?
- static const bool value = true;
- };
-}
-
-#endif
diff --git a/paludis/util/is_const_TEST.cc b/paludis/util/is_const_TEST.cc
deleted file mode 100644
index c1448f7..0000000
--- a/paludis/util/is_const_TEST.cc
+++ /dev/null
@@ -1,58 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2005, 2006 Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk>
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include <paludis/util/is_const.hh>
-#include <string>
-#include <test/test_framework.hh>
-#include <test/test_runner.hh>
-
-using namespace test;
-using namespace paludis;
-
-/**
- * \file
- * Test cases for is_const.hh .
- */
-
-namespace test_cases
-{
- /**
- * \test Test IsConst.
- */
- struct IsConstTest : TestCase
- {
- IsConstTest() : TestCase("is const") { }
-
- void run()
- {
- TEST_CHECK(IsConst<const int>::value);
- TEST_CHECK(IsConst<const std::string>::value);
- TEST_CHECK(IsConst<const std::string &>::value);
- TEST_CHECK(IsConst<int * const>::value);
-
- TEST_CHECK(! IsConst<int>::value);
- TEST_CHECK(! IsConst<std::string>::value);
- TEST_CHECK(! IsConst<std::string &>::value);
- TEST_CHECK(! IsConst<const int *>::value);
- }
- } test_is_const;
-}
-
-
-
diff --git a/paludis/util/is_file_with_extension.cc b/paludis/util/is_file_with_extension.cc
index f0a623b..77c3c12 100644
--- a/paludis/util/is_file_with_extension.cc
+++ b/paludis/util/is_file_with_extension.cc
@@ -24,7 +24,7 @@ using namespace paludis;
/** \file
* Implementation of IsFileWithExtension.
*
- * \ingroup Filesystem
+ * \ingroup grpfilesystem
*/
bool
diff --git a/paludis/util/is_file_with_extension.hh b/paludis/util/is_file_with_extension.hh
index 23934ed..86c2ccb 100644
--- a/paludis/util/is_file_with_extension.hh
+++ b/paludis/util/is_file_with_extension.hh
@@ -27,7 +27,7 @@
/** \file
* Declarations for the IsFileWithExtension class.
*
- * \ingroup Filesystem
+ * \ingroup grpfilesystem
*/
namespace paludis
@@ -37,7 +37,7 @@ namespace paludis
* FSEntry instance is a file with a given extension and (optionally) a
* given filename prefix.
*
- * \ingroup Filesystem
+ * \ingroup grpfilesystem
*/
class IsFileWithExtension :
public std::unary_function<bool, FSEntry>
diff --git a/paludis/util/is_file_with_extension_TEST.cc b/paludis/util/is_file_with_extension_TEST.cc
index e1c0496..a60c224 100644
--- a/paludis/util/is_file_with_extension_TEST.cc
+++ b/paludis/util/is_file_with_extension_TEST.cc
@@ -23,6 +23,12 @@
#include <test/test_runner.hh>
#include <vector>
+/** \file
+ * Test cases for IsFileWithExtension.
+ *
+ * \ingroup grptestcases
+ */
+
using namespace paludis;
using namespace test;
@@ -31,7 +37,7 @@ namespace test_cases
/**
* \test Test IsFileWithExtension.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct IsFileWithExtensionTest : TestCase
{
@@ -58,7 +64,7 @@ namespace test_cases
/**
* \test Test IsFileWithExtension with a prefix.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct IsFileWithExtensionPrefixTest : TestCase
{
diff --git a/paludis/util/iterator.hh b/paludis/util/iterator.hh
index 6f75320..55b721d 100644
--- a/paludis/util/iterator.hh
+++ b/paludis/util/iterator.hh
@@ -27,7 +27,7 @@
/** \file
* Declarations for various iterator helpers.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
namespace paludis
@@ -35,7 +35,7 @@ namespace paludis
/**
* Return a new iterator pointing to the item after i.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename T_>
T_ next(const T_ & i)
@@ -47,7 +47,7 @@ namespace paludis
/**
* Return a new iterator pointing to the item before i.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename T_>
T_ previous(const T_ & i)
@@ -63,6 +63,8 @@ namespace paludis
{
/**
* Determine the comparison class to use for IndirectIterator.
+ *
+ * \ingroup grpiterators
*/
template <typename IterCategory_, typename Iter_, typename Value_>
struct Comparisons
@@ -78,6 +80,8 @@ namespace paludis
/**
* Determine the comparison class to use for IndirectIterator
* (specialisation for random access iterators).
+ *
+ * \ingroup grpiterators
*/
template <typename Iter_, typename Value_>
struct Comparisons<std::random_access_iterator_tag, Iter_, Value_>
@@ -95,7 +99,7 @@ namespace paludis
* An IndirectIterator is an iterator adapter that does one additional level
* of dereferencing.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename Iter_, typename Value_>
class IndirectIterator : public std::iterator<typename std::iterator_traits<Iter_>::iterator_category, Value_>,
@@ -189,6 +193,8 @@ namespace paludis
/**
* Convenience constructor for an IndirectIterator.
+ *
+ * \ingroup grpiterators
*/
template <typename Value_, typename Iter_>
IndirectIterator<Iter_, Value_> indirect_iterator(const Iter_ & i)
@@ -201,7 +207,7 @@ namespace paludis
* if a particular predicate function returns true for the object to be
* inserted.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename Iter_, typename Pred_>
class FilterInsertIterator :
@@ -292,7 +298,7 @@ namespace paludis
/**
* Convenience function: make a FilterInsertIterator.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename Iter_, typename Pred_>
FilterInsertIterator<Iter_, Pred_> filter_inserter(
@@ -305,7 +311,7 @@ namespace paludis
* A TransformInsertIterator is an insert iterator that calls some function
* upon an item before inserting it.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename Iter_, typename Trans_>
class TransformInsertIterator :
@@ -391,7 +397,7 @@ namespace paludis
/**
* Convenience function: make a TransformInsertIterator.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename Iter_, typename Trans_>
TransformInsertIterator<Iter_, Trans_> transform_inserter(
@@ -402,6 +408,8 @@ namespace paludis
/**
* Convenience class: select the first item of a pair.
+ *
+ * \ingroup grpiterators
*/
template <typename A_, typename B_>
struct SelectFirst :
@@ -416,6 +424,8 @@ namespace paludis
/**
* Convenience class: select the second item of a pair.
+ *
+ * \ingroup grpiterators
*/
template <typename A_, typename B_>
struct SelectSecond :
@@ -432,7 +442,7 @@ namespace paludis
* A CreateInsertIterator is an insert iterator that creates an object of
* the specified type using the provided value.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename Iter_, typename Type_>
class CreateInsertIterator :
@@ -514,7 +524,7 @@ namespace paludis
/**
* Convenience function: make a CreateInsertIterator.
*
- * \ingroup Iterator
+ * \ingroup grpiterators
*/
template <typename Type_, typename Iter_>
CreateInsertIterator<Iter_, Type_> create_inserter(const Iter_ & i)
diff --git a/paludis/util/iterator_TEST.cc b/paludis/util/iterator_TEST.cc
index f0cb534..06e7d70 100644
--- a/paludis/util/iterator_TEST.cc
+++ b/paludis/util/iterator_TEST.cc
@@ -33,7 +33,7 @@ using namespace paludis;
/** \file
* Test cases for iterator utilities.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace test_cases
@@ -41,7 +41,7 @@ namespace test_cases
/**
* \test Test IndirectIterator over a vector of CountedPtr of int.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct IndirectIteratorVecCPIntTest : TestCase
{
@@ -69,7 +69,7 @@ namespace test_cases
/**
* \test Test IndirectIterator over a list of CountedPtr of int.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct IndirectIteratorListCPIntTest : TestCase
{
@@ -93,7 +93,7 @@ namespace test_cases
/**
* \test Test IndirectIterator over a vector of int *.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct IndirectIteratorVecPIntTest : TestCase
{
@@ -122,7 +122,7 @@ namespace test_cases
/**
* \test Test IndirectIterator over a list of int *.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct IndirectIteratorListPIntTest : TestCase
{
@@ -173,7 +173,7 @@ namespace test_cases
/**
* \test Test FilterInsertIterator.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct FilterInsertIteratorTest : TestCase
{
@@ -202,7 +202,7 @@ namespace test_cases
/**
* \test Test iterator_utilities next()
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct IteratorNextTest : public TestCase
{
@@ -225,7 +225,7 @@ namespace test_cases
/**
* \test Test iterator_utilities previous()
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct IteratorpreviousTest : public TestCase
{
@@ -258,7 +258,7 @@ namespace test_cases
/**
* \test Test TransformInsertIterator.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct TransformInsertIteratorTest : TestCase
{
@@ -281,7 +281,7 @@ namespace test_cases
/**
* \test Test SelectFirst and SelectSecond.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct SimpleSelectPairTest : TestCase
{
@@ -316,7 +316,7 @@ namespace test_cases
/**
* \test Test create_inserter.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct CreateInsertIteratorTest : TestCase
{
diff --git a/paludis/util/join.cc b/paludis/util/join.cc
deleted file mode 100644
index 36a1851..0000000
--- a/paludis/util/join.cc
+++ /dev/null
@@ -1,21 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2005, 2006 Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk>
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include <paludis/util/join.hh>
-
diff --git a/paludis/util/join.hh b/paludis/util/join.hh
index 2307bdf..a69b432 100644
--- a/paludis/util/join.hh
+++ b/paludis/util/join.hh
@@ -23,10 +23,18 @@
#include <paludis/util/stringify.hh>
#include <string>
+/** \file
+ * Declarations for the join function.
+ *
+ * \ingroup grpjoin
+ */
+
namespace paludis
{
/**
* Join together the items from i to end using joiner.
+ *
+ * \ingroup grpjoin
*/
template <typename I_, typename T_>
T_ join(I_ i, I_ end, const T_ & joiner)
@@ -46,6 +54,8 @@ namespace paludis
/**
* Convenience alternative join allowing a char * to be used for a
* string.
+ *
+ * \ingroup grpjoin
*/
template <typename I_>
std::string join(I_ begin, const I_ end, const char * const t)
diff --git a/paludis/util/join_TEST.cc b/paludis/util/join_TEST.cc
index bf9403c..8233e20 100644
--- a/paludis/util/join_TEST.cc
+++ b/paludis/util/join_TEST.cc
@@ -29,7 +29,7 @@ using namespace test;
/** \file
* Test cases for join.hh .
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace test_cases
@@ -37,7 +37,7 @@ namespace test_cases
/**
* \test Test join on a vector.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct JoinVectorTest : TestCase
{
@@ -58,7 +58,7 @@ namespace test_cases
/**
* \test Test join on a list.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct JoinListTest : TestCase
{
@@ -79,7 +79,7 @@ namespace test_cases
/**
* \test Test join with empty things.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct JoinEmptyTest : TestCase
{
@@ -99,3 +99,4 @@ namespace test_cases
}
} test_join_empty;
}
+
diff --git a/paludis/util/log.cc b/paludis/util/log.cc
index 7c9a687..52a81e0 100644
--- a/paludis/util/log.cc
+++ b/paludis/util/log.cc
@@ -20,12 +20,20 @@
#include <iostream>
#include <paludis/util/log.hh>
+/** \file
+ * Implementation for Log.
+ *
+ * \ingroup grplog
+ */
+
using namespace paludis;
namespace paludis
{
/**
* Implementation data for Log.
+ *
+ * \ingroup grplog
*/
template<>
struct Implementation<Log> :
diff --git a/paludis/util/log.hh b/paludis/util/log.hh
index 8c2a8c2..ce3a364 100644
--- a/paludis/util/log.hh
+++ b/paludis/util/log.hh
@@ -24,6 +24,12 @@
#include <paludis/util/instantiation_policy.hh>
#include <paludis/util/private_implementation_pattern.hh>
+/** \file
+ * Declarations for Log and related classes.
+ *
+ * \ingroup grplog
+ */
+
namespace paludis
{
/**
@@ -35,6 +41,8 @@ namespace paludis
*
* When modifying this, you will probably also want to take a look at
* ebuild/echo_functions.bash and the command_line source files.
+ *
+ * \ingroup grplog
*/
enum LogLevel
{
@@ -48,6 +56,8 @@ namespace paludis
/**
* Singleton class that handles log messages.
+ *
+ * \ingroup grplog
*/
class Log :
public InstantiationPolicy<Log, instantiation_method::SingletonAsNeededTag>,
diff --git a/paludis/util/log_TEST.cc b/paludis/util/log_TEST.cc
index a505b90..4671670 100644
--- a/paludis/util/log_TEST.cc
+++ b/paludis/util/log_TEST.cc
@@ -22,6 +22,12 @@
#include <test/test_framework.hh>
#include <test/test_runner.hh>
+/** \file
+ * Test cases for Log.
+ *
+ * \ingroup grptestcases
+ */
+
using namespace paludis;
using namespace test;
@@ -30,7 +36,7 @@ namespace test_cases
/**
* \test Test Log.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct LogTest : TestCase
{
diff --git a/paludis/util/match_sequence.cc b/paludis/util/match_sequence.cc
index 1572bec..cc29797 100644
--- a/paludis/util/match_sequence.cc
+++ b/paludis/util/match_sequence.cc
@@ -19,6 +19,12 @@
#include <paludis/util/match_sequence.hh>
+/** \file
+ * Implementation for MatchRule.
+ *
+ * \ingroup grpmatch
+ */
+
using namespace paludis;
struct MatchRule::Rule :
diff --git a/paludis/util/match_sequence.hh b/paludis/util/match_sequence.hh
index 117d500..4ebbbd3 100644
--- a/paludis/util/match_sequence.hh
+++ b/paludis/util/match_sequence.hh
@@ -23,8 +23,19 @@
#include <paludis/util/counted_ptr.hh>
#include <string>
+/** \file
+ * Declarations for the MatchRule classes.
+ *
+ * \ingroup grpmatch
+ */
+
namespace paludis
{
+ /**
+ * MatchRule is used to match text.
+ *
+ * \ingroup grpmatch
+ */
class MatchRule
{
private:
@@ -42,20 +53,44 @@ namespace paludis
MatchRule(CountedPtr<Rule>);
public:
+ /**
+ * Constructor.
+ */
MatchRule(const std::string &);
+ /**
+ * Copy constructor.
+ */
MatchRule(const MatchRule &);
+ /**
+ * A rule matching end of line.
+ */
static const MatchRule eol();
+ /**
+ * Destructor.
+ */
~MatchRule();
+ /**
+ * Followed by rule.
+ */
const MatchRule operator>> (const MatchRule &) const;
+ /**
+ * Alternation rule.
+ */
const MatchRule operator|| (const MatchRule &) const;
+ /**
+ * Repetition rule.
+ */
const MatchRule operator* () const;
+ /**
+ * Match against a string.
+ */
bool match(const std::string &) const;
};
}
diff --git a/paludis/util/match_sequence_TEST.cc b/paludis/util/match_sequence_TEST.cc
index 7b50f85..a81cf16 100644
--- a/paludis/util/match_sequence_TEST.cc
+++ b/paludis/util/match_sequence_TEST.cc
@@ -24,8 +24,19 @@
using namespace test;
using namespace paludis;
+/** \file
+ * Test cases for MatchRule.
+ *
+ * \ingroup grptestcases
+ */
+
namespace test_case
{
+ /**
+ * \test Test MatchRule
+ *
+ * \ingroup grptestcases
+ */
struct MatchRuleTest : TestCase
{
MatchRuleTest() : TestCase("match rule") { }
diff --git a/paludis/util/private_implementation_pattern.cc b/paludis/util/private_implementation_pattern.cc
deleted file mode 100644
index a793e42..0000000
--- a/paludis/util/private_implementation_pattern.cc
+++ /dev/null
@@ -1,21 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2005, 2006 Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk>
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include <paludis/util/private_implementation_pattern.hh>
-
diff --git a/paludis/util/private_implementation_pattern.hh b/paludis/util/private_implementation_pattern.hh
index c1ef717..a73a95c 100644
--- a/paludis/util/private_implementation_pattern.hh
+++ b/paludis/util/private_implementation_pattern.hh
@@ -23,11 +23,19 @@
#include <paludis/util/counted_ptr.hh>
#include <paludis/util/instantiation_policy.hh>
+/** \file
+ * Declarations for the PrivateImplementationPattern pattern.
+ *
+ * \ingroup grppimp
+ */
+
namespace paludis
{
/**
* Private implementation data, to be specialised for any class that
* uses PrivateImplementationPattern.
+ *
+ * \ingroup grppimp
*/
template <typename C_>
struct Implementation;
@@ -35,6 +43,8 @@ namespace paludis
/**
* A class descended from PrivateImplementationPattern has an associated
* Implementation instance.
+ *
+ * \ingroup grppimp
*/
template <typename C_>
class PrivateImplementationPattern :
diff --git a/paludis/util/pstream.cc b/paludis/util/pstream.cc
index b1c37ae..4ee8dea 100644
--- a/paludis/util/pstream.cc
+++ b/paludis/util/pstream.cc
@@ -22,6 +22,12 @@
#include <paludis/util/log.hh>
#include <paludis/util/pstream.hh>
+/** \file
+ * Implementation for PStream.
+ *
+ * \ingroup grpsystem
+ */
+
using namespace paludis;
PStreamError::PStreamError(const std::string & message) throw () :
diff --git a/paludis/util/pstream.hh b/paludis/util/pstream.hh
index 2ff02d7..af79b8f 100644
--- a/paludis/util/pstream.hh
+++ b/paludis/util/pstream.hh
@@ -32,8 +32,7 @@
* Declarations for the PStream and PStreamInBuf classes, and related
* utilities.
*
- * \ingroup PStream
- * \ingroup Exception
+ * \ingroup grpsystem
*/
namespace paludis
@@ -41,8 +40,8 @@ namespace paludis
/**
* Thrown if a PStream or PStreamInBuf encounters an error.
*
- * \ingroup PStream
- * \ingroup Exception
+ * \ingroup grpsystem
+ * \ingroup grpexceptions
*/
class PStreamError : public Exception
{
@@ -62,7 +61,7 @@ namespace paludis
* See \ref TCppSL Ch. 13.13 for what we're doing here. The buffer code is
* based upon the "io/inbuf1.hpp" example in section 13.13.3.
*
- * \ingroup PStream
+ * \ingroup grpsystem
*/
class PStreamInBuf :
public std::streambuf,
@@ -129,14 +128,14 @@ namespace paludis
/**
* For internal use by PStream classes.
*
- * \ingroup PStream
+ * \ingroup grpsystem
*/
namespace pstream_internals
{
/**
* Avoid base from member issues for PStream.
*
- * \ingroup PStream
+ * \ingroup grpsystem
*/
struct PStreamInBufBase :
private paludis::InstantiationPolicy<PStreamInBufBase, instantiation_method::NonCopyableTag>
@@ -160,7 +159,7 @@ namespace paludis
* A PStream class is a standard input stream class whose contents comes
* from the output of an executed command.
*
- * \ingroup PStream
+ * \ingroup grpsystem
*/
class PStream :
private InstantiationPolicy<PStream, instantiation_method::NonCopyableTag>,
diff --git a/paludis/util/pstream_TEST.cc b/paludis/util/pstream_TEST.cc
index d75050c..0f65660 100644
--- a/paludis/util/pstream_TEST.cc
+++ b/paludis/util/pstream_TEST.cc
@@ -27,14 +27,15 @@ using namespace test;
/** \file
* Tests for PStream.
*
- * \ingroup PStream
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace test_cases
{
/**
* \test Test PStream on a normal command.
+ *
+ * \ingroup grptestcases
*/
struct PStreamTest : TestCase
{
@@ -55,6 +56,8 @@ namespace test_cases
/**
* \test Test PStream on a command that doesn't exist.
+ *
+ * \ingroup grptestcases
*/
struct PStreamNoExistTest : TestCase
{
@@ -69,6 +72,8 @@ namespace test_cases
/**
* \test Test PStream on a command that returns a failure with no output.
+ *
+ * \ingroup grptestcases
*/
struct PStreamSilentFailTest : TestCase
{
@@ -83,6 +88,8 @@ namespace test_cases
/**
* \test Test PStream on a command that fails with output.
+ *
+ * \ingroup grptestcases
*/
struct PStreamFailTest : TestCase
{
diff --git a/paludis/util/random.cc b/paludis/util/random.cc
index 5d435ca..0b026fe 100644
--- a/paludis/util/random.cc
+++ b/paludis/util/random.cc
@@ -19,6 +19,12 @@
#include "random.hh"
+/** \file
+ * Implementation for random.hh.
+ *
+ * \ingroup grprandom
+ */
+
using namespace paludis;
bool Random::done_srand(false);
diff --git a/paludis/util/random.hh b/paludis/util/random.hh
index 8a7e7f0..547ef9f 100644
--- a/paludis/util/random.hh
+++ b/paludis/util/random.hh
@@ -25,7 +25,15 @@
namespace paludis
{
- /// \todo Don't use cstdlib functions here.
+ /**
+ * A basic random number generator class.
+ *
+ * See \ref TCppPL 22.7 for justification.
+ *
+ * \todo Don't use cstdlib functions here.
+ *
+ * \ingroup grprandom
+ */
class Random
{
private:
diff --git a/paludis/util/save.cc b/paludis/util/save.cc
deleted file mode 100644
index 7fcc0c9..0000000
--- a/paludis/util/save.cc
+++ /dev/null
@@ -1,21 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2005, 2006 Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk>
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include <paludis/util/save.hh>
-
diff --git a/paludis/util/save.hh b/paludis/util/save.hh
index ecbc1f0..cbc55ea 100644
--- a/paludis/util/save.hh
+++ b/paludis/util/save.hh
@@ -25,7 +25,7 @@
/** \file
* Declarations for the Save class.
*
- * \ingroup Utility
+ * \ingroup grpsave
*/
namespace paludis
@@ -35,7 +35,7 @@ namespace paludis
* duration of the Save instance's lifetime (RAII, see \ref EffCpp item 13 or
* \ref TCppPL section 14.4).
*
- * \ingroup Utility
+ * \ingroup grpsave
*/
template <typename T_>
class Save :
diff --git a/paludis/util/save_TEST.cc b/paludis/util/save_TEST.cc
index e6a9e43..8f33136 100644
--- a/paludis/util/save_TEST.cc
+++ b/paludis/util/save_TEST.cc
@@ -27,8 +27,7 @@ using namespace paludis;
/** \file
* Test cases for save.hh .
*
- * \ingroup Utility
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace test_cases
@@ -36,7 +35,7 @@ namespace test_cases
/**
* \test Test Save.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct SaveTest : TestCase
{
diff --git a/paludis/util/smart_record.hh.m4 b/paludis/util/smart_record.hh.m4
index 022a527..359bcdd 100644
--- a/paludis/util/smart_record.hh.m4
+++ b/paludis/util/smart_record.hh.m4
@@ -33,12 +33,20 @@ define(`_forloop', `$4`'ifelse($1, `$3', , `define(`$1', incr($1))_forloop(`$1',
#include <paludis/util/exception.hh>
#include <string>
+/** \file
+ * SmartRecord declarations.
+ *
+ * \ingroup grprecords
+ */
+
namespace paludis
{
namespace comparison_method
{
/**
* Comparisons are done by considering each member in order.
+ *
+ * \ingroup grprecords
*/
struct SmartRecordCompareByAllTag
{
@@ -46,6 +54,8 @@ namespace paludis
/**
* Comparisons are done by considering a specific key.
+ *
+ * \ingroup grprecords
*/
template <unsigned key_>
struct SmartRecordCompareByKeyTag
@@ -54,6 +64,8 @@ namespace paludis
/**
* Comparisons are done by considering a range of keys.
+ *
+ * \ingroup grprecords
*/
template <unsigned first_key_, unsigned last_key_>
struct SmartRecordCompareByKeyRangeTag
@@ -63,6 +75,8 @@ namespace paludis
/**
* Provides the basic typedefs required for a MakeSmartRecord instantiation.
+ *
+ * \ingroup grprecords
*/
template <
typename ComparisonModeTag_ = comparison_mode::NoComparisonTag,
@@ -71,6 +85,8 @@ namespace paludis
{
/**
* Mode used for ComparisonPolicy.
+ *
+ * \ingroup grprecords
*/
typedef ComparisonModeTag_ ComparisonModeTag;
@@ -78,6 +94,8 @@ namespace paludis
* Method used for ComparisonPolicy, should be either
* comparison_method::SmartRecordCompareByAllTag or
* comparison_method::SmartRecordCompareByKeyTag .
+ *
+ * \ingroup grprecords
*/
typedef ComparisonMethod_ ComparisonMethodTag;
};
@@ -85,6 +103,8 @@ namespace paludis
/**
* Provides the key information typedefs for a MakeSmartRecord
* instantiation.
+ *
+ * \ingroup grprecords
*/
template <typename E_, unsigned Count_>
struct SmartRecordKeys
@@ -113,6 +133,8 @@ forloop(`idx', `0', max_record_size, `
/**
* Internal use by SmartRecord.
+ *
+ * \ingroup grprecords
*/
namespace smart_record_internals
{
@@ -268,6 +290,8 @@ forloop(`idx', `0', max_record_size, `
/**
* RecordComparisonBase: specialisation for comparison_mode::NoComparisonTag.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_, typename ComparisonMethodTag_>
struct RecordComparisonBase<Tag_, key_count_, comparison_mode::NoComparisonTag, ComparisonMethodTag_> :
@@ -279,6 +303,8 @@ forloop(`idx', `0', max_record_size, `
* RecordComparisonBase: specialisation for
* comparison_mode::EqualityComparisonTag and
* comparison_method::SmartRecordCompareByKeyTag.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_, unsigned key_>
class RecordComparisonBase<Tag_, key_count_, comparison_mode::EqualityComparisonTag,
@@ -298,6 +324,8 @@ forloop(`idx', `0', max_record_size, `
* RecordComparisonBase: specialisation for
* comparison_mode::FullComparisonTag and
* comparison_method::SmartRecordCompareByKeyTag.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_, unsigned key_>
class RecordComparisonBase<Tag_, key_count_, comparison_mode::FullComparisonTag,
@@ -317,6 +345,8 @@ forloop(`idx', `0', max_record_size, `
* RecordComparisonBase: specialisation for
* comparison_mode::EqualityComparisonTag and
* comparison_method::SmartRecordCompareByAllTag.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_>
class RecordComparisonBase<Tag_, key_count_, comparison_mode::EqualityComparisonTag,
@@ -348,6 +378,8 @@ forloop(`idx', `0', max_record_size, `
* RecordComparisonBase: specialisation for
* comparison_mode::FullComparisonTag and
* comparison_method::SmartRecordCompareByAllTag.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_>
class RecordComparisonBase<Tag_, key_count_, comparison_mode::FullComparisonTag,
@@ -379,6 +411,8 @@ forloop(`idx', `0', max_record_size, `
* RecordComparisonBase: specialisation for
* comparison_mode::EqualityComparisonTag and
* comparison_method::SmartRecordCompareByKeyRangeTag.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_, unsigned first_key_, unsigned last_key_>
class RecordComparisonBase<Tag_, key_count_, comparison_mode::EqualityComparisonTag,
@@ -410,6 +444,8 @@ forloop(`idx', `0', max_record_size, `
* RecordComparisonBase: specialisation for
* comparison_mode::FullComparisonTag and
* comparison_method::SmartRecordCompareByKeyRangeTag.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_, unsigned first_key_, unsigned last_key_>
class RecordComparisonBase<Tag_, key_count_, comparison_mode::FullComparisonTag,
@@ -642,12 +678,16 @@ forloop(`idy', `0', decr(`'idx`'), `
/**
* Do the comparison for a range of keys.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_, unsigned from_key_, unsigned count_>
struct DoFullCompareByKeyRange
{
/**
* Do the comparison.
+ *
+ * \ingroup grprecords
*/
static int do_compare(const RecordBase<Tag_, key_count_> * const a,
const RecordBase<Tag_, key_count_> * const b)
@@ -666,6 +706,8 @@ forloop(`idy', `0', decr(`'idx`'), `
/**
* Do the comparison for a range of keys (specialisation for zero sized
* ranges).
+ *
+ * \ingroup grprecords
*/
template <typename Tag_, unsigned key_count_, unsigned from_key_>
struct DoFullCompareByKeyRange<Tag_, key_count_, from_key_, 0>
@@ -695,16 +737,25 @@ forloop(`idy', `0', decr(`'idx`'), `
/**
* Create a SmartRecord with the attributes described by Tag_.
+ *
+ * \ingroup grprecords
*/
template <typename Tag_>
struct MakeSmartRecord
{
/**
* The type of our SmartRecord.
+ *
+ * \ingroup grprecords
*/
typedef smart_record_internals::RecordBase<Tag_, Tag_::key_count> Type;
};
+ /**
+ * Create a named parameter for creating a SmartRecord instance.
+ *
+ * \ingroup grprecords
+ */
template <unsigned idx_, typename T_>
smart_record_internals::ParamListNode<idx_, typename smart_record_internals::CharStarToString<T_>::Type>
param(const T_ & t)
diff --git a/paludis/util/smart_record_TEST.cc b/paludis/util/smart_record_TEST.cc
index d9614df..589073c 100644
--- a/paludis/util/smart_record_TEST.cc
+++ b/paludis/util/smart_record_TEST.cc
@@ -29,7 +29,7 @@ using namespace test;
/** \file
* Test cases for smart_record.hh .
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace
@@ -77,7 +77,7 @@ namespace test_cases
/**
* \test Test a simple SmartRecord.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct SimpleRecordTest : TestCase
{
@@ -114,7 +114,7 @@ namespace test_cases
/**
* \test Test a list constructed SmartRecord.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct ListConstructedRecordTest : TestCase
{
diff --git a/paludis/util/stringify.hh b/paludis/util/stringify.hh
index d95cd84..a5df5f4 100644
--- a/paludis/util/stringify.hh
+++ b/paludis/util/stringify.hh
@@ -26,6 +26,8 @@
/** \file
* Stringify functions.
+ *
+ * \ingroup grpstringify
*/
namespace paludis
@@ -60,6 +62,8 @@ namespace paludis
/**
* Convert item to a string.
+ *
+ * \ingroup grpstringify
*/
template <typename T_>
std::string
@@ -76,6 +80,8 @@ namespace paludis
/**
* Convert item to a string (overload for std::string).
+ *
+ * \ingroup grpstringify
*/
inline std::string
stringify(const std::string & item)
@@ -85,6 +91,8 @@ namespace paludis
/**
* Convert item to a string (overload for char).
+ *
+ * \ingroup grpstringify
*/
inline std::string
stringify(const char & item)
@@ -94,6 +102,8 @@ namespace paludis
/**
* Convert item to a string (overload for unsigned char).
+ *
+ * \ingroup grpstringify
*/
inline std::string
stringify(const unsigned char & item)
@@ -103,6 +113,8 @@ namespace paludis
/**
* Convert item to a string (overload for bool).
+ *
+ * \ingroup grpstringify
*/
inline std::string
stringify(const bool & item)
@@ -113,6 +125,8 @@ namespace paludis
/**
* Convert item to a string (overload for char *, which isn't a
* screwup like other pointers).
+ *
+ * \ingroup grpstringify
*/
inline std::string
stringify(const char * const item)
diff --git a/paludis/util/stringify_TEST.cc b/paludis/util/stringify_TEST.cc
index 2980dd4..5cde52d 100644
--- a/paludis/util/stringify_TEST.cc
+++ b/paludis/util/stringify_TEST.cc
@@ -28,7 +28,7 @@ using namespace paludis;
/** \file
* Test cases for stringify.hh .
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace test_cases
@@ -36,7 +36,7 @@ namespace test_cases
/** \test
* Test stringify on int.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StringifyIntTests : TestCase
{
@@ -55,7 +55,7 @@ namespace test_cases
/** \test
* Test stringify on char *.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StringifyCharStarTests : TestCase
{
@@ -73,7 +73,7 @@ namespace test_cases
/** \test
* Test stringify on std::string.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StringifyStringTests : TestCase
{
@@ -91,7 +91,7 @@ namespace test_cases
/** \test
* Test stringify on char.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StringifyCharTests : TestCase
{
@@ -113,7 +113,7 @@ namespace test_cases
/** \test
* Test stringify on bool.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StringifyBoolTests : TestCase
{
diff --git a/paludis/util/strip.cc b/paludis/util/strip.cc
index 2371fee..3a220a1 100644
--- a/paludis/util/strip.cc
+++ b/paludis/util/strip.cc
@@ -20,6 +20,12 @@
#include <paludis/util/exception.hh>
#include <paludis/util/strip.hh>
+/** \file
+ * Implementation of strip things.
+ *
+ * \ingroup grpstrippers
+ */
+
namespace paludis
{
std::string strip_leading_string(const std::string & s, const std::string & prefix)
diff --git a/paludis/util/strip.hh b/paludis/util/strip.hh
index 3030a94..cc62d16 100644
--- a/paludis/util/strip.hh
+++ b/paludis/util/strip.hh
@@ -23,29 +23,43 @@
#include <functional>
#include <string>
+/** \file
+ * Strip functions and adapters.
+ *
+ * \ingroup grpstrippers
+ */
+
namespace paludis
{
/**
* Return a string equal to s minus any leading characters that are
* contained in prefix.
+ *
+ * \ingroup grpstrippers
*/
std::string strip_leading_string(const std::string & s, const std::string & prefix);
/**
* Return a string equal to s, minus the string remove if remove occurs at
* the start of s.
+ *
+ * \ingroup grpstrippers
*/
std::string strip_leading(const std::string & s, const std::string & remove);
/**
* Return a string equal to s minus any trailing characters that are
* contained in suffix.
+ *
+ * \ingroup grpstrippers
*/
std::string strip_trailing_string(const std::string & s, const std::string & suffix);
/**
* Return a string equal to s, minus the string remove if remove occurs at
* the end of s.
+ *
+ * \ingroup grpstrippers
*/
std::string strip_trailing(const std::string & s, const std::string & remove);
@@ -53,6 +67,8 @@ namespace paludis
* Adapt one of the strip_ functions for use as a std::unary_function by
* binding a value to the second parameter (avoids the reference to const
* issue with std::bind2nd).
+ *
+ * \ingroup grpstrippers
*/
template <std::string (* f_)(const std::string &, const std::string &)>
class StripAdapter :
@@ -81,21 +97,29 @@ namespace paludis
/**
* Adapt strip_leading_string to a functor by binding its second argument.
+ *
+ * \ingroup grpstrippers
*/
typedef StripAdapter<&strip_leading_string> StripLeadingString;
/**
* Adapt strip_leading to a functor by binding its second argument.
+ *
+ * \ingroup grpstrippers
*/
typedef StripAdapter<&strip_leading> StripLeading;
/**
* Adapt strip_trailing_string to a functor by binding its second argument.
+ *
+ * \ingroup grpstrippers
*/
typedef StripAdapter<&strip_trailing_string> StripTrailingString;
/**
* Adapt strip_trailing to a functor by binding its second argument.
+ *
+ * \ingroup grpstrippers
*/
typedef StripAdapter<&strip_trailing> StripTrailing;
}
diff --git a/paludis/util/strip_TEST.cc b/paludis/util/strip_TEST.cc
index 19deefe..54cf287 100644
--- a/paludis/util/strip_TEST.cc
+++ b/paludis/util/strip_TEST.cc
@@ -30,7 +30,7 @@ using namespace test;
/** \file
* Test cases for strip.hh.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
namespace test_cases
@@ -38,7 +38,7 @@ namespace test_cases
/**
* \test Test StripLeadingString.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StripLeadingStringTest : TestCase
{
@@ -59,7 +59,7 @@ namespace test_cases
/**
* \test Test StripLeading.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StripLeadingTest : TestCase
{
@@ -80,7 +80,7 @@ namespace test_cases
/**
* \test Test StripTrailingString.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StripTrailingStringTest : TestCase
{
@@ -101,7 +101,7 @@ namespace test_cases
/**
* \test Test StripTrailing.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct StripTrailingTest : TestCase
{
diff --git a/paludis/util/system.cc b/paludis/util/system.cc
index 5fb2257..cf4c42d 100644
--- a/paludis/util/system.cc
+++ b/paludis/util/system.cc
@@ -25,6 +25,12 @@
#include <sys/wait.h>
#include <unistd.h>
+/** \file
+ * Implementation of various system utilities.
+ *
+ * \ingroup grpsystem
+ */
+
using namespace paludis;
GetenvError::GetenvError(const std::string & key) throw () :
@@ -50,6 +56,11 @@ paludis::getenv_or_error(const std::string & key)
namespace
{
+ /**
+ * Fetch the kernel version, for paludis::kernel_version.
+ *
+ * \ingroup grpsystem
+ */
std::string get_kernel_version()
{
struct utsname u;
diff --git a/paludis/util/system.hh b/paludis/util/system.hh
index 7432b2f..9ef8ad2 100644
--- a/paludis/util/system.hh
+++ b/paludis/util/system.hh
@@ -23,12 +23,19 @@
#include <paludis/util/exception.hh>
#include <string>
+/** \file
+ * Various system utilities.
+ *
+ * \ingroup grpsystem
+ */
+
namespace paludis
{
/**
* Thrown if getenv_or_error fails.
*
- * \ingroup Exception
+ * \ingroup grpexceptions
+ * \ingroup grpsystem
*/
class GetenvError : public Exception
{
@@ -42,17 +49,23 @@ namespace paludis
/**
* Fetch the value of environment variable key, or def if the variable is
* not defined.
+ *
+ * \ingroup grpsystem
*/
std::string getenv_with_default(const std::string & key, const std::string & def);
/**
* Fetch the value of environment variable key, or throw a GetenvError if
* the variable is not defined.
+ *
+ * \ingroup grpsystem
*/
std::string getenv_or_error(const std::string & key);
/**
* Fetch the kernel version, for $KV.
+ *
+ * \ingroup grpsystem
*/
std::string kernel_version();
@@ -60,9 +73,14 @@ namespace paludis
* Run a command, wait for it to terminate and return its exit status.
*
* Use PStream instead if you need to capture stdout.
+ *
+ * \ingroup grpsystem
*/
int run_command(const std::string & cmd);
+ /**
+ * Make a command that's run in a particular environment.
+ */
class MakeEnvCommand
{
private:
@@ -70,15 +88,26 @@ namespace paludis
std::string args;
public:
+ /**
+ * Constructor.
+ */
explicit MakeEnvCommand(const std::string &, const std::string &);
+ /**
+ * Add some environment.
+ */
MakeEnvCommand operator() (const std::string &, const std::string &) const;
+ /**
+ * Turn ourself into a command string.
+ */
operator std::string() const;
};
/**
- * Run a command, with environment.
+ * Make a command, with environment.
+ *
+ * \ingroup grpsystem
*/
const MakeEnvCommand make_env_command(const std::string & cmd);
}
diff --git a/paludis/util/system_TEST.cc b/paludis/util/system_TEST.cc
index d16adfe..b9971ac 100644
--- a/paludis/util/system_TEST.cc
+++ b/paludis/util/system_TEST.cc
@@ -22,6 +22,12 @@
#include <test/test_framework.hh>
#include <test/test_runner.hh>
+/** \file
+ * Test cases for system.hh .
+ *
+ * \ingroup grptestcases
+ */
+
using namespace test;
using namespace paludis;
@@ -31,7 +37,7 @@ namespace test_cases
/**
* \test Test getenv_with_default.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct GetenvWithDefaultTest : TestCase
{
@@ -48,7 +54,7 @@ namespace test_cases
/**
* \test Test getenv_or_error.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct GetenvOrErrorTest : TestCase
{
@@ -64,7 +70,7 @@ namespace test_cases
/**
* \test Test kernel_version.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct KernelVersionTest : TestCase
{
@@ -85,7 +91,7 @@ namespace test_cases
/**
* \test Test run_command.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct RunCommandTest : TestCase
{
@@ -101,7 +107,7 @@ namespace test_cases
/**
* \test Test make_env_command.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct MakeEnvCommandTest : TestCase
{
@@ -133,7 +139,7 @@ namespace test_cases
/**
* \test Test make_env_command with quotes.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct MakeEnvCommandQuoteTest : TestCase
{
diff --git a/paludis/util/test_extras.cc b/paludis/util/test_extras.cc
index 8be0277..1e6b5bf 100644
--- a/paludis/util/test_extras.cc
+++ b/paludis/util/test_extras.cc
@@ -25,6 +25,12 @@
#include <sstream>
#include <test/test_framework.hh>
+/** \file
+ * Some extras, for test cases.
+ *
+ * \ingroup grptestcases
+ */
+
using namespace paludis;
namespace
diff --git a/paludis/util/tokeniser.hh b/paludis/util/tokeniser.hh
index e9f0866..24fdb12 100644
--- a/paludis/util/tokeniser.hh
+++ b/paludis/util/tokeniser.hh
@@ -27,7 +27,7 @@
/** \file
* Declarations for Tokeniser and related utilities.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
namespace paludis
@@ -35,14 +35,14 @@ namespace paludis
/**
* Delimiter policy for Tokeniser.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
namespace delim_kind
{
/**
* Any of the characters split, and the delimiter is discarded.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
struct AnyOfTag
{
@@ -52,14 +52,14 @@ namespace paludis
/**
* Delimiter mode for Tokeniser.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
namespace delim_mode
{
/**
* Discard the delimiters.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
struct DelimiterTag
{
@@ -68,7 +68,7 @@ namespace paludis
/**
* Keep the delimiters.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
struct BoundaryTag
{
@@ -78,14 +78,14 @@ namespace paludis
/**
* Tokeniser internal use only.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
namespace tokeniser_internals
{
/**
* A Writer handles Tokeniser's writes.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
template <typename DelimMode_, typename Char_, typename Iter_>
struct Writer;
@@ -94,7 +94,7 @@ namespace paludis
* A Writer handles Tokeniser's writes (specialisation for
* delim_mode::DelimiterTag).
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
template <typename Char_, typename Iter_>
struct Writer<delim_mode::DelimiterTag, Char_, Iter_>
@@ -119,7 +119,7 @@ namespace paludis
* A Writer handles Tokeniser's writes (specialisation for
* delim_mode::BoundaryTag).
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
template <typename Char_, typename Iter_>
struct Writer<delim_mode::BoundaryTag, Char_, Iter_>
@@ -146,7 +146,7 @@ namespace paludis
/**
* Tokeniser splits up strings into smaller strings.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
template <typename DelimKind_, typename DelimMode_, typename Char_ = std::string::value_type>
struct Tokeniser;
@@ -154,7 +154,7 @@ namespace paludis
/**
* Tokeniser: specialisation for delim_kind::AnyOfTag.
*
- * \ingroup Tokeniser
+ * \ingroup grptokenise
*/
template <typename DelimMode_, typename Char_>
class Tokeniser<delim_kind::AnyOfTag, DelimMode_, Char_> :
diff --git a/paludis/util/tokeniser_TEST.cc b/paludis/util/tokeniser_TEST.cc
index b3f2d6b..a8ea208 100644
--- a/paludis/util/tokeniser_TEST.cc
+++ b/paludis/util/tokeniser_TEST.cc
@@ -29,8 +29,7 @@ using namespace paludis;
/** \file
* Test cases for tokeniser.hh .
*
- * \ingroup Test
- * \ingroup Tokeniser
+ * \ingroup grptestcases
*/
namespace test_cases
@@ -38,7 +37,7 @@ namespace test_cases
/**
* \test Test Tokeniser<AnyOfTag, DelimiterTag>
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct TestTokeniserAD : TestCase
{
@@ -86,7 +85,7 @@ namespace test_cases
/**
* \test Test Tokeniser<AnyOfTag, BoundaryTag>
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct TestTokeniserAB : TestCase
{
diff --git a/paludis/util/validated.hh b/paludis/util/validated.hh
index ba2995a..b6f72fc 100644
--- a/paludis/util/validated.hh
+++ b/paludis/util/validated.hh
@@ -23,11 +23,19 @@
#include <ostream>
#include <paludis/util/comparison_policy.hh>
+/** \file
+ * Validated declarations.
+ *
+ * \ingroup grpvalidated
+ */
+
namespace paludis
{
/**
* A Validated wraps a particular class instance, ensuring that it always
* meets certain validation criteria.
+ *
+ * \ingroup grpvalidated
*/
template <typename ValidatedDataType_, typename Validator_>
class Validated : public ComparisonPolicy<
@@ -88,6 +96,8 @@ namespace paludis
/**
* Writing a Validated instance to a stream is done by its data.
+ *
+ * \ingroup grpvalidated
*/
template <typename D_, typename V_>
std::ostream &
diff --git a/paludis/util/validated_TEST.cc b/paludis/util/validated_TEST.cc
index cc59e42..626f968 100644
--- a/paludis/util/validated_TEST.cc
+++ b/paludis/util/validated_TEST.cc
@@ -27,7 +27,7 @@ using namespace paludis;
/** \file
* Test cases for validated.hh .
*
- * \ingroup Test
+ * \ingroup grpvalidated
*/
#ifndef DOXYGEN
@@ -52,7 +52,7 @@ namespace test_cases
/**
* \test Validated<PositiveEven> tests.
*
- * \ingroup Test
+ * \ingroup grpvalidated
*/
struct ValidatedPositiveEvenTests : TestCase
{
@@ -73,7 +73,7 @@ namespace test_cases
/**
* \test Validated<PositiveEven> comparison tests.
*
- * \ingroup Test
+ * \ingroup grpvalidated
*/
struct ValidatedPositiveEvenComparisonTests : TestCase
{
diff --git a/paludis/util/virtual_constructor.hh b/paludis/util/virtual_constructor.hh
index 4f182e8..503ebf9 100644
--- a/paludis/util/virtual_constructor.hh
+++ b/paludis/util/virtual_constructor.hh
@@ -31,7 +31,7 @@
/** \file
* Declarations for VirtualConstructor and related classes.
*
- * \ingroup VirtualConstructor
+ * \ingroup grpvc
*/
namespace paludis
@@ -40,7 +40,7 @@ namespace paludis
* Behaviour policy classes for what to do if an appropriate constructor
* cannot be found for a VirtualConstructor::find_maker call.
*
- * \ingroup VirtualConstructor
+ * \ingroup grpvc
*/
namespace virtual_constructor_not_found
{
@@ -48,7 +48,7 @@ namespace paludis
* Throw an exception of type ExceptionType_, which should have a
* constructor that takes a single parameter of KeyType_.
*
- * \ingroup VirtualConstructor
+ * \ingroup grpvc
*/
template <typename ExceptionType_>
struct ThrowException
@@ -56,7 +56,7 @@ namespace paludis
/**
* Internal use: provide handle_not_found.
*
- * \ingroup VirtualConstructor
+ * \ingroup grpvc
*/
template <typename KeyType_, typename ValueType_>
struct Parent
@@ -81,14 +81,14 @@ namespace paludis
/**
* For internal use by VirtualConstructor.
*
- * \ingroup VirtualConstructor
+ * \ingroup grpvc
*/
namespace virtual_constructor_internals
{
/**
* Comparator class for our entries.
*
- * \ingroup VirtualConstructor
+ * \ingroup grpvc
*/
template <typename First_, typename Second_>
struct ComparePairByFirst
@@ -116,7 +116,7 @@ namespace paludis
* some key type (often a string) to the construction of some kind of
* class (possibly via a functor) is required.
*
- * \ingroup VirtualConstructor
+ * \ingroup grpvc
*/
template <typename KeyType_, typename ValueType_, typename NotFoundBehaviour_>
class VirtualConstructor :
@@ -185,7 +185,7 @@ namespace paludis
* An instance of this class registers a new maker with the
* specified key.
*
- * \ingroup VirtualConstructor
+ * \ingroup grpvc
*/
struct RegisterMaker
{
diff --git a/paludis/util/virtual_constructor_TEST.cc b/paludis/util/virtual_constructor_TEST.cc
index ddbe150..2273dde 100644
--- a/paludis/util/virtual_constructor_TEST.cc
+++ b/paludis/util/virtual_constructor_TEST.cc
@@ -1,11 +1,34 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
+/*
+ * Copyright (c) 2006 Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk>
+ *
+ * This file is part of the Paludis package manager. Paludis is free software;
+ * you can redistribute it and/or modify it under the terms of the GNU General
+ * Public License version 2, as published by the Free Software Foundation.
+ *
+ * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
+ * Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
#include <paludis/util/counted_ptr.hh>
#include <paludis/util/virtual_constructor.hh>
#include <set>
#include <test/test_framework.hh>
#include <test/test_runner.hh>
+/** \file
+ * Test cases for VirtualConstructor.
+ *
+ * \ingroup grptestcases
+ */
+
using namespace test;
using namespace paludis;
@@ -116,7 +139,7 @@ namespace test_cases
/**
* \test Test VirtualConstructor.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct VirtualConstructorTest : TestCase
{
@@ -144,7 +167,7 @@ namespace test_cases
/**
* \test Test VirtualConstructor keys
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct VirtualConstructorKeysTest : TestCase
{
diff --git a/paludis/util/visitor.hh b/paludis/util/visitor.hh
index bacbaeb..33a4d6e 100644
--- a/paludis/util/visitor.hh
+++ b/paludis/util/visitor.hh
@@ -23,7 +23,7 @@
/** \file
* Declares the Visitor and related classes.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
namespace paludis
@@ -34,7 +34,7 @@ namespace paludis
/**
* Internal use for Visitor classes.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
namespace visitor_internals
{
@@ -43,7 +43,7 @@ namespace paludis
* parameter is used to avoid inheriting the same class more than once
* from a single parent.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <unsigned n_>
struct NoType
@@ -53,7 +53,7 @@ namespace paludis
/**
* Make a pointer to a const.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <typename>
struct MakePointerToConst;
@@ -61,7 +61,7 @@ namespace paludis
/**
* Make a pointer to a const (specialisation for non-const pointers).
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <typename T_>
struct MakePointerToConst<T_ *>
@@ -75,7 +75,7 @@ namespace paludis
/**
* Interface: visit a class of NodePtrType_.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <typename NodePtrType_>
class Visits
@@ -98,7 +98,7 @@ namespace paludis
/**
* Interface: don't visit NoType things.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <unsigned n_>
class Visits<const visitor_internals::NoType<n_> * >
@@ -115,7 +115,7 @@ namespace paludis
/**
* Interface: don't visit NoType things.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <unsigned n_>
class Visits<visitor_internals::NoType<n_> * >
@@ -131,7 +131,7 @@ namespace paludis
* A class that inherits virtually from VisitableInterface can accept a
* visitor that is descended from one of the VisitorType_ subclasses.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <typename VisitorType_>
class VisitableInterface
@@ -160,7 +160,7 @@ namespace paludis
* A class that inherits (non-virtually) from Visitable provides an
* implementation of VisitableInterface.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <typename OurType_, typename VisitorType_>
class Visitable :
@@ -192,7 +192,7 @@ namespace paludis
* Create the base classes for constant and non-constant visitors to the
* specified node types.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <
typename N1_,
@@ -255,7 +255,7 @@ namespace paludis
* Functor: simplify calling accept on a visitor when we have a container of
* pointers to nodes.
*
- * \ingroup Visitor
+ * \ingroup grpvisitor
*/
template <typename VisitorPointer_>
class AcceptVisitor
@@ -284,6 +284,8 @@ namespace paludis
/**
* Convenience function: create an AcceptVisitor.
+ *
+ * \ingroup grpvisitor
*/
template <typename VisitorPointer_>
AcceptVisitor<VisitorPointer_> accept_visitor(VisitorPointer_ * const p)
diff --git a/paludis/util/visitor_TEST.cc b/paludis/util/visitor_TEST.cc
index f836110..25e020e 100644
--- a/paludis/util/visitor_TEST.cc
+++ b/paludis/util/visitor_TEST.cc
@@ -31,8 +31,7 @@ using namespace test;
/** \file
* Test cases for visitor.hh .
*
- * \ingroup Test
- * \ingroup Visitor
+ * \ingroup grptestcases
*/
#ifndef DOXYGEN
@@ -117,7 +116,7 @@ namespace test_cases
/**
* \test Test const visitors.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct ConstVisitorTest : TestCase
{
@@ -143,7 +142,7 @@ namespace test_cases
/**
* \test Test non-const visitors.
*
- * \ingroup Test
+ * \ingroup grptestcases
*/
struct VisitorTest : TestCase
{