-
Notifications
You must be signed in to change notification settings - Fork 262
Support for custom value parsers #51
Copy link
Copy link
Closed
Labels
closed-resolvedThis issue is closed because the work done to resolve it is complete.This issue is closed because the work done to resolve it is complete.enhancementhelp wantedWe would be willing to take a well-written PR to help fix this.We would be willing to take a well-written PR to help fix this.
Milestone
Description
Metadata
Metadata
Assignees
Labels
closed-resolvedThis issue is closed because the work done to resolve it is complete.This issue is closed because the work done to resolve it is complete.enhancementhelp wantedWe would be willing to take a well-written PR to help fix this.We would be willing to take a well-written PR to help fix this.
In the vein of automating as much as possible, it would be nice to be able to supply our own value parsers to the library. This is useful when an application has its own data structures because it removes boilerplate from argument parsing.
For example, we are parsing
DateTimeOffsets,TimeSpans,Colorstructs, and some other domain-specific types.If you think this would be a valuable contribution I'd be happy to implement it, but I'd appreciate a suggestion on how I should extend the public API. A trivial (but perhaps naive) way to do it would be to add an
AddParsermethodValueParserProvider.