aboutsummaryrefslogtreecommitdiff
path: root/libjava/java/net/PlainSocketImpl.java
diff options
context:
space:
mode:
authorMichael Koch <konqueror@gmx.de>2002-09-10 18:02:02 +0000
committerMichael Koch <mkoch@gcc.gnu.org>2002-09-10 18:02:02 +0000
commita886956a40a502e3b7ae25e6b79195985c30a1bf (patch)
treeefa74de037bafc64f9022b0f9ef627af5465a3cb /libjava/java/net/PlainSocketImpl.java
parentbfae804050ac712d29b556ea0cd1f6e06199ae12 (diff)
downloadgcc-a886956a40a502e3b7ae25e6b79195985c30a1bf.zip
gcc-a886956a40a502e3b7ae25e6b79195985c30a1bf.tar.gz
gcc-a886956a40a502e3b7ae25e6b79195985c30a1bf.tar.bz2
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
Diffstat (limited to 'libjava/java/net/PlainSocketImpl.java')
-rw-r--r--libjava/java/net/PlainSocketImpl.java11
1 files changed, 9 insertions, 2 deletions
diff --git a/libjava/java/net/PlainSocketImpl.java b/libjava/java/net/PlainSocketImpl.java
index dd04a14..2b65ba0 100644
--- a/libjava/java/net/PlainSocketImpl.java
+++ b/libjava/java/net/PlainSocketImpl.java
@@ -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.