restinio::easy_parser::impl::transformed_value_producer_traits_checker< Producer, Transformer > Struct Template Reference

A helper template for checking a possibility to connect a producer with a transformer. More...

`#include <easy_parser.hpp>`

## Public Types

using | producer_result_t = std::decay_t< decltype(std::declval< Producer & >().try_parse(std::declval< source_t & >())) >
using | transformation_result_t = std::decay_t< decltype(std::declval< Transformer & >().transform(std::move(*(std::declval< producer_result_t >())))) >
using | expected_result_t = typename Transformer::result_type

## Static Public Attributes

static constexpr bool | is_valid_transformation_result_type

## Detailed Description

template<typename Producer, typename Transformer>
struct restinio::easy_parser::impl::transformed_value_producer_traits_checker< Producer, Transformer >

A helper template for checking a possibility to connect a producer with a transformer.

This helper can be seen as a metafunction that defines a boolean value is_valid_transformation_result_type. If that value is `true` then Transformer::transform method returns allowed type (T or expected_t<T, error_reson_t>).

Since
  v.0.6.11

Definition at line 1144 of file easy_parser.hpp.

## Member Typedef Documentation

## expected_result_t

template<typename Producer , typename Transformer >

using restinio::easy_parser::impl::transformed_value_producer_traits_checker< Producer, Transformer >::expected_result_t = typename Transformer::result_type

Definition at line 1160 of file easy_parser.hpp.

## producer_result_t

template<typename Producer , typename Transformer >

using restinio::easy_parser::impl::transformed_value_producer_traits_checker< Producer, Transformer >::producer_result_t = std::decay_t< decltype( std::declval<Producer &>().try_parse( std::declval<source_t &>() ) ) >

Definition at line 1151 of file easy_parser.hpp.

## transformation_result_t

template<typename Producer , typename Transformer >

using restinio::easy_parser::impl::transformed_value_producer_traits_checker< Producer, Transformer >::transformation_result_t = std::decay_t< decltype( std::declval<Transformer &>().transform( std::move(*(std::declval<producer_result_t>())) ) ) >

Definition at line 1155 of file easy_parser.hpp.

## Member Data Documentation

## is_valid_transformation_result_type

template<typename Producer , typename Transformer >

constexpr bool restinio::easy_parser::impl::transformed_value_producer_traits_checker< Producer, Transformer >::is_valid_transformation_result_type

static constexpr

Initial value:
=
is_appropriate_transformer_result_type< expected_result_t >::value
restinio::easy_parser::impl::is_appropriate_transformer_result_type::value
static constexpr bool value
Definition: easy_parser.hpp:1112

Definition at line 1162 of file easy_parser.hpp.

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

- restinio/helpers/easy_parser.hpp