We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 64bca8f commit 31ed3aaCopy full SHA for 31ed3aa
openpdf/src/main/java/com/lowagie/text/pdf/PdfPTable.java
@@ -654,11 +654,12 @@ public PdfPCell addCell(String text) {
654
* Adds a nested table.
655
*
656
* @param table the table to be added to the cell
657
+ * @throws DocumentException if table tries to add itself
658
*/
- public PdfPCell addCell(PdfPTable table) {
659
- if(table == this) {
660
- throw new DocumentException("unable.to.add.self.to.table.contents");
661
- }
+ public PdfPCell addCell(PdfPTable table) throws DocumentException {
+ if (table == this) {
+ throw new DocumentException("unable.to.add.self.to.table.contents");
662
+ }
663
defaultCell.setTable(table);
664
addCell(defaultCell);
665
defaultCell.setTable(null);
0 commit comments