summaryrefslogtreecommitdiffstats
path: root/libjava/gnu/gcj/util/path/ZipPathEntry.java
diff options
context:
space:
mode:
authortromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4>1999-11-03 19:25:13 +0000
committertromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4>1999-11-03 19:25:13 +0000
commitfa0c0389856cd16537461344b6c44743b84731a2 (patch)
treeceb7d28c254b76b64efc3bb9f90d8b4d41262884 /libjava/gnu/gcj/util/path/ZipPathEntry.java
parentc7f30ba623007a4ca24fb998a2f98ae55595ca31 (diff)
downloadppe42-gcc-fa0c0389856cd16537461344b6c44743b84731a2.tar.gz
ppe42-gcc-fa0c0389856cd16537461344b6c44743b84731a2.zip
Actually removed files which were supposedly
removed a long time ago. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@30379 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/gnu/gcj/util/path/ZipPathEntry.java')
-rw-r--r--libjava/gnu/gcj/util/path/ZipPathEntry.java86
1 files changed, 0 insertions, 86 deletions
diff --git a/libjava/gnu/gcj/util/path/ZipPathEntry.java b/libjava/gnu/gcj/util/path/ZipPathEntry.java
deleted file mode 100644
index ac0226290a5..00000000000
--- a/libjava/gnu/gcj/util/path/ZipPathEntry.java
+++ /dev/null
@@ -1,86 +0,0 @@
-// ZipPathEntry.java -- search path element for directories
-
-/* Copyright (C) 1999 Cygnus Solutions
-
- This file is part of libgcj.
-
-This software is copyrighted work licensed under the terms of the
-Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
-details. */
-
-/* Author: Kresten Krab Thorup <krab@gnu.org> */
-
-package gnu.gcj.util.path;
-
-import java.util.*;
-import java.util.zip.*;
-import java.io.*;
-import java.net.*;
-
-
-final class ZipPathEntry extends PathEntry {
- final ZipFile zip;
- final URL file;
-
- public String toString () { return zip.getName (); }
-
- ZipPathEntry (File f)
- throws MalformedURLException, ZipException, IOException
- {
- file = new URL ("file", "", f.getPath ());
- zip = new ZipFile (f);
- zip.readDirectory ();
- }
-
- /*
- The url for a zip-file resource is,
-
- <code>file:///path/file.zip#name</code>
-
- Then, it is URLConnection's problem to handle that.
- */
-
- URL getURL (String f) {
-
- ZipEntry ent = zip.getEntry (f);
-
- try {
- if (ent != null)
- return new URL (file, "#"+f);
- else
- return null;
- } catch (IOException x) {
- return null;
- }
- }
-
- InputStream getStream (String f) {
-
- ZipEntry ent = zip.getEntry (f);
-
- try {
- if (ent != null)
- return zip.getInputStream (ent);
- else
- return null;
- } catch (IOException x) {
- return null;
- }
- }
-
- byte[] getBytes (String f) {
- ZipEntry ent = zip.getEntry (f);
-
- try {
- if (ent != null)
- return readbytes (zip.getInputStream (ent),
- (int) ent.getSize ());
- else
- return null;
- } catch (IOException x) {
- return null;
- }
-
- }
-}
-
OpenPOWER on IntegriCloud