AnCH Framework 0.2
Another C++ Hack: C++23 utility libraries
Loading...
Searching...
No Matches
csv.hpp
1/*
2 ANCH Framework: ANother C++ Hack is a C++ framework based on C++23 standard
3 Copyright (C) 2026 Vincent Lachenal
4
5 This file is part of ANCH Framework.
6
7 ANCH Framework is free software: you can redistribute it and/or modify
8 it under the terms of the GNU Lesser General Public License as published by
9 the Free Software Foundation, either version 3 of the License, or
10 (at your option) any later version.
11
12 ANCH Framework is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU Lesser General Public License for more details.
16
17 You should have received a copy of the GNU Lesser General Public License
18 along with ANCH Framework. If not, see <https://www.gnu.org/licenses/>.
19*/
20#pragma once
21
22#include "anch-codec-csv-export.hpp"
23
24#include <exception>
25
26#include "csv/format.hpp"
27
28#include "codec/codec.hpp"
29#include "codec/formatCodec.hpp"
30
31namespace anch::codec {
32
44 template<>
45 struct ANCH_CODEC_CSV_EXPORT FormatPolicy<anch::csv::CsvFormat> {
52 static void configure(anch::csv::Options& options, anch::codec::Side side);
53
59 static void translate(const std::exception& error);
60 };
61
70
71}
72
73// Options of each side are instantiated in anch-codec-csv (unique in the program)
74extern template struct ANCH_CODEC_CSV_EXPORT anch::codec::FormatCodec<anch::csv::CsvFormat>;
AnCH codec library namespace.
Definition csv.hpp:31
Side
Definition codec.hpp:48
anch::codec::FormatCodec< anch::csv::CsvFormat > Csv
Definition csv.hpp:69
AnCH framework base namespace.
Definition app.hpp:30
Codec of a data format: media type, options of each side ( FormatPolicy ), serialization and deserial...
Definition formatCodec.hpp:130
static void translate(const std::exception &error)
static void configure(anch::csv::Options &options, anch::codec::Side side)
Policy of a format codec: options of each side and errors translation.
Definition formatCodec.hpp:90
CSV format: serialization and deserialization of lists of described objects with options.
Definition format.hpp:46
Definition options.hpp:35