/// <summary> /// Initializes a new instance of the <see cref="CsvWriterBusiness"/> class. /// </summary> /// <param name="csvReaderOption">The csvReaderOption<see cref="CsvReaderOption"/></param> public CsvWriterBusiness(CsvReaderOption csvReaderOption = null) { if (csvReaderOption != null) { _csvReaderOption = csvReaderOption; } else { _csvReaderOption = new CsvReaderOption(); } }
/// <summary> /// Initializes a new instance of the <see cref="CsvReaderBusiness"/> class. /// </summary> /// <param name="pathFile">The pathFile<see cref="string"/></param> /// <param name="csvReaderOption">The csvReaderOption<see cref="CsvReaderOption"/></param> public CsvReaderBusiness(string pathFile, CsvReaderOption csvReaderOption = null) { if (csvReaderOption != null) { _csvReaderOption = csvReaderOption; } else { _csvReaderOption = new CsvReaderOption(); } _datas = File.ReadAllLines(pathFile); }
/// <summary> /// The GetCsvWriter /// </summary> /// <param name="csvReaderOption">The csvReaderOption<see cref="CsvReaderOption"/></param> /// <returns>The <see cref="ICsvWriter"/></returns> public static ICsvWriter GetCsvWriter(CsvReaderOption csvReaderOption = null) { return(new CsvWriterBusiness(csvReaderOption)); }
/// <summary> /// The GetCsvReader /// </summary> /// <param name="pathFile">The pathFile<see cref="string"/></param> /// <param name="csvReaderOption">The csvReaderOption<see cref="CsvReaderOption"/></param> /// <returns>The <see cref="ICsvReader"/></returns> public static ICsvReader GetCsvReader(string pathFile, CsvReaderOption csvReaderOption = null) { return(new CsvReaderBusiness(pathFile, csvReaderOption)); }