public class JbaseSocketConnection
extends java.lang.Object
This class handles the connection and communication to a jBASE server over a socket interface using the JbaseMsg protocol. see also JbaseMsg.
Constructor and Description |
---|
JbaseSocketConnection(java.lang.String host,
int port)
Construct and connect to a jBASE host.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
protected void |
connect(java.lang.String host,
int port) |
java.net.SocketAddress |
getRemoteSocketAddress() |
void |
read(JbaseMsg msg) |
void |
write(JbaseMsg msg) |
public JbaseSocketConnection(java.lang.String host, int port) throws java.io.IOException
Construct and connect to a jBASE host.
host
- port
- java.io.IOException
protected void connect(java.lang.String host, int port) throws java.net.UnknownHostException, java.io.IOException
java.net.UnknownHostException
java.io.IOException
public void write(JbaseMsg msg) throws java.io.IOException
java.io.IOException
public void close() throws java.io.IOException
java.io.IOException
public void read(JbaseMsg msg) throws java.io.IOException
java.io.IOException
public java.net.SocketAddress getRemoteSocketAddress()