21#include <daw/daw_arith_traits.h>
22#include <daw/daw_cpp_feature_check.h>
23#include <daw/daw_fwd_pack_apply.h>
24#include <daw/daw_move.h>
25#include <daw/daw_parser_helper_sv.h>
26#include <daw/daw_scope_guard.h>
27#include <daw/daw_string_view.h>
28#include <daw/daw_traits.h>
40 struct json_deduce_type;
42 template<
typename ParseState>
45 namespace json_details {
51 typename daw::detected_or_t<T, ordered_member_subtype_test, T>;
53 template<
typename T,
typename Default>
57 template<
typename Value,
typename Constructor,
typename ParseState,
59 [[maybe_unused]] DAW_ATTRIB_FLATINLINE
static inline constexpr auto
64 if constexpr( ParseState::has_allocator ) {
66 typename ParseState::template allocator_type_as<Value>;
67 auto alloc =
parse_state.get_allocator_for( template_arg<Value> );
68 if constexpr( std::is_invocable<Constructor, Args...,
70 return Constructor{ }( DAW_FWD2( Args, args )...,
72 }
else if constexpr( daw::traits::is_callable_v<Constructor,
75 return Constructor{ }( std::allocator_arg, DAW_MOVE( alloc ),
76 DAW_FWD2( Args, args )... );
79 std::is_invocable<Constructor, Args...>::value,
80 "Unable to construct value with the supplied arguments" );
81 return Constructor{ }( DAW_FWD2( Args, args )... );
85 std::is_invocable<Constructor, Args...>::value,
86 "Unable to construct value with the supplied arguments" );
87 return Constructor{ }( DAW_FWD2( Args, args )... );
91 template<
typename Constructor>
93 template<
typename... TArgs, std::size_t... Is>
94 DAW_ATTRIB_FLATINLINE
inline constexpr decltype( auto )
95 operator( )( fwd_pack<TArgs...> &&tp,
96 std::index_sequence<Is...> )
const {
97 return Constructor{ }( get<Is>( DAW_MOVE( tp ) )... );
100 template<
typename... TArgs,
typename Allocator, std::size_t... Is>
101 DAW_ATTRIB_FLATINLINE
inline constexpr decltype( auto )
102 operator( )( fwd_pack<TArgs...> &&tp, Allocator &alloc,
103 std::index_sequence<Is...> )
const {
104 return Constructor{ }( get<Is>( DAW_MOVE( tp ) )...,
105 DAW_FWD2( Allocator, alloc ) );
108 template<
typename Alloc,
typename... TArgs, std::size_t... Is>
109 DAW_ATTRIB_FLATINLINE
inline constexpr decltype( auto )
110 operator( )( std::allocator_arg_t, Alloc &&alloc,
111 fwd_pack<TArgs...> &&tp,
112 std::index_sequence<Is...> )
const {
114 return Constructor{ }( std::allocator_arg, DAW_FWD2( Alloc, alloc ),
115 get<Is>( DAW_MOVE( tp ) )... );
119 template<
typename Constructor>
123 template<
typename Value,
typename Constructor,
typename ParseState,
125 [[maybe_unused]] DAW_ATTRIB_FLATINLINE
static inline constexpr auto
127 fwd_pack<Args...> &&tp_args ) {
128 if constexpr( ParseState::has_allocator ) {
130 typename ParseState::template allocator_type_as<Value>;
131 auto alloc =
parse_state.get_allocator_for( template_arg<Value> );
132 if constexpr( std::is_invocable<Constructor, Args...,
134 return construct_value_tp_invoke<Constructor>(
135 DAW_MOVE( tp_args ), DAW_MOVE( alloc ),
136 std::index_sequence_for<Args...>{ } );
137 }
else if constexpr( daw::traits::is_callable_v<Constructor,
138 std::allocator_arg_t,
139 alloc_t, Args...> ) {
140 return construct_value_tp_invoke<Constructor>(
141 std::allocator_arg, DAW_MOVE( alloc ), DAW_MOVE( tp_args ),
142 std::index_sequence_for<Args...>{ } );
145 std::is_invocable<Constructor, Args...>::value,
146 "Unable to construct value with the supplied arguments" );
147 return construct_value_tp_invoke<Constructor>(
148 DAW_MOVE( tp_args ), std::index_sequence_for<Args...>{ } );
154 std::is_invocable<Constructor, Args...>::value,
155 "Unable to construct value with the supplied arguments" );
156 return construct_value_tp_invoke<Constructor>(
157 DAW_MOVE( tp_args ), std::index_sequence_for<Args...>{ } );
161 template<
typename Allocator>
163 decltype( std::declval<Allocator &>( ).allocate(
size_t{ 1 } ) );
165 template<
typename Allocator>
167 decltype( std::declval<Allocator &>( ).deallocate(
168 static_cast<void *
>(
nullptr ),
size_t{ 1 } ) );
170 template<
typename Allocator>
172 daw::is_detected<has_allocate_test, Allocator>,
173 daw::is_detected<has_deallocate_test, Allocator>>::value;
177 not_trait<std::is_same<missing_json_data_contract_for<T>,
183 template<
typename Container,
typename Value>
185 std::declval<Value>( ) ) );
187 template<
typename Container,
typename Value>
189 std::end( std::declval<Container &>( ) ), std::declval<Value>( ) ) );
191 template<
typename Container,
typename Value>
193 daw::is_detected<detect_push_back, Container, Value>::value;
195 template<
typename Container,
typename Value>
197 daw::is_detected<detect_insert_end, Container, Value>::value;
199 template<
typename JsonMember>
202 template<
typename JsonMember>
205 template<
typename Container>
217 template<
typename Value>
218 DAW_ATTRIB_FLATINLINE
inline constexpr void
219 operator( )( Value &&value )
const {
221 daw::remove_cvref_t<Value>> ) {
222 m_container->push_back( DAW_FWD2( Value, value ) );
224 daw::remove_cvref_t<Value>> ) {
226 DAW_FWD2( Value, value ) );
229 has_push_back_v<Container, daw::remove_cvref_t<Value>> or
230 has_insert_end_v<Container, daw::remove_cvref_t<Value>>,
231 "basic_appender requires a Container that either has push_back "
233 "insert with the end iterator as first argument" );
240 not std::is_same<basic_appender, daw::remove_cvref_t<Value>>::value,
241 std::nullptr_t> =
nullptr>
243 operator( )( DAW_FWD2( Value, v ) );
266 daw::is_detected<json_parser_to_json_data_t, T>::value;
274 daw::is_detected<is_submember_tagged_variant_t, T>::value;
282 template<
typename JsonType>
284 std::bool_constant<JsonType::expected_type == JsonParseTypes::Null>;
286 template<
typename JsonType>
293 template<
json_options_t CurrentOptions,
auto option,
auto... options>
297 template<
json_options_t CurrentOptions,
auto option,
auto... options>
301 template<
json_options_t CurrentOptions,
auto option,
auto... options>
305 template<
json_options_t CurrentOptions,
auto option,
auto... options>
309 template<
json_options_t CurrentOptions,
auto option,
auto... options>
313 template<
json_options_t CurrentOptions,
auto option,
auto... options>
317 template<
json_options_t CurrentOptions,
auto option,
auto... options>
322 namespace json_base {
323 template<
typename T,
typename Constructor = default_constructor<T>,
324 json_details::json_options_t Options =
class_opts_def>
327 template<
typename T,
typename Constructor = nullable_constructor<T>,
328 json_details::json_options_t Options =
class_opts_def>
331 json_details::class_opts_set<Options, JsonNullDefault>>;
333 template<
typename JsonElement,
typename Container,
338 template<
typename JsonElement,
typename Container,
352 T, json_details::string_raw_opts_set<Options, JsonNullDefault>,
389 template<
typename Container,
typename JsonValueType,
typename JsonKeyType,
394 template<
typename Container,
typename JsonValueType,
typename JsonKeyType,
397 json_key_value<Container, JsonValueType, JsonKeyType, Constructor,
400 template<
typename Tuple,
403 typename JsonTupleTypesList = json_deduce_type>
406 template<
typename Tuple,
409 typename JsonTupleTypesList = json_deduce_type>
412 json_details::tuple_opts_set<Options, JsonNullDefault>,
425 template<
typename T,
typename Constructor = default_constructor<T>,
426 JsonNullable Nullable = JsonNullable::MustExist>
438 template<
typename T,
typename Constructor = nullable_constructor<T>>
442 namespace json_details {
445 static_assert( daw::is_arithmetic<T>::value,
"Unexpected non-number" );
446 if constexpr( daw::is_floating_point<T>::value ) {
448 }
else if constexpr( daw::is_signed<T>::value ) {
450 }
else if constexpr( daw::is_unsigned<T>::value ) {
459 return number_parse_type_impl_v<std::underlying_type_t<T>>;
465 return number_parse_type_impl_v<T>;
472 template<
typename,
typename =
void>
480 template<
typename JsonType>
482 JsonType, std::enable_if_t<json_details::is_a_json_type_v<JsonType>>> {
483 static constexpr bool is_null =
false;
486 using type = JsonType;
491 struct json_deduced_type_map<
492 T, std::enable_if_t<json_details::has_json_data_contract_trait_v<T>>> {
493 static constexpr bool is_null =
false;
510 static constexpr bool is_null =
false;
517 struct json_deduced_type_map<std::string> {
518 static constexpr bool is_null =
false;
535#if defined( _LIBCPP_VERSION )
538 typename std::vector<bool>::const_reference> {
540 static constexpr bool is_null =
false;
547 template<
typename Integer>
548 struct json_deduced_type_map<
550 std::enable_if_t<std::conjunction_v<
551 not_trait<json_details::has_json_data_contract_trait<Integer>>,
552 daw::is_integral<Integer>>>> {
553 static constexpr bool is_null =
false;
561 template<
typename Enum>
562 struct json_deduced_type_map<
563 Enum, std::enable_if_t<std::conjunction_v<
564 not_trait<json_details::has_json_data_contract_trait<Enum>>,
565 std::is_enum<Enum>>>> {
566 static constexpr bool is_null =
false;
568 daw::is_signed_v<std::underlying_type<Enum>>
575 template<
typename FloatingPo
int>
576 struct json_deduced_type_map<
578 std::enable_if_t<std::conjunction_v<
579 not_trait<json_details::has_json_data_contract_trait<FloatingPoint>>,
580 daw::is_floating_point<FloatingPoint>>>> {
581 static constexpr bool is_null =
false;
587 template<
typename Tuple>
588 struct json_deduced_type_map<
589 Tuple, std::enable_if_t<std::conjunction_v<
590 not_trait<json_details::has_json_data_contract_trait<Tuple>>,
592 static constexpr bool is_null =
false;
598 namespace container_detect {
602 template<
typename Container>
604 decltype( std::begin( std::declval<Container const &>( ) ) );
606 template<
typename Container>
608 decltype( std::end( std::declval<Container const &>( ) ) );
612 std::conjunction_v<daw::is_detected<container_value_type, T>,
613 daw::is_detected<container_begin_type, T>,
614 daw::is_detected<container_end_type, T>>;
616 template<
typename AssociativeContainer>
619 template<
typename AssociativeContainer>
621 typename AssociativeContainer::mapped_type;
629 daw::is_detected<container_detect::container_value_type, T>,
630 daw::is_detected<container_detect::container_begin_type, T>,
631 daw::is_detected<container_detect::container_end_type, T>>;
633 template<
typename Container>
636 template<
typename String>
638 std::conjunction<is_container<String>,
641 template<
typename String>
644 template<
typename AssociativeContainer>
648 AssociativeContainer>,
650 AssociativeContainer>>;
652 template<
typename AssociativeContainer>
656 template<
typename AssociativeContainer>
658 AssociativeContainer,
659 std::enable_if_t<std::conjunction_v<
660 not_trait<has_json_data_contract_trait<AssociativeContainer>>,
661 is_associative_container<AssociativeContainer>>>> {
663 static constexpr bool is_null =
false;
664 using key =
typename AssociativeContainer::key_type;
665 using value =
typename AssociativeContainer::mapped_type;
671 template<
typename Container>
672 struct json_deduced_type_map<
673 Container, std::enable_if_t<std::conjunction_v<
674 not_trait<has_json_data_contract_trait<Container>>,
675 not_trait<is_associative_container<Container>>,
676 json_details::is_container<Container>,
677 not_trait<is_string<Container>>>>> {
679 static constexpr bool is_null =
false;
680 using value =
typename Container::value_type;
687 struct json_deduced_type_map<
689 std::enable_if_t<std::conjunction_v<
690 not_trait<has_json_data_contract_trait<std::optional<T>>>,
691 daw::is_detected<json_deduced_type_map, T>>>> {
693 static constexpr bool is_null =
true;
694 using type = json_deduced_type_map<T>;
702 std::bool_constant<json_deduced_type_map<T>::type_map_found>;
708 template<
typename Mapped,
bool Found = true>
713 template<
auto Value,
auto... Values>
715 std::bool_constant<( ( Value == Values ) or ... )>;
717 template<
auto Value,
auto... Values>
723 if constexpr( is_a_json_type_v<T> ) {
725 }
else if constexpr( has_deduced_type_mapping_v<T> ) {
727 using parse_type = daw::constant<mapped_type_t::parse_type>;
728 using is_null = daw::constant<mapped_type_t::is_null>;
730 if constexpr( is_null::value ) {
735 }
else if constexpr( parse_type::value ==
737 if constexpr( is_null::value ) {
743 }
else if constexpr( parse_type::value ==
745 if constexpr( is_null::value ) {
752 if constexpr( is_null::value ) {
761 if constexpr( is_null::value ) {
768 if constexpr( is_null::value ) {
774 if constexpr( is_null::value ) {
775 using b_t =
typename mapped_type_t::base_type;
776 using k_t =
typename b_t::key;
777 using v_t =
typename b_t::value;
781 using k_t =
typename mapped_type_t::key;
782 using v_t =
typename mapped_type_t::value;
787 if constexpr( is_null::value ) {
788 using b_t =
typename mapped_type_t::base_type;
789 using v_t =
typename b_t::value;
793 using v_t =
typename mapped_type_t::value;
819 typename decltype( json_link_quick_map<T>( ) )::mapped_type;
821 namespace vector_detect {
825 static constexpr bool value =
false;
829 template<
typename T,
typename Alloc>
831 static constexpr bool value =
true;
841 std::bool_constant<vector_detect::vector_test<T>::value>;
843 template<
typename JsonType>
848 template<
typename JsonType>
852 template<
typename JsonType>
860 std::conjunction_v<has_json_data_contract_trait<T>,
863 template<
typename T,
bool Ordered,
bool Contract,
bool JsonType,
864 bool QuickMap,
bool Container>
869 template<
typename T,
bool Contract,
bool JsonType,
870 bool QuickMap,
bool Container>
886 template<
typename T,
bool JsonType,
bool QuickMap,
890 static_assert( not std::is_same_v<T, void> );
899 static_assert( not std::is_same_v<daw::remove_cvref_t<type>,
void>,
900 "Detection failure" );
902 not std::is_same_v<daw::remove_cvref_t<type>, daw::nonesuch>,
903 "Detection failure" );
907 bool QuickMap,
bool Container>
909 static_assert( not std::is_same_v<T, void> );
911 typename std::conditional_t<is_json_class_map_v<T>,
913 daw::traits::identity<T>>
::type;
914 static_assert( not std::is_same_v<daw::remove_cvref_t<type>,
void>,
915 "Detection failure" );
917 not std::is_same_v<daw::remove_cvref_t<type>, daw::nonesuch>,
918 "Detection failure" );
921 template<
typename T ,
924 static_assert( not std::is_same_v<T, void> );
926 static_assert( not std::is_same_v<daw::remove_cvref_t<type>,
void>,
927 "Detection failure" );
929 not std::is_same_v<daw::remove_cvref_t<type>, daw::nonesuch>,
930 "Detection failure" );
931 static_assert( not std::is_same_v<daw::remove_cvref_t<type>,
void>,
932 "Detection failure" );
938 static_assert( not std::is_same_v<T, void> );
940 static_assert( not std::is_same_v<daw::remove_cvref_t<type>,
void>,
941 "Detection failure" );
943 not std::is_same_v<daw::remove_cvref_t<type>, daw::nonesuch>,
944 "Detection failure" );
945 static_assert( not std::is_same_v<daw::remove_cvref_t<type>,
void>,
946 "Detection failure" );
951 T, is_an_ordered_member_v<T>, has_json_data_contract_trait_v<T>,
952 json_details::is_a_json_type_v<T>, has_json_link_quick_map_v<T>,
953 is_container_v<T>>::type;
958 template<
typename ParsePolicy,
typename JsonMember>
960 ParsePolicy::exec_tag_t::always_rvo;
975 template<
typename JsonMember>
978 template<
typename Constructor,
typename... Members>
980 Constructor{ }( std::declval<typename Members::parse_to_t &&>( )... ) );
982 template<
typename Constructor,
typename... Members>
986 template<
typename Constructor,
typename... Members>
990 template<
typename Constructor,
typename... Members>
992 std::is_invocable_v<Constructor,
typename Members::parse_to_t...>;
994 template<
typename JsonMember>
997 template<
typename JsonMember>
999 daw::is_detected_v<dependent_member_t, JsonMember>;
ParseState & parse_state
Definition: daw_json_parse_class.h:182
typename AssociativeContainer::key_type container_key_type
Definition: daw_json_parse_common.h:617
typename AssociativeContainer::mapped_type container_mapped_type
Definition: daw_json_parse_common.h:621
typename T::value_type container_value_type
Definition: daw_json_parse_common.h:600
decltype(std::begin(std::declval< Container const & >())) container_begin_type
Definition: daw_json_parse_common.h:604
std::is_same< char, container_value_type< T > > is_value_type_char
Definition: daw_json_parse_common.h:624
constexpr bool container_detect_v
Definition: daw_json_parse_common.h:611
decltype(std::end(std::declval< Container const & >())) container_end_type
Definition: daw_json_parse_common.h:608
typename vector_test< T >::type vector_test_t
Definition: daw_json_parse_common.h:836
decltype(std::declval< Container & >().push_back(std::declval< Value >())) detect_push_back
Definition: daw_json_parse_common.h:185
typename json_class_map_type< JsonType >::type json_class_map_type_t
Definition: daw_json_parse_common.h:850
std::bool_constant< JsonType::expected_type==JsonParseTypes::Null > is_json_nullable
Definition: daw_json_parse_common.h:284
typename T::json_member ordered_member_subtype_test
Definition: daw_json_parse_common.h:47
constexpr bool has_json_to_json_data_v
Definition: daw_json_parse_common.h:265
constexpr bool has_json_data_contract_trait_v
Definition: daw_json_parse_common.h:180
decltype(std::declval< Allocator & >().allocate(size_t{ 1 })) has_allocate_test
Definition: daw_json_parse_common.h:163
decltype(Constructor{ }(std::declval< typename Members::parse_to_t && >()...)) json_class_parse_result_impl2
Definition: daw_json_parse_common.h:980
std::conjunction< is_container< AssociativeContainer >, daw::is_detected< container_detect::container_key_type, AssociativeContainer >, daw::is_detected< container_detect::container_mapped_type, AssociativeContainer > > is_associative_container
Definition: daw_json_parse_common.h:650
decltype(json_link_quick_map< T >()) has_json_link_quick_map
Definition: daw_json_parse_common.h:808
constexpr json_options_t string_opts_set
Definition: daw_json_parse_common.h:306
daw::not_trait< std::is_same< json_deduced_type< T >, missing_json_data_contract_for< T > > > has_json_deduced_type
Definition: daw_json_parse_common.h:969
constexpr JsonParseTypes number_parse_type_v
Definition: daw_json_parse_common.h:470
constexpr json_options_t tuple_opts_set
Definition: daw_json_parse_common.h:318
constexpr json_options_t bool_opts_set
Definition: daw_json_parse_common.h:302
constexpr bool equal_to_one_of_v
Definition: daw_json_parse_common.h:718
constexpr bool has_push_back_v
Definition: daw_json_parse_common.h:192
constexpr bool has_unnamed_default_type_mapping_v
Definition: daw_json_parse_common.h:972
constexpr bool has_dependent_member_v
Definition: daw_json_parse_common.h:998
constexpr auto json_link_quick_map()
Definition: daw_json_parse_common.h:722
constexpr json_options_t set_bits(JsonOptionList< OptionList... >, json_options_t value, Option pol, Options... pols)
Definition: daw_json_option_bits.h:138
typename daw::detected_or_t< T, ordered_member_subtype_test, T > ordered_member_subtype_t
Definition: daw_json_parse_common.h:51
daw::detected_t< json_class_parse_result_impl2, Constructor, Members... > json_class_parse_result_impl
Definition: daw_json_parse_common.h:984
std::conjunction< is_container< String >, container_detect::is_value_type_char< String > > is_string
Definition: daw_json_parse_common.h:639
constexpr auto number_parse_type_test() -> std::enable_if_t< std::is_enum< T >::value, JsonParseTypes >
Definition: daw_json_parse_common.h:456
typename decltype(json_link_quick_map< T >())::mapped_type json_link_quick_map_t
Definition: daw_json_parse_common.h:819
std::conjunction< daw::is_detected< container_detect::container_value_type, T >, daw::is_detected< container_detect::container_begin_type, T >, daw::is_detected< container_detect::container_end_type, T > > is_container
Definition: daw_json_parse_common.h:631
static constexpr DAW_ATTRIB_FLATINLINE auto construct_value_tp(ParseState &parse_state, fwd_pack< Args... > &&tp_args)
Definition: daw_json_parse_common.h:126
constexpr bool is_allocator_v
Definition: daw_json_parse_common.h:171
constexpr auto json_class_constructor
Definition: daw_json_parse_common.h:54
constexpr bool is_string_v
Definition: daw_json_parse_common.h:642
typename JsonMember::dependent_member dependent_member_t
Definition: daw_json_parse_common.h:995
std::uint32_t json_options_t
Definition: daw_json_option_bits.h:23
constexpr bool has_deduced_type_mapping_v
Definition: daw_json_parse_common.h:705
typename T::parse_to_t parse_to_t_test
Definition: daw_json_parse_common.h:878
decltype(json_data_contract< T >::to_json_data(std::declval< T & >())) json_parser_to_json_data_t
Definition: daw_json_parse_common.h:262
json_result< json_deduced_type< JsonMember > > from_json_result_t
Definition: daw_json_parse_common.h:976
constexpr bool is_submember_tagged_variant_v
Definition: daw_json_parse_common.h:273
typename json_data_contract< T >::type::i_am_a_submember_tagged_variant is_submember_tagged_variant_t
Definition: daw_json_parse_common.h:270
typename JsonType::json_member json_class_map_type_test
Definition: daw_json_parse_common.h:853
decltype(std::declval< Container & >().insert(std::end(std::declval< Container & >()), std::declval< Value >())) detect_insert_end
Definition: daw_json_parse_common.h:189
std::bool_constant< vector_detect::vector_test< T >::value > is_vector
Definition: daw_json_parse_common.h:841
constexpr bool has_insert_end_v
Definition: daw_json_parse_common.h:196
constexpr json_options_t string_raw_opts_set
Definition: daw_json_parse_common.h:310
constexpr std::size_t parse_space_needed_v< simd_exec_tag >
Definition: daw_json_parse_common.h:280
constexpr JsonParseTypes number_parse_type_impl_v
Definition: daw_json_parse_common.h:444
constexpr bool is_container_v
Definition: daw_json_parse_common.h:634
std::bool_constant< json_deduced_type_map< T >::type_map_found > has_deduced_type_mapping
Definition: daw_json_parse_common.h:702
constexpr auto construct_value_tp_invoke
Definition: daw_json_parse_common.h:120
decltype(std::declval< Allocator & >().deallocate(static_cast< void * >(nullptr), size_t{ 1 })) has_deallocate_test
Definition: daw_json_parse_common.h:168
constexpr json_options_t number_opts_set
Definition: daw_json_parse_common.h:298
constexpr bool is_associative_container_v
Definition: daw_json_parse_common.h:653
static constexpr DAW_ATTRIB_FLATINLINE auto construct_value(template_params< Value, Constructor >, ParseState &parse_state, Args &&...args)
Definition: daw_json_parse_common.h:60
constexpr std::size_t parse_space_needed_v
Definition: daw_json_parse_common.h:277
constexpr bool is_null(std::optional< T > const &v)
Definition: to_daw_json_string.h:951
typename JsonMember::parse_to_t json_result
Definition: daw_json_parse_common.h:200
not_trait< std::is_same< missing_json_data_contract_for< T >, json_data_contract_trait_t< T > > > has_json_data_contract_trait
Definition: daw_json_parse_common.h:178
static constexpr bool is_json_nullable_v
Definition: daw_json_parse_common.h:287
constexpr bool can_defer_construction_v
Definition: daw_json_parse_common.h:991
constexpr bool is_json_class_map_v
Definition: daw_json_parse_common.h:859
typename json_type_deducer< T, is_an_ordered_member_v< T >, has_json_data_contract_trait_v< T >, json_details::is_a_json_type_v< T >, has_json_link_quick_map_v< T >, is_container_v< T > >::type json_deduced_type
Definition: daw_json_parse_common.h:953
daw::remove_cvref_t< json_class_parse_result_impl< Constructor, Members... > > json_class_parse_result_t
Definition: daw_json_parse_common.h:988
constexpr bool has_json_link_quick_map_v
Definition: daw_json_parse_common.h:811
constexpr json_options_t json_custom_opts_set
Definition: daw_json_parse_common.h:314
constexpr bool use_direct_construction_v
Definition: daw_json_parse_common.h:959
typename JsonMember::base_type json_base_type
Definition: daw_json_parse_common.h:203
daw::detected_or_t< Default, json_class_constructor_t_impl, T > json_class_constructor_t
Definition: daw_json_traits.h:516
constexpr json_options_t class_opts_set
Definition: daw_json_parse_common.h:294
std::bool_constant<((Value==Values) or ...)> equal_to_one_of
Definition: daw_json_parse_common.h:715
constexpr json_details::json_options_t string_opts_def
Definition: daw_json_type_options.h:163
JsonParseTypes
The tags used by the parser to determine what parser to call.
Definition: daw_json_enums.h:22
@ Array
A class type with named members.
@ Signed
Number - Floating Point.
@ Unknown
Array - An array type where each element is mapped to the member of a C++ class.
@ Unsigned
Number - Signed Integer.
@ Tuple
A variant type where the Switcher is based on a submember of the class being parsed.
@ StringEscaped
String - A raw string as is. Escapes are left in.
@ Bool
Number - Unsigned Integer.
constexpr auto bool_opts
Definition: daw_json_type_options.h:120
typename json_data_contract< T >::type json_data_contract_trait_t
Definition: daw_json_traits.h:135
constexpr auto string_raw_opts
Definition: daw_json_type_options.h:195
constexpr json_details::json_options_t tuple_opts_def
Definition: daw_json_type_options.h:219
JsonNullable
Definition: daw_json_enums.h:90
constexpr json_details::json_options_t class_opts_def
Definition: daw_json_type_options.h:208
constexpr json_details::json_options_t bool_opts_def
Definition: daw_json_type_options.h:121
basic_json_value(ParseState) -> basic_json_value< ParseState >
constexpr auto tuple_opts
Definition: daw_json_type_options.h:218
constexpr json_details::json_options_t string_raw_opts_def
Definition: daw_json_type_options.h:196
constexpr JsonNullable JsonNullDefault
Definition: daw_json_enums.h:96
constexpr auto json_custom_opts
Definition: daw_json_type_options.h:252
constexpr auto class_opts
Definition: daw_json_type_options.h:207
constexpr auto string_opts
Definition: daw_json_type_options.h:162
constexpr json_details::json_options_t number_opts_def
Definition: daw_json_type_options.h:108
constexpr auto number_opts
Definition: daw_json_type_options.h:107
Definition: daw_from_json.h:22
Definition: daw_from_json.h:22
Definition: daw_json_traits.h:199
Definition: daw_json_link_types.h:1251
Definition: daw_json_link_types.h:510
Definition: daw_json_link_types.h:810
Definition: daw_json_link_types.h:1454
Definition: daw_json_link_types.h:377
Definition: daw_json_link_types.h:1944
String - A raw string as is. Escapes are left in.
Definition: daw_json_link_types.h:582
Definition: daw_json_link_types.h:670
Definition: daw_json_link_types.h:1684
Definition: daw_json_link_types.h:858
Definition: daw_json_traits.h:127
Definition: daw_json_parse_common.h:881
Definition: daw_json_parse_common.h:206
Container * m_container
Definition: daw_json_parse_common.h:212
constexpr basic_appender & operator=(Value &&v)
Definition: daw_json_parse_common.h:242
value_type reference
Definition: daw_json_parse_common.h:208
constexpr basic_appender(Container &container)
Definition: daw_json_parse_common.h:214
constexpr basic_appender & operator*()
Definition: daw_json_parse_common.h:255
typename Container::value_type value_type
Definition: daw_json_parse_common.h:207
std::output_iterator_tag iterator_category
Definition: daw_json_parse_common.h:211
constexpr basic_appender & operator++()
Definition: daw_json_parse_common.h:247
constexpr basic_appender operator++(int)
Definition: daw_json_parse_common.h:251
value_type const * pointer
Definition: daw_json_parse_common.h:209
std::ptrdiff_t difference_type
Definition: daw_json_parse_common.h:210
Definition: daw_json_parse_common.h:92
Definition: daw_json_parse_common.h:856
Definition: daw_json_parse_common.h:844
typename json_data_contract_trait_t< JsonType >::json_member type
Definition: daw_json_parse_common.h:845
Definition: daw_json_parse_common.h:473
static constexpr JsonParseTypes parse_type
Definition: daw_json_parse_common.h:475
static constexpr bool is_null
Definition: daw_json_parse_common.h:474
static constexpr bool type_map_found
Definition: daw_json_parse_common.h:477
Definition: daw_json_parse_common.h:709
Mapped mapped_type
Definition: daw_json_parse_common.h:710
json_link_quick_map_t< T > type
Definition: daw_json_parse_common.h:925
T type
Definition: daw_json_parse_common.h:874
typename std::conditional_t< is_json_class_map_v< T >, json_class_map_type< T >, daw::traits::identity< T > >::type type
Definition: daw_json_parse_common.h:913
Definition: daw_json_parse_common.h:865
missing_json_data_contract_for< T > type
Definition: daw_json_parse_common.h:866
Definition: daw_json_parse_common.h:824
Definition: daw_json_parse_common.h:823
static constexpr bool value
Definition: daw_json_parse_common.h:825
not_vector type
Definition: daw_json_parse_common.h:826
Definition: daw_json_traits.h:119
Definition: daw_json_traits.h:351
#define DAW_JSON_VER
The version string used in namespace definitions. Must be a valid namespace name.
Definition: version.h:16