protected class XmlToPdf.XmlCell
extends java.lang.Object
implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
protected com.itextpdf.text.pdf.PdfPCell |
__cell |
protected int |
__index |
protected org.w3c.dom.Node |
__node |
protected XmlToPdf.XmlTable |
__parent |
private static long |
serialVersionUID
The class' serialization version id.
|
Modifier | Constructor and Description |
---|---|
protected |
XmlCell(XmlToPdf.XmlTable parent,
org.w3c.dom.Node node,
int index)
Constructs a new XML table cell node.
|
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
getAlign()
Returns the override alignment value for the cell.
|
protected java.lang.String |
getAttr(java.lang.String name)
Returns an attribute value from the XML cell node.
|
protected int |
getColSpan()
Returns the column span value for the cell.
|
protected com.itextpdf.text.Font |
getFont()
Returns the font value for the cell based on the cell's type (th, td)
and the parent table's style.
|
protected XmlToPdf.XmlTable |
getTable()
Determines if this cell contains a table and, if so, returns the table.
|
protected java.lang.String |
getValue()
Returns the text value for the cell.
|
protected void |
setBackgroundColor()
Sets the background color for the cell based on the cell's type (th, td)
and the parent table's style.
|
protected void |
setBorder()
Enables or disables the border for the cell based on the cell's type
(th, td) and the parent table's style.
|
protected void |
setBorderColor()
Sets the border color for the cell based on the parent table's style.
|
protected void |
setColSpan()
Sets the column span value for the cell (if one is defined).
|
protected void |
setHorizontalAlignment()
Sets the horizontal alignment for the cell based on the cell's type
(th, td) and the parent table's style.
|
protected void |
setPadding()
Sets the padding for the cell based on the parent table's style.
|
protected com.itextpdf.text.pdf.PdfPCell |
toPdf()
Performs translation of the XML table cell to a PDF table cell.
|
private static final long serialVersionUID
protected XmlToPdf.XmlTable __parent
protected org.w3c.dom.Node __node
protected int __index
protected com.itextpdf.text.pdf.PdfPCell __cell
protected XmlCell(XmlToPdf.XmlTable parent, org.w3c.dom.Node node, int index)
parent
- (XmlTable) The cell's parent XML table object.node
- (Node) A table cell node from the XML document object.index
- (int) The column index of the cell (zero based).protected java.lang.String getAttr(java.lang.String name)
name
- (String) The name of the attribute to retrieve.protected java.lang.String getAlign()
null
if no override alignment is defined.protected int getColSpan()
protected com.itextpdf.text.Font getFont()
protected XmlToPdf.XmlTable getTable()
null
if the
cell does not contain a table.protected java.lang.String getValue()
protected void setBackgroundColor()
protected void setBorder()
protected void setBorderColor()
protected void setColSpan()
protected void setHorizontalAlignment()
protected void setPadding()
protected com.itextpdf.text.pdf.PdfPCell toPdf() throws java.lang.Exception
java.lang.Exception
- - if an error occurs during processing.