cox.jmatt.java.MathTools.markup.latex
Class LaTable

java.lang.Object
  extended by cox.jmatt.java.MathTools.markup.latex.LaBaseTag
      extended by cox.jmatt.java.MathTools.markup.latex.LaTable

public class LaTable
extends LaBaseTag

This class provides LaTeX table-generating ('tabular') capability. When instantiated it creates an empty table with a single center-aligned column. Any number of columns are available but the column alignment String must be set.


Field Summary
 
Fields inherited from class cox.jmatt.java.MathTools.markup.latex.LaBaseTag
BS, DBS, DBSN, myAuthor, myDate, myEndTag, myEnvironment, myEnvParams, myOptions, myPicHasOrigin, myPicX, myPicXOrigin, myPicY, myPicYOrigin, mySectionLabel, myTagName, myTitle
 
Constructor Summary
LaTable()
          Basic constructor for an empty table.
LaTable(java.lang.String pColAlign)
          Deluxe constructor that allows column alignment to be set.
 
Method Summary
 LaTable addLine()
          Add a horizontal line ('/hline') to the table.
 LaTable addLine(int pLN, int pRN)
          Add a '/cline{}' tag to the table.
 LaTable addRow(java.lang.String... pRow)
          Add a row to the table.
 LaTable copyOf()
          Standard copy method.
 LaTable copyOfSET()
          Copy method, end tag suppressed.
 void reset()
          Overridden to reset local settings.
 LaTable setColAlign(java.lang.String pAlign)
          Set the column alignment.
 
Methods inherited from class cox.jmatt.java.MathTools.markup.latex.LaBaseTag
_addContent, _addRawContent, _getContent, _setEndTagEnabled, _setETEn, getEndTag, hasEndTag, isEndTagEnabled, setLabel, toString, toStringSET
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LaTable

public LaTable()
Basic constructor for an empty table.


LaTable

public LaTable(java.lang.String pColAlign)
Deluxe constructor that allows column alignment to be set. If 'pColAlign' is null or blank it defaults to a single centered column.

Parameters:
pColAlign - The column alignment specifier for this table.
Method Detail

setColAlign

public LaTable setColAlign(java.lang.String pAlign)
Set the column alignment. THIS IS MANDATORY! If set to null or blank the default is a single center-aligned column: '{c}'.


addRow

public LaTable addRow(java.lang.String... pRow)
Add a row to the table. No column-counting is enforced so it is up to the user to make certain each row contains the right number of entries. The column break ('&') and end-of-row delimiters are added automatically.

Parameters:
pRow - The row of elements to add to the table.

addLine

public LaTable addLine()
Add a horizontal line ('/hline') to the table.


addLine

public LaTable addLine(int pLN,
                       int pRN)
Add a '/cline{}' tag to the table. If either number is less than one nothing happens.

Parameters:
pLN - The left-side number in the curly braces.
pRN - The right-side number.

reset

public void reset()
Overridden to reset local settings.

Overrides:
reset in class LaBaseTag

copyOf

public LaTable copyOf()
Standard copy method.

Specified by:
copyOf in class LaBaseTag

copyOfSET

public LaTable copyOfSET()
Copy method, end tag suppressed.

Specified by:
copyOfSET in class LaBaseTag