FOPを使用してHTML(XMLに埋め込まれている)をPDFに変換しています。HTMLスニペットは次のようになります:-
<table border="1" width="100%">
<thead>
<tr>
<th>Name</th>
<th>Value</th>
</tr>
</thead>
<tbody/>
</table>
変換すると、次のエラーが発生します:-
Caused by: org.apache.fop.fo.ValidationException: Error(Unknown location): fo:table-body i
s missing child elements.
Required Content Model: marker* (table-row+|table-cell+)
要素を削除したときに同様のエラーが発生しました<tbody/>
:-
org.apache.fop.fo.ValidationException: Error(Unknown location): fo:table is missing child
elements.
Required Content Model: (marker*,table-column*,table-header?,table-footer?,table-body+)
fo:tableにはtable-bodyが必要であり、table-bodyにはtable-rowが必要なようです。私の質問は:-
テーブルヘッダーのみでテーブル本体なし、または空のテーブル本体でテーブルを作成することは可能ですか?