// SplitPattern returns a function which will specify the regular expression
// used by the DFReader when splitting lines into columns.
SplitPattern returns a function which will specify the regular expression
used by the DFReader when splitting lines into columns.
// SplitPattern returns a function which will specify the regular expression // used by the DFReader when splitting lines into columns .
func SplitPattern(pattern string) DFReaderOpt {
	return func(dfr *DFReader) error {
		var err error
		dfr.splitRegex, err = regexp.Compile(pattern)
		if err != nil {
			err = dfErrorf("the pattern for splitting lines is invalid: %s",
				err)
		}
		return err
	}
}
func SplitPattern ( pattern string ) DFReaderOpt { return func ( dfr * DFReader ) error { var err error dfr . splitRegex , err = regexp . Compile ( pattern ) if err != nil { err = dfErrorf ( " " , err ) } return err } }
SplitPattern returns a function which will specify the regular expression
used by the DFReader when splitting lines into columns.
SplitPattern returns a function which will specify the regular expression used by the DFReader when splitting lines into columns .