All Projects → kevin-montrose → Cesil

kevin-montrose / Cesil

Licence: mit
Modern CSV (De)Serializer

Projects that are alternatives of or similar to Cesil

Pxi
🧚 pxi (pixie) is a small, fast, and magical command-line data processor similar to jq, mlr, and awk.
Stars: ✭ 248 (+320.34%)
Mutual labels:  csv, serializer
Servicestack.text
.NET's fastest JSON, JSV and CSV Text Serializers
Stars: ✭ 1,157 (+1861.02%)
Mutual labels:  csv, serializer
Ether sql
A python library to push ethereum blockchain data into an sql database.
Stars: ✭ 41 (-30.51%)
Mutual labels:  csv
Fifa Fut Data
Web-scraping script that writes the data of all players from FutHead and FutBin to a CSV file or a DB
Stars: ✭ 55 (-6.78%)
Mutual labels:  csv
Joiner
A simple utility for SQL-like joins with Json, GeoJson or dbf data in Node, the browser and on the command line. Also creates join reports so you can know how successful a given join was. Try it in the browser -->
Stars: ✭ 47 (-20.34%)
Mutual labels:  csv
Serd
A lightweight C library for RDF syntax
Stars: ✭ 43 (-27.12%)
Mutual labels:  serializer
Fast Csv
CSV parser and formatter for node
Stars: ✭ 1,054 (+1686.44%)
Mutual labels:  csv
Province City China
🇨🇳最全最新中国【省、市、区县、乡镇街道】json,csv,sql数据
Stars: ✭ 993 (+1583.05%)
Mutual labels:  csv
Q
q - Run SQL directly on CSV or TSV files
Stars: ✭ 8,809 (+14830.51%)
Mutual labels:  csv
Csv To Geojson
Convert a CSV to GeoJSON
Stars: ✭ 46 (-22.03%)
Mutual labels:  csv
Serializer Pack
A Symfony Pack for Symfony Serializer
Stars: ✭ 1,068 (+1710.17%)
Mutual labels:  serializer
Django Rest Pandas
📊📈 Serves up Pandas dataframes via the Django REST Framework for use in client-side (i.e. d3.js) visualizations and offline analysis (e.g. Excel)
Stars: ✭ 1,030 (+1645.76%)
Mutual labels:  csv
Jsoncsv
a command tool easily convert json file to csv or xlsx
Stars: ✭ 43 (-27.12%)
Mutual labels:  csv
Faster Than Csv
Faster CSV on Python 3
Stars: ✭ 52 (-11.86%)
Mutual labels:  csv
Goloc
A flexible tool for application localization using Google Sheets.
Stars: ✭ 42 (-28.81%)
Mutual labels:  csv
Parsrs
CSV, JSON, XML text parsers and generators written in pure POSIX shellscript
Stars: ✭ 56 (-5.08%)
Mutual labels:  csv
Pyexcel Io
One interface to read and write the data in various excel formats, import the data into and export the data from databases
Stars: ✭ 40 (-32.2%)
Mutual labels:  csv
Jl Sql
SQL for JSON and CSV streams
Stars: ✭ 44 (-25.42%)
Mutual labels:  csv
Azure Functions Billing
Azure Functions v2 with .NET Core - billing in serverless architecture.
Stars: ✭ 49 (-16.95%)
Mutual labels:  csv
Re Txt
converts text-formats from one to another, it is very useful if you want to re-format a json file to yaml, toml to yaml, csv to yaml, ... etc
Stars: ✭ 59 (+0%)
Mutual labels:  csv

Cesil

Modern CSV (De)Serializer

Run Tests (Debug) Line Coverage Branch Coverage

PRE-RELEASE

This code hasn't seen much production use, please use with caution and report any issues you encounter.

Documentation

Consult The Wiki™ for documentation, and Cesil's Github Pages for references.

You may be interested in:

Quick Start

  1. Install the latest Cesil off of Nuget.
  2. Add using Cesil; to your C# file
  3. Create a configuration (with default Options) with either Configuration.For<TYourType>() or Configuration.ForDynamic(), as appropriate for your use case
  4. Create a reader or writer using one of the CreateReader, CreateAsyncReader, CreateWriter, or CreateAsyncWriter methods on the configuration.
    • Each of these methods has a number of overloads, supporting using TextReaders, Pipes, and so on.
  5. Use the methods on the IReader<TRow>, IAsyncReader<TRow>, IWriter<TRow>, or IAsyncWriter<TRow> interface to read or write your data.

Example: Reading Synchronously

Using a convient method:

using Cesil;

// ...

IEnumerable<MyType> rows = CesilUtils.Enumerate<MyType>(/*Some TextReader*/);

In a more explicit, and configurable, way using explicit configuration and options.

using Cesil;

// ...

Options myOptions = /* ... */
IBoundConfiguration<MyType> myConfig = Configuration.For<MyType>(myOptions);

using(TextReader reader = /* ... */)
using(IReader<MyType> csv = myConfig.CreateReader(reader))
{
    IEnumerable<MyType> rows = csv.EnumerateAll();
}

For more detail, see Reading.

Example: Reading Asynchronously

Using a convient method:

using Cesil;

// ...

IAsyncEnumerable<MyType> rows = CesilUtils.EnumerateAsync<MyType>(/*Some TextReader*/);

In a more explicit, and configurable, way using explicit configuration and options.

using Cesil;

// ...

Options myOptions = /* ... */
IBoundConfiguration<MyType> myConfig = Configuration.For<MyType>(myOptions);

using(TextReader reader = /* ... */)
await using(IAsyncReader<MyType> csv = myConfig.CreateAsyncReader(reader))
{
    IAsyncReader<MyType> rows = csv.EnumerateAllAsync();
}

For more detail, see Reading.

Example: Writing Synchronously

Using a convient method:

using Cesil;

// ...

IEnumerable<MyType> myRows = /* ... */

using(TextWriter writer = /* .. */)
{
    CesilUtilities.Write(myRows, writer);
}

In a more explicit, and configurable, way using explicit configuration and options.

using Cesil;

// ...

IEnumerable<MyType> myRows = /* ... */

Options myOptions = /* ... */
IBoundConfiguration<MyType> myConfig = Configuration.For<MyType>(myOptions);

using(TextWriter writer = /* ... */)
using(IWriter<MyType> csv = myConfig.CreateWriter(writer))
{
    csv.WriteAll(myRows);
}

For more detail, see Writing.

Example: Writing Asynchronously

Using a convient method:

using Cesil;

// ...

// IAsyncEnumerable<MyType> will also work
IEnumerable<MyType> myRows = /* ... */

using(TextWriter writer = /* .. */)
{
    await CesilUtilities.WriteAsync(myRows, writer);
}

In a more explicit, and configurable, way using explicit configuration and options.

using Cesil;

// ...

// IAsyncEnumerable<MyType> will also work
IEnumerable<MyType> myRows = /* ... */

Options myOptions = /* ... */
IBoundConfiguration<MyType> myConfig = Configuration.For<MyType>(myOptions);

using(TextWriter writer = /* ... */)
await using(IWriter<MyType> csv = myConfig.CreateAsyncWriter(writer))
{
    await csv.WriteAllAsync(myRows);
}

For more detail, see Writing.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].