package csv

Import Path
	encoding/csv (on golang.org and go.dev)

Dependency Relation
	imports 8 packages, and imported by 0 packages

Involved Source Files
	d-> reader.go
	    writer.go

Exported Type Names

type ParseError (struct) A ParseError is returned for parsing errors. Line numbers are 1-indexed and columns are 0-indexed. Column int Err error Line int StartLine int (*T) Error() string (*T) Unwrap() error *T : error
type Reader (struct) A Reader reads records from a CSV-encoded file. As returned by NewReader, a Reader expects input conforming to RFC 4180. The exported fields can be changed to customize the details before the first call to Read or ReadAll. The Reader converts all \r\n sequences in its input to plain \n, including in multiline field values, so that the returned data does not depend on which line-ending convention an input file uses. Comma rune Comment rune FieldsPerRecord int LazyQuotes bool ReuseRecord bool TrailingComma bool TrimLeadingSpace bool (*T) Read() (record []string, err error) (*T) ReadAll() (records [][]string, err error) func NewReader(r io.Reader) *Reader
type Writer (struct) A Writer writes records using CSV encoding. As returned by NewWriter, a Writer writes records terminated by a newline and uses ',' as the field delimiter. The exported fields can be changed to customize the details before the first call to Write or WriteAll. Comma is the field delimiter. If UseCRLF is true, the Writer ends each output line with \r\n instead of \n. The writes of individual records are buffered. After all data has been written, the client should call the Flush method to guarantee all data has been forwarded to the underlying io.Writer. Any errors that occurred should be checked by calling the Error method. Comma rune UseCRLF bool (*T) Error() error (*T) Flush() (*T) Write(record []string) error (*T) WriteAll(records [][]string) error *T : net/http.Flusher func NewWriter(w io.Writer) *Writer
Exported Values
var ErrBareQuote error These are the errors that can be returned in ParseError.Err.
var ErrFieldCount error These are the errors that can be returned in ParseError.Err.
var ErrQuote error These are the errors that can be returned in ParseError.Err.
var ErrTrailingComma error // Deprecated: No longer used. These are the errors that can be returned in ParseError.Err.
func NewReader(r io.Reader) *Reader NewReader returns a new Reader that reads from r.
func NewWriter(w io.Writer) *Writer NewWriter returns a new Writer that writes to w.