|
RESTinio
|
Classes | |
| class | alternatives_clause_t |
| A template for implementation of clause that selects one of alternative clauses. More... | |
| class | and_clause_t |
| A template for implementation of clause that checks the presence of some entity in the input stream. More... | |
| class | any_symbol_if_not_producer_t |
| A producer for the case when any character except the specific sentinel character is expected in the input stream. More... | |
| struct | any_symbol_predicate_t |
| A predicate that allows extraction of any symbol. More... | |
| struct | any_value_skipper_t |
| A special consumer that simply throws any value away. More... | |
| struct | as_result_consumer_t |
| A consumer for the case when the current value should be returned as the result for the producer at one level up. More... | |
| class | caseless_exact_fixed_size_fragment_producer_t |
| A producer that expects a fragment in the input and produces boolean value if that fragment is found. More... | |
| class | caseless_exact_fragment_producer_t |
| A producer that expects a fragment in the input and produces boolean value if that fragment is found. More... | |
| struct | caseless_particular_symbol_predicate_t |
| A predicate for cases where the case-insensitive match of expected and actual symbols is required. More... | |
| class | caseless_symbol_producer_t |
| A producer for the case when a particual character is expected in the input stream. More... | |
| struct | character_t |
| One character extracted from the input stream. More... | |
| struct | clause_tag |
| A special base class to be used with clauses. More... | |
| class | consume_value_clause_t |
| A template for a clause that binds a value producer with value consumer. More... | |
| struct | consumer_tag |
| A special base class to be used with consumers. More... | |
| struct | conversion_result_type_detector |
| A helper template for the detection of type to be produced as conversion procedure. More... | |
| struct | conversion_result_type_detector< expected_t< Result_Type, error_reason_t > > |
| class | convert_transformer_proxy_t |
| A proxy for the creation of convert_transformer instances for a specific value producers. More... | |
| class | convert_transformer_t |
| A transformator that uses a user supplied function/functor for conversion a value from one type to another. More... | |
| class | custom_consumer_t |
| A template for consumers that are released by lambda/functional objects. More... | |
| class | decimal_number_producer_t |
| A producer for the case when a signed decimal number is expected in the input stream. More... | |
| class | decimal_number_producer_with_digits_limit_t |
| A producer for the case when a signed decimal number is expected in the input stream. More... | |
| class | digit_producer_t |
| A producer for the case when a decimal digit is expected in the input stream. More... | |
| class | exact_fixed_size_fragment_producer_t |
| A producer that expects a fragment in the input and produces boolean value if that fragment is found. More... | |
| class | exact_fragment_producer_t |
| A producer that expects a fragment in the input and produces boolean value if that fragment is found. More... | |
| class | field_setter_consumer_t |
| A template for consumers that store a value to the specified field of a target object. More... | |
| class | forced_alternative_clause_t |
| An alternative that should be parsed correctly or the parsing of the whole alternatives clause should fail. More... | |
| class | hexadecimal_number_producer_t |
| A producer for the case when a number in hexadecimal form is expected in the input stream. More... | |
| class | hexadecimal_number_producer_with_digits_limit_t |
| A producer for the case when a number in hexadecimal form is expected in the input stream. More... | |
| class | hexdigit_producer_t |
| A producer for the case when a hexadecimal digit is expected in the input stream. More... | |
| struct | is_appropriate_transformer_result_type |
| A metafunction that checks is Result_Type can be used as the result of transformation method. More... | |
| struct | is_appropriate_transformer_result_type< expected_t< Result_Type, error_reason_t > > |
| struct | is_appropriate_transformer_result_type< expected_t< Result_Type, parse_error_t > > |
| struct | is_clause |
| struct | is_clause< T, meta::void_t< decltype(std::decay_t< T >::entity_type) > > |
| struct | is_consumer |
| struct | is_consumer< T, meta::void_t< decltype(T::entity_type) > > |
| struct | is_digit_predicate_t |
| A predicate for cases where char to be expected to be a decimal digit. More... | |
| struct | is_hexdigit_predicate_t |
| A predicate for cases where char to be expected to be a hexadecimal digit. More... | |
| struct | is_producer |
| struct | is_producer< T, meta::void_t< decltype(T::entity_type) > > |
| struct | is_space_predicate_t |
| A preducate for symbol_producer_template that checks that a symbol is a space. More... | |
| struct | is_transformer |
| struct | is_transformer< T, meta::void_t< decltype(T::entity_type) > > |
| struct | is_transformer_proxy |
| struct | is_transformer_proxy< T, meta::void_t< decltype(T::entity_type) > > |
| class | just_result_consumer_t |
| A consumer for the case when a specific value should be used as the result instead of the value produced on the previous step. More... | |
| class | just_value_transformer_t |
| A transformer that skips incoming value and returns a value specified by a user. More... | |
| class | maybe_clause_t |
| A template for implementation of clause that checks and handles presence of optional entity in the input stream. More... | |
| class | non_negative_decimal_number_producer_t |
| A producer for the case when a non-negative decimal number is expected in the input stream. More... | |
| class | non_negative_decimal_number_producer_with_digits_limit_t |
| A producer for the case when a non-negative decimal number is expected in the input stream. More... | |
| class | not_clause_t |
| A template for implementation of clause that checks absence of some entity in the input stream. More... | |
| struct | not_particular_symbol_predicate_t |
| A predicate for cases where mismatch with a particular symbol is required. More... | |
| struct | particular_symbol_predicate_t |
| A predicate for cases where exact match of expected and actual symbols is required. More... | |
| class | produce_t |
| A template for producing a value of specific type of a sequence of entities from the input stream. More... | |
| struct | producer_tag |
| A special base class to be used with producers. More... | |
| class | repeat_clause_t |
| A template for handling repetition of clauses. More... | |
| class | sequence_clause_t |
| A template for implementation of clause that checks and handles presence of sequence of entities in the input stream. More... | |
| class | source_t |
| The class that implements "input stream". More... | |
| struct | std_array_wrapper |
| A special wrapper for std::array type to be used inside a producer during the parsing. More... | |
| struct | symbol_from_range_predicate_t |
| A predicate for cases where a symbol should belong to specified range. More... | |
| class | symbol_from_range_producer_t |
| A producer for the case when a symbol should belong to specified range. More... | |
| class | symbol_producer_t |
| A producer for the case when a particual character is expected in the input stream. More... | |
| class | symbol_producer_template_t |
| A template for producer of charachers that satisfy some predicate. More... | |
| struct | to_container_consumer_t |
| A template for a consumer that stories values into a container. More... | |
| struct | to_lower_transformer_proxy_t |
| A proxy for the creation of an appropriate to_lower_transformer. More... | |
| struct | to_lower_transformer_t |
| struct | to_lower_transformer_t< char > |
| An implementation of transformer that converts the content of the input character to lower case. More... | |
| struct | to_lower_transformer_t< std::array< char, S > > |
| An implementation of transformer that converts the content of the input std::array to lower case. More... | |
| struct | to_lower_transformer_t< std::string > |
| An implementation of transformer that converts the content of the input std::string to lower case. More... | |
| class | top_level_clause_t |
| A special class to be used as the top level clause in parser. More... | |
| class | transformed_value_producer_t |
| A template of producer that gets a value from another producer, transforms it and produces transformed value. More... | |
| struct | transformed_value_producer_traits_checker |
| A helper template for checking a possibility to connect a producer with a transformer. More... | |
| struct | transformer_invoker |
| A helper template for calling transformation function. More... | |
| struct | transformer_invoker< expected_t< Result_Type, error_reason_t > > |
| struct | transformer_proxy_tag |
| A special base class to be used with transformer-proxies. More... | |
| struct | transformer_tag |
| A special base class to be used with transformers. More... | |
| struct | tuple_item_consumer_t |
| A consumer that stores a result value at the specified index in the result tuple. More... | |
Typedefs | |
| template<typename... Entities> | |
| using | tuple_of_entities_t = meta::rename_t< meta::transform_t< std::decay, meta::type_list< Entities... > >, std::tuple > |
| A helper meta-function to create an actual type of tuple with clauses/producers. More... | |
| template<typename Result_Type > | |
| using | conversion_result_type_detector_t = typename conversion_result_type_detector< Result_Type >::type |
Enumerations | |
| enum | entity_type_t { entity_type_t::producer, entity_type_t::transformer, entity_type_t::consumer, entity_type_t::clause, entity_type_t::transformer_proxy } |
| A marker for distinguish different kind of entities in parser. More... | |
Functions | |
| bool | operator== (const character_t &a, const character_t &b) noexcept |
| bool | operator!= (const character_t &a, const character_t &b) noexcept |
| constexpr bool | is_space (const char ch) noexcept |
| If a character a space character? More... | |
| constexpr bool | is_digit (const char ch) noexcept |
| Is a character a decimal digit? More... | |
| constexpr bool | is_hexdigit (const char ch) noexcept |
| Is a character a hexadecimal digit? More... | |
| template<typename P , typename T > | |
| std::enable_if_t< is_producer_v< P > &is_transformer_v< T >, transformed_value_producer_t< P, T > > | operator>> (P producer, T transformer) |
| A special operator to connect a value producer with value transformer. More... | |
| template<typename P , typename T , typename S = std::enable_if_t< is_producer_v<P> & is_transformer_proxy_v<T>, void >> | |
| auto | operator>> (P producer, T transformer_proxy) |
| A special operator to connect a value producer with value transformer via transformer-proxy. More... | |
| template<typename P , typename C > | |
| std::enable_if_t< is_producer_v< P > &&is_consumer_v< C >, consume_value_clause_t< P, C > > | operator>> (P producer, C consumer) |
| A special operator to connect a value producer with a value consumer. More... | |
| std::optional< parse_error_t > | ensure_no_remaining_content (source_t &from) |
| A special function to check that there is no more actual data in the input stream except whitespaces. More... | |
| string_view_t | remove_trailing_spaces (string_view_t from) noexcept |
| Helper function for removal of trailing spaces from a string-view. More... | |
| template<typename T , typename Value_Accumulator > | |
| expected_t< T, parse_error_t > | try_parse_digits_with_digits_limit (source_t &from, digits_to_consume_t digits_limit, Value_Accumulator acc) noexcept |
| Helper function for parsing integers with respect to the number of digits to be consumed. More... | |
| template<typename T , typename Value_Accumulator > | |
| expected_t< T, parse_error_t > | try_parse_hexdigits_with_digits_limit (source_t &from, digits_to_consume_t digits_limit, Value_Accumulator acc) noexcept |
| Helper function for parsing integers in hexadecimal form. More... | |
| template<typename P , typename F , typename C > | |
| std::enable_if_t< is_producer_v< P >, consume_value_clause_t< P, field_setter_consumer_t< F, C > > > | operator>> (P producer, F C::*member_ptr) |
| A special operator to connect a value producer with field_setter_consumer. More... | |
| template<typename It > | |
| expected_t< bool, parse_error_t > | try_parse_exact_fragment (source_t &from, It begin, It end) |
| template<typename It > | |
| expected_t< bool, parse_error_t > | try_parse_caseless_exact_fragment (source_t &from, It begin, It end) |
Variables | |
| constexpr char | SP = ' ' |
| A constant for SPACE value. More... | |
| constexpr char | HTAB = '\x09' |
| A constant for Horizontal Tab value. More... | |
| template<typename T > | |
| constexpr bool | is_producer_v = is_producer<T>::value |
| A meta-value to check whether T is a producer type. More... | |
| template<typename T > | |
| constexpr bool | is_transformer_v = is_transformer<T>::value |
| A meta-value to check whether T is a transformer type. More... | |
| template<typename T > | |
| constexpr bool | is_transformer_proxy_v = is_transformer_proxy<T>::value |
| A meta-value to check whether T is a transformer-proxy type. More... | |
| template<typename T > | |
| constexpr bool | is_consumer_v = is_consumer<T>::value |
| A meta-value to check whether T is a consumer type. More... | |
| template<typename T > | |
| constexpr bool | is_clause_v = is_clause<T>::value |
| A meta-value to check whether T is a consumer type. More... | |
| using restinio::easy_parser::impl::conversion_result_type_detector_t = typedef typename conversion_result_type_detector<Result_Type>::type |
A helper for simplification of usage of conversion_result_type_detector<R>.
Definition at line 3244 of file easy_parser.hpp.
| using restinio::easy_parser::impl::tuple_of_entities_t = typedef meta::rename_t< meta::transform_t< std::decay, meta::type_list<Entities...> >, std::tuple > |
A helper meta-function to create an actual type of tuple with clauses/producers.
Usage example:
The tuple_of_entities_t takes care about such cases as references and constness of parameters. For example:
In that case Clauses... will be symbol_clause_t&, const symbol_clause_t&. And an attempt to make type std::tuple<Clauses...> will produce type std::tuple<symbol_clause_t&, const symbol_clause_t&>. But we need std::tuple<symbol_clause_t, symbol_clause_t>. This result will be obtained if tuple_of_entities_t is used instead of std::tuple.
Definition at line 1459 of file easy_parser.hpp.
|
strong |
A marker for distinguish different kind of entities in parser.
Definition at line 901 of file easy_parser.hpp.
|
inline |
A special function to check that there is no more actual data in the input stream except whitespaces.
Definition at line 1567 of file easy_parser.hpp.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
Definition at line 608 of file easy_parser.hpp.
|
inlinenoexcept |
Definition at line 601 of file easy_parser.hpp.
| std::enable_if_t< is_producer_v<P> & is_transformer_v<T>, transformed_value_producer_t< P, T > > restinio::easy_parser::impl::operator>> | ( | P | producer, |
| T | transformer | ||
| ) |
A special operator to connect a value producer with value transformer.
Definition at line 1234 of file easy_parser.hpp.
| auto restinio::easy_parser::impl::operator>> | ( | P | producer, |
| T | transformer_proxy | ||
| ) |
A special operator to connect a value producer with value transformer via transformer-proxy.
Definition at line 1307 of file easy_parser.hpp.
| std::enable_if_t< is_producer_v<P> && is_consumer_v<C>, consume_value_clause_t< P, C > > restinio::easy_parser::impl::operator>> | ( | P | producer, |
| C | consumer | ||
| ) |
A special operator to connect a value producer with a value consumer.
Definition at line 1514 of file easy_parser.hpp.
| std::enable_if_t< is_producer_v<P>, consume_value_clause_t< P, field_setter_consumer_t<F,C> > > restinio::easy_parser::impl::operator>> | ( | P | producer, |
| F C::* | member_ptr | ||
| ) |
A special operator to connect a value producer with field_setter_consumer.
Definition at line 3003 of file easy_parser.hpp.
|
inlinenoexcept |
Helper function for removal of trailing spaces from a string-view.
Definition at line 1595 of file easy_parser.hpp.
| expected_t< bool, parse_error_t > restinio::easy_parser::impl::try_parse_caseless_exact_fragment | ( | source_t & | from, |
| It | begin, | ||
| It | end | ||
| ) |
Definition at line 3420 of file easy_parser.hpp.
|
noexcept |
Helper function for parsing integers with respect to the number of digits to be consumed.
Usage example:
Definition at line 2438 of file easy_parser.hpp.
| expected_t< bool, parse_error_t > restinio::easy_parser::impl::try_parse_exact_fragment | ( | source_t & | from, |
| It | begin, | ||
| It | end | ||
| ) |
Definition at line 3314 of file easy_parser.hpp.
|
noexcept |
Helper function for parsing integers in hexadecimal form.
Usage example:
Definition at line 2502 of file easy_parser.hpp.
| constexpr char restinio::easy_parser::impl::HTAB = '\x09' |
| constexpr bool restinio::easy_parser::impl::is_clause_v = is_clause<T>::value |
A meta-value to check whether T is a consumer type.
Definition at line 1421 of file easy_parser.hpp.
| constexpr bool restinio::easy_parser::impl::is_consumer_v = is_consumer<T>::value |
A meta-value to check whether T is a consumer type.
Definition at line 1368 of file easy_parser.hpp.
| constexpr bool restinio::easy_parser::impl::is_producer_v = is_producer<T>::value |
A meta-value to check whether T is a producer type.
Definition at line 971 of file easy_parser.hpp.
| constexpr bool restinio::easy_parser::impl::is_transformer_proxy_v = is_transformer_proxy<T>::value |
A meta-value to check whether T is a transformer-proxy type.
Definition at line 1291 of file easy_parser.hpp.
| constexpr bool restinio::easy_parser::impl::is_transformer_v = is_transformer<T>::value |
A meta-value to check whether T is a transformer type.
Definition at line 1025 of file easy_parser.hpp.
| constexpr char restinio::easy_parser::impl::SP = ' ' |
1.8.14