/// <summary> /// Set whether or not to end the last row with a new line. /// </summary> public OptionsBuilder WithWriteTrailingRowEnding(WriteTrailingRowEnding writeTrailingNewLine) { if (!Enum.IsDefined(Types.WriteTrailingRowEnding, writeTrailingNewLine)) { Throw.ArgumentException($"Unexpected {nameof(Cesil.WriteTrailingRowEnding)} value: {writeTrailingNewLine}", nameof(writeTrailingNewLine)); } return(WithWriteTrailingRowEndingInternal(writeTrailingNewLine)); }
// sometimes we want to skip validation in tests internal OptionsBuilder WithWriteTrailingRowEndingInternal(WriteTrailingRowEnding w) { WriteTrailingRowEnding = w; return(this); }