Skip to content

Commit

Permalink
Update Options.md (#232)
Browse files Browse the repository at this point in the history
* Update Options.md

Updated options to reflect current source code (probably not complete)

* Update Options.md

---------

Co-authored-by: Mark Pflug <MarkPflug@users.noreply.github.com>
  • Loading branch information
burnchar and MarkPflug authored Jan 15, 2024
1 parent 474263a commit e47d546
Showing 1 changed file with 25 additions and 3 deletions.
28 changes: 25 additions & 3 deletions docs/Csv/Options.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,34 @@ These defaults to `null`, which attempt to parse the values as the default "true

If either `TrueString` or `FalseString` are non-null, then that value is the singular, case-insensitive string that will be interpreted as the associated boolean value. If only one of the two is assigned it causes all other values to be interpreted as the negation. If both are assigned any value that is not one or the other will result in a `FormatException` being thrown.

__DateFormat__

__DateTimeFormat__
The format string used to parse `DateTime` values. This defaults to null, which will result in values being parsed using the provide `CultureInfo`.

Some CSV data sources use a compact date format like `"yyyyMMdd"` which cannot be parsed by default date parsing behavior, in which case this option allows parsing such values.

__DateTimeOffsetFormat__
The format string used when writing DateTimeOffset values
This defaults to null, which will result in values being parsed using the provided `CultureInfo`.

__TimeSpanFormat__
The format string used when writing TimeSpan values that have to time component. This defaults to null, which will result in values being parsed using the provided `CultureInfo`.

__TimeOnlyFormat__
The format string used when writing TimeOnly values. This option is only available when using .NET 6 or greater.
This defaults to null, which will result in values being parsed using the provided `CultureInfo`.

__DateOnlyFormat__
The format string used when writing DateOnly values. This option is only available when using .NET 6 or greater.
This defaults to null, which will result in values being parsed using the provided `CultureInfo`.

__DateFormat__

**Obsolete**, Use DateTimeFormat instead.

__TimeFormat__

**Obsolete**, Use TimeOnlyFormat instead.

__BinaryEncoding__

The encoding format used to interpret binary data, either Base64 or Hexadecimal. Hexadecimal values can optionally be prefixed with "0x".
Expand Down Expand Up @@ -122,4 +144,4 @@ static string Pool(char[] buf, int offset, int length)
// anything else just construct normally (or call a nested factory)
return new string(buf, offset, length);
}
```
```

0 comments on commit e47d546

Please sign in to comment.