org.apache.poi.xslf.usermodel
Class XSLFSheet
java.lang.Object
org.apache.poi.POIXMLDocumentPart
org.apache.poi.xslf.usermodel.XSLFSheet
- Direct Known Subclasses:
- XSLFSlide, XSLFSlideLayout, XSLFSlideMaster
@Beta
public abstract class XSLFSheet
- extends POIXMLDocumentPart
Methods inherited from class org.apache.poi.POIXMLDocumentPart |
addRelation, createRelationship, createRelationship, createRelationship, getPackagePart, getPackageRelationship, getParent, getRelationById, getRelationId, getRelations, getTargetPart, getTargetPart, onDocumentCreate, onDocumentRead, onDocumentRemove, onSave, read, rebase, removeRelation, removeRelation, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
XSLFSheet
public XSLFSheet()
XSLFSheet
public XSLFSheet(PackagePart part,
PackageRelationship rel)
getSlideShow
public XMLSlideShow getSlideShow()
buildShapes
protected java.util.List<XSLFShape> buildShapes(org.openxmlformats.schemas.presentationml.x2006.main.CTGroupShape spTree)
getXmlObject
public abstract org.apache.xmlbeans.XmlObject getXmlObject()
createAutoShape
public XSLFAutoShape createAutoShape()
createFreeform
public XSLFFreeformShape createFreeform()
createTextBox
public XSLFTextBox createTextBox()
createConnector
public XSLFConnectorShape createConnector()
createGroup
public XSLFGroupShape createGroup()
createPicture
public XSLFPictureShape createPicture(int pictureIndex)
createTable
public XSLFTable createTable()
getShapes
public XSLFShape[] getShapes()
removeShape
public boolean removeShape(XSLFShape xShape)
getRootElementName
protected abstract java.lang.String getRootElementName()
getSpTree
protected org.openxmlformats.schemas.presentationml.x2006.main.CTGroupShape getSpTree()
commit
protected final void commit()
throws java.io.IOException
- Description copied from class:
POIXMLDocumentPart
- Save the content in the underlying package part.
Default implementation is empty meaning that the package part is left unmodified.
Sub-classes should override and add logic to marshal the "model" into Ooxml4J.
For example, the code saving a generic XML entry may look as follows:
protected void commit() throws IOException {
PackagePart part = getPackagePart();
OutputStream out = part.getOutputStream();
XmlObject bean = getXmlBean(); //the "model" which holds changes in memory
bean.save(out, DEFAULT_XML_OPTIONS);
out.close();
}
- Overrides:
commit
in class POIXMLDocumentPart
- Throws:
java.io.IOException
copy
public void copy(XSLFSheet src)
- Set the contents of this sheet to be a copy of the source sheet.
- Parameters:
src
- the source sheet to copy data from
Copyright 2011 The Apache Software Foundation or
its licensors, as applicable.