Class HeaderFormatter
java.lang.Object
dev.toonformat.jtoon.encoder.HeaderFormatter
Formats headers for arrays and tables in TOON format.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordConfiguration for header formatting. -
Method Summary
-
Method Details
-
format
Formats a header for arrays and tables.- Parameters:
config- Header configuration- Returns:
- Formatted header string
-
format
public static String format(int length, String key, List<String> fields, String delimiter, boolean lengthMarker) Legacy method for backward compatibility. Delegates to the record-based format method.- Parameters:
length- the array or table lengthkey- optional key prefixfields- optional field names for tabular formatdelimiter- the delimiter being usedlengthMarker- whether to include # marker before length- Returns:
- formatted header string
-