/** * Get the ID of the footnote. * <p>Footnote IDs are unique across all bottom-of-the-page and * end note footnotes.</p> * * @return Footnote ID * @since 4.0.0 */ public BigInteger getId() { return this.ctFtnEdn.getId(); }
public XWPFAbstractFootnoteEndnote getFootnoteById(int id) { for (XWPFAbstractFootnoteEndnote note : listFootnote) { if (note.getCTFtnEdn().getId().intValue() == id) return note; } return null; }
/** * Get the ID of the footnote. * <p>Footnote IDs are unique across all bottom-of-the-page and * end note footnotes.</p> * * @return Footnote ID * @since 4.0.0 */ public BigInteger getId() { return this.ctFtnEdn.getId(); }
public XWPFFootnote getFootnoteById(int id) { for(XWPFFootnote note : listFootnote) { if(note.getCTFtnEdn().getId().intValue() == id) return note; } return null; }
public XWPFAbstractFootnoteEndnote getFootnoteById(int id) { for (XWPFAbstractFootnoteEndnote note : listFootnote) { if (note.getCTFtnEdn().getId().intValue() == id) return note; } return null; }
public XWPFFootnote addEndnote(CTFtnEdn note) { XWPFFootnote endnote = new XWPFFootnote(this, note); endnotes.put(note.getId().intValue(), endnote); return endnote; }
private void initFootnotes() throws XmlException, IOException { for(POIXMLDocumentPart p : getRelations()){ String relation = p.getPackageRelationship().getRelationshipType(); if (relation.equals(XWPFRelation.FOOTNOTE.getRelation())) { FootnotesDocument footnotesDocument = FootnotesDocument.Factory.parse(p.getPackagePart().getInputStream()); this.footnotes = (XWPFFootnotes)p; this.footnotes.onDocumentRead(); for(CTFtnEdn ctFtnEdn : footnotesDocument.getFootnotes().getFootnoteList()) { footnotes.addFootnote(ctFtnEdn); } } else if (relation.equals(XWPFRelation.ENDNOTE.getRelation())){ EndnotesDocument endnotesDocument = EndnotesDocument.Factory.parse(p.getPackagePart().getInputStream()); for(CTFtnEdn ctFtnEdn : endnotesDocument.getEndnotes().getEndnoteList()) { endnotes.put(ctFtnEdn.getId().intValue(), new XWPFFootnote(this, ctFtnEdn)); } } } }