encode

Build the CSV content as a String — pure function so callers can inspect rows without filesystem access.