Skip to content

Commit 5b15d6c

Browse files
committed
json_conv_traits -> json_traits
1 parent 20458bd commit 5b15d6c

16 files changed

Lines changed: 544 additions & 155 deletions

doc/ref/corelib/reflect.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,21 +9,21 @@ See [Eigen::Matrix example](json_type_traits/Eigen-Matrix-example.md) for an exa
99

1010
Note that in typical cases traits can be generated by the convenience macros described below.
1111

12-
### jsoncons::reflect::json_conv_traits
12+
### jsoncons::reflect::json_traits
1313

14-
jsoncons 1.4.0 introduces new trait definitions, [json_conv_traits](reflect/json_conv_traits.md), that support
14+
jsoncons 1.4.0 introduces new trait definitions, [json_traits](reflect/json_traits.md), that support
1515
non-throwing conversions and [uses-allocator construction](https://en.cppreference.com/w/cpp/memory/uses_allocator.html).
1616

17-
See [Eigen::Matrix example](reflect/Eigen-Matrix-example.md) for an example of specializing `json_conv_traits` for an [Eigen matrix class](https://eigen.tuxfamily.org/dox-devel/group__TutorialMatrixClass.html).
17+
See [Eigen::Matrix example](reflect/Eigen-Matrix-example.md) for an example of specializing `json_traits` for an [Eigen matrix class](https://eigen.tuxfamily.org/dox-devel/group__TutorialMatrixClass.html).
1818

19-
See [User-allocator construction example](reflect/uses-allocator-construction-example.md) for an example that illustrates uses-allocator construction for types with `json_conv_traits` defined.
19+
See [User-allocator construction example](reflect/uses-allocator-construction-example.md) for an example that illustrates uses-allocator construction for types with `json_traits` defined.
2020

21-
For backwards compatability, `json_conv_traits` defaults to `json_type_traits` if a type conversion is undefined.
21+
For backwards compatability, `json_traits` defaults to `json_type_traits` if a type conversion is undefined.
2222

2323
### Convenience macros
2424

2525
jsoncons includes some [convenience macros](reflect/reflect-traits-gen.md) for generating reflection traits classes.
2626
Until 1.4.0, these macros generated [json_type_traits](json_type_traits/json_type_traits.md) class templates. Since 1.4.0, they
27-
generate [json_conv_traits](reflect/json_conv_traits.md) class templates, as well as some additional traits that support streaming.
27+
generate [json_traits](reflect/json_traits.md) class templates, as well as some additional traits that support streaming.
2828

2929

doc/ref/corelib/reflect/Eigen-Matrix-example.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
### Eigen::Matrix examples
22

3-
This example shows how to specialize [json_conv_traits](json_conv_traits.md) for an [Eigen matrix class](https://eigen.tuxfamily.org/dox-devel/group__TutorialMatrixClass.html).
4-
It defines separate `json_conv_traits` class templates for the dynamic and fixed sized row/column cases.
3+
This example shows how to specialize [json_traits](json_traits.md) for an [Eigen matrix class](https://eigen.tuxfamily.org/dox-devel/group__TutorialMatrixClass.html).
4+
It defines separate `json_traits` class templates for the dynamic and fixed sized row/column cases.
55

66
```cpp
77
#include <jsoncons/json.hpp>
@@ -15,7 +15,7 @@ namespace reflect {
1515
// fixed sized row/columns
1616

1717
template <typename Json, typename Scalar, std::size_t RowsAtCompileTime, std::size_t ColsAtCompileTime>
18-
struct json_conv_traits<Json, Eigen::Matrix<Scalar, RowsAtCompileTime, ColsAtCompileTime>>
18+
struct json_traits<Json, Eigen::Matrix<Scalar, RowsAtCompileTime, ColsAtCompileTime>>
1919
{
2020
using allocator_type = typename Json::allocator_type;
2121
using matrix_type = Eigen::Matrix<Scalar, RowsAtCompileTime, ColsAtCompileTime>;
@@ -91,7 +91,7 @@ struct json_conv_traits<Json, Eigen::Matrix<Scalar, RowsAtCompileTime, ColsAtCom
9191
// dynamic sized row/columns
9292

9393
template <typename Json, typename Scalar>
94-
struct json_conv_traits<Json, Eigen::Matrix<Scalar, Eigen::Dynamic, Eigen::Dynamic>>
94+
struct json_traits<Json, Eigen::Matrix<Scalar, Eigen::Dynamic, Eigen::Dynamic>>
9595
{
9696
using allocator_type = typename Json::allocator_type;
9797
using matrix_type = Eigen::Matrix<Scalar, Eigen::Dynamic, Eigen::Dynamic>;

0 commit comments

Comments
 (0)