public class StaticUDPReceiver
extends java.lang.Object
Constructor and Description |
---|
StaticUDPReceiver()
Create a OSC Receiver finding own port
|
StaticUDPReceiver(int port)
Create a Receiver port
|
Modifier and Type | Method and Description |
---|---|
void |
addListener(net.happybrackets.core.StaticUDPReceiver.UDPPacketListener listener)
Registers a listener that gets informed
about incoming messages.
|
int |
getPort()
Return the port for this server
|
static void |
main(java.lang.String[] args) |
void |
removeListener(net.happybrackets.core.StaticUDPReceiver.UDPPacketListener listener)
Unregisters a listener that gets informed
about incoming messages
|
boolean |
start()
Start listening
|
public StaticUDPReceiver(int port) throws java.io.IOException
port
- the port to receivejava.net.SocketException
- Exception if Unable to open Socketjava.io.IOException
public StaticUDPReceiver() throws java.io.IOException
java.net.SocketException
- Exception if unable to openjava.io.IOException
public void addListener(net.happybrackets.core.StaticUDPReceiver.UDPPacketListener listener)
listener
- the listener to registerpublic void removeListener(net.happybrackets.core.StaticUDPReceiver.UDPPacketListener listener)
listener
- the listener to remove from
the list of notified objects.public int getPort()
public boolean start()
public static void main(java.lang.String[] args)