Class CsvReflectionBinder<T>
Binds type members and constructor parameters to CSV fields using reflection.
public sealed class CsvReflectionBinder<T> : CsvReflectionBinder, ICsvTypeBinder<T> where T : unmanaged, IBinaryInteger<T>Type Parameters
- T
- Token type 
- Inheritance
- 
      objectCsvReflectionBinder<T>
- Implements
Constructors
CsvReflectionBinder(CsvOptions<T>)
Creates an instance of CsvReflectionBinder<T>.
public CsvReflectionBinder(CsvOptions<T> options)Parameters
- optionsCsvOptions<T>
Methods
GetDematerializer<TValue>()
Returns a dematerializer for TValue.
[RequiresUnreferencedCode("This code path uses reflection. Use the overloads accepting source generated CsvTypeMap for AOT/trimming compatible code.")]
[RequiresDynamicCode("This code path uses compiled expressions. Use the overloads accepting source generated CsvTypeMap for AOT/trimming compatible code.")]
public IDematerializer<T, TValue> GetDematerializer<TValue>()Returns
- IDematerializer<T, TValue>
Type Parameters
- TValue
Remarks
Caches the return values based on the options.
Exceptions
- CsvBindingException
- Options is configured not to write a header, but - TValuehas no index binding.
GetMaterializer<TValue>()
Returns a materializer for TValue bound to field indexes.
[RequiresUnreferencedCode("This code path uses reflection. Use the overloads accepting source generated CsvTypeMap for AOT/trimming compatible code.")]
[RequiresDynamicCode("This code path uses compiled expressions. Use the overloads accepting source generated CsvTypeMap for AOT/trimming compatible code.")]
public IMaterializer<T, TValue> GetMaterializer<TValue>()Returns
- IMaterializer<T, TValue>
Type Parameters
- TValue
Remarks
Caches the return values based on the options.
Exceptions
- CsvBindingException
- Options is configured not to write a header, but - TValuehas no index binding.
GetMaterializer<TValue>(ImmutableArray<string>)
Returns a materializer for TValue bound to a CSV header.
[RequiresUnreferencedCode("This code path uses reflection. Use the overloads accepting source generated CsvTypeMap for AOT/trimming compatible code.")]
[RequiresDynamicCode("This code path uses compiled expressions. Use the overloads accepting source generated CsvTypeMap for AOT/trimming compatible code.")]
public IMaterializer<T, TValue> GetMaterializer<TValue>(ImmutableArray<string> headers)Parameters
- headersImmutableArray<string>
Returns
- IMaterializer<T, TValue>
Type Parameters
- TValue
Remarks
Caches the return values based on the options and headers.