Extractors implemented. Exporters name simplified. README Updated for extracting data. Removed go 1.11 support

This commit is contained in:
Musab Gültekin
2019-06-28 13:00:30 +03:00
parent 679fd8ab7a
commit b000581c3d
13 changed files with 138 additions and 27 deletions

View File

@@ -10,15 +10,15 @@ import (
"sort"
)
// CSVExporter exports response data as CSV streaming file
type CSVExporter struct {
// CSV exports response data as CSV streaming file
type CSV struct {
FileName string
Comma rune
UseCRLF bool
}
// Export exports response data as CSV streaming file
func (e *CSVExporter) Export(exports chan interface{}) {
func (e *CSV) Export(exports chan interface{}) {
// Create or append file
file, err := os.OpenFile(internal.PreferFirst(e.FileName, "out.csv"), os.O_RDWR|os.O_CREATE|os.O_APPEND, 0666)