Interface MarkdownCompiler<T extends MarkdownCompiler<?>>
- Type Parameters:
 T- The class type to return in append methods. This should be the class inheriting this interface
- All Known Implementing Classes:
 MarkdownBuffer,MarkdownWriter
Implements methods used within any markdown compiler. Provides many shortcut methods for each markdown element that can be appended
- Since:
 - 0.0.14
 - Author:
 - Thomas Kwashnak
 
- 
Method Summary
Modifier and TypeMethodDescriptiondefault TAppends any given object to the end of the document.default TappendBold(Object content) Displays provided content as bold.default TappendBulletList(Object[] objects) default TappendBulletList(String name, Object[] objects) default TappendBulletList(String name, List<?> objects) default TappendBulletList(String name, Stream<?> stream) default TappendBulletList(List<?> objects) default TappendBulletList(Stream<?> stream) default TappendCode(Object content) Displays provided content as short code snippetsdefault TappendCodeBlock(Object content) Displays a block of codedefault TappendCodeBlock(String language, Object content) Displays a block of code with syntax highlightingdefault TappendHeader(int level, Object content) default TappendHeader(Object content) default TappendImage(String src) default TappendImage(String content, String src) default TappendItalic(Object content) Appends text to the end of the compiler formatted as italicsdefault TappendLink(Object content, String url) default TappendLink(String url) appendMarkdownElement(MarkdownElement element) Appends a markdown element to the end of the document.default TappendNumberedList(int start, Object[] objects) default TappendNumberedList(int start, List<?> objects) default TappendNumberedList(int start, Stream<?> stream) default TappendNumberedList(Object[] objects) default TappendNumberedList(String name, int start, Object[] objects) default TappendNumberedList(String name, int start, List<?> objects) default TappendNumberedList(String name, int start, Stream<?> stream) default TappendNumberedList(String name, Object[] objects) default TappendNumberedList(String name, List<?> objects) default TappendNumberedList(String name, Stream<?> stream) default TappendNumberedList(List<?> objects) default TappendNumberedList(Stream<?> stream) default TappendStrikethrough(Object content) Appends content formatted as struck outappendString(String string) Appends a string to the end of the document.default TappendTable(Object[] headers, Object[][] content) default TappendTable(Object[] headers, Table.Alignment[] alignments, Object[][] content)  
- 
Method Details
- 
append
Appends any given object to the end of the document. Checks what type of object was passed and uses the correct method accordingly
- If the object provided extends the 
MarkdownElementclass, then this method will useappendMarkdownElement(MarkdownElement)to handle adding the element to the document. - Otherwise, this method will use 
appendString(String)and pass theObject.toString()result as the string. 
- Parameters:
 object- Content to add to the end of the document- Returns:
 - An instance of the MarkdownCompiler used
 - Since:
 - 0.0.14
 - See Also:
 
 - If the object provided extends the 
 - 
appendMarkdownElement
Appends a markdown element to the end of the document. Adjusts and manages new lines depending on the requirements set by the Markdown Element
- Parameters:
 element- Markdown Element to add to the end of the document- Returns:
 - An instance of the MarkdownCompiler used
 - Since:
 - 0.0.14
 - See Also:
 
 - 
appendString
Appends a string to the end of the document.
- Parameters:
 string- String to append to the end of the document- Returns:
 - An instance of the MarkdownCompiler used
 - Since:
 - 0.0.14
 
 - 
appendBold
Displays provided content as bold.
Wraps the content provided in
~- Parameters:
 content- The content to be displayed in bold- Returns:
 - This MarkdownCompiler
 - Since:
 - 0.0.15
 
 - 
appendBulletList
- Since:
 - 0.0.15
 
 - 
appendBulletList
- Since:
 - 0.0.15
 
 - 
appendBulletList
 - 
appendBulletList
- Since:
 - 0.0.15
 
 - 
appendBulletList
- Since:
 - 0.0.15
 
 - 
appendBulletList
- Since:
 - 0.0.15
 
 - 
appendCode
Displays provided content as short code snippets
These code snippets are typically displayed in a monospace font and have a grey background
This will throw an
IllegalContentsExceptionif aMarkdownElementis passed in. If you really want to pass aMarkdownElementin, you can simply just use itstoString()method to convert it to a String first.- Parameters:
 content- The content to display within the code snippet.- Returns:
 - This Compiler
 - Since:
 - 0.0.15
 
 - 
appendCodeBlock
Displays a block of code
These code blocks are typically displayed in a monospace font and have a grey background
- Parameters:
 content- The code to display in the code snippet- Returns:
 - This Compiler
 - Since:
 - 0.0.15
 
 - 
appendCodeBlock
Displays a block of code with syntax highlighting
These code blocks are typically displayed in a monospaced font and have a grey background. Indentation is also displayed
- Parameters:
 language- The syntax highlighting language to usecontent- The code to display in the code snippet- Returns:
 - This Compiler
 - Since:
 - 0.0.15
 
 - 
appendHeader
 - 
appendHeader
- Since:
 - 0.0.15
 
 - 
appendImage
- Since:
 - 0.0.15
 
 - 
appendImage
- Since:
 - 0.0.15
 
 - 
appendStrikethrough
Appends content formatted as struck out
- Parameters:
 content- Content to strike out- Returns:
 - This instance of the compiler
 - Since:
 - 0.0.15
 
 - 
appendItalic
Appends text to the end of the compiler formatted as italics
- Parameters:
 content- The content you wish to be formatted in italics- Since:
 - 0.0.15
 
 - 
appendLink
- Since:
 - 0.0.15
 
 - 
appendLink
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendNumberedList
- Since:
 - 0.0.15
 
 - 
appendTable
- Since:
 - 0.0.15
 
 - 
appendTable
- Since:
 - 0.0.15
 
 
 -