CsvHelperAliases.

ReadCsv<T>(ICakeContext, FilePath, CsvHelperSettings) Method

Summary

Reads a CSV file into a C# object.
Assembly
Cake.CsvHelper.dll
Namespace
Cake.CsvHelper
Containing Type
CsvHelperAliases

Syntax

public static IEnumerable<T> ReadCsv<T>(this ICakeContext context, FilePath csvFile, CsvHelperSettings settings)

Examples

var people = ReadCsv<Person>("./people.csv");

Attributes

Type Description
CakeMethodAliasAttribute
CakeAliasCategoryAttribute

Type Parameters

Name Description
T The type.

Parameters

Name Type Description
context ICakeContext The context.
csvFile FilePath The CSV to read.
settings CsvHelperSettings The settings.

Return Value

Type Description
IEnumerable<T> List objects as defined by type.