2002-09-10 Michael Koch <konqueror@gmx.de>

* java/net/SocketImpl.java
	(connect): New method.
	(supportsUrgentData): New method.
	(sendUrgentData): New method.
	* java/net/PlainSocketImpl.java
	(connect): One new method and two new implementation.
	(sendUrgentData): New method.
	* java/natPlainSocketImpl.cc
	(connect): Arguments changed, added support for timeouts.
	(getOption): Another __java_boolean to jboolean.

From-SVN: r57009
This commit is contained in:
Michael Koch 2002-09-10 18:02:02 +00:00 committed by Michael Koch
parent bfae804050
commit a886956a40
4 changed files with 118 additions and 12 deletions

View file

@ -67,10 +67,15 @@ class PlainSocketImpl extends SocketImpl
protected void connect (String host, int port) throws IOException
{
connect(InetAddress.getByName(host), port);
connect (new InetSocketAddress (InetAddress.getByName(host), port), 0);
}
protected native void connect (InetAddress host, int port)
protected void connect (InetAddress host, int port) throws IOException
{
connect (new InetSocketAddress (host, port), 0);
}
protected native void connect (SocketAddress addr, int timeout)
throws IOException;
protected native void bind (InetAddress host, int port) throws IOException;
@ -88,6 +93,8 @@ class PlainSocketImpl extends SocketImpl
protected native void close () throws IOException;
protected native void sendUrgentData(int data)
throws IOException;
// Stream handling.