Table of Contents

Interface Csv.IWriteBuilder<T>

Namespace
FlameCsv
Assembly
FlameCsv.Core.dll

Builder to create a CSV writing pipeline from.

public interface Csv.IWriteBuilder<T> : Csv.IWriteBuilderBase<T, Csv.IWriteBuilder<T>> where T : unmanaged, IBinaryInteger<T>

Type Parameters

T
Inherited Members

Methods

WriteAsync<TValue>(CsvTypeMap<T, TValue>, IAsyncEnumerable<TValue>, CsvOptions<T>?, CancellationToken)

Writes CSV records to the target, binding them using reflection.

Task WriteAsync<TValue>(CsvTypeMap<T, TValue> typeMap, IAsyncEnumerable<TValue> values, CsvOptions<T>? options = null, CancellationToken cancellationToken = default)

Parameters

typeMap CsvTypeMap<T, TValue>
values IAsyncEnumerable<TValue>

Values to write

options CsvOptions<T>

Options to use, Default used by default

cancellationToken CancellationToken

Token to cancel the asynchronous writing operation

Returns

Task

A task that completes when writing has finished

Type Parameters

TValue

Remarks

A header or newline (depending on configuration) is written even if values is empty.

WriteAsync<TValue>(CsvTypeMap<T, TValue>, IEnumerable<TValue>, CsvOptions<T>?, CancellationToken)

Writes CSV records to the target, binding them using reflection.

[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.")]
Task WriteAsync<TValue>(CsvTypeMap<T, TValue> typeMap, IEnumerable<TValue> values, CsvOptions<T>? options = null, CancellationToken cancellationToken = default)

Parameters

typeMap CsvTypeMap<T, TValue>

Type map used to bind the CSV data

values IEnumerable<TValue>

Values to write

options CsvOptions<T>

Options to use, Default used by default

cancellationToken CancellationToken

Token to cancel the asynchronous writing operation

Returns

Task

A task that completes when writing has finished

Type Parameters

TValue

Remarks

A header or newline (depending on configuration) is written even if values is empty.

WriteAsync<TValue>(IAsyncEnumerable<TValue>, CsvOptions<T>?, CancellationToken)

Writes CSV records to the target, binding them using reflection.

[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.")]
Task WriteAsync<TValue>(IAsyncEnumerable<TValue> values, CsvOptions<T>? options = null, CancellationToken cancellationToken = default)

Parameters

values IAsyncEnumerable<TValue>

Values to write

options CsvOptions<T>

Options to use, Default used by default

cancellationToken CancellationToken

Token to cancel the asynchronous writing operation

Returns

Task

A task that completes when writing has finished

Type Parameters

TValue

Remarks

A header or newline (depending on configuration) is written even if values is empty.

WriteAsync<TValue>(IEnumerable<TValue>, CsvOptions<T>?, CancellationToken)

Writes CSV records to the target, binding them using reflection.

[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.")]
Task WriteAsync<TValue>(IEnumerable<TValue> values, CsvOptions<T>? options = null, CancellationToken cancellationToken = default)

Parameters

values IEnumerable<TValue>

Values to write

options CsvOptions<T>

Options to use, Default used by default

cancellationToken CancellationToken

Token to cancel the asynchronous writing operation

Returns

Task

A task that completes when writing has finished

Type Parameters

TValue

Remarks

A header or newline (depending on configuration) is written even if values is empty.

Write<TValue>(CsvTypeMap<T, TValue>, IEnumerable<TValue>, CsvOptions<T>?)

Writes CSV records to the target, binding them using reflection.

void Write<TValue>(CsvTypeMap<T, TValue> typeMap, IEnumerable<TValue> values, CsvOptions<T>? options = null)

Parameters

typeMap CsvTypeMap<T, TValue>

Type map used to bind the CSV data

values IEnumerable<TValue>

Values to write

options CsvOptions<T>

Options to use, Default used by default

Type Parameters

TValue

Remarks

A header or newline (depending on configuration) is written even if values is empty.

Write<TValue>(IEnumerable<TValue>, CsvOptions<T>?)

Writes CSV records to the target, binding them using reflection.

[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.")]
void Write<TValue>(IEnumerable<TValue> values, CsvOptions<T>? options = null)

Parameters

values IEnumerable<TValue>

Values to write

options CsvOptions<T>

Options to use, Default used by default

Type Parameters

TValue

Remarks

A header or newline (depending on configuration) is written even if values is empty.