summaryrefslogtreecommitdiffstats
path: root/libjava/java/util
diff options
context:
space:
mode:
Diffstat (limited to 'libjava/java/util')
-rw-r--r--libjava/java/util/zip/ZipEntry.java7
-rw-r--r--libjava/java/util/zip/ZipFile.java9
-rw-r--r--libjava/java/util/zip/ZipInputStream.java6
-rw-r--r--libjava/java/util/zip/ZipOutputStream.java17
4 files changed, 19 insertions, 20 deletions
diff --git a/libjava/java/util/zip/ZipEntry.java b/libjava/java/util/zip/ZipEntry.java
index aa14bd27e09..9e0ac310ef1 100644
--- a/libjava/java/util/zip/ZipEntry.java
+++ b/libjava/java/util/zip/ZipEntry.java
@@ -1,4 +1,4 @@
-/* java.util.zip.ZipEntry
+/* ZipEntry.java --
Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc.
This file is part of GNU Classpath.
@@ -71,15 +71,14 @@ public class ZipEntry implements ZipConstants, Cloneable
int flags; /* used by ZipOutputStream */
int offset; /* used by ZipFile and ZipOutputStream */
-
/**
* Compression method. This method doesn't compress at all.
*/
- public final static int STORED = 0;
+ public static final int STORED = 0;
/**
* Compression method. This method uses the Deflater.
*/
- public final static int DEFLATED = 8;
+ public static final int DEFLATED = 8;
/**
* Creates a zip entry with the given name.
diff --git a/libjava/java/util/zip/ZipFile.java b/libjava/java/util/zip/ZipFile.java
index 1f9ab5ed5ee..c95a34d6b4e 100644
--- a/libjava/java/util/zip/ZipFile.java
+++ b/libjava/java/util/zip/ZipFile.java
@@ -148,7 +148,7 @@ public class ZipFile implements ZipConstants
* @exception IOException if a i/o error occured.
* @exception EOFException if the file ends prematurely
*/
- private final int readLeShort(DataInput di, byte[] b) throws IOException
+ private int readLeShort(DataInput di, byte[] b) throws IOException
{
di.readFully(b, 0, 2);
return (b[0] & 0xff) | (b[1] & 0xff) << 8;
@@ -165,14 +165,13 @@ public class ZipFile implements ZipConstants
* @exception IOException if a i/o error occured.
* @exception EOFException if the file ends prematurely
*/
- private final int readLeInt(DataInput di, byte[] b) throws IOException
+ private int readLeInt(DataInput di, byte[] b) throws IOException
{
di.readFully(b, 0, 4);
return ((b[0] & 0xff) | (b[1] & 0xff) << 8)
| ((b[2] & 0xff) | (b[3] & 0xff) << 8) << 16;
}
-
/**
* Read an unsigned short in little endian byte order from the given
* byte buffer at the given offset.
@@ -181,7 +180,7 @@ public class ZipFile implements ZipConstants
* @param off the offset to read from.
* @return The value read.
*/
- private final int readLeShort(byte[] b, int off)
+ private int readLeShort(byte[] b, int off)
{
return (b[off] & 0xff) | (b[off+1] & 0xff) << 8;
}
@@ -194,7 +193,7 @@ public class ZipFile implements ZipConstants
* @param off the offset to read from.
* @return The value read.
*/
- private final int readLeInt(byte[] b, int off)
+ private int readLeInt(byte[] b, int off)
{
return ((b[off] & 0xff) | (b[off+1] & 0xff) << 8)
| ((b[off+2] & 0xff) | (b[off+3] & 0xff) << 8) << 16;
diff --git a/libjava/java/util/zip/ZipInputStream.java b/libjava/java/util/zip/ZipInputStream.java
index 40ba8055b51..3cc67516e2a 100644
--- a/libjava/java/util/zip/ZipInputStream.java
+++ b/libjava/java/util/zip/ZipInputStream.java
@@ -106,7 +106,7 @@ public class ZipInputStream extends InflaterInputStream implements ZipConstants
}
}
- private final int readLeByte() throws IOException
+ private int readLeByte() throws IOException
{
if (avail <= 0)
{
@@ -120,7 +120,7 @@ public class ZipInputStream extends InflaterInputStream implements ZipConstants
/**
* Read an unsigned short in little endian byte order.
*/
- private final int readLeShort() throws IOException
+ private int readLeShort() throws IOException
{
return readLeByte() | (readLeByte() << 8);
}
@@ -128,7 +128,7 @@ public class ZipInputStream extends InflaterInputStream implements ZipConstants
/**
* Read an int in little endian byte order.
*/
- private final int readLeInt() throws IOException
+ private int readLeInt() throws IOException
{
return readLeShort() | (readLeShort() << 16);
}
diff --git a/libjava/java/util/zip/ZipOutputStream.java b/libjava/java/util/zip/ZipOutputStream.java
index 9c3a2c81908..ab1d0ce56a2 100644
--- a/libjava/java/util/zip/ZipOutputStream.java
+++ b/libjava/java/util/zip/ZipOutputStream.java
@@ -1,5 +1,5 @@
-/* java.util.zip.ZipOutputStream
- Copyright (C) 2001 Free Software Foundation, Inc.
+/* ZipOutputStream.java --
+ Copyright (C) 2001, 2004 Free Software Foundation, Inc.
This file is part of GNU Classpath.
@@ -71,17 +71,18 @@ public class ZipOutputStream extends DeflaterOutputStream implements ZipConstant
/**
* Our Zip version is hard coded to 1.0 resp. 2.0
*/
- private final static int ZIP_STORED_VERSION = 10;
- private final static int ZIP_DEFLATED_VERSION = 20;
+ private static final int ZIP_STORED_VERSION = 10;
+ private static final int ZIP_DEFLATED_VERSION = 20;
/**
* Compression method. This method doesn't compress at all.
*/
- public final static int STORED = 0;
+ public static final int STORED = 0;
+
/**
* Compression method. This method uses the Deflater.
*/
- public final static int DEFLATED = 8;
+ public static final int DEFLATED = 8;
/**
* Creates a new Zip output stream, writing a zip archive.
@@ -136,7 +137,7 @@ public class ZipOutputStream extends DeflaterOutputStream implements ZipConstant
/**
* Write an unsigned short in little endian byte order.
*/
- private final void writeLeShort(int value) throws IOException
+ private void writeLeShort(int value) throws IOException
{
out.write(value & 0xff);
out.write((value >> 8) & 0xff);
@@ -145,7 +146,7 @@ public class ZipOutputStream extends DeflaterOutputStream implements ZipConstant
/**
* Write an int in little endian byte order.
*/
- private final void writeLeInt(int value) throws IOException
+ private void writeLeInt(int value) throws IOException
{
writeLeShort(value);
writeLeShort(value >> 16);
OpenPOWER on IntegriCloud