Migration guide
Migrating to v3.0.0-rc05
Moving to v3.0.0-rc05 from v3.0.0-rc04. Changelog.
Breaking changes
CsvHelper
BadDataExceptionclass3 breaking1 removed2 changed
BadDataException(IReadingContext, string)Breaking
The parameters changed from (ReadingContext, string) to (IReadingContext, string).
public BadDataException(ReadingContext context, string message)public BadDataException(IReadingContext context, string message)BadDataException(IReadingContext, string, Exception)Breaking
The parameters changed from (ReadingContext, string, Exception) to (IReadingContext, string, Exception).
public BadDataException(ReadingContext context, string message, Exception innerException)public BadDataException(IReadingContext context, string message, Exception innerException)Removed
CsvFieldReaderclass1 breaking1 changed
ContextBreaking
The type changed from IFieldReaderContext to IReadingContext.
public virtual IFieldReaderContext Context { get; }public virtual IReadingContext Context { get; }CsvHelperExceptionclass8 breaking2 removed6 changed
CsvHelperException(IReadingContext, string)Breaking
The parameters changed from (ReadingContext, string) to (IReadingContext, string).
public CsvHelperException(ReadingContext context, string message)public CsvHelperException(IReadingContext context, string message)CsvHelperException(IReadingContext, string, Exception)Breaking
The parameters changed from (ReadingContext, string, Exception) to (IReadingContext, string, Exception).
public CsvHelperException(ReadingContext context, string message, Exception innerException)public CsvHelperException(IReadingContext context, string message, Exception innerException)CsvHelperException(IWritingContext, string)Breaking
The parameters changed from (WritingContext, string) to (IWritingContext, string).
public CsvHelperException(WritingContext context, string message)public CsvHelperException(IWritingContext context, string message)CsvHelperException(IWritingContext, string, Exception)Breaking
The parameters changed from (WritingContext, string, Exception) to (IWritingContext, string, Exception).
public CsvHelperException(WritingContext context, string message, Exception innerException)public CsvHelperException(IWritingContext context, string message, Exception innerException)ReadingContextBreaking
The type changed from ReadingContext to IReadingContext.
public ReadingContext ReadingContext { get; }public IReadingContext ReadingContext { get; }WritingContextBreaking
The type changed from WritingContext to IWritingContext.
public WritingContext WritingContext { get; }public IWritingContext WritingContext { get; }Removed
CsvParserclass1 breaking1 changed
ContextBreaking
The type changed from IParserContext to IReadingContext.
public virtual IParserContext Context { get; }public virtual IReadingContext Context { get; }CsvReaderclass17 breaking14 removed3 changed
CanRead(MemberMap)Breaking
The signature changed.
protected virtual bool CanRead(MemberMap memberMap)public virtual bool CanRead(MemberMap memberMap)CanRead(MemberReferenceMap)Breaking
The signature changed.
protected virtual bool CanRead(MemberReferenceMap memberReferenceMap)public virtual bool CanRead(MemberReferenceMap memberReferenceMap)ContextBreaking
The type changed from IReaderContext to IReadingContext.
public virtual IReaderContext Context { get; }public virtual IReadingContext Context { get; }Removed
CsvSerializerclass1 breaking1 changed
ContextBreaking
The type changed from WritingContext to IWritingContext.
public virtual WritingContext Context { get; }public virtual IWritingContext Context { get; }CsvWriterclass11 breaking9 removed2 changed
CanWrite(MemberMap)Breaking
The signature changed.
protected virtual bool CanWrite(MemberMap memberMap)public virtual bool CanWrite(MemberMap memberMap)ContextBreaking
The type changed from WritingContext to IWritingContext.
public virtual WritingContext Context { get; }public virtual IWritingContext Context { get; }Removed
IFieldReaderinterface1 breaking1 changed
ContextBreaking
The type changed from IFieldReaderContext to IReadingContext.
IFieldReaderContext Context { get; }IReadingContext Context { get; }IParserinterface1 breaking1 changed
ContextBreaking
The type changed from IParserContext to IReadingContext.
IParserContext Context { get; }IReadingContext Context { get; }IReaderRowinterface1 breaking1 changed
ContextBreaking
The type changed from IReaderContext to IReadingContext.
IReaderContext Context { get; }IReadingContext Context { get; }ISerializerinterface1 breaking1 changed
ContextBreaking
The type changed from WritingContext to IWritingContext.
WritingContext Context { get; }IWritingContext Context { get; }IWriterRowinterface1 breaking1 changed
ContextBreaking
The type changed from WritingContext to IWritingContext.
WritingContext Context { get; }IWritingContext Context { get; }MissingFieldExceptionclass3 breaking1 removed2 changed
MissingFieldException(IReadingContext, string)Breaking
The parameters changed from (ReadingContext, string) to (IReadingContext, string).
public MissingFieldException(ReadingContext context, string message)public MissingFieldException(IReadingContext context, string message)MissingFieldException(IReadingContext, string, Exception)Breaking
The parameters changed from (ReadingContext, string, Exception) to (IReadingContext, string, Exception).
public MissingFieldException(ReadingContext context, string message, Exception innerException)public MissingFieldException(IReadingContext context, string message, Exception innerException)Removed
ParserExceptionclass3 breaking1 removed2 changed
ParserException(IReadingContext, string)Breaking
The parameters changed from (ReadingContext, string) to (IReadingContext, string).
public ParserException(ReadingContext context, string message)public ParserException(IReadingContext context, string message)ParserException(IReadingContext, string, Exception)Breaking
The parameters changed from (ReadingContext, string, Exception) to (IReadingContext, string, Exception).
public ParserException(ReadingContext context, string message, Exception innerException)public ParserException(IReadingContext context, string message, Exception innerException)Removed
ReaderExceptionclass3 breaking1 removed2 changed
ReaderException(IReadingContext, string)Breaking
The parameters changed from (ReadingContext, string) to (IReadingContext, string).
public ReaderException(ReadingContext context, string message)public ReaderException(IReadingContext context, string message)ReaderException(IReadingContext, string, Exception)Breaking
The parameters changed from (ReadingContext, string, Exception) to (IReadingContext, string, Exception).
public ReaderException(ReadingContext context, string message, Exception innerException)public ReaderException(IReadingContext context, string message, Exception innerException)Removed
ReadingContextclass1 breaking1 changed
ReadingContextBreaking
The type no longer implements IFieldReaderContext, IParserContext, IReaderContext. The type now implements IReadingContext.
public class ReadingContext : IReaderContext, IParserContext, IFieldReaderContext, IDisposablepublic class ReadingContext : IReadingContext, IDisposableValidationExceptionclass3 breaking1 removed2 changed
ValidationException(IReadingContext, string)Breaking
The parameters changed from (ReadingContext, string) to (IReadingContext, string).
public ValidationException(ReadingContext context, string message)public ValidationException(IReadingContext context, string message)ValidationException(IReadingContext, string, Exception)Breaking
The parameters changed from (ReadingContext, string, Exception) to (IReadingContext, string, Exception).
public ValidationException(ReadingContext context, string message, Exception innerException)public ValidationException(IReadingContext context, string message, Exception innerException)Removed
WriterExceptionclass3 breaking1 removed2 changed
WriterException(IWritingContext, string)Breaking
The parameters changed from (WritingContext, string) to (IWritingContext, string).
public WriterException(WritingContext context, string message)public WriterException(IWritingContext context, string message)WriterException(IWritingContext, string, Exception)Breaking
The parameters changed from (WritingContext, string, Exception) to (IWritingContext, string, Exception).
public WriterException(WritingContext context, string message, Exception innerException)public WriterException(IWritingContext context, string message, Exception innerException)Removed
WritingContextclass1 breaking1 changed
WritingContextBreaking
The type no longer implements ISerializerContext, IWriterContext. The type now implements IWritingContext.
public class WritingContext : IWriterContext, ISerializerContext, IDisposablepublic class WritingContext : IWritingContext, IDisposableRemoved types (5)
CsvHelper.Configuration
Configurationclass3 breaking3 changed
BadDataFoundCallbackBreaking
The type changed from Action<ReadingContext> to Action<IReadingContext>.
public virtual Action<ReadingContext> BadDataFoundCallback { get; set; }public virtual Action<IReadingContext> BadDataFoundCallback { get; set; }HeaderValidatedCallbackBreaking
The type changed from Action<bool, string[], int, ReadingContext> to Action<bool, string[], int, IReadingContext>.
public virtual Action<bool, string[], int, ReadingContext> HeaderValidatedCallback { get; set; }public virtual Action<bool, string[], int, IReadingContext> HeaderValidatedCallback { get; set; }MissingFieldFoundCallbackBreaking
The type changed from Action<string[], int, ReadingContext> to Action<string[], int, IReadingContext>.
public virtual Action<string[], int, ReadingContext> MissingFieldFoundCallback { get; set; }public virtual Action<string[], int, IReadingContext> MissingFieldFoundCallback { get; set; }IParserConfigurationinterface1 breaking1 changed
BadDataFoundCallbackBreaking
The type changed from Action<ReadingContext> to Action<IReadingContext>.
Action<ReadingContext> BadDataFoundCallback { get; set; }Action<IReadingContext> BadDataFoundCallback { get; set; }IReaderConfigurationinterface2 breaking2 changed
HeaderValidatedCallbackBreaking
The type changed from Action<bool, string[], int, ReadingContext> to Action<bool, string[], int, IReadingContext>.
Action<bool, string[], int, ReadingContext> HeaderValidatedCallback { get; set; }Action<bool, string[], int, IReadingContext> HeaderValidatedCallback { get; set; }MissingFieldFoundCallbackBreaking
The type changed from Action<string[], int, ReadingContext> to Action<string[], int, IReadingContext>.
Action<string[], int, ReadingContext> MissingFieldFoundCallback { get; set; }Action<string[], int, IReadingContext> MissingFieldFoundCallback { get; set; }IWriterConfigurationinterface1 breaking1 removed
Removed
Other changes
Not breaking, but worth a look.
ReadingContextclass20 changed
The property now has a set accessor.
Now virtual.
WritingContextclass4 changed
The property now has a set accessor.