mirror of
https://github.com/ibm-s390-linux/s390-tools.git
synced 2026-08-05 02:14:52 +00:00
For structured output (i.e. JSON), some type information of the columns is required, at least the ability to distinguish values that are strings and possibly need to be quoted. Unfortunately at the time column values are formatted this information is lost. The column types are specified implicitly during the unit conversion of the raw value. For example, online time is stored as a u64 value but is converted into a "d:h:m" string. Introduce a private flag per column that signifies if that column is to be formatted as a string. This flag will be set in the appropriate unit conversion function. Reviewed-by: Mete Durlu <meted@linux.ibm.com> Signed-off-by: Bjoern Walk <bwalk@linux.ibm.com> Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
7.6 KiB
7.6 KiB