Basic usage is as follows.
namespace StringUtilities { STRINGSTREAM_MAPPING(int) }; namespace StringUtilities { STRINGSTREAM_MAPPING_PRECISION(float, numeric_limits<float>::digits10) }; namespace StringUtilities { BEGIN_ENUM_MAPPING(AoiAddMode) ADD_ENUM_MAPPING(APPEND_AOI, "Append", "Append") ADD_ENUM_MAPPING(REPLACE_AOI, "Replace", "Replace") ADD_ENUM_MAPPING(NEW_AOI, "New", "New") END_ENUM_MAPPING() };
Advanced configurations, such as using the macros for type to string conversion but specifying a custom string to type conversion are beyond the scope of this document. If you need such advanced usage, it is suggested that you study the macro definitions in StringUtilitiesMacros.h to determine the best combination of macros and custom code.