DAW JSON Link
Public Types | Static Public Attributes | List of all members
daw::json::DAW_JSON_VER::json_custom< Name, T, FromJsonConverter, ToJsonConverter, Options > Struct Template Reference

#include <daw_json_link_types.h>

Inheritance diagram for daw::json::DAW_JSON_VER::json_custom< Name, T, FromJsonConverter, ToJsonConverter, Options >:
daw::json::DAW_JSON_VER::json_base::json_custom< T, FromJsonConverter, ToJsonConverter, Options >

Public Types

template<JSONNAMETYPE NewName>
using with_name = json_custom< NewName, T, FromJsonConverter, ToJsonConverter, Options >
 
using without_name = json_base::json_custom< T, FromJsonConverter, ToJsonConverter, Options >
 
- Public Types inherited from daw::json::DAW_JSON_VER::json_base::json_custom< T, FromJsonConverter, ToJsonConverter, Options >
using base_type = json_details::unwrapped_t< T, nullable >
 
using constructor_t = FromJsonConverter
 
using from_converter_t = FromJsonConverter
 
using i_am_a_json_type = void
 
using parse_to_t = typename json_details::construction_result< nullable !=JsonNullable::MustExist, FromJsonConverter, std::string_view >::type
 
using to_converter_t = ToJsonConverter
 
template<JSONNAMETYPE NewName>
using with_name = daw::json::json_custom< NewName, T, FromJsonConverter, ToJsonConverter, Options >
 
using without_name = json_custom
 

Static Public Attributes

static constexpr daw::string_view name = Name
 
- Static Public Attributes inherited from daw::json::DAW_JSON_VER::json_base::json_custom< T, FromJsonConverter, ToJsonConverter, Options >
static constexpr JsonParseTypes base_expected_type
 
static constexpr JsonCustomTypes custom_json_type
 
static constexpr JsonParseTypes expected_type
 
static constexpr bool must_be_class_member = false
 
static constexpr daw::string_view name = no_name
 
static constexpr JsonNullable nullable
 
static constexpr JsonBaseParseTypes underlying_json_type
 

Detailed Description

template<JSONNAMETYPE Name, typename T, typename FromJsonConverter, typename ToJsonConverter, json_details::json_options_t Options>
struct daw::json::DAW_JSON_VER::json_custom< Name, T, FromJsonConverter, ToJsonConverter, Options >

Allow parsing of a nullable type that does not fit

Template Parameters
NameName of JSON member to link to
Ttype of value being constructed
FromJsonConverterCallable that accepts a std::string_view of the range to parse
ToJsonConverterReturns a string from the value
JsonRawTypeJSON type value is encoded as literal/string

Allow parsing of a type that does not fit

Template Parameters
NameName of JSON member to link to
Ttype of value being constructed
FromJsonConverterCallable that accepts a std::string_view of the range to parse. The default requires an overload of from_string( daw::tag<T>, std::string_view ) that returns a T
ToJsonConverterReturns a string from the value. The default requires a to_string( T const & ) overload that returns a String like type
JsonRawTypeJSON type value is encoded as literal/string/any
NullableCan the member be missing or have a null value

Member Typedef Documentation

◆ with_name

template<JSONNAMETYPE Name, typename T , typename FromJsonConverter , typename ToJsonConverter , json_details::json_options_t Options>
template<JSONNAMETYPE NewName>
using daw::json::DAW_JSON_VER::json_custom< Name, T, FromJsonConverter, ToJsonConverter, Options >::with_name = json_custom<NewName, T, FromJsonConverter, ToJsonConverter, Options>

◆ without_name

template<JSONNAMETYPE Name, typename T , typename FromJsonConverter , typename ToJsonConverter , json_details::json_options_t Options>
using daw::json::DAW_JSON_VER::json_custom< Name, T, FromJsonConverter, ToJsonConverter, Options >::without_name = json_base::json_custom<T, FromJsonConverter, ToJsonConverter, Options>

Member Data Documentation

◆ name

template<JSONNAMETYPE Name, typename T , typename FromJsonConverter , typename ToJsonConverter , json_details::json_options_t Options>
constexpr daw::string_view daw::json::DAW_JSON_VER::json_custom< Name, T, FromJsonConverter, ToJsonConverter, Options >::name = Name
staticconstexpr

The documentation for this struct was generated from the following file: