Reactions  0.1.2
Handling reaction trees and decays
Classes | Functions
reactions::pow_enum Namespace Reference

Utilities to define smart enumeration types. More...

Classes

struct  apply_range
 Transform a template of characters into a string. More...
 
struct  apply_range< 0, meta_functor, indices... >
 Transform a template of characters into a string. More...
 
struct  string_builder
 Helper struct to convert strings to templates of strings. More...
 
struct  string_group
 Group of string templates. More...
 
struct  string_tpl
 String as a template of characters. More...
 

Functions

template<class... Strings, char... C>
constexpr auto parse_string_impl (string_group< Strings... >, string_tpl< C... >, string_tpl<>)
 Implementation of the function to parse a string. More...
 
template<class... Strings, char... Cp, char C0, char... C>
constexpr auto parse_string_impl (string_group< Strings... >, string_tpl< Cp... >, string_tpl< C0, C... >)
 Implementation of the function to parse a string. More...
 
template<char... C>
constexpr auto parse_string (string_tpl< C... > s)
 Parse a string template and return it as an array of strings. More...
 

Detailed Description

Utilities to define smart enumeration types.

Function Documentation

◆ parse_string()

template<char... C>
constexpr auto reactions::pow_enum::parse_string ( string_tpl< C... >  s)

Parse a string template and return it as an array of strings.

Commas act as separators, whilst whitespaces and tabulators are omitted

◆ parse_string_impl() [1/2]

template<class... Strings, char... C>
constexpr auto reactions::pow_enum::parse_string_impl ( string_group< Strings... >  ,
string_tpl< C... >  ,
string_tpl<>   
)

Implementation of the function to parse a string.

◆ parse_string_impl() [2/2]

template<class... Strings, char... Cp, char C0, char... C>
constexpr auto reactions::pow_enum::parse_string_impl ( string_group< Strings... >  ,
string_tpl< Cp... >  ,
string_tpl< C0, C... >   
)

Implementation of the function to parse a string.