// Copyright 2009-2022 Josh Close // This file is a part of CsvHelper and is dual licensed under MS-PL and Apache 2.0. // See LICENSE.txt for details or visit http://www.opensource.org/licenses/ms-pl.html for MS-PL and http://opensource.org/licenses/Apache-2.0 for Apache 2.0. // https://github.com/JoshClose/CsvHelper using System.Globalization; using System.IO; using CsvHelper.Configuration; namespace CsvHelper { /// /// Defines methods used to create /// CsvHelper classes. /// public interface IFactory { /// /// Creates an . /// /// The text reader to use for the csv parser. /// The configuration to use for the csv parser. /// The created parser. IParser CreateParser(TextReader reader, Configuration.CsvConfiguration configuration); /// /// Creates an . /// /// The text reader to use for the csv parser. /// The culture information. /// /// The created parser. /// IParser CreateParser(TextReader reader, CultureInfo cultureInfo); /// /// Creates an . /// /// The text reader to use for the csv reader. /// The configuration to use for the reader. /// The created reader. IReader CreateReader(TextReader reader, Configuration.CsvConfiguration configuration); /// /// Creates an . /// /// The text reader to use for the csv reader. /// The culture information. /// /// The created reader. /// IReader CreateReader(TextReader reader, CultureInfo cultureInfo); /// /// Creates an . /// /// The parser used to create the reader. /// The created reader. IReader CreateReader(IParser parser); /// /// Creates an . /// /// The text writer to use for the csv writer. /// The configuration to use for the writer. /// The created writer. IWriter CreateWriter(TextWriter writer, Configuration.CsvConfiguration configuration); /// /// Creates an . /// /// The text writer to use for the csv writer. /// The culture information. /// /// The created writer. /// IWriter CreateWriter(TextWriter writer, CultureInfo cultureInfo); /// /// Provides a fluent interface for dynamically creating s /// /// Type of class to map /// Next available options IHasMap CreateClassMapBuilder(); } }