qformat¶
-
hhpy.main.
qformat
(value: Any, int_format: str = ', ', float_format: str = ', .2f', datetime_format: str = '%Y-%m-%d', sep: str = ' - ', key_sep: str = ': ', print_key: bool = True) → str[source]¶ Creates a human readable representation of a generic python object
Parameters: - value – Any python object
- int_format – Format string for integer
- float_format – Format string for float
- datetime_format – Format string for datetime
- sep – Separator
- key_sep – Separator used between key and value if print_key is True
- print_key – Whether to print keys as well as values (if object has keys)
Returns: Formated string