Skip to content

Commit 0ac8105

Browse files
committed
Missing documentation and more doc
1 parent 11b143e commit 0ac8105

29 files changed

+443
-300
lines changed

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
## SPDX-License-Identifier: BSL-1.0
55
##======================================================================================================================
66
cmake_minimum_required(VERSION 3.22)
7-
project(kumi LANGUAGES CXX)
7+
project(KUMI LANGUAGES CXX)
88

99
##======================================================================================================================
1010
option( KUMI_BUILD_TEST "Build tests using Kumi headers" ON )

doc/index.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@
105105
//!
106106
//! This library is licensed under the [Boost Software License](https://opensource.org/licenses/BSL):
107107
//!
108-
//! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~none
108+
//! ```text
109109
//! Copyright : KUMI Project Contributors
110110
//!
111111
//! Boost Software License - Version 1.0 - August 17th, 2003
@@ -131,6 +131,6 @@
131131
//! FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
132132
//! ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
133133
//! DEALINGS IN THE SOFTWARE.
134-
//! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
134+
//! ```
135135
//!
136136
//==================================================================================================

doc/layout.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
</tab>
1111
<tab type="usergroup" visible="yes" title="Reference Documentation">
1212
<tab type="usergroup" visible="yes" title="Types">
13-
<tab type="user" url="@ref product_types" title="Product types"/>
14-
<tab type="user" url="@ref record_types" title="Record Types"/>
13+
<tab type="user" url="@ref tuple" title="Product types"/>
14+
<tab type="user" url="@ref record" title="Record Types"/>
1515
</tab>
1616
<tab type="usergroup" visible="yes" title="Algorithms">
1717
<tab type="user" url="@ref transforms" title="Transformations"/>

doc/licence.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Licence {#licence}
33

44
This library is licensed under the [Boost Software License](http://opensource.org/licenses/BSL):
55

6-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~none
6+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
77
Copyright : KUMI Project Contributors
88
99
Boost Software License - Version 1.0 - August 17th, 2003

include/kumi/algorithm.hpp

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,19 +13,16 @@ namespace kumi
1313
//! @defgroup algorithm Product Type Algorithms
1414
//! @brief Algorithms for manipulating Product types
1515
//!
16-
//! @addtogroup algorithm
1716
//! @{
1817
//! @defgroup transforms Product Type Transformations
1918
//! @brief Algorithms applying transformation to product types
20-
//!
21-
//! @addtogroup transforms
22-
//! @{
19+
//! @{
2320
//! @defgroup tuple_transforms Tuple Type Specific Transformations
2421
//! @brief Algorithms applying transformation to tuples
25-
//!
22+
//!
2623
//! @defgroup record_transforms Record Type Specific Transformations
27-
//! @brief Algorithms applying transformation to records
28-
//! @}
24+
//! @brief Algorithms applying transformation to records
25+
//! @}
2926
//!
3027
//! @defgroup queries Product Type Queries
3128
//! @brief Algorithms querying properties from product types

include/kumi/algorithm/cartesian_product.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,9 @@ namespace kumi
3737
}
3838

3939
//====================================================================================================================
40-
//! @ingroup generators
40+
//! @ingroup generators
4141
//! @brief Return the Cartesian Product of all elements of its arguments product types
42-
//! @param ts Product types to process
42+
//! @param ts Product types to process
4343
//! @return A tuple containing all the product types built from all combination of all ts'
4444
//! elements
4545
//!

include/kumi/algorithm/cast.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ namespace kumi
3030
}
3131

3232
//====================================================================================================================
33-
//! @ingroup algorithms
34-
//! @brief Converts a product_type<Ts...> to an instance of a product_type<Target...>
33+
//! @ingroup generators
34+
//! @brief Converts a product_type<Ts...> to an instance of a product_type<Target...>
3535
//!
3636
//! @tparam Target destination type to associate to each member of the product type `t`
3737
//! @param t Product type to convert

include/kumi/algorithm/cat.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
namespace kumi
1111
{
1212
//====================================================================================================================
13-
//! @ingroup generators
14-
//! @brief Concatenates product types in a single one
13+
//! @ingroup generators
14+
//! @brief Concatenates product types in a single one
1515
//!
1616
//! @param ts Product types to concatenate
1717
//! @return A product type made of all element of all input product types in order.

include/kumi/algorithm/contains.hpp

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ namespace kumi
1616
}
1717

1818
//====================================================================================================================
19-
//! @ingroup algorithm
19+
//! @ingroup queries
2020
//! @brief Checks if a product type contains a given identifier
2121
//!
2222
//! @param t the product type to inspect.
@@ -27,25 +27,25 @@ namespace kumi
2727
//! @include doc/tuple/algo/contains.cpp
2828
//! @include doc/record/algo/contains.cpp
2929
//====================================================================================================================
30-
template<concepts::product_type T, concepts::identifier I>
31-
KUMI_ABI constexpr bool contains([[maybe_unused]] T&& t, [[maybe_unused]] I const& id) noexcept
30+
template<concepts::product_type T, concepts::identifier ID>
31+
KUMI_ABI constexpr bool contains([[maybe_unused]] T&& t, [[maybe_unused]] ID const& id) noexcept
3232
{
3333
if constexpr (concepts::sized_product_type<T, 0>) return false;
3434
else if constexpr (concepts::record_type<T>)
3535
return []<std::size_t... I>(std::index_sequence<I...>) {
36-
return _::can_get_field_by_value<std::remove_cvref_t<K>, element_t<I, T>...>;
36+
return _::can_get_field_by_value<std::remove_cvref_t<ID>, element_t<I, T>...>;
3737
}(std::make_index_sequence<size_v<T>>{});
3838
else
3939
return []<std::size_t... I>(std::index_sequence<I...>) {
40-
if constexpr (((concepts::field<element_t<I, T>> && std::invocable<element_t<I, T>, std::remove_cvref_t<K>>) ||
40+
if constexpr (((concepts::field<element_t<I, T>> && std::invocable<element_t<I, T>, std::remove_cvref_t<ID>>) ||
4141
...))
4242
return true;
4343
else return false;
4444
}(std::make_index_sequence<size_v<T>>{});
4545
}
4646

4747
//====================================================================================================================
48-
//! @ingroup algorithm
48+
//! @ingroup queries
4949
//! @brief Checks if a product type contains at least one of many identifiers
5050
//!
5151
//! @param t the product type to inspect.
@@ -60,12 +60,12 @@ namespace kumi
6060
KUMI_ABI constexpr bool contains_any(T&& t, Is const&... ids) noexcept
6161
{
6262
if constexpr (concepts::sized_product_type<T, 0>) return false;
63-
else if constexpr (sizeof...(Ks) == 0) return false;
64-
else return (contains(KUMI_FWD(t), ks) || ...);
63+
else if constexpr (sizeof...(Is) == 0) return false;
64+
else return (contains(KUMI_FWD(t), ids) || ...);
6565
}
6666

6767
//==================================================================================================================
68-
//! @ingroup algorithm
68+
//! @ingroup queries
6969
//! @brief Checks if a product type contains fields based only on selected identifiers
7070
//!
7171
//! @param t the product type to inspect.
@@ -80,16 +80,16 @@ namespace kumi
8080
KUMI_ABI constexpr bool contains_only([[maybe_unused]] T&& t, [[maybe_unused]] Is const&... ids) noexcept
8181
{
8282
if constexpr (concepts::sized_product_type<T, 0>) return false;
83-
else if constexpr (sizeof...(Ks) == 0) return false;
84-
else if constexpr (sizeof...(Ks) < size_v<T>) return false;
83+
else if constexpr (sizeof...(Is) == 0) return false;
84+
else if constexpr (sizeof...(Is) < size_v<T>) return false;
8585
else
8686
return [&]<std::size_t... I>(std::index_sequence<I...>) {
87-
return (_::contains<element_t<I, T>, Ks...> && ...);
87+
return (_::contains<element_t<I, T>, Is...> && ...);
8888
}(std::make_index_sequence<size_v<T>>{});
8989
}
9090

9191
//==================================================================================================================
92-
//! @ingroup algorithm
92+
//! @ingroup queries
9393
//! @brief Checks if a product type contains no fields based on any of the selected identifiers
9494
//!
9595
//! @param t the product type to inspect.
@@ -103,6 +103,6 @@ namespace kumi
103103
template<concepts::product_type T, concepts::identifier... Is>
104104
KUMI_ABI constexpr bool contains_none(T&& t, Is const&... ids) noexcept
105105
{
106-
return !contains_any(KUMI_FWD(t), ks...);
106+
return !contains_any(KUMI_FWD(t), ids...);
107107
}
108108
}

include/kumi/product_types.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@ namespace kumi
1313
//! @defgroup types Kumi Types
1414
//! @brief Class definition and functions on kumi types
1515
//!
16-
//! @defgroup product_types Product Types and associated Functions
17-
//! @ingroup types
16+
//! @defgroup tuple Product Types and associated Functions
17+
//! @ingroup types
1818
//! @brief Definition for kumi defined product type classes and functions
1919
//!
20-
//! @defgroup record_types Record Types and associated Functions
21-
//! @ingroup types
20+
//! @defgroup record Record Types and associated Functions
21+
//! @ingroup types
2222
//! @brief Definition for kumi defined record type classes and functions
2323
//================================================================================================
2424
}

0 commit comments

Comments
 (0)