Class PackagePropertiesUnmarshaller
- All Implemented Interfaces:
PartUnmarshaller
- Author:
- Julien Chable
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
protected static final String
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Check the element for the following OPC compliance rules:unmarshall
(UnmarshallContext context, InputStream in) Save the content of the package in the stream
-
Field Details
-
KEYWORD_CATEGORY
- See Also:
-
KEYWORD_CONTENT_STATUS
- See Also:
-
KEYWORD_CONTENT_TYPE
- See Also:
-
KEYWORD_CREATED
- See Also:
-
KEYWORD_CREATOR
- See Also:
-
KEYWORD_DESCRIPTION
- See Also:
-
KEYWORD_IDENTIFIER
- See Also:
-
KEYWORD_KEYWORDS
- See Also:
-
KEYWORD_LANGUAGE
- See Also:
-
KEYWORD_LAST_MODIFIED_BY
- See Also:
-
KEYWORD_LAST_PRINTED
- See Also:
-
KEYWORD_MODIFIED
- See Also:
-
KEYWORD_REVISION
- See Also:
-
KEYWORD_SUBJECT
- See Also:
-
KEYWORD_TITLE
- See Also:
-
KEYWORD_VERSION
- See Also:
-
-
Constructor Details
-
PackagePropertiesUnmarshaller
public PackagePropertiesUnmarshaller()
-
-
Method Details
-
unmarshall
public PackagePart unmarshall(UnmarshallContext context, InputStream in) throws InvalidFormatException, IOException Description copied from interface:PartUnmarshaller
Save the content of the package in the stream- Specified by:
unmarshall
in interfacePartUnmarshaller
- Parameters:
in
- The input stream from which the part will be unmarshall.- Returns:
- The part freshly unmarshall from the input stream.
- Throws:
InvalidFormatException
IOException
-
checkElementForOPCCompliance
Check the element for the following OPC compliance rules: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: invalid input: '<'dcterms:created> and invalid input: '<'dcterms:modified> Consumers shall consider a document element that violates this constraint to be an error.
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 invalid input: '<'dcterms:created> or invalid input: '<'dcterms:modified> element where the xsi:type attribute shall be present and shall hold the value dcterms:W3CDTF, where dcterms is the namespace prefix of the Dublin Core namespace. Consumers shall consider a document element that violates this constraint to be an error.
- Throws:
InvalidFormatException
-