Struct CsvReader.RecordEnumerator
Supports a simple iteration over the records of a CsvReader.
Implements
IEnumerator<System.String[]>
Namespace: Mars.Common.IO.Csv
Assembly: Mars.IO.dll
Syntax
public struct RecordEnumerator : IEnumerator<string[]>
Constructors
RecordEnumerator(CsvReader)
Initializes a new instance of the RecordEnumerator class.
Declaration
public RecordEnumerator(CsvReader reader)
Parameters
Type | Name | Description |
---|---|---|
CsvReader | reader | The CsvReader to iterate over. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException |
reader is a langword_csharp_null.
|
Properties
Current
Gets the current record.
Declaration
public string[] Current { get; }
Property Value
Type | Description |
---|---|
System.String[] |
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Declaration
public void Dispose()
MoveNext()
Advances the enumerator to the next record of the CSV.
Declaration
public bool MoveNext()
Returns
Type | Description |
---|---|
System.Boolean | langword_csharp_true if the enumerator was successfully advanced to the next record, langword_csharp_false if the enumerator has passed the end of the CSV. |
Reset()
Sets the enumerator to its initial position, which is before the first record in the CSV.
Declaration
public void Reset()
Implements
IEnumerator<>