Package org.docx4j.model.table
Class TableModelCell
java.lang.Object
org.docx4j.model.table.TableModelCell
- Direct Known Subclasses:
AbstractTableWriterModelCell
A cell in the table holding its own content, too
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate intthis col number is not intuitive; it increments for each real cell, and again so that it is the same for all following placeholder cells!private intprotected booleanIf this is a real cell or only a placeholder.protected booleanprotected booleanIn XSL FO, we need to write cells for before & after, but not dummy cells for horizontal mergeprivate static final org.slf4j.Loggerprivate intprotected intprivate TableModelprotected TcPr -
Constructor Summary
ConstructorsConstructorDescriptionTableModelCell(TableModel table, int row, int col) Create a dummy cell without contentTableModelCell(TableModel table, int row, int col, Tc tc) -
Method Summary
Modifier and TypeMethodDescriptiondebugStr()intintintHow many columns are merged into this cellintgetTcPr()protected voidIf this is a real cell, increment rowspan; if this is a dummy, propagate the call to the cell upwardsbooleanisDummy()booleanbooleanbooleanvoidsetColspan(int colspan)
-
Field Details
-
logger
private static final org.slf4j.Logger logger -
table
-
row
private int row -
col
private int colthis col number is not intuitive; it increments for each real cell, and again so that it is the same for all following placeholder cells! -
rowspan
protected int rowspan -
colspan
private int colspan -
dummy
protected boolean dummyIf this is a real cell or only a placeholder. Vertically merged cells are represented as a real cell on the top and dummy cell(s) below -
dummyBefore
protected boolean dummyBeforeIn XSL FO, we need to write cells for before & after, but not dummy cells for horizontal merge -
dummyAfter
protected boolean dummyAfter -
tcPr
-
-
Constructor Details
-
TableModelCell
Create a dummy cell without content -
TableModelCell
-
-
Method Details
-
getColspan
public int getColspan() -
setColspan
public void setColspan(int colspan) -
isDummyBefore
public boolean isDummyBefore() -
isDummyAfter
public boolean isDummyAfter() -
getTcPr
-
getExtraCols
public int getExtraCols()How many columns are merged into this cell- Returns:
- 0 if none merged; 1 if two cells are merged so there is one extra; etc. A dummy cell has the same extraCols value as its upper neighbor.
-
getExtraRows
public int getExtraRows() -
isDummy
public boolean isDummy() -
getColumn
public int getColumn() -
incrementRowSpan
protected void incrementRowSpan()If this is a real cell, increment rowspan; if this is a dummy, propagate the call to the cell upwards -
debugStr
-
isVMerged
public boolean isVMerged()
-