gws.helper.csv
¶
Common csv writer helper.
Source code: gws.helper.csv
Package Contents¶
- class gws.helper.csv.Config(*args, **kwargs)¶
Bases:
gws.Config
CSV helper.
- format: FormatConfig¶
CSV format settings.
- class gws.helper.csv.Format(*args, **kwargs)¶
Bases:
gws.Data
Basic data object.
This object can be instantiated by passing one or or
dict
arguments and/or keyword args. All dicts keys and keywords become attributes of the object.Accessing an undefined attribute returns
None
and no error is raised, unless the attribute name starts with an underscore.- delimiter: str¶
- encoding: str¶
- formulaHack: bool¶
- quote: str¶
- quoteAll: bool¶
- rowDelimiter: str¶
- class gws.helper.csv.FormatConfig(*args, **kwargs)¶
Bases:
gws.Config
CSV format settings
- delimiter: str = ','¶
Field delimiter.
- encoding: str = 'utf8'¶
Text encoding.
- formulaHack: bool = True¶
Prepend numeric strings with an equals sign.
- quote: str = '"'¶
Quote character.
- quoteAll: bool = False¶
Quote all fields.
- rowDelimiter: str = 'LF'¶
Row delimiter.