/// <summary> /// Initializes a new instance /// using Default CSV Special Characters /// </summary> public CsvSerializer() { //Initialize the Column Schema //with Default Values ColumnSchema = new List<CsvColumn>(); foreach (PropertyInfo property in Properties) ColumnSchema.Add(new CsvColumn(property)); CsvStyle = new CsvStyle(CsvCharacterStyle.Windows); }
/// <summary> /// Initializes with Custom CSV style and Column Schema /// </summary> /// <param name="csvStyle">Template CSV Style</param> /// <param name="columnSchema"><see cref="CsvColumn"/> columnSchema</param> public CsvSerializer(CsvStyle csvStyle, List<CsvColumn> columnSchema) : this(columnSchema) { CsvStyle = csvStyle; }
/// <summary> /// Initializes with Custom Column Schema /// </summary> /// <param name="columnSchema"><see cref="CsvColumn"/> schema</param> public CsvSerializer(List<CsvColumn> columnSchema) { CsvStyle = new CsvStyle(CsvCharacterStyle.Windows); ColumnSchema = columnSchema; }
/// <summary> /// Initializes with Custom CSV Style /// </summary> /// <paramref name="csvStyle">Template Style</paramref> public CsvSerializer(CsvStyle csvStyle) : this() { CsvStyle = csvStyle; }