Skip to content

RKest/scsv

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SCSV

CSV to static data types parser

Motivational example

#include <scsv/parse_file.hpp>

struct Person
{
    std::string name;
    int age;
    std::string address;
};

int main()
{
    std::vector<Person> people = scsv::parse_file("people.csv");
    ...
}

Usage

Requires c++20.
scsv is header only, however it depends on:

  • boost::pfr
  • boost::lexical_cast
  • mio
  • magic_enum

Therefor the easiest way to use this library, is via conan, by requiring the following conanfile.txt:

[requires]
scsv/0.1.0

and running

conan create . --build=missing

Then all is left is to link against the library, to include its headers.
For example in cmake:

target_link_libraries(your_target PRIVATE|PUBLIC|INTERFACE scsv)

About

CSV To static types converter

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published