25#ifndef ROUTER_SRC_REST_MRS_SRC_HELPER_TO_STRING_H_
26#define ROUTER_SRC_REST_MRS_SRC_HELPER_TO_STRING_H_
43inline const char *
to_cstr(
const bool b) {
return b ?
"true" :
"false"; }
45template <
typename Type>
46std::string
to_string(
const std::optional<Type> &v) {
49 if (!v.has_value())
return k_none;
std::string to_string(const DummyType &)
Definition: to_string.h:38
std::string to_string(const std::optional< Type > &v)
Definition: to_string.h:46
const std::string k_true
Definition: to_string.h:34
const std::string k_none
Definition: to_string.h:33
const std::string k_false
Definition: to_string.h:35
const char * to_cstr(const bool b)
Definition: to_string.h:43
ValueType value(const std::optional< ValueType > &v)
Definition: gtid.h:83