Class AptParser.Table
- java.lang.Object
-
- org.apache.maven.doxia.module.apt.AptParser.Block
-
- org.apache.maven.doxia.module.apt.AptParser.Table
-
- Enclosing class:
- AptParser
private class AptParser.Table extends AptParser.Block
A Table Block.
-
-
Field Summary
-
Fields inherited from class org.apache.maven.doxia.module.apt.AptParser.Block
indent, text, textLength, type
-
-
Constructor Summary
Constructors Constructor Description Table(int indent, java.lang.String firstLine)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private int[]
parseJustification(java.lang.String jline, int lineLength)
Parse a table justification line.void
traverse()
Parse the block.private boolean
traverseRow(java.lang.StringBuilder[] cells, boolean[] headers, int[] justification)
Traverse a table row.-
Methods inherited from class org.apache.maven.doxia.module.apt.AptParser.Block
getIndent, getType, skipFromLeftToRightBracket, skipLeadingBullets, skipSpaceFrom, traverseText, traverseText
-
-
-
-
Constructor Detail
-
Table
Table(int indent, java.lang.String firstLine) throws AptParseException
Constructor.- Parameters:
indent
- indent.firstLine
- the first line.- Throws:
AptParseException
- AptParseException
-
-
Method Detail
-
traverse
public void traverse() throws AptParseException
Parse the block.- Specified by:
traverse
in classAptParser.Block
- Throws:
AptParseException
- if something goes wrong.
-
parseJustification
private int[] parseJustification(java.lang.String jline, int lineLength) throws AptParseException
Parse a table justification line.- Parameters:
jline
- the justification line.lineLength
- the length of the line. Must be > 2.- Returns:
- int[]
- Throws:
AptParseException
- if something goes wrong.
-
traverseRow
private boolean traverseRow(java.lang.StringBuilder[] cells, boolean[] headers, int[] justification) throws AptParseException
Traverse a table row.- Parameters:
cells
- The table cells.headers
- true for header cells.justification
- the justification for each cell.- Returns:
- boolean
- Throws:
AptParseException
- if something goes wrong.
-
-