Class TextFormatting.TableBuilder
java.lang.Object
de.chojo.jdautil.text.TextFormatting.TableBuilder
- Enclosing class:
TextFormatting
-
Method Summary
Modifier and TypeMethodDescriptionvoidnext()The pointer starts at 0.setHighlighting(@NotNull String markdown) Set the markdown for the table code block.voidsetNextRow(String... columnEntries) Moves the row pointer one step forward an set the row content.setPadding(int padding) Set the space between the columns.voidSet the current row.toString()Returns the formatted table in block code style.
-
Method Details
-
setNextRow
Moves the row pointer one step forward an set the row content.- Parameters:
columnEntries- Entries for the columns in the current row
-
setRow
Set the current row. To go a row forward user next().- Parameters:
columnEntries- Entries for the columns in the current row
-
next
public void next()The pointer starts at 0. Row zero can only be set on object creation. use next() before you set the first row. -
setHighlighting
Set the markdown for the table code block.- Parameters:
markdown- Markdown code (i.e. java, md, csharp)- Returns:
- self instance with highlighting set
-
setPadding
Set the space between the columns.- Parameters:
padding- number between 1 and 10- Returns:
- self instance with padding set
-
toString
-