Table of Contents

Interface IExcelCellWriter<T>

Namespace
ExcelReader.Core.Writer
Assembly
ExcelReader.Core.dll

Writes a value of type T as a cell of a row, for use with the [ExcelConverter] attribute on a property that FromAttributes<T>() writes. Implement this alongside IExcelCellConverter<T> on the same converter type to round-trip a custom type through both writing (via FromAttributes<T>()) and reading (via ExcelParser<T>). A single instance is shared across every row and thread, so implementations must be stateless and thread-safe.

public interface IExcelCellWriter<in T>

Type Parameters

T

The property type this converter writes.

Methods

Write(IRowWriter, T)

Writes value as exactly one cell on row; the row's column position auto-advances as with any other IRowWriter write.

void Write(IRowWriter row, T value)

Parameters

row IRowWriter

The row to write the cell to.

value T

The value to write.