protected class XmlToPdf.XmlTable
extends java.lang.Object
implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
protected org.w3c.dom.Node |
__colnode |
protected com.itextpdf.text.pdf.PdfPTable |
__table |
protected org.w3c.dom.Node |
__tblnode |
private static long |
serialVersionUID
The class' serialization version id.
|
Modifier | Constructor and Description |
---|---|
protected |
XmlTable(org.w3c.dom.Node node)
Constructs a new XML table node.
|
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
getAttr(org.w3c.dom.Node node,
java.lang.String name)
Returns an attribute value from the XML table node.
|
protected int |
getColAlign(int index)
Returns the column alignment value for a column.
|
protected java.lang.String[] |
getColAligns()
Returns an array of column alignment values.
|
protected float[] |
getColWidths()
Returns an array of column width values.
|
protected int |
getHeaderRows()
Returns the number of header rows in the table.
|
protected java.lang.String |
getStyle()
Returns the style of the table (pagehead, gridlist, etc.)
|
protected float |
getWidth()
Returns the width of the table.
|
protected void |
recurseXml(org.w3c.dom.NodeList children)
Recurses the table's XML child nodes and creates the table's PDF
cells.
|
protected com.itextpdf.text.pdf.PdfPTable |
toPdf()
Performs translation of the XML table to a PDF table.
|
private static final long serialVersionUID
protected org.w3c.dom.Node __tblnode
protected org.w3c.dom.Node __colnode
protected com.itextpdf.text.pdf.PdfPTable __table
protected XmlTable(org.w3c.dom.Node node)
node
- (Node) A table node from the XML document object.protected java.lang.String getAttr(org.w3c.dom.Node node, java.lang.String name)
name
- (String) The name of the attribute to retrieve.protected int getColAlign(int index)
index
- (int) The index of the column to retrieve (zero based).protected java.lang.String[] getColAligns()
protected float[] getColWidths()
protected int getHeaderRows()
protected java.lang.String getStyle()
protected float getWidth()
protected void recurseXml(org.w3c.dom.NodeList children) throws java.lang.Exception
children
- (NodeList) The table's child nodes.java.lang.Exception
- - if an error occurs during processing.protected com.itextpdf.text.pdf.PdfPTable toPdf() throws java.lang.Exception
java.lang.Exception
- - if an error occurs during processing.