TrueZIP Driver ZIP 7.1

de.schlichtherle.truezip.fs.archive.zip
Class OdfDriver

java.lang.Object
  extended by de.schlichtherle.truezip.fs.FsDriver
      extended by de.schlichtherle.truezip.fs.archive.FsArchiveDriver<E>
          extended by de.schlichtherle.truezip.fs.archive.FsCharsetArchiveDriver<ZipArchiveEntry>
              extended by de.schlichtherle.truezip.fs.archive.zip.ZipDriver
                  extended by de.schlichtherle.truezip.fs.archive.zip.JarDriver
                      extended by de.schlichtherle.truezip.fs.archive.zip.OdfDriver
All Implemented Interfaces:
ZipEntryFactory<ZipArchiveEntry>
Direct Known Subclasses:
CheckedOdfDriver

@Immutable
public class OdfDriver
extends JarDriver

An archive driver which supports building archive files according to the OpenDocument Format Specification (ODF), version 1.1. This driver ensures that the entry named mimetype, if present at all, is always written as the first entry and uses the STORED method rather than the DEFLATED method in the resulting archive file in order to meet the requirements of section 17.4 of the OpenDocument Specification, version 1.1.

Other than this, ODF files are treated like regular JAR files. In particular, this class does not check an ODF file for the existance of the META-INF/manifest.xml entry or any other entry.

When using this driver to create or modify an ODF file, then in order to achieve best performance, the mimetype entry should be created or modified first in order to avoid temp file buffering of any other entries.

Author:
Christian Schlichtherle
See Also:
OdfOutputShop

Field Summary
 
Fields inherited from class de.schlichtherle.truezip.fs.archive.zip.JarDriver
JAR_CHARSET
 
Fields inherited from class de.schlichtherle.truezip.fs.archive.FsArchiveDriver
NO_INPUT_OPTION, NO_OUTPUT_OPTION
 
Constructor Summary
OdfDriver(IOPoolProvider provider)
           
 
Method Summary
 OutputShop<ZipArchiveEntry> newOutputShop(FsModel model, OutputSocket<?> output, InputShop<ZipArchiveEntry> source)
           The implementation in ZipDriver simply forwards the call to ZipDriver.newZipOutputShop(de.schlichtherle.truezip.fs.FsModel, java.io.OutputStream, de.schlichtherle.truezip.fs.archive.zip.ZipInputShop) and wraps the result in a new FsMultiplexedArchiveOutputShop.
 
Methods inherited from class de.schlichtherle.truezip.fs.archive.zip.JarDriver
newEntry, newEntry, newEntry
 
Methods inherited from class de.schlichtherle.truezip.fs.archive.zip.ZipDriver
getLevel, getMethod, getOutputSocket, getPool, getPostambled, getPreambled, newInputShop, newZipInputShop, newZipOutputShop
 
Methods inherited from class de.schlichtherle.truezip.fs.archive.FsCharsetArchiveDriver
assertEncodable, getCharset, toString, toZipOrTarEntryName
 
Methods inherited from class de.schlichtherle.truezip.fs.archive.FsArchiveDriver
getClosedIcon, getInputSocket, getOpenIcon, isFederated, newController, newEntry
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OdfDriver

public OdfDriver(IOPoolProvider provider)
Method Detail

newOutputShop

public OutputShop<ZipArchiveEntry> newOutputShop(FsModel model,
                                                 OutputSocket<?> output,
                                                 InputShop<ZipArchiveEntry> source)
                                          throws IOException
Description copied from class: ZipDriver

The implementation in ZipDriver simply forwards the call to ZipDriver.newZipOutputShop(de.schlichtherle.truezip.fs.FsModel, java.io.OutputStream, de.schlichtherle.truezip.fs.archive.zip.ZipInputShop) and wraps the result in a new FsMultiplexedArchiveOutputShop.

Overrides:
newOutputShop in class ZipDriver
Throws:
IOException

TrueZIP Driver ZIP 7.1

Copyright © 2005-2011 Schlichtherle IT Services. All Rights Reserved.