OZO 「お象」
Boost.Asio and libpq based asynchronous PostgreSQL unofficial header-only C++17 client library.
ozo::send_impl< In, typename > Struct Template Reference

#include <ozo/io/send.h>

Description

template<typename In, typename = std::void_t<>>
struct ozo::send_impl< In, typename >

Defines how to send an object to an output stream.

This functor is used to serialize object as query parameter.

Template Parameters
In— type of an object to apply to
<anonymous>— SFINAE-based overloading parameter.

The default implementation uses ozo::write function to serialize simple objects like integers or strings. To serialize complex types like Array or Composite special internal implementations are used.

Note
This functor requires type definition via OZO_PG_BIND_TYPE or OZO_PG_DEFINE_CUSTOM_TYPE.

Customization point

This template is a customization point for specializing serialization for user defined types if it can not be obtained via the library. Typically user does not need it.

Static Public Member Functions

template<typename OidMap >
static ostream & apply (ostream &out, const OidMap &, const In &in)
 Implementation of serialization object into stream. More...
 

Member Function Documentation

◆ apply()

template<typename In , typename = std::void_t<>>
template<typename OidMap >
static ostream& ozo::send_impl< In, typename >::apply ( ostream &  out,
const OidMap &  ,
const In &  in 
)
static

Implementation of serialization object into stream.

Parameters
out— output stream
OidMap— #OidMap to get oid for custom types
in— object to serialize
Returns
ostream& — output stream