Imported GNU Classpath 0.92
2006-08-14 Mark Wielaard <mark@klomp.org> Imported GNU Classpath 0.92 * HACKING: Add more importing hints. Update automake version requirement. * configure.ac (gconf-peer): New enable AC argument. Add --disable-gconf-peer and --enable-default-preferences-peer to classpath configure when gconf is disabled. * scripts/makemake.tcl: Set gnu/java/util/prefs/gconf and gnu/java/awt/dnd/peer/gtk to bc. Classify gnu/java/security/Configuration.java as generated source file. * gnu/java/lang/management/VMGarbageCollectorMXBeanImpl.java, gnu/java/lang/management/VMMemoryPoolMXBeanImpl.java, gnu/java/lang/management/VMClassLoadingMXBeanImpl.java, gnu/java/lang/management/VMRuntimeMXBeanImpl.java, gnu/java/lang/management/VMMemoryManagerMXBeanImpl.java, gnu/java/lang/management/VMThreadMXBeanImpl.java, gnu/java/lang/management/VMMemoryMXBeanImpl.java, gnu/java/lang/management/VMCompilationMXBeanImpl.java: New VM stub classes. * java/lang/management/VMManagementFactory.java: Likewise. * java/net/VMURLConnection.java: Likewise. * gnu/java/nio/VMChannel.java: Likewise. * java/lang/Thread.java (getState): Add stub implementation. * java/lang/Class.java (isEnum): Likewise. * java/lang/Class.h (isEnum): Likewise. * gnu/awt/xlib/XToolkit.java (getClasspathTextLayoutPeer): Removed. * javax/naming/spi/NamingManager.java: New override for StackWalker functionality. * configure, sources.am, Makefile.in, gcj/Makefile.in, include/Makefile.in, testsuite/Makefile.in: Regenerated. From-SVN: r116139
This commit is contained in:
parent
abab460491
commit
ac1ed908de
1294 changed files with 99479 additions and 35933 deletions
|
@ -466,7 +466,8 @@ public class HTTPConnection
|
|||
*/
|
||||
synchronized HTTPConnection get(String host,
|
||||
int port,
|
||||
boolean secure)
|
||||
boolean secure,
|
||||
int connectionTimeout, int timeout)
|
||||
{
|
||||
String ttl =
|
||||
SystemProperties.getProperty("classpath.net.http.keepAliveTTL");
|
||||
|
@ -494,7 +495,7 @@ public class HTTPConnection
|
|||
}
|
||||
if (c == null)
|
||||
{
|
||||
c = new HTTPConnection(host, port, secure);
|
||||
c = new HTTPConnection(host, port, secure, connectionTimeout, timeout);
|
||||
c.setPool(this);
|
||||
}
|
||||
return c;
|
||||
|
|
|
@ -65,7 +65,7 @@ import javax.net.ssl.SSLSocketFactory;
|
|||
* @author Chris Burdess (dog@gnu.org)
|
||||
*/
|
||||
public class HTTPURLConnection
|
||||
extends HttpsURLConnection
|
||||
extends HttpsURLConnection
|
||||
implements HandshakeCompletedListener
|
||||
{
|
||||
/*
|
||||
|
@ -346,11 +346,11 @@ public class HTTPURLConnection
|
|||
HTTPConnection connection;
|
||||
if (keepAlive)
|
||||
{
|
||||
connection = HTTPConnection.Pool.instance.get(host, port, secure);
|
||||
connection = HTTPConnection.Pool.instance.get(host, port, secure, getConnectTimeout(), 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
connection = new HTTPConnection(host, port, secure);
|
||||
connection = new HTTPConnection(host, port, secure, 0, getConnectTimeout());
|
||||
}
|
||||
return connection;
|
||||
}
|
||||
|
@ -653,5 +653,27 @@ public class HTTPURLConnection
|
|||
handshakeEvent = event;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the connection timeout speed, in milliseconds, or zero if the timeout
|
||||
* is to be considered infinite.
|
||||
*
|
||||
* Overloaded.
|
||||
*
|
||||
*/
|
||||
public void setConnectTimeout(int timeout)
|
||||
throws IllegalArgumentException
|
||||
{
|
||||
super.setConnectTimeout( timeout );
|
||||
if( connection == null )
|
||||
return;
|
||||
try
|
||||
{
|
||||
connection.getSocket().setSoTimeout( timeout );
|
||||
}
|
||||
catch(IOException se)
|
||||
{
|
||||
// Ignore socket exceptions.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -188,7 +188,7 @@ public final class Connection extends JarURLConnection
|
|||
else if (field.equals("last-modified"))
|
||||
{
|
||||
// Both creating and manipulating dateFormat need synchronization.
|
||||
synchronized (this.getClass())
|
||||
synchronized (Connection.class)
|
||||
{
|
||||
if (dateFormat == null)
|
||||
dateFormat = new SimpleDateFormat
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue