public class XSSFPivotCacheRecords extends POIXMLDocumentPart
POIXMLDocumentPart.RelationPart
Modifier | Constructor and Description |
---|---|
|
XSSFPivotCacheRecords() |
protected |
XSSFPivotCacheRecords(PackagePart part)
Creates an XSSFPivotCacheRecords representing the given package part and relationship.
|
Modifier and Type | Method and Description |
---|---|
protected void |
commit()
Save the content in the underlying package part.
|
org.openxmlformats.schemas.spreadsheetml.x2006.main.CTPivotCacheRecords |
getCtPivotCacheRecords() |
protected void |
readFrom(java.io.InputStream is) |
_invokeOnDocumentRead, addRelation, createRelationship, createRelationship, createRelationship, getNextPartNumber, getPackagePart, getParent, getRelationById, getRelationId, getRelationPartById, getRelationParts, getRelations, getTargetPart, isCommited, isCommitted, onDocumentCreate, onDocumentRead, onDocumentRemove, onSave, prepareForCommit, read, rebase, removeRelation, removeRelation, removeRelation, setCommited, setCommitted, toString
@Beta public XSSFPivotCacheRecords()
@Beta protected XSSFPivotCacheRecords(PackagePart part) throws java.io.IOException
part
- - The package part that holds xml data representing this pivot cache records.java.io.IOException
@Beta protected void readFrom(java.io.InputStream is) throws java.io.IOException
java.io.IOException
@Beta @Internal public org.openxmlformats.schemas.spreadsheetml.x2006.main.CTPivotCacheRecords getCtPivotCacheRecords()
@Beta protected void commit() throws java.io.IOException
POIXMLDocumentPart
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(); }
commit
in class POIXMLDocumentPart
java.io.IOException
- a subclass may throw an IOException if the changes can't be committedCopyright 2020 The Apache Software Foundation or its licensors, as applicable.