sv-core-0.2.2: Encode and decode separated values (CSV, PSV, ...)

Copyright(C) CSIRO 2017-2018
LicenseBSD3
MaintainerGeorge Wilson <george.wilson@data61.csiro.au>
Stabilityexperimental
Portabilitynon-portable
Safe HaskellSafe
LanguageHaskell2010

Data.Sv.Structure.Core

Description

 
Synopsis

Documentation

type Separator = Word8 Source #

By what are your values separated? The answer is often comma, but not always.

A Separator is just a Word8. It could be a sum type instead, since it will usually be comma or pipe, but our preference has been to be open here so that you can use whatever you'd like.

comma :: Separator Source #

The venerable comma separator. Used for CSV documents.

pipe :: Separator Source #

The pipe separator. Used for PSV documents.

tab :: Separator Source #

Tab is a separator too - why not?

class HasSeparator c where Source #

Classy lens for Separator

Minimal complete definition

separator

data Headedness Source #

Does the CSV have a Header or not? A header is a row at the beginning of a file which contains the string names of each of the columns.

If a header is present, it must not be decoded with the rest of the data.

Constructors

Unheaded 
Headed 

class HasHeadedness c where Source #

Classy lens for Headedness

Minimal complete definition

headedness