Package eu.europa.esig.dss.asic.common
Class ContainerEntryDocument
java.lang.Object
eu.europa.esig.dss.model.CommonDocument
eu.europa.esig.dss.asic.common.ContainerEntryDocument
- All Implemented Interfaces:
DSSZipEntryDocument
,DSSDocument
,Serializable
Represents an entry within a ZIP archive, containing its metadata and file's content.
This class can be used to create a file entry to be incorporated within an ASiC container
with customized
ZipEntry
metadata (e.g. creation time, compression method, etc.).- See Also:
-
Field Summary
Fields inherited from class eu.europa.esig.dss.model.CommonDocument
digestMap, mimeType, name
-
Constructor Summary
ConstructorDescriptionContainerEntryDocument
(DSSDocument content) Default constructorContainerEntryDocument
(DSSDocument content, DSSZipEntry zipEntry) Constructor with providedDSSZipEntry
-
Method Summary
Modifier and TypeMethodDescriptionReturns ZIP entry wrapper containing metadata about a file within a ZIP-containerOpens aInputStream
on theDSSDocument
contents.void
This method sets the name of theDSSDocument
.Methods inherited from class eu.europa.esig.dss.model.CommonDocument
getDigest, getDigestValue, getMimeType, getName, save, setMimeType, toString, writeTo
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface eu.europa.esig.dss.model.DSSDocument
getDigest, getDigestValue, getMimeType, getName, save, setMimeType, writeTo
-
Constructor Details
-
ContainerEntryDocument
Default constructor- Parameters:
content
-DSSDocument
representing file's content
-
ContainerEntryDocument
Constructor with providedDSSZipEntry
- Parameters:
content
-DSSDocument
representing file's contentzipEntry
-DSSZipEntry
containing metadata about the ZIP entry
-
-
Method Details
-
openStream
Description copied from interface:DSSDocument
Opens aInputStream
on theDSSDocument
contents. The type of theInputStream
depends on the type of theDSSDocument
.- Specified by:
openStream
in interfaceDSSDocument
- Returns:
- an
InputStream
-
setName
Description copied from interface:DSSDocument
This method sets the name of theDSSDocument
.- Specified by:
setName
in interfaceDSSDocument
- Overrides:
setName
in classCommonDocument
- Parameters:
name
- the document name
-
getZipEntry
Description copied from interface:DSSZipEntryDocument
Returns ZIP entry wrapper containing metadata about a file within a ZIP-container- Specified by:
getZipEntry
in interfaceDSSZipEntryDocument
- Returns:
DSSZipEntry
-