to top
Android APIs
public class

JarOutputStream

extends ZipOutputStream
java.lang.Object
   ↳ java.io.OutputStream
     ↳ java.io.FilterOutputStream
       ↳ java.util.zip.DeflaterOutputStream
         ↳ java.util.zip.ZipOutputStream
           ↳ java.util.jar.JarOutputStream

Class Overview

The JarOutputStream is used to write data in the JarFile format to an arbitrary output stream

Summary

[Expand]
Inherited Constants
From class java.util.zip.ZipOutputStream
[Expand]
Inherited Fields
From class java.util.zip.DeflaterOutputStream
From class java.io.FilterOutputStream
Public Constructors
JarOutputStream(OutputStream os, Manifest mf)
Constructs a new JarOutputStream using an output stream.
JarOutputStream(OutputStream os)
Constructs a new JarOutputStream using an arbitrary output stream.
Public Methods
void putNextEntry(ZipEntry ze)
Writes the specified ZIP entry to the underlying stream.
[Expand]
Inherited Methods
From class java.util.zip.ZipOutputStream
From class java.util.zip.DeflaterOutputStream
From class java.io.FilterOutputStream
From class java.io.OutputStream
From class java.lang.Object
From interface java.io.Closeable
From interface java.io.Flushable

Public Constructors

public JarOutputStream (OutputStream os, Manifest mf)

Since: API Level 1

Constructs a new JarOutputStream using an output stream. The content of the Manifest must match the JAR entry information written subsequently to the stream.

Parameters
os the OutputStream to write to
mf the Manifest to output for this JAR file.
Throws
IOException if an error occurs creating the JarOutputStream.

public JarOutputStream (OutputStream os)

Since: API Level 1

Constructs a new JarOutputStream using an arbitrary output stream.

Parameters
os the OutputStream to write to.
Throws
IOException if an error occurs creating the JarOutputStream.

Public Methods

public void putNextEntry (ZipEntry ze)

Since: API Level 1

Writes the specified ZIP entry to the underlying stream. The previous entry is closed if it is still open.

Parameters
ze the ZipEntry to write to.
Throws
IOException if an error occurs writing to the entry.
See Also