|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.lwes.listener.ThreadedEnqueuer
org.lwes.listener.DatagramEnqueuer
public class DatagramEnqueuer
This class listens to packets sent via UDP, and enqueues them for processing. It detects multicast addresses and listens to multicast groups if one is detected, otherwise it listens for unicast datagrams.
| Field Summary |
|---|
| Fields inherited from class org.lwes.listener.ThreadedEnqueuer |
|---|
queue |
| Constructor Summary | |
|---|---|
DatagramEnqueuer()
|
|
| Method Summary | |
|---|---|
java.net.InetAddress |
getAddress()
Gets the network address being used for this listener. |
java.net.InetAddress |
getInterface()
Gets the network interface being used for this listener. |
int |
getPort()
Gets the port being used for this listener. |
int |
getTimeToLive()
Returns the multicast TTL (if applicable). |
void |
initialize()
Default initialize() method. |
void |
run()
While running, repeatedly read datagrams and insert them into the queue along with the receipt time and other metadata. |
void |
setAddress(java.net.InetAddress address)
Sets the address being used for this listener. |
void |
setInterface(java.net.InetAddress iface)
Sets the network interface to use for this listener. |
void |
setPort(int port)
Sets the port being used for this listener. |
void |
setTimeToLive(int ttl)
Sets the multicast TTL. |
void |
shutdown()
Default shutdown() method. |
| Methods inherited from class org.lwes.listener.ThreadedEnqueuer |
|---|
getQueue, setQueue |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DatagramEnqueuer()
| Method Detail |
|---|
public java.net.InetAddress getAddress()
public void setAddress(java.net.InetAddress address)
address - the address to usepublic int getPort()
public void setPort(int port)
port - the port numberpublic java.net.InetAddress getInterface()
public void setInterface(java.net.InetAddress iface)
iface - the interfacepublic int getTimeToLive()
public void setTimeToLive(int ttl)
ttl - the multicast TTL value.
public void initialize()
throws java.io.IOException
ThreadedEnqueuer
initialize in class ThreadedEnqueuerjava.io.IOExceptionpublic void shutdown()
ThreadedEnqueuer
shutdown in class ThreadedEnqueuerpublic void run()
run in interface java.lang.Runnablerun in class ThreadedEnqueuer
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||