aboutsummaryrefslogtreecommitdiff
path: root/libjava/java/util/jar/JarFile.java
blob: b36338c218b411e1f392bee0854132a4d03c7a31 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
/* Copyright (C) 1999  Free Software Foundation

   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.  */

package java.util.jar;

import java.util.zip.*;
import java.io.File;

/**
 * Does not implement any of the security.  Just a place holder, so
 * that I can implement URLClassLoader.
 *
 * @author Kresten Krab Thorup <krab@gnu.org>
 * @date August 10, 1999.
 */

public class JarFile extends ZipFile
{
  private boolean verify;

  public JarFile (String file) throws java.io.IOException
  {
    super (file);
  }
    
  public JarFile (File file) throws java.io.IOException
  {
    super (file);
  }

  public JarFile (String file, boolean verify) throws java.io.IOException
  {
    super (file);
    this.verify = verify;
  }
    
  public JarFile (File file, boolean verify) throws java.io.IOException
  {
    super (file);
    this.verify = verify;
  }

  public JarEntry getJarEntry (String name)
  {
    ZipEntry ent = getEntry(name);
    if (ent == null)
      return null;
    else
      return new JarEntry(ent);
  }
}