AnCH Framework 0.2
Another C++ Hack: C++23 utility libraries
Loading...
Searching...
No Matches
anch::csv::ObjectMapper< T >::Field Struct Reference

Field mapping. More...

#include <mapper.hpp>

Collaboration diagram for anch::csv::ObjectMapper< T >::Field:

Public Attributes

std::string name
bool required
std::function< void(T &, std::string_view, bool, anch::csv::detail::ReadContext &, const anch::csv::Options &)> read
std::function< anch::csv::detail::FieldText(const T &, anch::csv::detail::WriteContext &, const anch::csv::Options &)> write

Detailed Description

template<typename T>
struct anch::csv::ObjectMapper< T >::Field

Field mapping.

Member Data Documentation

◆ name

template<typename T>
std::string anch::csv::ObjectMapper< T >::Field::name

Field (column) name

◆ read

template<typename T>
std::function<void(T&, std::string_view, bool, anch::csv::detail::ReadContext&, const anch::csv::Options&)> anch::csv::ObjectMapper< T >::Field::read

Field reader (empty for fields without setter): text, quoted, context, options

◆ required

template<typename T>
bool anch::csv::ObjectMapper< T >::Field::required

Column is required

◆ write

template<typename T>
std::function<anch::csv::detail::FieldText(const T&, anch::csv::detail::WriteContext&, const anch::csv::Options&)> anch::csv::ObjectMapper< T >::Field::write

Field writer (empty for fields without getter)


The documentation for this struct was generated from the following file: