Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r68060 - sandbox/tti/libs/tti/doc
From: eldiener_at_[hidden]
Date: 2011-01-12 12:01:20


Author: eldiener
Date: 2011-01-12 12:01:17 EST (Wed, 12 Jan 2011)
New Revision: 68060
URL: http://svn.boost.org/trac/boost/changeset/68060

Log:
Updated the doc with links to the reference
Text files modified:
   sandbox/tti/libs/tti/doc/TTIDetail.qbk | 32 +++++-----
   sandbox/tti/libs/tti/doc/TTIIntroduction.qbk | 8 +-
   sandbox/tti/libs/tti/doc/TTIMetafunctions.qbk | 108 ++++++++++++++++++++++----------------
   sandbox/tti/libs/tti/doc/TTINestedType.qbk | 112 ++++++++++++++++++++--------------------
   4 files changed, 140 insertions(+), 120 deletions(-)

Modified: sandbox/tti/libs/tti/doc/TTIDetail.qbk
==============================================================================
--- sandbox/tti/libs/tti/doc/TTIDetail.qbk (original)
+++ sandbox/tti/libs/tti/doc/TTIDetail.qbk 2011-01-12 12:01:17 EST (Wed, 12 Jan 2011)
@@ -28,8 +28,8 @@
   [
     [Type]
     [
- TTI\_HAS\_TYPE(name)[br]
- TTI\_TRAIT\_HAS\_TYPE(trait,name)
+ [macroref TTI_HAS_TYPE TTI\_HAS\_TYPE](name)[br]
+ [macroref TTI_TRAIT_HAS_TYPE TTI\_TRAIT\_HAS\_TYPE](trait,name)
     ]
     [
     tti::has\_type\_'name'[br]
@@ -39,8 +39,8 @@
   [
     [Type with check]
     [
- TTI\_HAS\_TYPE\_CHECK\_TYPEDEF(name)[br]
- TTI\_TRAIT\_HAS\_TYPE\_CHECK\_TYPEDEF(trait,name)
+ [macroref TTI_HAS_TYPE_CHECK_TYPEDEF TTI\_HAS\_TYPE\_CHECK\_TYPEDEF](name)[br]
+ [macroref TTI_TRAIT_HAS_TYPE_CHECK_TYPEDEF TTI\_TRAIT\_HAS\_TYPE\_CHECK\_TYPEDEF](trait,name)
     ]
     [
     tti::has\_type\_check\_typedef\_'name'[br]
@@ -50,8 +50,8 @@
   [
     [Class Template]
     [
- TTI\_HAS\_TEMPLATE(name)[br]
- TTI\_TRAIT\_HAS\_TEMPLATE(trait,name)
+ [macroref TTI_HAS_TEMPLATE TTI\_HAS\_TEMPLATE](name)[br]
+ [macroref TTI_TRAIT_HAS_TEMPLATE TTI\_TRAIT\_HAS\_TEMPLATE](trait,name)
     ]
     [
     tti::has\_template\_'name'[br]
@@ -62,8 +62,8 @@
   [
     [Class Template with params]
     [
- TTI\_HAS\_TEMPLATE\_CHECK\_PARAMS(name,ppSeq[footnote A Boost PP data sequence with each comma separated portion of the template parameters as its own sequence element.])[br]
- TTI\_TRAIT\_HAS\_TEMPLATE\_CHECK\_PARAMS(trait,name,ppSeq)
+ [macroref TTI_HAS_TEMPLATE_CHECK_PARAMS TTI\_HAS\_TEMPLATE\_CHECK\_PARAMS](name,ppSeq[footnote A Boost PP data sequence with each comma separated portion of the template parameters as its own sequence element.])[br]
+ [macroref TTI_TRAIT_HAS_TEMPLATE_CHECK_PARAMS TTI\_TRAIT\_HAS\_TEMPLATE\_CHECK\_PARAMS](trait,name,ppSeq)
     ]
     [
     tti::has\_template\_check\_params\_'name'[br]
@@ -73,8 +73,8 @@
   [
     [Class Template with params using variadic macros[footnote Header file is TTIntrospectionVM.hpp.]]
     [
- TTI\_VM\_HAS\_TEMPLATE\_CHECK\_PARAMS(name,...[footnote The template parameters as variadic data.])[br]
- TTI\_VM\_TRAIT\_HAS\_TEMPLATE\_CHECK\_PARAMS(trait,name,...)
+ [macroref TTI_VM_HAS_TEMPLATE_CHECK_PARAMS TTI\_VM\_HAS\_TEMPLATE\_CHECK\_PARAMS](name,...[footnote The template parameters as variadic data.])[br]
+ [macroref TTI_VM_TRAIT_HAS_TEMPLATE_CHECK_PARAMS TTI\_VM\_TRAIT\_HAS\_TEMPLATE\_CHECK\_PARAMS](trait,name,...)
     ]
     [
     tti::has\_template\_check\_params\_'name'[br]
@@ -84,8 +84,8 @@
   [
     [Data or function member]
     [
- TTI\_HAS\_MEMBER(name)[br]
- TTI\_TRAIT\_HAS\_MEMBER(trait,name)
+ [macroref TTI_HAS_MEMBER TTI\_HAS\_MEMBER](name)[br]
+ [macroref TTI_TRAIT_HAS_MEMBER TTI\_TRAIT\_HAS\_MEMBER](trait,name)
     ]
     [
     tti::has\_member\_'name'[br]
@@ -97,8 +97,8 @@
   [
     [Static data or static function member]
     [
- TTI\_HAS\_STATIC\_MEMBER(name)[br]
- TTI\_TRAIT\_HAS\_STATIC\_MEMBER(trait,name)
+ [macroref TTI_HAS_STATIC_MEMBER TTI\_HAS\_STATIC\_MEMBER](name)[br]
+ [macroref TTI_TRAIT_HAS_STATIC_MEMBER TTI\_TRAIT\_HAS\_STATIC\_MEMBER](trait,name)
     ]
     [
     tti::has\_static\_member\_'name'[br]
@@ -121,8 +121,8 @@
   [
     [Type]
     [
- TTI\_MEMBER\_TYPE(name)[br]
- TTI\_TRAIT\_MEMBER\_TYPE(trait,name)
+ [macroref TTI_MEMBER_TYPE TTI\_MEMBER\_TYPE](name)[br]
+ [macroref TTI_TRAIT_MEMBER_TYPE TTI\_TRAIT\_MEMBER\_TYPE](trait,name)
     ]
     [
     tti::member\_type\_'name'[br]

Modified: sandbox/tti/libs/tti/doc/TTIIntroduction.qbk
==============================================================================
--- sandbox/tti/libs/tti/doc/TTIIntroduction.qbk (original)
+++ sandbox/tti/libs/tti/doc/TTIIntroduction.qbk 2011-01-12 12:01:17 EST (Wed, 12 Jan 2011)
@@ -47,11 +47,13 @@
 functionality supporting variadic macros is to be used.
 
 # The main header, which does not require using the library
-support for variadic macros, is 'TTIntrospection.hpp'. This
-can be used for the vast majority of functionality in the library.
+support for variadic macros, is
+[headerref boost/tti/TTIntrospection.hpp 'TTIntrospection.hpp'].
+This can be used for the vast majority of functionality in the library.
 # The secondary header, which uses a very small subset of the
 library functionality, providing an alternate use of a particular
-macro with variadic macro support, is 'TTIntrospectionVM.hpp'.
+macro with variadic macro support, is
+[headerref boost/tti/TTIntrospectionVM.hpp 'TTIntrospectionVM.hpp'].
 
 Furthermore there is a third header file which both of the header
 files above include, called 'TTIntrospectionTemplate.hpp' but

Modified: sandbox/tti/libs/tti/doc/TTIMetafunctions.qbk
==============================================================================
--- sandbox/tti/libs/tti/doc/TTIMetafunctions.qbk (original)
+++ sandbox/tti/libs/tti/doc/TTIMetafunctions.qbk 2011-01-12 12:01:17 EST (Wed, 12 Jan 2011)
@@ -37,7 +37,9 @@
   ]
   [
     [Type]
- [tti::mf\_has\_type]
+ [
+ [classref tti::mf_has_type]
+ ]
     [
     template<class> class HasType[br]
     = generated macro metafunction[br]
@@ -47,7 +49,9 @@
   ]
   [
     [Type with check]
- [tti::mf\_has\_type\_check\_typedef]
+ [
+ [classref tti::mf_has_type_check_typedef]
+ ]
     [
     template<class,class> class HasTypeCheckTypedef[br]
     = generated macro metafunction[br]
@@ -58,7 +62,9 @@
   ]
   [
     [Class Template]
- [tti::mf\_has\_template]
+ [
+ [classref tti::mf_has_template]
+ ]
     [
     template<class> class HasTemplate[br]
     = generated macro metafunction[br]
@@ -70,7 +76,9 @@
   ]
   [
     [Class Template with params]
- [tti::mf\_has\_template\_check\_params]
+ [
+ [classref tti::mf_has_template_check_params]
+ ]
     [
     template<class> class HasTemplateCheckParams[br]
     = generated macro metafunction[br]
@@ -83,7 +91,9 @@
   ]
   [
     [Member data]
- [tti::mf\_has\_member\_data]
+ [
+ [classref tti::mf_has_member_data]
+ ]
     [
     template<class> class HasMember[br]
     = generated macro metafunction[br]
@@ -94,7 +104,9 @@
   ]
   [
     [Member function]
- [tti::mf\_has\_member\_function]
+ [
+ [classref tti::mf_has_member_function]
+ ]
     [
     template<class> class HasMember[br]
     = generated macro metafunction[br]
@@ -106,7 +118,9 @@
   ]
   [
     [Static data]
- [tti::mf\_has\_static\_data]
+ [
+ [classref tti::mf_has_static_data]
+ ]
     [
     template<class,class> class HasStaticMember[br]
     = generated macro metafunction[br]
@@ -117,7 +131,9 @@
   ]
   [
     [Static function]
- [tti::mf\_has\_static\_function]
+ [
+ [classref tti::mf_has_static_function]
+ ]
     [
     template<class,class> class HasStaticMember[br]
     = generated macro metafunction[br]
@@ -152,7 +168,9 @@
   ]
   [
     [Type]
- [tti::mf\_member\_type]
+ [
+ [classref tti::mf_member_type]
+ ]
     [
     template<class> class MemberType[br]
     = generated macro metafunction[br]
@@ -169,49 +187,49 @@
 
 As an example, given the theoretical relationship of types we used before:
 
-struct T
- {
- struct AType
- {
- struct BType
- {
- struct CType
- {
- struct FindType
- {
- };
- }
- };
- };
- };
+ struct T
+ {
+ struct AType
+ {
+ struct BType
+ {
+ struct CType
+ {
+ struct FindType
+ {
+ };
+ }
+ };
+ };
+ };
   
 We can use mf_member_type as follows. First we create our corresponding macro metafunctions:
 
-TTI\_MEMBER\_TYPE(FindType)
-TTI\_MEMBER\_TYPE(AType)
-TTI\_MEMBER\_TYPE(BType)
-TTI\_MEMBER\_TYPE(CType)
+ TTI_MEMBER_TYPE(FindType)
+ TTI_MEMBER_TYPE(AType)
+ TTI_MEMBER_TYPE(BType)
+ TTI_MEMBER_TYPE(CType)
 
 Next we can create a typedef to reflect a nested type called FindType which has the relationship
 as specified above by instantiating using mf_member_type.
 
-typedef
-tti::mf\_member\_type
- <
- tti::member\_type\_FindType,
- tti::mf\_member\_type
- <
- tti::member\_type\_CType,
- tti::mf\_member\_type
- <
- tti::member\_type\_BType,
- tti::member\_type\_AType
- <
- T
- >
- >
- >
- > MyFindType;
+ typedef
+ tti::mf_member_type
+ <
+ tti::member_type_FindType,
+ tti::mf_member_type
+ <
+ tti::member_type_CType,
+ tti::mf_member_type
+ <
+ tti::member_type_BType,
+ tti::member_type_AType
+ <
+ T
+ >
+ >
+ >
+ > MyFindType;
   
 The nested type created can be used with the other nested type metafunctions above.
 The key information above is that the enclosing type is a nullary metafunction,

Modified: sandbox/tti/libs/tti/doc/TTINestedType.qbk
==============================================================================
--- sandbox/tti/libs/tti/doc/TTINestedType.qbk (original)
+++ sandbox/tti/libs/tti/doc/TTINestedType.qbk 2011-01-12 12:01:17 EST (Wed, 12 Jan 2011)
@@ -62,47 +62,47 @@
 whose enclosing type is CType, where CType's enclosing type is BType, where BType's enclosing type
 is AType, and where AType's enclosing type is our original T. We can represent this conventially as:
 
-struct T
- {
- struct AType
- {
- struct BType
- {
- struct CType
- {
- struct FindType
- {
- };
- }
- };
- };
- };
+ struct T
+ {
+ struct AType
+ {
+ struct BType
+ {
+ struct CType
+ {
+ struct FindType
+ {
+ };
+ }
+ };
+ };
+ };
 
 We can represent this by first creating a series of member type macros for each of our nested
 types:
 
-TTI\_MEMBER\_TYPE(FindType)
-TTI\_MEMBER\_TYPE(AType)
-TTI\_MEMBER\_TYPE(BType)
-TTI\_MEMBER\_TYPE(CType)
+ TTI_MEMBER_TYPE(FindType)
+ TTI_MEMBER_TYPE(AType)
+ TTI_MEMBER_TYPE(BType)
+ TTI_MEMBER_TYPE(CType)
 
 Next we can create a typedef to reflect a nested type called FindType which has the relationship
 as specified above by instantiating our macro metafunctions.
 
-typedef typename
-tti::member\_type\_FindType
- <
- typename tti::member\_type\_CType
- <
- typename tti::member\_type\_BType
- <
- typename tti::member\_type\_AType
- <
- T
- >::type
- >::type
- >::type
- > MyFindType;
+ typedef typename
+ tti::member_type_FindType
+ <
+ typename tti::member_type_CType
+ <
+ typename tti::member_type_BType
+ <
+ typename tti::member_type_AType
+ <
+ T
+ >::type
+ >::type
+ >::type
+ > MyFindType;
   
 We can use the above typedef to pass the type of FindType
 to one of our macro metafunctions. FindType may not actually exist but we will not generate
@@ -110,15 +110,15 @@
 
 As one example, let's ask whether FindType has a static member data called MyData of type 'int'. We add:
 
-TTI\_HAS\_STATIC\_MEMBER(MyData)
+ TTI_HAS_STATIC_MEMBER(MyData)
 
 Next we create our metafunction:
 
-tti::has\_static\_member\_MyData
- <
- MyFindType,
- int
- >
+ tti::has_static_member_MyData
+ <
+ MyFindType,
+ int
+ >
   
 and use this in our metaprogramming code. Our metafunction now tells us whether the nested type
 FindType has a static member data called MyData of type 'int', even if FindType does not actually
@@ -127,24 +127,24 @@
 We can also find out whether the deeply nested type 'FindType' actually exists in a similar manner.
 Our metafunction would be:
 
-TTI\_HAS\_TYPE(FindType)
+ TTI_HAS_TYPE(FindType)
 
-tti::has\_type\_FindType
- <
- typename
- tti::member\_type\_CType
- <
- typename
- tti::member\_type\_BType
- <
- typename
- tti::member\_type\_AType
- <
- T
- >::type
- >::type
- >::type
- >
+ tti::has_type_FindType
+ <
+ typename
+ tti::member_type_CType
+ <
+ typename
+ tti::member_type_BType
+ <
+ typename
+ tti::member_type_AType
+ <
+ T
+ >::type
+ >::type
+ >::type
+ >
   
 Because this duplicates much of our code to create our nested type as a metafunction,
 TTI\_MEMBER\_TYPE also has, as a convenience, a boolean compile-time constant value


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk