JarURLConnection.java (getCertificates): New method from Classpath.
* java/net/JarURLConnection.java (getCertificates): New method from Classpath. * java/net/URLClassLoader.java (URLClassLoader): Extends SecureClassLoader. (definePackage): New method from Classpath. (getPermissions): Likewise. (newInstance): Likewise. (findClass): Construct CodeSource for new class (from Classpath). * java/net/SocketImpl.java (shutdownInput, shutdownOutput): New methods. * java/net/URL.java (getUserInfo): New method. (set(String,String,int,String,String,String,String,String)): New method. * java/net/PlainSocketImpl.java (_Jv_SO_KEEPALIVE_): Define. (shutdownInput, shutdownOutput): Declare. * java/net/PlainDatagramSocketImpl.java (_Jv_SO_KEEPALIVE_): Define. * java/net/natPlainSocketImpl.cc (setOption): Handle keepalive. (getOption): Likewise. (shutdownInput): New method. (shutdownOutput): Likewise. * java/net/natPlainDatagramSocketImpl.cc (setOption): Handle keepalive. (getOption): Likewise. * java/net/SocketOptions.java (SO_KEEPALIVE): New constant. * java/net/Socket.java (setKeepAlive): New method. (getKeepAlive): Likewise. (shutdownInput, shutdownOutput): New methods. From-SVN: r56685
This commit is contained in:
parent
55f49e3d50
commit
4c322bff29
11 changed files with 392 additions and 15 deletions
|
@ -1,4 +1,4 @@
|
|||
/* Copyright (C) 1999, 2000 Free Software Foundation
|
||||
/* Copyright (C) 1999, 2000, 2002 Free Software Foundation
|
||||
|
||||
This file is part of libgcj.
|
||||
|
||||
|
@ -15,6 +15,7 @@ import java.util.zip.*;
|
|||
import java.util.Map;
|
||||
import java.util.Vector;
|
||||
import java.util.Hashtable;
|
||||
import java.security.cert.Certificate;
|
||||
|
||||
/**
|
||||
* @author Kresten Krab Thorup <krab@gnu.org>
|
||||
|
@ -316,4 +317,16 @@ public abstract class JarURLConnection extends URLConnection
|
|||
hdrHash.put(key.toLowerCase(), Long.toString(len));
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an array of Certificate objects for the jar file entry specified
|
||||
* by this URL or null if there are none
|
||||
*
|
||||
* @return A Certificate array
|
||||
*
|
||||
* @exception IOException If an error occurs
|
||||
*/
|
||||
public Certificate[] getCertificates() throws IOException
|
||||
{
|
||||
return getJarEntry().getCertificates();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue