Click or drag to resize

IFileHelperEngineT Interface

Interface for The fileHelpers generic engine

Namespace:  FileHelpers
Assembly:  FileHelpers (in FileHelpers.dll) Version: 3.2.6
Syntax
public interface IFileHelperEngine<T>
where T : class

Type Parameters

T
Type of object array to return

The IFileHelperEngineT type exposes the following members.

Properties
  NameDescription
Public propertyEncoding
The encoding to Read and Write the streams. Default is the system's current ANSI code page.
Public propertyErrorManager
This is a common class that manage the errors of the library.
Public propertyErrorMode
Indicates the behavior of the engine when it found an error. (shortcut for ErrorManager.ErrorMode)
Public propertyFooterText
The read footer in the last read operation. If any.
Public propertyHeaderText
The read header in the last read operation. If any.
Public propertyLineNumber
The current line number.
Public propertyNewLineForWrite
Newline char or string to be used when engine writes records.
Public propertyOptions
Allows to change some record layout options at runtime
Public propertyRecordType
Returns the type of records handled by this engine.
Public propertyTotalRecords
The total numbers of records in the last read/written file (only works with whole read/write).
Top
Methods
  NameDescription
Public methodCode exampleAppendToFile(String, IEnumerableT)
Append an array of records to the specified file.
Public methodCode exampleAppendToFile(String, T)
Append a record to the specified file.
Public methodCode exampleReadFile(String)
Read a file and return an array of the contained records.
Public methodCode exampleReadFile(String, Int32)
Read a file and return an array of the contained records.
Public methodReadFileAsDT(String)
Read the records of the file and fill a DataTable with them
Public methodReadFileAsDT(String, Int32)
Read the records of the file and fill a DataTable with them
Public methodCode exampleReadStream(TextReader)
Read a Stream and return an array of the contained records.
Public methodCode exampleReadStream(TextReader, Int32)
Read a Stream and return an array of the contained records.
Public methodReadStreamAsDT(TextReader)
Read the records of the stream and fill a DataTable with them
Public methodReadStreamAsDT(TextReader, Int32)
Read the records of the stream and fill a DataTable with them
Public methodReadString(String)
Read a String and return an array of the contained records.
Public methodReadString(String, Int32)
Read a String and return an array of the contained records.
Public methodReadStringAsDT(String)
Read the records of a string and fill a DataTable with them.
Public methodReadStringAsDT(String, Int32)
Read the records of a string and fill a DataTable with them.
Public methodCode exampleWriteFile(String, IEnumerableT)
Write an array of records to the specified file.
Public methodCode exampleWriteFile(String, IEnumerableT, Int32)
Write the specified number of records from the array to a file.
Public methodCode exampleWriteStream(TextWriter, IEnumerableT)
Write an array of records to the specified Stream.
Public methodCode exampleWriteStream(TextWriter, IEnumerableT, Int32)
Write the specified number of records in the array to the Stream.
Public methodWriteString(IEnumerableT)
Write an array of records to an String and return it.
Public methodWriteString(IEnumerableT, Int32)
Write an array of records to an String and return it.
Top
Events
  NameDescription
Public eventAfterReadRecord
Called in read operations just after the record was created from a record string.
Public eventAfterWriteRecord
Called in write operations just after the record was converted to a string.
Public eventBeforeReadRecord
Called in read operations just before the record string is translated to a record.
Public eventBeforeWriteRecord
Called in write operations just before the record is converted to a string to write it.
Public eventProgress
Called to notify progress.
Top
See Also