Jpp  19.1.0
the software that should make you happy
csv2code.hh
Go to the documentation of this file.
1 #ifndef __csv2code__hh
2 #define __csv2code__hh
3 
4 #include <iostream>
5 #include <string>
6 #include <vector>
7 
8 struct Header {
9  std::string base;
10  std::string description;
11  std::string url;
12 };
13 
14 // the columns of the input CSV file
15 struct CSV {
20 };
21 
22 template <typename LANG>
23 void convertCSV(std::ostream& out, const CSV& csv);
24 
25 template <typename LANG>
26 void convertHeader(std::ostream& out, const Header& header);
27 
28 template <typename LANG>
29 void convert(std::ostream& out, const Header& header, const CSV& csv) {
30  convertHeader<LANG>(out, header);
31  convertCSV<LANG>(out, csv);
32 }
33 
34 CSV readCSV(std::istream& in);
35 
36 #endif
void convert(std::ostream &out, const Header &header, const CSV &csv)
Definition: csv2code.hh:29
void convertHeader(std::ostream &out, const Header &header)
void convertCSV(std::ostream &out, const CSV &csv)
CSV readCSV(std::istream &in)
Definition: csv2code.cc:18
Definition: csv2code.hh:15
std::vector< std::string > numbers
Definition: csv2code.hh:18
std::vector< std::string > types
Definition: csv2code.hh:16
std::vector< std::string > names
Definition: csv2code.hh:17
std::vector< std::string > comments
Definition: csv2code.hh:19
std::string description
Definition: csv2code.hh:10
std::string base
Definition: csv2code.hh:9
std::string url
Definition: csv2code.hh:11