public void _doEndTag() throws JspException, IOException, DocumentException {
// set root header/footer to sections
boolean doBookmarks=false;
boolean doHtmlBookmarks=false;
if(_document!=null){
PDFPageMark header = _document.getHeader();
PDFPageMark footer = _document.getFooter();
boolean hasHeader=header!=null;
boolean hasFooter=footer!=null;
if(hasFooter || hasHeader) {
Iterator<PDFDocument> it = documents.iterator();
PDFDocument doc;