Add functions to convert a line to a csv, and to convert a csv to lines.