public final class SocketMessage
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
class |
SocketMessage.Event |
static interface |
SocketMessage.EventListener |
Constructor and Description |
---|
SocketMessage(int port,
java.lang.String message)
Try to start a listener on the given port.
|
Modifier and Type | Method and Description |
---|---|
void |
addEventListener(SocketMessage.EventListener l)
Add a EventListener
|
boolean |
isAlreadyRunning()
Was the port already in use?
|
void |
removeEventListener(SocketMessage.EventListener l)
Remove an EventListener.
|
void |
setRaw(boolean raw) |
public SocketMessage(int port, java.lang.String message)
port
- listen on this server port.message
- send this message if port in usepublic void setRaw(boolean raw)
public boolean isAlreadyRunning()
public void addEventListener(SocketMessage.EventListener l)
l
- the listenerpublic void removeEventListener(SocketMessage.EventListener l)
l
- the listener