ctd_csv: Moved functions into struct.