Documentation
      ¶
    
    
  
    
  
    Index ¶
- func FilterCSVFile(inPath, outPath string, inComma rune, ...) error
 - func MergeFilterCSVFiles(inPaths []string, outPath string, inComma rune, inStripBom bool, ...) error
 - func MergeFilterCSVFilesToJSONL(inPaths []string, outPath string, inComma rune, ...) error
 - func NewReader(rs io.ReadSeeker, comma rune) (*csv.Reader, error)
 - func NewReaderFile(path string, comma rune) (*csv.Reader, *os.File, error)
 - func NewWriterFile(filename string) (*csv.Writer, *os.File, error)
 - func ParseOneColListToGrid(lines []string, colCount int, validateLength bool) ([][]string, error)
 - func ReadCSVFileSingleColumnValuesString(filename string, sep rune, hasHeader, trimSpace bool, colIdx uint, ...) ([]string, error)
 - func ReadCSVFilesSingleColumnValuesString(files []string, sep rune, hasHeader, trimSpace bool, colIdx uint, ...) ([]string, error)
 - func ReadFileOneColListToGrid(filename string, colCount int, validateLength bool) ([][]string, error)
 - func WriteCSVFiltered(reader *csv.Reader, writer *csv.Writer, ...) error
 - func WriteFile(filename string, rows [][]string) error
 - type CSVHeader
 - type Writer
 
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FilterCSVFile ¶
func MergeFilterCSVFiles ¶
func MergeFilterCSVFiles(inPaths []string, outPath string, inComma rune, inStripBom bool, andFilter map[string]stringsutil.MatchInfo) error
MergeFilterCSVFiles can merge and filter multiple CSV files. It expects row definitions to be the same across all input files.
func NewReaderFile ¶
NewReaderFile will create a csv.Reader and optionally strip off the byte order mark (BOM) if requested. Close file reader with `defer f.Close()`.
func ParseOneColListToGrid ¶
ParseOneColListToGrid parses a set of lines with one value per row.
func ReadFileOneColListToGrid ¶
func ReadFileOneColListToGrid(filename string, colCount int, validateLength bool) ([][]string, error)
ReadFileOneColListToGrid parses a file with one value per row.
Types ¶
type Writer ¶
type Writer struct {
	Separator        string
	StripRepeatedSep bool
	ReplaceSeparator bool
	SeparatorAlt     string
	File             *os.File
}
    Writer is a struct for a CSV/TSV writer.
 Click to show internal directories. 
   Click to hide internal directories.