blob: 14900aa8ebbb35dab4a9dbe14941ca282d1ae54d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
package org.zwobble.mammoth.internal.documents;
import java.util.List;
public class TableCell implements DocumentElement, HasChildren<TableCell> {
private final int rowspan;
private final int colspan;
private final List<DocumentElement> children;
public TableCell(int rowspan, int colspan, List<DocumentElement> children) {
this.rowspan = rowspan;
this.children = children;
this.colspan = colspan;
}
public int getColspan() {
return colspan;
}
public int getRowspan() {
return rowspan;
}
@Override
public List<DocumentElement> getChildren() {
return children;
}
@Override
public TableCell replaceChildren(List<DocumentElement> newChildren) {
return new TableCell(this.rowspan, this.colspan, newChildren);
}
@Override
public <T, U> T accept(DocumentElementVisitor<T, U> visitor, U context) {
return visitor.visit(this, context);
}
}
|