Top Description Fields Constructors Methods
org.apache.commons.compress.harmony.pack200

public Class Pack200PackerAdapter

extends Pack200Adapter
implements Packer
Class Inheritance
All Implemented Interfaces
org.apache.commons.compress.java.util.jar.Pack200.Packer
Imports
java.io.IOException, .OutputStream, java.util.jar.JarFile, .JarInputStream, org.apache.commons.compress.java.util.jar.Pack200.Packer, org.apache.commons.compress.utils.ParsingUtils

This class provides the binding between the standard Pack200 interface and the internal interface for (un)packing. As this uses generics for the SortedMap, this class must be compiled and run on a Java 1.5 system. However, Java 1.5 is not necessary to use the internal libraries for unpacking.

Field Summary

Modifier and TypeField and Description
private final PackingOptions
Inherited from org.apache.commons.compress.harmony.pack200.Pack200Adapter:
DEFAULT_BUFFER_SIZE

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
protected void
firePropertyChange(final String
name of property being updated
propertyName
,
final Object
old property value
oldValue
,
final Object
new property value
newValue
)

Overrides org.apache.commons.compress.harmony.pack200.Pack200Adapter.firePropertyChange.

Reports a property update to listeners
public void
pack(final JarFile
JAR file to be compressed.
file
,
final OutputStream
stream of compressed data.
out
)

Implements org.apache.commons.compress.java.util.jar.Pack200.Packer.pack.

Packs the specified JAR file to the specified output stream.
public void
pack(final JarInputStream
stream of uncompressed JAR data.
in
,
final OutputStream
stream of compressed data.
out
)

Implements org.apache.commons.compress.java.util.jar.Pack200.Packer.pack.

Packs the data from the specified jar input stream to the specified output stream.
Inherited from org.apache.commons.compress.harmony.pack200.Pack200Adapter:
addPropertyChangeListenercompletedpropertiesremovePropertyChangeListener

Field Detail

optionsback to summary
private final PackingOptions options

Constructor Detail

Pack200PackerAdapterback to summary
public Pack200PackerAdapter()

Method Detail

firePropertyChangeback to summary
protected void firePropertyChange(final String propertyName, final Object oldValue, final Object newValue) throws IOException

Overrides org.apache.commons.compress.harmony.pack200.Pack200Adapter.firePropertyChange.

Doc from org.apache.commons.compress.harmony.pack200.Pack200Adapter.firePropertyChange.

Reports a property update to listeners

Parameters
propertyName:String

name of property being updated

oldValue:Object

old property value

newValue:Object

new property value

Annotations
@Override
Exceptions
IOException:
if the values cannot be parsed
packback to summary
public void pack(final JarFile file, final OutputStream out) throws IOException

Implements org.apache.commons.compress.java.util.jar.Pack200.Packer.pack.

Doc from org.apache.commons.compress.java.util.jar.Pack200.Packer.pack.

Packs the specified JAR file to the specified output stream.

Parameters
file:JarFile

JAR file to be compressed.

out:OutputStream

stream of compressed data.

Annotations
@Override
Exceptions
IOException:
if I/O exception occurs.
packback to summary
public void pack(final JarInputStream in, final OutputStream out) throws IOException

Implements org.apache.commons.compress.java.util.jar.Pack200.Packer.pack.

Doc from org.apache.commons.compress.java.util.jar.Pack200.Packer.pack.

Packs the data from the specified jar input stream to the specified output stream.

Parameters
in:JarInputStream

stream of uncompressed JAR data.

out:OutputStream

stream of compressed data.

Annotations
@Override
Exceptions
IOException:
if I/O exception occurs.