public class TimedSocket
extends java.lang.Object
| Constructor and Description |
|---|
TimedSocket() |
| Modifier and Type | Method and Description |
|---|---|
static java.net.Socket |
getSocket(java.net.InetAddress addr,
int port,
int delay)
Attempts to connect to a service at the specified address and port, for a specified maximum amount of time.
|
static java.net.Socket |
getSocket(java.lang.String host,
int port,
int delay)
Attempts to connect to a service at the specified address and port, for a specified maximum amount of time.
|
static void |
main(java.lang.String[] args) |
public static java.net.Socket getSocket(java.net.InetAddress addr,
int port,
int delay)
throws java.io.InterruptedIOException,
java.io.IOException
java.io.InterruptedIOExceptionjava.io.IOExceptionpublic static java.net.Socket getSocket(java.lang.String host,
int port,
int delay)
throws java.io.InterruptedIOException,
java.io.IOException
java.io.InterruptedIOExceptionjava.io.IOExceptionpublic static void main(java.lang.String[] args)
throws java.lang.Exception
java.lang.Exception