if (parent instanceof TableRow) {
final TableRow parentRow = (TableRow) parent;
return new TableCell(parentRow, propertyList);
}
if (parent instanceof AbstractTablePart) {
final AbstractTablePart tablePart = (AbstractTablePart) parent;
return new TableCell(tablePart, propertyList);
}
throwException(locator, "fo:" + enumeration.toXslFo()
+ " must be child of fo:table-row, fo:table-body, " +
"fo:table-header, or fo:table-footer.");