Class CsvColumnAttribute
An attribute used to map public properties in strongly-typed object classes to columns in CSV files.
[AttributeUsage(AttributeTargets.Property, Inherited = false, AllowMultiple = false)]
public sealed class CsvColumnAttribute : Attribute, _Attribute
- Inheritance
-
CsvColumnAttribute
- Implements
- Inherited Members
Constructors
CsvColumnAttribute(int)
Initializes a new instance of the CsvColumnAttribute class.
public CsvColumnAttribute(int index)
Parameters
index
intThe column index to which this property should be mapped.
Properties
Index
Gets the column index to which this property should be mapped.
public int Index { get; }
Property Value
PreserveWhiteSpace
Gets or sets whether leading and trailing white-space in the CSV column will be preserved.
public bool PreserveWhiteSpace { get; set; }
Property Value
TreatBlankAsNull
Gets or sets whether blank values will be treated as null.
public bool TreatBlankAsNull { get; set; }