Class CsvOrderAttribute
- Namespace
- FlameCsv.Attributes
- Assembly
- FlameCsv.Core.dll
Configures the order in which fields will be written when writing CSV (and headers matched when reading).
When not placed on a member or parameter, MemberName must be set.
When placed on an assembly, TargetType must be set.
[AttributeUsage(AttributeTargets.Assembly|AttributeTargets.Class|AttributeTargets.Struct|AttributeTargets.Property|AttributeTargets.Field|AttributeTargets.Interface|AttributeTargets.Parameter, AllowMultiple = true)]
public sealed class CsvOrderAttribute : CsvFieldConfigurationAttribute
- Inheritance
-
CsvOrderAttribute
- Inherited Members
Constructors
CsvOrderAttribute(int)
Initializes a new instance of the CsvOrderAttribute class.
public CsvOrderAttribute(int order)
Parameters
order
intOrder value of the CSV field.
Exceptions
Properties
Order
Order value of the CSV field. The default value is zero for unconfigured fields. Fields with a lower order value will be written before fields with a higher order value. Order of fields with the same order value is not guaranteed.
public int Order { get; }