Boost
C++ Libraries
...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
This is an older version of Boost and was released in 2024. The current version is 1.92.0.
(EXPERIMENTAL) An extension point to customize SQL formatting.
Defined in header <boost/mysql/format_sql.hpp>
template< class T> struct formatter
This type can be specialized for custom types to make them formattable. This
makes them satisfy the Formattable
concept, and usable in format_sql and format_context_base::append_value.
A formatter specialization
for a type T should have
the following form:
template <> struct formatter<MyType> { static void format( const MyType&, format_context_base&); }
Don't specialize formatter
for built-in types, like int,
std::string or optionals (formally, any type
satisfying WritableField).
This is not supported and will result in a compile-time error.
Convenience header <boost/mysql.hpp>