|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.poi.POIXMLDocumentPart
org.apache.poi.POIXMLDocument
public abstract class POIXMLDocument
| Field Summary | |
|---|---|
static java.lang.String |
CORE_PROPERTIES_REL_TYPE
|
static java.lang.String |
CUSTOM_PROPERTIES_REL_TYPE
|
static java.lang.String |
EXTENDED_PROPERTIES_REL_TYPE
|
static java.lang.String |
OLE_OBJECT_REL_TYPE
|
static java.lang.String |
PACK_OBJECT_REL_TYPE
|
| Fields inherited from class org.apache.poi.POIXMLDocumentPart |
|---|
DEFAULT_XML_OPTIONS |
| Constructor Summary | |
|---|---|
protected |
POIXMLDocument(OPCPackage pkg)
|
| Method Summary | |
|---|---|
protected static OPCPackage |
ensureWriteAccess(OPCPackage pkg)
YK: current implementation of OpenXML4J is funny. |
abstract java.util.List<PackagePart> |
getAllEmbedds()
Get the document's embedded files. |
protected PackagePart |
getCorePart()
|
OPCPackage |
getPackage()
|
POIXMLProperties |
getProperties()
Get the document properties. |
protected PackagePart[] |
getRelatedByType(java.lang.String contentType)
Retrieves all the PackageParts which are defined as relationships of the base document with the specified content type. |
protected static PackagePart |
getTargetPart(OPCPackage pkg,
PackageRelationship rel)
Get the PackagePart that is the target of a relationship. |
protected PackagePart |
getTargetPart(PackageRelationship rel)
Get the PackagePart that is the target of a relationship. |
static boolean |
hasOOXMLHeader(java.io.InputStream inp)
Checks that the supplied InputStream (which MUST support mark and reset, or be a PushbackInputStream) has a OOXML (zip) header at the start of it. |
static OPCPackage |
openPackage(java.lang.String path)
Wrapper to open a package, returning an IOException in the event of a problem. |
void |
write(java.io.OutputStream stream)
Write out this document to an Outputstream. |
| Methods inherited from class org.apache.poi.POIXMLDocumentPart |
|---|
addRelation, commit, createRelationship, createRelationship, createRelationship, getPackagePart, getPackageRelationship, getParent, getRelations, onDocumentCreate, onDocumentRead, onSave, read, removeRelation, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String CORE_PROPERTIES_REL_TYPE
public static final java.lang.String EXTENDED_PROPERTIES_REL_TYPE
public static final java.lang.String CUSTOM_PROPERTIES_REL_TYPE
public static final java.lang.String OLE_OBJECT_REL_TYPE
public static final java.lang.String PACK_OBJECT_REL_TYPE
| Constructor Detail |
|---|
protected POIXMLDocument(OPCPackage pkg)
| Method Detail |
|---|
public static OPCPackage openPackage(java.lang.String path)
throws java.io.IOException
java.io.IOExceptionpublic OPCPackage getPackage()
protected PackagePart getCorePart()
protected PackagePart getTargetPart(PackageRelationship rel)
throws InvalidFormatException
rel - The relationship
InvalidFormatException
protected static PackagePart getTargetPart(OPCPackage pkg,
PackageRelationship rel)
throws InvalidFormatException
rel - The relationshippkg - The package to fetch from
InvalidFormatException
protected PackagePart[] getRelatedByType(java.lang.String contentType)
throws InvalidFormatException
InvalidFormatException
public static boolean hasOOXMLHeader(java.io.InputStream inp)
throws java.io.IOException
inp - An InputStream which supports either mark/reset, or is a PushbackInputStream
java.io.IOException
public POIXMLProperties getProperties()
throws OpenXML4JException,
java.io.IOException,
org.apache.xmlbeans.XmlException
OpenXML4JException
java.io.IOException
org.apache.xmlbeans.XmlException
public abstract java.util.List<PackagePart> getAllEmbedds()
throws OpenXML4JException
OpenXML4JException
protected static OPCPackage ensureWriteAccess(OPCPackage pkg)
throws java.io.IOException
java.io.IOException
public final void write(java.io.OutputStream stream)
throws java.io.IOException
stream - - the java OutputStream you wish to write the XLS to
java.io.IOException - if anything can't be written.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||