public final class PackagePropertiesUnmarshaller extends java.lang.Object implements PartUnmarshaller
Modifier and Type | Field and Description |
---|---|
protected static java.lang.String |
KEYWORD_CATEGORY |
protected static java.lang.String |
KEYWORD_CONTENT_STATUS |
protected static java.lang.String |
KEYWORD_CONTENT_TYPE |
protected static java.lang.String |
KEYWORD_CREATED |
protected static java.lang.String |
KEYWORD_CREATOR |
protected static java.lang.String |
KEYWORD_DESCRIPTION |
protected static java.lang.String |
KEYWORD_IDENTIFIER |
protected static java.lang.String |
KEYWORD_KEYWORDS |
protected static java.lang.String |
KEYWORD_LANGUAGE |
protected static java.lang.String |
KEYWORD_LAST_MODIFIED_BY |
protected static java.lang.String |
KEYWORD_LAST_PRINTED |
protected static java.lang.String |
KEYWORD_MODIFIED |
protected static java.lang.String |
KEYWORD_REVISION |
protected static java.lang.String |
KEYWORD_SUBJECT |
protected static java.lang.String |
KEYWORD_TITLE |
protected static java.lang.String |
KEYWORD_VERSION |
Constructor and Description |
---|
PackagePropertiesUnmarshaller() |
Modifier and Type | Method and Description |
---|---|
void |
checkElementForOPCCompliance(org.w3c.dom.Element el)
Check the element for the following OPC compliance rules:
|
PackagePart |
unmarshall(UnmarshallContext context,
java.io.InputStream in)
Save the content of the package in the stream
|
protected static final java.lang.String KEYWORD_CATEGORY
protected static final java.lang.String KEYWORD_CONTENT_STATUS
protected static final java.lang.String KEYWORD_CONTENT_TYPE
protected static final java.lang.String KEYWORD_CREATED
protected static final java.lang.String KEYWORD_CREATOR
protected static final java.lang.String KEYWORD_DESCRIPTION
protected static final java.lang.String KEYWORD_IDENTIFIER
protected static final java.lang.String KEYWORD_KEYWORDS
protected static final java.lang.String KEYWORD_LANGUAGE
protected static final java.lang.String KEYWORD_LAST_MODIFIED_BY
protected static final java.lang.String KEYWORD_LAST_PRINTED
protected static final java.lang.String KEYWORD_MODIFIED
protected static final java.lang.String KEYWORD_REVISION
protected static final java.lang.String KEYWORD_SUBJECT
protected static final java.lang.String KEYWORD_TITLE
protected static final java.lang.String KEYWORD_VERSION
public PackagePart unmarshall(UnmarshallContext context, java.io.InputStream in) throws InvalidFormatException, java.io.IOException
PartUnmarshaller
unmarshall
in interface PartUnmarshaller
in
- The input stream from which the part will be read.InvalidFormatException
- If the data can not be interpreted correctlyjava.io.IOException
- if reading from the stream failspublic void checkElementForOPCCompliance(org.w3c.dom.Element el) throws InvalidFormatException
Rule M4.2: A format consumer shall consider the use of the Markup Compatibility namespace to be an error.
Rule M4.3: Producers shall not create a document element that contains
refinements to the Dublin Core elements, except for the two specified in
the schema:
Rule M4.4: Producers shall not create a document element that contains the xml:lang attribute. Consumers shall consider a document element that violates this constraint to be an error.
Rule M4.5: Producers shall not create a document element that contains
the xsi:type attribute, except for a
InvalidFormatException
Copyright 2020 The Apache Software Foundation or its licensors, as applicable.