package text
Ordering
- Alphabetic
Visibility
- Public
- Protected
Type Members
- class SortedTableFormatter extends TableFormatter
Extension of TableFormatter that sorts the rows by a column before outputting.
- class TableFormatter extends AnyRef
Simple textual formatter for tabular data.
Simple textual formatter for tabular data. This is intended to be used in text based user interfaces such as CLIs.
Example without headers
TableFormatter() .addRow("Apples", "25") .addRow("Pears", "10") .addRow("Bananas", "4") .print()
Would output:
Apples 25 Pears 10 Bananas 4
Example with headers
TableFormatter("Produce", "Remaining") .addRow("Apples", "25") .addRow("Pears", "10") .addRow("Bananas", "4") .print()
Would output:
| Produce | Remaining | ----------------------- | Apples | 25 | | Pears | 10 | | Bananas | 4 |
Value Members
- object SortedTableFormatter
- object TableFormatter