Skip to content

Contribution approvals #164

@waynebrantley

Description

@waynebrantley

@MarcosMeli I finally am making the jump to the latest version of FileHelpers after a long run in 2.9.9. I want to contribute back a number of things, but wanted to make sure my contributions were in line with your thinking.

  • CsvHeader
    I need to write out the csv header that represents the file format. That is done with a GetCsvHeader call. My current implementation uses a static method on a type as that was the best way I could do it without modifying the source. (This makes use of existing FieldOrder attribute and a new FieldTitleAttribute to make this happen) It looks like this:
                var engine = new FileHelperEngine<SomeClass>();
                var streamWriter = new StreamWriter(memoryStream);
                engine.HeaderText = typeof(SomeClass).GetCsvHeader();
What I would like to do is have this implemented directly in filehelpers.  Is this something you think is     useful and where do you think it should go?  (If you think useful, need your guidance on where it should go)
  • CurrencyConveter - a more advanced converter around values that are currency and my include $, etc.
  • Removing internal sealed from converter classes. I have an exact copy of your class DateTimeConverter with a new constructor and small feature. Would be better to inherit.
  • ImpliedDecimalsConverter used for fixed length fields to remove decimals from the number using a given number of implied decimals.
  • StringFormatOutputConverter used to take a string and a standard string format item and use that when outputting the value. (For example to output a decimal as a value with 2 decimal points would be "{0:F2}", etc.

Thanks for all your work!

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions