public class RCSSLogFileConnection extends ConnectionBase implements IServerConnection
MONITOR_PORT, REMOTE_SERVER_IP, SERVER_IP, SERVER_PORT
Constructor and Description |
---|
RCSSLogFileConnection(java.io.File file) |
Modifier and Type | Method and Description |
---|---|
void |
establishConnection()
Creates a connection to the server and initializes the input and output
stream
|
java.lang.String |
next() |
void |
sendMessage(byte[] msg)
Sends the passed message to the server
|
void |
startReceiveLoop()
Starts the receive loop that only ends once the socket is shutdown
|
void |
stopReceiveLoop()
Stops the loop of receiving messages and notifying observers after
receiving the next message
|
attach, isConnected
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
isConnected
attach
public java.lang.String next()
public void establishConnection() throws ConnectionException
IServerConnection
establishConnection
in interface IServerConnection
ConnectionException
public void sendMessage(byte[] msg) throws ConnectionException
IServerConnection
sendMessage
in interface IServerConnection
msg
- the message to sendConnectionException
public void startReceiveLoop() throws ConnectionException
IServerConnection
startReceiveLoop
in interface IServerConnection
ConnectionException
- if any connection problem occuredpublic void stopReceiveLoop()
ConnectionBase
stopReceiveLoop
in interface IServerConnection
stopReceiveLoop
in class ConnectionBase