org.apache.poi.xwpf.usermodel
Class XWPFFootnote
- java.lang.Object
-
- org.apache.poi.xwpf.usermodel.XWPFFootnote
-
- All Implemented Interfaces:
- java.lang.Iterable<XWPFParagraph>, IBody
public class XWPFFootnote extends java.lang.Object implements java.lang.Iterable<XWPFParagraph>, IBody
-
-
Constructor Summary
Constructors Constructor and Description XWPFFootnote(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn note, XWPFFootnotes xFootnotes)XWPFFootnote(XWPFDocument document, org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn body)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description XWPFParagraphaddNewParagraph(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTP paragraph)add a new paragraph to the end of the footnoteXWPFTableaddNewTbl(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTbl table)add a new table to the end of the footnotejava.util.List<IBodyElement>getBodyElements()Returns an Iterator with paragraphs and tables, in the order that they occur in the text.org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdngetCTFtnEdn()POIXMLDocumentPartgetOwner()XWPFParagraphgetParagraph(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTP p)if there is a correspondingXWPFParagraphof the parameter ctTable in the paragraphList of this header or footer the method will return this paragraph if there is no correspondingXWPFParagraphthe method will return nullXWPFParagraphgetParagraphArray(int pos)Returns the paragraph that holds the text of the header or footer.java.util.List<XWPFParagraph>getParagraphs()Returns the paragraph(s) that holds the text of the header or footer.POIXMLDocumentPartgetPart()returns the Part, to which the body belongs, which you need for adding relationship to other partsBodyTypegetPartType()get the PartType of the bodyjava.util.List<XWPFPictureData>getPictures()XWPFTablegetTable(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTbl ctTable)XWPFTablegetTableArray(int pos)Returns the table at position posXWPFTableCellgetTableCell(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTc cell)get the TableCell which belongs to the TableCelljava.util.List<XWPFTable>getTables()Return the table(s) that holds the text of the IBodyPart, for complex cases where a paragraph isn't used.XWPFDocumentgetXWPFDocument()Return XWPFDocumentXWPFParagraphinsertNewParagraph(org.apache.xmlbeans.XmlCursor cursor)add a new paragraph at position of the cursorXWPFTableinsertNewTbl(org.apache.xmlbeans.XmlCursor cursor)inserts a new Table at the cursor position.voidinsertTable(int pos, XWPFTable table)inserts an existing XWPFTable to the arrays bodyElements and tablesjava.util.Iterator<XWPFParagraph>iterator()voidsetCTFtnEdn(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn footnote)
-
-
-
Constructor Detail
-
XWPFFootnote
public XWPFFootnote(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn note, XWPFFootnotes xFootnotes)
-
XWPFFootnote
public XWPFFootnote(XWPFDocument document, org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn body)
-
-
Method Detail
-
getParagraphs
public java.util.List<XWPFParagraph> getParagraphs()
Description copied from interface:IBodyReturns the paragraph(s) that holds the text of the header or footer.- Specified by:
getParagraphsin interfaceIBody
-
iterator
public java.util.Iterator<XWPFParagraph> iterator()
- Specified by:
iteratorin interfacejava.lang.Iterable<XWPFParagraph>
-
getTables
public java.util.List<XWPFTable> getTables()
Description copied from interface:IBodyReturn the table(s) that holds the text of the IBodyPart, for complex cases where a paragraph isn't used.
-
getPictures
public java.util.List<XWPFPictureData> getPictures()
-
getBodyElements
public java.util.List<IBodyElement> getBodyElements()
Description copied from interface:IBodyReturns an Iterator with paragraphs and tables, in the order that they occur in the text.- Specified by:
getBodyElementsin interfaceIBody
-
getCTFtnEdn
public org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn getCTFtnEdn()
-
setCTFtnEdn
public void setCTFtnEdn(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn footnote)
-
getTableArray
public XWPFTable getTableArray(int pos)
Description copied from interface:IBodyReturns the table at position pos- Specified by:
getTableArrayin interfaceIBody- Parameters:
pos- in table array- Returns:
- The table at position pos
- See Also:
IBody.getTableArray(int)
-
insertTable
public void insertTable(int pos, XWPFTable table)inserts an existing XWPFTable to the arrays bodyElements and tables- Specified by:
insertTablein interfaceIBody- Parameters:
pos-table-- See Also:
IBody.insertTable(int pos, XWPFTable table)
-
getTable
public XWPFTable getTable(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTbl ctTable)
if there is a correspondingXWPFTableof the parameter ctTable in the tableList of this header the method will return this table if there is no correspondingXWPFTablethe method will return null- Specified by:
getTablein interfaceIBody- Parameters:
ctTable-- See Also:
IBody.getTable(CTTbl ctTable)
-
getParagraph
public XWPFParagraph getParagraph(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTP p)
if there is a correspondingXWPFParagraphof the parameter ctTable in the paragraphList of this header or footer the method will return this paragraph if there is no correspondingXWPFParagraphthe method will return null- Specified by:
getParagraphin interfaceIBody- Parameters:
p- is instance of CTP and is searching for an XWPFParagraph- Returns:
- null if there is no XWPFParagraph with an corresponding CTPparagraph in the paragraphList of this header or footer XWPFParagraph with the correspondig CTP p
- See Also:
IBody.getParagraph(CTP p)
-
getParagraphArray
public XWPFParagraph getParagraphArray(int pos)
Returns the paragraph that holds the text of the header or footer.- Specified by:
getParagraphArrayin interfaceIBody- See Also:
IBody.getParagraphArray(int pos)
-
getTableCell
public XWPFTableCell getTableCell(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTc cell)
get the TableCell which belongs to the TableCell- Specified by:
getTableCellin interfaceIBody- Parameters:
cell-- See Also:
IBody.getTableCell(CTTc cell)
-
getOwner
public POIXMLDocumentPart getOwner()
-
insertNewTbl
public XWPFTable insertNewTbl(org.apache.xmlbeans.XmlCursor cursor)
Description copied from interface:IBodyinserts a new Table at the cursor position.- Specified by:
insertNewTblin interfaceIBody- Parameters:
cursor-- Returns:
- the inserted table
- See Also:
IBody.insertNewTbl(XmlCursor cursor)
-
insertNewParagraph
public XWPFParagraph insertNewParagraph(org.apache.xmlbeans.XmlCursor cursor)
add a new paragraph at position of the cursor- Specified by:
insertNewParagraphin interfaceIBody- Parameters:
cursor-- Returns:
- the inserted paragraph
- See Also:
IBody.insertNewParagraph(XmlCursor cursor)
-
addNewTbl
public XWPFTable addNewTbl(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTbl table)
add a new table to the end of the footnote- Parameters:
table-- Returns:
- the added XWPFTable
-
addNewParagraph
public XWPFParagraph addNewParagraph(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTP paragraph)
add a new paragraph to the end of the footnote- Parameters:
paragraph-- Returns:
- the added XWPFParagraph
-
getXWPFDocument
public XWPFDocument getXWPFDocument()
Description copied from interface:IBodyReturn XWPFDocument- Specified by:
getXWPFDocumentin interfaceIBody- See Also:
IBody.getXWPFDocument()
-
getPart
public POIXMLDocumentPart getPart()
returns the Part, to which the body belongs, which you need for adding relationship to other parts- Specified by:
getPartin interfaceIBody- Returns:
- the Part, to which the body belongs
- See Also:
IBody.getPart()
-
getPartType
public BodyType getPartType()
get the PartType of the body- Specified by:
getPartTypein interfaceIBody- Returns:
- the PartType of the body
- See Also:
IBody.getPartType()
-
-
DataMelt 3.0 © DataMelt by jWork.ORG