public class AsciiDocTable extends Object
tableEnd()
is called.
This class is not thread-safe.
Modifier and Type | Field and Description |
---|---|
static int |
COLUMN_WIDTH_MEDIUM
Medium column-width (2x
COLUMN_WIDTH_SMALL ) for use with columnWidths(int...) . |
static int |
COLUMN_WIDTH_SMALL
Small column-width for use with
columnWidths(int...) . |
Modifier and Type | Method and Description |
---|---|
AsciiDocTable |
columnCell(String columnCell)
Inserts a column-cell.
|
AsciiDocTable |
columnCell(String columnCell,
AsciiDocTableColumnStyles style)
Inserts a column-cell, with a style.
|
AsciiDocTable |
columnsPerRow(int columnsPerRow)
Sets number of columns per row, which is implicitly set by
headers(String...) and
columnWidths(int...) . |
AsciiDocTable |
columnWidths(int... columnWidths)
Sets the widths for all columns-per-row, which can be a proportional integer (the default is 1) or a
percentage (1 to 99).
|
AsciiDocTable |
columnWidths(List<Integer> columnWidths)
Sets the widths for all columns-per-row, which can be a proportional integer (the default is 1) or a
percentage (1 to 99).
|
AsciiDocTable |
headers(List<String> columnHeaders)
Sets the column headers, where blank entries can be null/empty, but the length of the headers array must
be equal to the number of columns in the table.
|
AsciiDocTable |
headers(String... columnHeaders)
Sets the column headers, where blank entries can be null/empty, but the length of the headers array must
be equal to the number of columns in the table.
|
AsciiDocTable |
rowEnd()
Adds an optional space to visually delineate the end of a row in the generated markup.
|
AsciiDoc |
tableEnd()
Completes the table being built, and inserts it at the end of the parent document.
|
AsciiDocTable |
title(String title)
Sets a table-title.
|
public static final int COLUMN_WIDTH_SMALL
columnWidths(int...)
.public static final int COLUMN_WIDTH_MEDIUM
COLUMN_WIDTH_SMALL
) for use with columnWidths(int...)
.public AsciiDocTable title(String title)
title
- Table-titlepublic AsciiDocTable headers(List<String> columnHeaders)
columnHeaders
- Column headerspublic AsciiDocTable headers(String... columnHeaders)
columnHeaders
- Column headerspublic AsciiDocTable columnsPerRow(int columnsPerRow)
headers(String...)
and
columnWidths(int...)
.
This value can only be set once.
columnsPerRow
- Columns per rowpublic AsciiDocTable columnWidths(List<Integer> columnWidths)
columnWidths
- An entry for each column-per row in value range [1,99]public AsciiDocTable columnWidths(int... columnWidths)
columnWidths
- An entry for each column-per row in value range [1,99]public AsciiDocTable columnCell(String columnCell)
columnCell
- Column-cell or null
for empty cellpublic AsciiDocTable columnCell(String columnCell, AsciiDocTableColumnStyles style)
columnCell
- Column-cell or null
for empty cellstyle
- Column-stylepublic AsciiDocTable rowEnd()
public AsciiDoc tableEnd()
Copyright 2010-2022 ForgeRock AS.